Quote:
Originally Posted by KHall
I would like to ask a general question to the CPU experts:
If we have a 400MHz CPU does that mean 1 machine instruction every 0.0025uS? Lets say for discussions that we can make use of the techniques in the PDF and compensate for the sensor/motor latency. Then if an autonomous robot takes say 1,000,000 machine instructions between 'reactions' does that mean it can implement changes to its behavior every 2.5mS?
|
The IFI speed controllers have a maximum update rate of around 120hz. No one knows what we will be using in the future, but that has been a limitation in the past. See this page for more details:
http://www.ifirobotics.com/forum/viewtopic.php?t=303
Most CPUs do not execute 1 instruction per cycle, instead, each instruction can take different amounts of cycles to execute. And, things that might seem like 1 instruction (eg one operation in C) can be many machine instructions. PICs are designed for one cycle per operation, so you can add two 8 bit values in operation because there is an instruction for that. But, you can't add two 32 bit numbers in one operation, because there isn't an instruction for that. Instead, the C compiler, when you write something that is a long + a long generates many instructions to complete that one operation.
It's even harder to figure out when you have a highly abstracted language (Labview) and an operating system (VxWorks). On the other hand, with a real time OS, you should be able to schedule tasks and make sure your calculations run at a set rate (at the expense of lower priority tasks).
Overall, your project is very ambitious, but is a great learning experience in real robotics. I work with GPS/Navigation and a lot of time goes into tuning a Kalman filter (although I've never dealt with them directly).