![]() |
Robot Code Making Programming Laptop Disconnect
We are getting an extremely weird problem here. When we run a certain version of our code on a practice bot, the robot responds to commands for about a half of a second, then the robot stops and on the programming laptop, a "Lost connection to real time target" message is displayed. If you don't click abort, after about 20 seconds it gets connection for another few seconds, and then loses connection again.
Our setup has two laptops, the 2010 classmate and a windows seven programming laptop our team bought. The programming laptop is running code via pressing the "run" button (not running as startup). I believe the C RIO had some startup code on it, but that was overwritten. Both laptops are connected to the router from the 2011 KOP via their onboard wireless systems. The router connects to Port 1 of the C RIO. We are using CAN for our jaguars, with the black jaguar bridge. With an older version of the code, the robot still runs and everything works perfectly. The newer version has some added functionality though. We can go back and forth between the two, and the older code consistently works, and the newer code consistently doesn't. When the error message appears on the programming laptop, the classmate does not state either a connection or robot code loss (judging from the lights on the driver station). However, the robot does stop responding to driver signals. We have a custom dashboard, but it is only sending back a few things (two or three clusters of 2 numbers each and the array coming out of elapsed times). We are not sending back any camera feed. I don't see what would be starving the connection. As far as I can tell from the limited debug information we're getting (since it freezes so often we don't get much), the teleop loop is not running abnormally slow. Tomorrow, I'll try swapping out each vi individually and see when it breaks. If anybody has any suggestions for what might be happening, please post them. I'll try to get our team leader to upload the robot code on our website, so I'll post the link when that gets up. Otherwise, thanks for helping! |
Re: Robot Code Making Programming Laptop Disconnect
Try disabling the wireless on whichever laptop you aren't currently using. For example, if you are doing a real-time deployment, only use wireless on the laptop that is executing the deployment.
This seemed to solve much of our problems, but we still lost communication occasionally. On a similar note, we seemed to notice that we lost communication more frequently during a real-time deployment when the driver station was open. We didn't look into this much, but it seemed strange to us. |
Re: Robot Code Making Programming Laptop Disconnect
Quote:
Also, using both laptops in the exact same configuration worked fine with a different version of the robot code. |
Re: Robot Code Making Programming Laptop Disconnect
Sounds like an overly saturated CPU -- code demanding too much CPU time.
Try running the System Manager and watching the CPU utilization. |
Re: Robot Code Making Programming Laptop Disconnect
Found the problem - one single loop in periodic tasks didn't have a wait on it. Ugh. I should remember to use the CPU measurer thing (See, I don't even know its name!) more often.
|
| All times are GMT -5. The time now is 03:52. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi