em3242 hall effect rotary encoder Arduino sketch