C API for BALTECH SDK
commands.h
Go to the documentation of this file.
1 
11 #if ! defined(__COMMANDS_H__)
12 #define __COMMANDS_H__
13 
14 
15 #include "brp_protocol.h"
16 
17 
18 #define BRP_ERR_AR_NOMESSAGE BRP_ERR_STATUS(0x0500, 0x01)
19 #define BRP_ERR_AR_DISABLED BRP_ERR_STATUS(0x0500, 0x10)
20 
21 
25 #define BRP_CMD_SYS_GETINFO_FWS_LEN 41
26 
27 
37 (
38  brp_protocol protocol,
39  char * fws
40 );
44 
45 
55 (
56  brp_protocol protocol,
57  int * msg_type,
58  char * msg,
60  size_t max_msg_len,
61  size_t * msg_len
62 );
63 
64 
76 (
77  brp_protocol protocol,
78  int key,
79  int value,
80  brp_buf data,
81  size_t data_len
82 );
83 
84 
95 (
96  brp_protocol protocol,
97  int key,
98  int value,
99  brp_buf data,
100  size_t max_data_len,
103  size_t * data_len
106 );
109 
110 
111 #endif
112  // end of defgroup brp_lib
BRP_LIB brp_errcode brp_exec_AR_GetMessage(brp_protocol protocol, int *msg_type, char *msg, size_t max_msg_len, size_t *msg_len)
Returns the last message read by device.
Implements the core BRP protocol.
unsigned int brp_errcode
This type is used library-wide for passing error codes in the return value of functions.
Definition: errorcodes.h:23
BRP_LIB brp_errcode brp_exec_Sys_CfgSetValue(brp_protocol protocol, int key, int value, brp_buf data, size_t data_len)
Modifies the devices (permanent) configuration.
struct brp_protocol_t * brp_protocol
This is a generic handle of a protocol.
Definition: protocol.h:34
BRP_LIB brp_errcode brp_exec_Sys_CfgGetValue(brp_protocol protocol, int key, int value, brp_buf data, size_t max_data_len, size_t *data_len)
Retrieves a configuration value from the device.
BRP_LIB brp_errcode brp_exec_Sys_GetInfo(brp_protocol protocol, char *fws)
Retrieves the firmware string.
unsigned char * brp_buf
represents a pointer to a protocol data buffer.
Definition: common.h:61