serial_interface.h
Go to the documentation of this file.
00001 #include <stdio.h>
00002 #include <sys/termios.h>
00003 #include <sys/ioctl.h>
00004 #include <cstring>
00005 #include <unistd.h>
00006 #include <cstdlib>
00007 #include <time.h>
00008 #include <errno.h>
00009 #include <bitset>
00010 #include <math.h>
00011 #include <sys/types.h>
00012 #include <fcntl.h>
00013 #include "ros/ros.h"
00014 
00015 struct str_ExternControl
00016 {
00017 unsigned char ID;        //two 1/0-buttons, not used atm
00018 unsigned char N; // ? something to control the lcd menues?!
00019 unsigned char Throttle;                 
00020 signed char   Yaw;
00021 signed char   Pitch;
00022 signed char   Roll;
00023 signed char   Aux1;
00024 signed char   Aux2;
00025 signed char   Aux3;
00026 signed char   Aux4;
00027 };
00028 
00029 extern struct str_ExternControl ExternControl;  //create an instance of the struct
00030 
00031 void InitSerialInterface (std::string serialport_name_, uint32_t serialport_speed_);
00032 void CloseSerialInterface (void);
00033 speed_t bitrate (int Bitrate);
00034 void SendOutData(unsigned char ID, struct str_ExternControl cmd, unsigned char N);
00035 void AddCRC_CAN(unsigned int frame_length);
00036 int sendStringToCom (unsigned char *output, int len);
00037         
00038 


quad_can_driver
Author(s): Henrique
autogenerated on Mon Jan 6 2014 11:48:02