View Single Post
  #3   Spotlight this post!  
Unread 23-01-2016, 14:13
fovea1959's Avatar
fovea1959 fovea1959 is offline
Herder of programmers
AKA: Doug Wegscheid
FRC #3620 (The Average Joes)
Team Role: Mentor
 
Join Date: Jan 2011
Rookie Year: 2011
Location: St Joseph
Posts: 336
fovea1959 will become famous soon enough
Re: How to detect missing CAN devices from Java?

Getting

Robot Drive... Output not updated often enough.

when it stutters.

Figuring out way to send code; zip file of project is too large to be a CD attachment.

I suspect the problem may be that all the console messages are swamping the network pipe, so the RIO is missing some DS packets, periodic() doesn't get called for a while, the drive object doesn't get poked for a while, and the safety watchdog fires off. Just conjecture, but will turn off the safeties when I get the chassis back (students are driving....).

We can turn off the logging, but checking to see if we can turn it on and off based on whether the devices are present.

I think a getVersion for the CAN Talon will work to detect it's presence or absence (if I see 0.0, I know it's not there). No documented way to check for presence or version on the PDB.