https://diyprojectslabs.com/rotary-encoder-with-arduino/