Total control sjoel robot
Dependencies: HIDScope MODSERIAL QEI TextLCD mbed
Mode.cpp
- Committer:
- RichardRoos
- Date:
- 2015-10-20
- Revision:
- 37:090ba5b1e655
- Parent:
- 27:f62e450bb411
File content as of revision 37:090ba5b1e655:
#include "Mode.h" double mode; int Mode(double y, double thresholdlow, double thresholdmid, double thresholdhigh){ if ( y <= thresholdlow){ mode = 1; } if (y > thresholdhigh){ mode = 3; } if (y > thresholdmid && mode == 1){ mode = 2; } return mode; }