Class for Futaba Servo motor RS3xx series
Dependents: Hobby_Humanoid_controlor
RS300.h
- Committer:
- syundo0730
- Date:
- 2013-09-25
- Revision:
- 2:1ab1adf0915c
- Parent:
- 0:6b230fd13b40
File content as of revision 2:1ab1adf0915c:
#ifndef _RS300_H_2013_9_10_ #define _RS300_H_2013_9_10_ #include "mbed.h" #include <vector> class RS300 { public: RS300(PinName tx, PinName rx); void send_servo_pos(uint8_t id_s, std::vector<uint16_t> &pos); void on_all_servo(); void off_all_servo(); private: void send_packet(uint8_t adr, std::vector<uint8_t> &data, uint8_t cnt, uint8_t id = 0x00, uint8_t flag = 0x00); private: Serial serial; }; #endif