謙一 永井
/
SRC2018Auto
0910
MotorDrive.h@1:5f5d47a593bc, 2019-09-10 (annotated)
- Committer:
- kenboh
- Date:
- Tue Sep 10 09:30:41 2019 +0000
- Revision:
- 1:5f5d47a593bc
- Parent:
- 0:2a0c62e53e9c
SRC2018Auto
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Hase_jun | 0:2a0c62e53e9c | 1 | #include "mbed.h" |
Hase_jun | 0:2a0c62e53e9c | 2 | /* |
Hase_jun | 0:2a0c62e53e9c | 3 | void morter1(char,float); |
Hase_jun | 0:2a0c62e53e9c | 4 | void morter2(char,float); |
Hase_jun | 0:2a0c62e53e9c | 5 | void morter3(char,float); |
Hase_jun | 0:2a0c62e53e9c | 6 | */ |
Hase_jun | 0:2a0c62e53e9c | 7 | //void motor(); |
Hase_jun | 0:2a0c62e53e9c | 8 | //void motor(int,char,float); |
Hase_jun | 0:2a0c62e53e9c | 9 | |
Hase_jun | 0:2a0c62e53e9c | 10 | enum direction_of_rotation{ |
Hase_jun | 0:2a0c62e53e9c | 11 | CW, |
Hase_jun | 0:2a0c62e53e9c | 12 | CCW, |
Hase_jun | 0:2a0c62e53e9c | 13 | STOP |
Hase_jun | 0:2a0c62e53e9c | 14 | }; |
Hase_jun | 0:2a0c62e53e9c | 15 | |
Hase_jun | 0:2a0c62e53e9c | 16 | typedef enum{ |
Hase_jun | 0:2a0c62e53e9c | 17 | LIMITSWITCH, |
Hase_jun | 0:2a0c62e53e9c | 18 | MAINSWITCH |
Hase_jun | 0:2a0c62e53e9c | 19 | }SW; |
Hase_jun | 0:2a0c62e53e9c | 20 | |
Hase_jun | 0:2a0c62e53e9c | 21 | /* |
Hase_jun | 0:2a0c62e53e9c | 22 | void morter1(char direction_of_rotation,float PWM_PULSEWIDTH ); |
Hase_jun | 0:2a0c62e53e9c | 23 | void morter2(char direction_of_rotation,float PWM_PULSEWIDTH ); |
Hase_jun | 0:2a0c62e53e9c | 24 | void morter3(char direction_of_rotation,float PWM_PULSEWIDTH ); |
Hase_jun | 0:2a0c62e53e9c | 25 | */ |
Hase_jun | 0:2a0c62e53e9c | 26 | void motor_init(); |
Hase_jun | 0:2a0c62e53e9c | 27 | void motor(int motor_num,char direction_of_rotation,float PWM_WRITE); |