picolo
Fork of Step_Motor by
Embed:
(wiki syntax)
Show/hide line numbers
Step_Motor.h
00001 #ifndef STEP_MOTOR_H 00002 #define STEP_MOTOR_H 00003 00004 #include "mbed.h" 00005 00006 class stepmotor { 00007 public: 00008 00009 stepmotor(PinName in1, PinName in2, PinName in3, PinName in4, PinName in5,PinName in6, PinName in7, PinName in8); 00010 void step(uint32_t num_steps,uint8_t cw); 00011 void set_speed(int speed); 00012 uint32_t get_speed(); 00013 private: 00014 BusOut motor_out; 00015 uint32_t motorSpeed; 00016 int32_t nstep,nstep2; 00017 uint8_t add; 00018 void move(); 00019 }; 00020 00021 #endif
Generated on Wed Aug 17 2022 10:56:07 by 1.7.2