|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
|||
|
|||
|
Re: Desperately need help optimizing
Have you been to your first competition yet? During practice/qualifying rounds, the staff at the event will let you know if you are having any packet loss. This would be caused most likely by the camera. The camera default frame rate is 30 fps and the may recommend changing it to 10 fps. Does it happen when you are tethered? If it does not, it's probably packet loss across the WiFi.
The other option is what is running in periodictasks.vi. There are different times loops. If you are running something in a fast loop that doesn't give enough control to other parts, maybe it could tie up the CPU. In the driver station, there is a tab where you can view CPU and network utilization stats. Do you know if your CPU is running at close to 100%? I've read that lots of teams are running near 100% at time. |
|
#2
|
|||
|
|||
|
Re: Desperately need help optimizing
If you want to post your code, or pictures of the major code you edited, people will give feedback. You can also ask questions you may have had while writing the code related to performance.
Optimizing code mostly involves measuring it, finding the slowest stuff, or the stuff which is farthest from the time it should execute in, and fixing issues until the performance is what you want. There isn't one problem or one solution. Greg McKaskle |
|
#3
|
|||||
|
|||||
|
Re: Desperately need help optimizing
Quote:
If you look around the internet, you'll find that NI is awesome (what else is new?) and has a few really helpful documents on optimizing your code. http://zone.ni.com/devzone/cda/tut/p/id/3747 http://zone.ni.com/reference/en-XX/h..._memory_usage/ https://decibel.ni.com/content/docs/DOC-15337 http://digital.ni.com/public.nsf/all...256CAB00079F57 http://zone.ni.com/devzone/cda/tut/p/id/11472 Just take some time to go through your code, watch memory/CPU usage closely (it's displayed on the Driver Station 'Charts' tab), and do what you can to bring them down as much as possible. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|