Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Motor_3/Motor_3.h@0:b7d3adaffc0a, 2018-05-07 (annotated)
- Committer:
- himarsmty
- Date:
- Mon May 07 06:57:22 2018 +0000
- Revision:
- 0:b7d3adaffc0a
a
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| himarsmty | 0:b7d3adaffc0a | 1 | #ifndef MOTOR_3_H_ |
| himarsmty | 0:b7d3adaffc0a | 2 | #define MOTOR_3_H_ |
| himarsmty | 0:b7d3adaffc0a | 3 | #include "mbed.h" |
| himarsmty | 0:b7d3adaffc0a | 4 | |
| himarsmty | 0:b7d3adaffc0a | 5 | DigitalOut mydia1(PinName a1,int b1); |
| himarsmty | 0:b7d3adaffc0a | 6 | DigitalOut mydia2(PinName a2,int b2); |
| himarsmty | 0:b7d3adaffc0a | 7 | PwmOut mypwa(PinName pa); |
| himarsmty | 0:b7d3adaffc0a | 8 | |
| himarsmty | 0:b7d3adaffc0a | 9 | |
| himarsmty | 0:b7d3adaffc0a | 10 | class Motor_3{ |
| himarsmty | 0:b7d3adaffc0a | 11 | public: |
| himarsmty | 0:b7d3adaffc0a | 12 | Motor_3(PinName dia1,PinName dia2,PinName pwa); |
| himarsmty | 0:b7d3adaffc0a | 13 | void mv(double speed); |
| himarsmty | 0:b7d3adaffc0a | 14 | int _pwmout; |
| himarsmty | 0:b7d3adaffc0a | 15 | protected: |
| himarsmty | 0:b7d3adaffc0a | 16 | PinName _dia1; |
| himarsmty | 0:b7d3adaffc0a | 17 | PinName _dia2; |
| himarsmty | 0:b7d3adaffc0a | 18 | PinName _pwa; |
| himarsmty | 0:b7d3adaffc0a | 19 | }; |
| himarsmty | 0:b7d3adaffc0a | 20 | #endif |