Go to the documentation of this file.00001
00007 #ifndef dynamixel_h
00008 #define dynamixel_h
00009
00010
00011 #include <WProgram.h>
00012 #include <TimerOne/TimerOne.h>
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00032 #define PING 0x01
00033
00034 #define READ 0x02
00035
00036 #define READ_DATA 0x02
00037
00038 #define WRITE 0x03
00039
00040 #define WRITE_DATA 0x03
00041
00042 #define REG_WRITE 0x04
00043
00044 #define ACTION 0x05
00045
00046 #define RESET 0x06
00047
00048 #define SYNC_WRITE 0x83
00049 #define __DEBUG__DYNAMIXEL__
00050
00053 void InitDynamixel();
00054
00061 void SendPacket (unsigned char ID, unsigned char Instruction,unsigned char * Parameters,int Nb);
00062
00068 int ReceivePacket (unsigned char * Buffer,int NbMax, long TimeOut_Us);
00069
00073 int Errors (unsigned char * Packet);
00074
00077 void EmptyReceptionBuffer ();
00078
00081 void ISR_TimeOut_Dynamixel();
00082
00083 #endif