Final version of stepper motor demo

Dependencies:   Stepper_Motor_X27168 mbed

Fork of Stepper_Motor_Demo by Hanbin Ying

main.cpp

Committer:
agarg45
Date:
2015-10-20
Revision:
0:71dc3ae7e2eb
Child:
1:5de876de6423

File content as of revision 0:71dc3ae7e2eb:

#include "mbed.h"
#include "StepperMotor_X27168.h"

StepperMotor_X27168 smotor(p25, p26, p23, p22);

int main() {

    smotor.step_position(180);
    wait(0.5);
    
    smotor.step_position(100);
    wait(0.5);
    
    smotor.angle_position(270);
    wait(0.5);
    
    smotor.step_position(0);
    wait(0.5);
}