Test the set param mode
Diff: PositionSensor/PositionSensor.cpp
- Revision:
- 48:74a40481740c
- Parent:
- 47:e1196a851f76
- Child:
- 52:8e74c22ed89f
--- a/PositionSensor/PositionSensor.cpp Wed Dec 05 04:07:46 2018 +0000 +++ b/PositionSensor/PositionSensor.cpp Sun Mar 03 02:51:51 2019 +0000 @@ -30,7 +30,7 @@ //raw = spi->write(readAngleCmd); //raw &= 0x3FFF; raw = spi->write(0); - raw = raw>>1; //Extract last 14 bits + raw = raw>>2; //Extract last 14 bits GPIOA->ODR |= (1 << 15); int off_1 = offset_lut[raw>>7]; int off_2 = offset_lut[((raw>>7)+1)%128];