View Single Post
  #7   Spotlight this post!  
Unread 25-04-2016, 16:19
Rsave7 Rsave7 is offline
Memer
AKA: Ryan
FRC #0379 (The RoboCats)
Team Role: Programmer
 
Join Date: Feb 2015
Rookie Year: 2015
Location: Ohio, United States
Posts: 6
Rsave7 is an unknown quantity at this point
Re: Moderate Lag With Dashboard

Quote:
Originally Posted by Greg McKaskle View Post
Several of the tabs are Bound to network variables and update bidirectionally at 10Hz or whatever the rate that the client is run at. The first loop, however, runs at whatever rate you determine, and variables placed there, could run much faster or much slower depending on if the loop has a large delay or a large amount of work to do.

The next thing I'd do is to probe the i terminal of the first loop and see if it goes up by 10 per second, 1 per second, or seconds per increment. You can drop timers and be more precise, but this is usually a good start.

You may have lots of stuff running in the top loop and you may want to separate some of your network variables out. If you have a simple binding other tabs may make sense. Otherwise, you can keep them and move the expensive/slow stuff out of the top loop.

Greg McKaskle
So i probed the iteration terminal with the code running but i couldn't do it with it connected to the robot because the team was doing stuff with it and such but i observed that it runs every 4 or 5 milliseconds so it seems like its running pretty fast and i couldn't actually find the wait so i think its just running as fast as it can. Would that be a problem?

I also noticed that while tethered via Ethernet to the robot that the dashboard values don't actually lag; only when it is wireless is when it lags so maybe a bandwidth problem? i mean i don't see how we would be using up too much bandwidth but i guess it could be possible?

I uploaded our code to google drive, this was my first time doing this so please let me know if i did it wrong.

https://drive.google.com/open?id=0B9...0p2TUtXV3RKVVk
__________________
“Scientists discover the world that exists; engineers create the world that never was.”

― Theodore von Karman
Reply With Quote