Go to Post knowing 'my breath stinks' has helped me far more than any thanks and praise I've ever received.. - DonRotolo [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
  #1   Spotlight this post!  
Unread 24-01-2013, 19:49
Self.This() Self.This() is offline
Programmer From Beyond the 4th Wall
AKA: Trent Gamber
FRC #1245 (Shazbots)
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2009
Location: Louisville
Posts: 4
Self.This() is an unknown quantity at this point
Issues with image processing with RoboRealm and Network Tables

Hey guys,

We are having some problems with networking, specifically with communications between the cRIO and RoboRealm. In RoboRealm script, we do our image processing, and then use the Set Variables module to reset the FPS and IMAGE_COUNT variables to /tableName/FPS and /tableName/IMAGE_COUNT to enable use over the network. Then we use the Network_Tables module to send those two variables over the network and to receive variables written in Java, the X value of our joystick and just a static number called test. Finally we display all 4 of those variables over our image so we can compare the values we are getting. We also have the internal version of the IMAGE_COUNT variable displayed, not only the network specific one.

On the Java side, we are using the .getNumber("name", default_value) method to receive the IMAGE_COUNT and FPS values, and then we are using the putNumber("name", default_value) method to send the joystick X value and our static test variable.

We have opened a the table with the getTable("tableName") method, and it matches the name that we rename the variables to with the Set_Variables. We have all of our IP addresses set correctly, and there are communications.

We are getting some very interesting results. On the SmartDashboard and through TableViewer we get strange numbers. The actual IMAGE_COUNT value according to RoboRealms seems to go to the value, and the read FPS value according to RoboRealms does not directly translate to the Java-read IMAGE_COUNT. For example, if RoboRealms says the FPS is 29.4, the IMAGE_COUNT on the SmartDashboard/TableViewer will say it's 58 or something similar. The values do not seem to be related (even though in the given example it seems to be roughly double the FPS).

We can send the test variable and have that displays the correct value in RoboRealm, but we can not get the joystick value to update, it seems to show only the last read value by the joystick before disabling.

So our question is, how do you do successfully send data between Java and RoboRealm? We can post actual code from either end if needed.

Thanks!

-1245 Programmers
__________________
Cro-grammer: Someone whose code is so unreadable, it might as well be a bunch of grunts.
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 11:44.

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