Go to Post We can help FIRST improve the system, but we can't just blame them and wait. - Siri [more]
Home
Go Back   Chief Delphi > Technical > Programming > Java
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #17   Spotlight this post!  
Unread 01-06-2014, 07:20 PM
aaronjeline aaronjeline is offline
Aaron
FRC #1719 (Umbrella Corporation)
Team Role: Programmer
 
Join Date: Nov 2013
Rookie Year: 2013
Location: Baltimore
Posts: 17
aaronjeline is an unknown quantity at this point
Re: Running Smartdashboard without cRIO/robot?

Quote:
Originally Posted by krieck View Post
In your client code you should specify the IP address and also set up for client mode. Try this:
  1. Start the NetworkTableServer
  2. Start up SmartDashboard with -ip 127.0.0.1
  3. Run the client code below


Code:
import edu.wpi.first.wpilibj.networktables.NetworkTable;
import edu.wpi.first.wpilibj.smartdashboard.SmartDashboard;

public class NetworkingOne {

    public static void main(String[] args) {
        NetworkTable.setClientMode();
        NetworkTable.setIPAddress("127.0.0.1");
        SmartDashboard.putNumber("set value", 0);
        double num = SmartDashboard.getNumber("set value");
        NetworkTable.getTable("SmartDashboard").putNumber("share value", num);
    }
}
That's still not working for me. Just trying to pass one int to the smartdashboard. Any ideas?
Reply With Quote
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 06:48 PM.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi