06-03-2008 01:54 AM
06-04-2008 10:30 AM
Hi Andi,
What cRIO back plane and controller are you using? Your issue may be that you aren't getting the data from the controller to the FPGA fast enough, as you suggested. If you are using a 901x series controller then you can use DMA's to transfer from the controller to the FPGA which will be very fast. The 900x controllers only support DMA transfers from the FPGA to the controller. Also, you can take a look at this Knowledgebase for some tips on optimizing your FPGA code and reduct resource usage. It might be possible to get your resource usage low enough that you could keep your motor control program on the FPGA. Thanks.
06-05-2008 12:01 AM
06-06-2008 12:26 PM
Andi,
Well...the most elegant solution is the one that fits on your FPGA, but otherwise, it is always good to take out the fat in loops and functions that are just doing basic things. This is why reducing coercions and using the saturation VI's for math functions can be a big help. If you are not waisting space on your FPGA with poorly executed code then you will have room to do the things that simply require more space. I'm not sure what you mean by a Fixed Point PID vs a norman PID module. The PID module has a number of different VI's...did you simply change the VI's you were using?