Different outcome when using different OS (Mac and Windows) #2134
Replies: 1 comment
-
|
Can you share your relevant control loop? It's a good idea to have at least some kind of wait in the loop, such as while True:
apply_pid() # Now it gets called about 100 times per second
wait(10) # Here it has time for things like Bluetooth connectivity, etc.If you have a loop like this: while True:
apply_pid()Then it gets called "as fast as possible". This sounds great, but it really isn't. It could be 1,000x per second or 10,000x per second depending on how busy your hub is with other things like Bluetooth. If your code doesn't take this into account (for example like when computing the D in your PID), then your performance is not going to be constant. It is usually better to aim for consistency. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I am been experiencing a weird thing ever since the 3.6.0 update. I been experiencing weird movement in my PID followline with drivebase, it seems like it was not as responsive as before. I tried the same program with the same robot but on 2 different OS which is Mac and Windows, i found out that with Mac OS it runs perfectly fine and smoothly but on Windows OS it shows a way different outcome, not showing any PID function for the followline. I have experimented with 4 Windows device and 2 Mac device and outcome has been the same. On the other hand i would like to ask if we are able to revert to older versions of pybricks just in case anything like this happen before the competition to ensure the stability of my robot. Hope to get a answer!
Beta Was this translation helpful? Give feedback.
All reactions