I have heard conflicting stories on the forum about the optical encoder. Can or can’t it be used with the built in PID control?
It can be used, but you need V4.52 or later, pervious versions had a bug. You will need to change the default values and make sure that the encoder count increases with positive control values. See this post from Jan 18 for a little more information.
https://vexforum.com/t/robotc-has-pid-to-control-your-flywheel/31108/1