16 if (arm_port->
is_ok() != 0) {
17 printf(
"Error: Serial RS485 connection failed\n");
21 printf(
"Serial RS485 connection successful\n");
28 if (arm_port->
is_ok() != 0) {
29 printf(
"Error: Tcp Control connection failed\n");
33 printf(
"Tcp Control connection successful\n");
40 if (arm_report->
is_ok() != 0) {
41 printf(
"Error: Tcp Report Norm connection failed, ip: %s\n", server_ip);
44 printf(
"Tcp Report Norm connection successful\n");
51 if (arm_report->
is_ok() != 0) {
52 printf(
"Error: Tcp Report Rich connection failed\n");
55 printf(
"Tcp Report Rich connection successful\n");
62 if (arm_report->
is_ok() != 0) {
63 printf(
"Error: Tcp Report develop connection failed\n");
66 printf(
"Tcp Report develop connection successful\n");
71 if (report_type ==
"dev")
73 else if (report_type ==
"rich")
static const int TCP_PORT_REPORT_RICH
static const int TCP_PORT_CONTROL
SocketPort * connect_tcp_report(char *server_ip, std::string report_type)
static const int TCP_PORT_REPORT_DEVL
SocketPort * connect_tcp_report_devl(char *server_ip)
static const int TCP_PORT_REPORT_NORM
UxbusCmdTcp * connect_tcp_control(char *server_ip)
static const int SERIAL_BAUD
UxbusCmdSer * connect_rs485_control(const char *com)
SocketPort * connect_tcp_report_rich(char *server_ip)
SocketPort * connect_tcp_report_norm(char *server_ip)