c
Dependencies: Servo ServoArm mbed
Fork of PES_PIXY_Official by
Diff: Sources/Arm.cpp
- Revision:
- 1:fd3cef0f116d
- Parent:
- 0:15a8480061e8
--- a/Sources/Arm.cpp Mon May 22 11:24:46 2017 +0000 +++ b/Sources/Arm.cpp Tue May 23 16:24:49 2017 +0000 @@ -70,26 +70,30 @@ int Arm::backToDown(){ static float pos = RELEASE_POS; + static int i=0; if( pos > TAKE_POS ){ - pos -= 0.0015f; + pos -= 3; this->arm->position(pos); return 0; } else{ - pos = RELEASE_POS; + //pos = RELEASE_POS; + return 1; } } int Arm::downToBack(){ static float pos = TAKE_POS; + static int i=0; if( pos < RELEASE_POS ){ - pos += 0.0015f; + pos += 5; this->arm->position(pos); return 0; } else{ - pos = TAKE_POS; + //pos = TAKE_POS; + return 1; } } \ No newline at end of file