Rotary Encoder script

Script with two functions:
- get_button_state
- get_rotation_state

Determining if the rotation is left or right and if the button is
pressed.