эээм
Dependencies: mbed-STM32F103C8T6 mbed
main.cpp
- Committer:
- RuslanUrya
- Date:
- 2018-04-07
- Revision:
- 1:c86ffbbf8803
- Parent:
- 0:2d3da2f0f265
File content as of revision 1:c86ffbbf8803:
#include "mbed.h" #include "stm32f103c8t6.h" #define position 0.05 PwmOut Servo(PA_8); int main() { confSysClock(); Servo.period_ms(20); while(1) { Servo = position * 0.545; // max right wait_ms(1000); Servo = position * 1.5; //center wait_ms(1000); Servo = position * 2.6; //max left wait_ms(1000); } }