![]() |
JAVA Printing
Hello,
Is there any way to print something from the code and have it display to the user? Tired System.out.print(); and didn't see anything come up. Thanks in advance :) |
Re: JAVA Printing
public void output(String text){
System.out.println(text); } |
Re: JAVA Printing
That prints to the Net Beans console, useful for debugging, not so useful in competition though. Does any one know how to print to the Drive Station console?
|
Re: JAVA Printing
printing to the driver station you only have 7 lines or so, and you have to replace previous lines. So utilizing it for debugging is a little difficult.
it doesnt work like a typical printf where you can keep going. |
Re: JAVA Printing
To output text to the Driver Station, you must create a DriverStationLCD object. Once it has been initialized, lines can be outputted using:
Code:
[DriverStationLCD object name].println(DriverStationLCD.Line.[line], |
Re: JAVA Printing
Ah, yes that worked. For some reason I got a null pointer exception when I tried that before. It worked now though. Thanks!
|
| All times are GMT -5. The time now is 10:38. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi