Close

PID controller in Amaranth HDL / FPGA

A project log for prism laser scanner

bringing additive manufacturing to the next level

hexastormHexastorm 01/31/2023 at 11:572 Comments

I finished the PI controller. Speed seems very stable like 1998-2002 RPM when the target is 2000 RPM. Next step is to restructure the code base and add laser measurments.

Discussions

Hexastorm wrote 02/02/2023 at 10:54 point

This indeed is very key. As said, I now count if I have seen six magnets. This was more accurate than one specific magnet. A measurement mistake results in an error of 1/6 and not a full cycle.
There are variations in strength and position. These are however very constant. I am surprised by this as well. I now solve this via an interpolation table.

  Are you sure? yes | no

Gravis wrote 02/02/2023 at 02:22 point

Nice! I hope this level of stability is sufficient but if not, it's still a good start.  Just a thought but if you are reading a hall sensor then keep track of rotation using the same magnet. Minor variations in the positioning and/or the strength of the magnets could result in varying trigger times.

  Are you sure? yes | no