Mini Cheetah Actuator Branch Superseded by: https://github.com/bgkatz/motorcontrol
Dependencies: mbed-dev-f303 FastPWM3
Superseded by: https://github.com/bgkatz/motorcontrol
Diff: PositionSensor/PositionSensor.h
- Revision:
- 56:fe5056ac6740
- Parent:
- 47:e1196a851f76
diff -r c4c9fec8539c -r fe5056ac6740 PositionSensor/PositionSensor.h --- a/PositionSensor/PositionSensor.h Fri Oct 04 14:18:39 2019 +0000 +++ b/PositionSensor/PositionSensor.h Thu Oct 10 15:03:12 2019 +0000 @@ -35,7 +35,7 @@ //DigitalOut *ZTest; virtual void ZeroEncoderCount(void); virtual void ZeroEncoderCountDown(void); - int _CPR, flag, rotations, _ppairs, raw; + int _CPR, flag, rotations, _ppairs, raw, first_sample; //int state; float _offset, MechPosition, MechOffset, dir, test_pos, oldVel, out_old, velVec[40]; int offset_lut[128]; @@ -58,7 +58,7 @@ virtual void WriteLUT(int new_lut[128]); private: float position, ElecPosition, ElecOffset, MechPosition, MechOffset, modPosition, oldModPosition, oldVel, velVec[40], MechVelocity, ElecVelocity, ElecVelocityFilt; - int raw, _CPR, rotations, old_counts, _ppairs; + int raw, _CPR, rotations, old_counts, _ppairs, first_sample; SPI *spi; DigitalOut *cs; int readAngleCmd;