Go to Post Our robotics lab has been closed for two days, TWO DAYS! :ahh: - Kevin Selavko [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
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
  #5   Spotlight this post!  
Unread 18-02-2013, 12:36
jwhite jwhite is offline
Registered User
FRC #2823
Team Role: Mentor
 
Join Date: Feb 2013
Rookie Year: 2013
Location: Saint Paul, MN
Posts: 69
jwhite is an unknown quantity at this point
Re: New SmartDashboard installer

Quote:
Originally Posted by bob.wolff68 View Post
Jeremy,
I'm going to read some tea leaves here on your PutNumber crash with a boolean and I may or may not hit the mark... we saw an issue (and have reported it) which would crash smartdashboard/network tables and the robot consistently...

1) int i = 5; SmartDashboard:utNumber("MyLocation", i); // This works and must be done once to induce the crash - put a non-boolean into a named location...

2) bool i = false; SmartDashboard:utNumber("MyLocation", i); // This crashes consistently - the change from an int to a bool leaves someone with the "wrong expectation" of what type will actually be used.

// And here's the fix... don't re-use "MyLocation" with different types - in fact if you want to be sure, make sure you name your locations based on what type they will wind up receiving - "bool_MyLocation" and "int_MyLocation"
3) bool i = false; SmartDashboard:utNumber("differentLocation", i); // This works just fine.

bob
Yes, I think your instinct is sound; I was suspecting something along those lines. Although note that our case uses PutBoolean, and I'm not sure that the programmers were reusing variables. We're going to try playing with this a bit, and seeing if adding an exception handler around the PutNumber calls prevents the robot code from dying at the least. Losing your camera is bad, losing your whole robot is catastrophic...

Presumably, there is some xml or other config file on the Driver Station somewhere that can be deleted to 'forget' that information, right? I'll have them try to find that and see if deleting it eases some of this pain.

One of my programmers has a hunch that sending too many variables, too fast, is another source of trouble. I think that's just superstition on his part, but I thought I'd mention it to anyone else losing hair over this.

Cheers,

Jeremy
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 03:31.

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