Very simple reading of encoders
Beter encoding routine.