Public Member Functions | |
void | Clear () |
int | comInit () |
WORD | CRC16 (unsigned char *p, WORD len) |
void | delay (unsigned int z) |
char * | GetBuf () |
int | getLen () |
int | openPort (int fd, int comport) |
bool | operator== (SerialCom &in) |
int | packSend (int fd, char ptr, char buff[]) |
void | sendcommand () |
SerialCom () | |
void | SetBuf (char *buf, bool change, bool addCRC) |
Packet转换数据 | |
void | SetBuf (char *buf, int len, bool change, bool addCRC) |
int | setOpt (int fd, int nspeed, int nbits, char nevent, int nstop) |
~SerialCom () | |
Public Attributes | |
ros::NodeHandle | serial_node_handle_ |
Private Attributes | |
char | _buf [MAX_BUF+3] |
char | _crc [10] |
int | _len |
int | baudrate_ |
char | command_buff_ [30] |
unsigned char | CRC_H |
unsigned char | CRC_L |
ros::Time | current_time_ |
char | hex [16] |
ros::Time | last_time_ |
int | nread |
int | nwrite |
int | port_ |
Definition at line 58 of file odometry_serialcom.cpp.
Definition at line 98 of file odometry_serialcom.cpp.
Definition at line 113 of file odometry_serialcom.cpp.
void SerialCom::Clear | ( | ) |
Definition at line 358 of file odometry_serialcom.cpp.
int SerialCom::comInit | ( | ) |
Definition at line 270 of file odometry_serialcom.cpp.
WORD SerialCom::CRC16 | ( | unsigned char * | p, |
WORD | len | ||
) |
Definition at line 392 of file odometry_serialcom.cpp.
void SerialCom::delay | ( | unsigned int | z | ) |
Definition at line 428 of file odometry_serialcom.cpp.
char * SerialCom::GetBuf | ( | ) |
Definition at line 365 of file odometry_serialcom.cpp.
int SerialCom::getLen | ( | ) |
Definition at line 371 of file odometry_serialcom.cpp.
int SerialCom::openPort | ( | int | fd, |
int | comport | ||
) |
Definition at line 119 of file odometry_serialcom.cpp.
bool SerialCom::operator== | ( | SerialCom & | in | ) |
Definition at line 378 of file odometry_serialcom.cpp.
int SerialCom::packSend | ( | int | fd, |
char | ptr, | ||
char | buff[] | ||
) |
void SerialCom::sendcommand | ( | ) |
Definition at line 410 of file odometry_serialcom.cpp.
void SerialCom::SetBuf | ( | char * | buf, |
bool | change, | ||
bool | addCRC | ||
) |
Packet转换数据
Definition at line 293 of file odometry_serialcom.cpp.
void SerialCom::SetBuf | ( | char * | buf, |
int | len, | ||
bool | change, | ||
bool | addCRC | ||
) |
int SerialCom::setOpt | ( | int | fd, |
int | nspeed, | ||
int | nbits, | ||
char | nevent, | ||
int | nstop | ||
) |
Definition at line 157 of file odometry_serialcom.cpp.
char SerialCom::_buf[MAX_BUF+3] [private] |
Definition at line 73 of file odometry_serialcom.cpp.
char SerialCom::_crc[10] [private] |
Definition at line 75 of file odometry_serialcom.cpp.
int SerialCom::_len [private] |
Definition at line 77 of file odometry_serialcom.cpp.
int SerialCom::baudrate_ [private] |
Definition at line 78 of file odometry_serialcom.cpp.
char SerialCom::command_buff_[30] [private] |
Definition at line 79 of file odometry_serialcom.cpp.
unsigned char SerialCom::CRC_H [private] |
Definition at line 76 of file odometry_serialcom.cpp.
unsigned char SerialCom::CRC_L [private] |
Definition at line 76 of file odometry_serialcom.cpp.
ros::Time SerialCom::current_time_ [private] |
Definition at line 80 of file odometry_serialcom.cpp.
char SerialCom::hex[16] [private] |
Definition at line 83 of file odometry_serialcom.cpp.
ros::Time SerialCom::last_time_ [private] |
Definition at line 80 of file odometry_serialcom.cpp.
int SerialCom::nread [private] |
Definition at line 82 of file odometry_serialcom.cpp.
int SerialCom::nwrite [private] |
Definition at line 81 of file odometry_serialcom.cpp.
int SerialCom::port_ [private] |
Definition at line 78 of file odometry_serialcom.cpp.
Definition at line 69 of file odometry_serialcom.cpp.