View Single Post
  #3   Spotlight this post!  
Unread 08-02-2011, 01:59
jhersh jhersh is offline
National Instruments
AKA: Joe Hershberger
FRC #2468 (Appreciate)
Team Role: Mentor
 
Join Date: May 2008
Rookie Year: 1997
Location: Austin, TX
Posts: 1,006
jhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond repute
Re: Using the cRIO serial port in Java

Quote:
Originally Posted by Daniel View Post
I am looking for a Jave code snippet of how to configure the cRIO serial port and how to use it. Can it take over the System.Out functionality?

I am also looking for code to do formatted number to string conversion. Is there any native Java class? I need something simple. I do not need all of the Swing overhead.

I am planning on sending data out the cRIO serial port into a PC running HyperTerminal to make an elaborate disgnostic screen. I will send it ANSI escape sequences to control the cursor. I've done this in C and it is a great tool for the team to maintain the robot.

Daniel
If you switch the CONSOLE OUT DIP switch off, the serial port will not be controlled by the System.out. You can then use the SerialPort class in WPILib to access the port.

Have you considered using a TCP connection to the PC instead?

-Joe