17 #ifndef LIDAR_HESAI_SRC_TCP_CMD_CLIENT_H_ 18 #define LIDAR_HESAI_SRC_TCP_CMD_CLIENT_H_ 37 unsigned char cmd =
'\0';
44 unsigned char* data =
nullptr;
46 if (data !=
nullptr) {
54 TcpCmdClient(
const std::string& ip, uint32_t port) : ip_(ip), port_(port) {}
56 bool GetCalibration(std::string* content);
61 bool ReadCmd(
Command* feedBack);
62 int Read(
unsigned char* buffer,
int n);
64 int BuildCmdHeader(
const Command& cmd,
unsigned char* buffer);
65 void ParseHeader(
const unsigned char* buffer,
const int len,
Definition: tcp_cmd_client.h:33
PlanningContext is the runtime context in planning. It is persistent across multiple frames...
Definition: atomic_hash_map.h:25
Definition: tcp_cmd_client.h:28
Definition: tcp_cmd_client.h:52
Definition: tcp_cmd_client.h:29
~Command()
Definition: tcp_cmd_client.h:45
uint32_t len
Definition: tcp_cmd_client.h:39
Definition: tcp_cmd_client.h:30
Definition: tcp_cmd_client.h:32
unsigned char cmd
Definition: tcp_cmd_client.h:37
~TcpCmdClient()
Definition: tcp_cmd_client.h:55
TcpCmdClient(const std::string &ip, uint32_t port)
Definition: tcp_cmd_client.h:54
Definition: tcp_cmd_client.h:36
unsigned char ret_code
Definition: tcp_cmd_client.h:38
struct apollo::drivers::hesai::CommandHeader CommandHeader
Definition: tcp_cmd_client.h:31
CommandHeader header
Definition: tcp_cmd_client.h:43
struct apollo::drivers::hesai::Command Command
Definition: tcp_cmd_client.h:42
PTC_COMMAND
Definition: tcp_cmd_client.h:27