Magnetic encode with MSP430 board