encoder help!

so my team is trying to have encoders control the speed of our flywheel. we want it to spin at X amount of rpm 100% of the time so battery power wont effect it. how do we do this and are there any tips on doing this? thanks!

Firstly, are you using IME’s or shaft encoders? Secondly, the best way of having a constant velocity is to make a velocity control loop like PID or TBH.

Quad optical shaft encoders.

Can you explain what the PID and the TBH are in greater detail.

W O W that was much more than I expected. the only thing that I really got from that is how they are different. (thank you for that) but I would like to know how to program it and which one to use for easy c purposes that I have.

for some reason it wont open is it able to cross from mac to windows?

can that code be used with easyc? if so how do I get what I need from it?

or I can upload my program that I have now so you can look at it and see what I need to change

those are the files I get but when I go to open it, it says
cannot open

this is what I have so far (sorry for quality couldn’t figure out how to take a screenshot)