BALTECH SDK wrapper functions reference
eth.h
Go to the documentation of this file.
1 
10 #ifndef __BRP_BALTECH_SDK_CMDS_ETH_H__
11 #define __BRP_BALTECH_SDK_CMDS_ETH_H__
12 #include "../typedefs.h"
13 #ifdef BALTECH_SDK_INTERNAL
14 
17 #define BRP_Eth_ErrNoResultYet BRP_ERR_STATUS(0x4500, 0x01)
18 #endif // BALTECH_SDK_INTERNAL
19 #ifdef BALTECH_SDK_INTERNAL
20 
23 #define BRP_Eth_ErrNotConnected BRP_ERR_STATUS(0x4500, 0x02)
24 #endif // BALTECH_SDK_INTERNAL
25 #ifdef BALTECH_SDK_INTERNAL
26 
29 #define BRP_Eth_ErrDisabled BRP_ERR_STATUS(0x4500, 0x03)
30 #endif // BALTECH_SDK_INTERNAL
31 #ifdef BALTECH_SDK_INTERNAL
32 typedef struct {
33  brp_protocol protocol;
34  brp_buf* MAC;
35  brp_mempool *mempool;
36 } brp_Eth_GetMacAdr_t;
45 #ifdef BRP_SUPPORT_LEGACY_METHODS
46 brp_errcode brp_Eth_GetMacAdr(brp_protocol protocol, brp_buf* MAC, brp_mempool *mempool);
47 #else
48 brp_errcode brp_Eth_GetMacAdr(brp_Eth_GetMacAdr_t params);
49 #endif
50 #endif // BALTECH_SDK_INTERNAL
51 #ifdef BALTECH_SDK_INTERNAL
52 typedef struct {
53  brp_protocol protocol;
54  brp_buf* IP;
55  brp_mempool *mempool;
56 } brp_Eth_GetConnDevIP_t;
65 #ifdef BRP_SUPPORT_LEGACY_METHODS
66 brp_errcode brp_Eth_GetConnDevIP(brp_protocol protocol, brp_buf* IP, brp_mempool *mempool);
67 #else
68 brp_errcode brp_Eth_GetConnDevIP(brp_Eth_GetConnDevIP_t params);
69 #endif
70 #endif // BALTECH_SDK_INTERNAL
71 #ifdef BALTECH_SDK_INTERNAL
72 typedef struct {
73  brp_protocol protocol;
74 } brp_Eth_CreateRecoveryPoint_t;
81 #ifdef BRP_SUPPORT_LEGACY_METHODS
82 brp_errcode brp_Eth_CreateRecoveryPoint(brp_protocol protocol);
83 #else
84 brp_errcode brp_Eth_CreateRecoveryPoint(brp_Eth_CreateRecoveryPoint_t params);
85 #endif
86 #endif // BALTECH_SDK_INTERNAL
87 #ifdef BALTECH_SDK_INTERNAL
88 typedef struct {
89  brp_protocol protocol;
90 } brp_Eth_DelRecoveryPoint_t;
97 #ifdef BRP_SUPPORT_LEGACY_METHODS
98 brp_errcode brp_Eth_DelRecoveryPoint(brp_protocol protocol);
99 #else
100 brp_errcode brp_Eth_DelRecoveryPoint(brp_Eth_DelRecoveryPoint_t params);
101 #endif
102 #endif // BALTECH_SDK_INTERNAL
103 #ifdef BALTECH_SDK_INTERNAL
104 typedef struct {
105  brp_protocol protocol;
106  unsigned* PortStatus;
107  brp_buf* StaticIPAdr;
108  brp_buf* StaticIPNetmask;
109  brp_buf* StaticIPGateway;
110  brp_buf* DHCPAdr;
111  brp_buf* DHCPNetmask;
112  brp_buf* DHCPGateway;
113  brp_buf* LinkLocalAdr;
114  brp_buf* LinkLocalNetmask;
115  brp_buf* LinkLocalGateway;
116  brp_buf* DNSAdr;
117  brp_buf* HostAdr;
118  unsigned* HostPort;
119  unsigned* AutocloseTimeout;
120  brp_mempool *mempool;
121 } brp_Eth_GetNetworkStatus_t;
143 #ifdef BRP_SUPPORT_LEGACY_METHODS
144 brp_errcode brp_Eth_GetNetworkStatus(brp_protocol protocol, unsigned* PortStatus, brp_buf* StaticIPAdr, brp_buf* StaticIPNetmask, brp_buf* StaticIPGateway, brp_buf* DHCPAdr, brp_buf* DHCPNetmask, brp_buf* DHCPGateway, brp_buf* LinkLocalAdr, brp_buf* LinkLocalNetmask, brp_buf* LinkLocalGateway, brp_buf* DNSAdr, brp_buf* HostAdr, unsigned* HostPort, unsigned* AutocloseTimeout, brp_mempool *mempool);
145 #else
146 brp_errcode brp_Eth_GetNetworkStatus(brp_Eth_GetNetworkStatus_t params);
147 #endif
148 #endif // BALTECH_SDK_INTERNAL
149 #ifdef BALTECH_SDK_INTERNAL
150 typedef struct {
151  brp_protocol protocol;
152  unsigned Port;
153  unsigned** MIBCounterList;
154  size_t* MIBCounterList_len;
155  brp_mempool *mempool;
156 } brp_Eth_GetMIBCounters_t;
167 #ifdef BRP_SUPPORT_LEGACY_METHODS
168 brp_errcode brp_Eth_GetMIBCounters(brp_protocol protocol, unsigned Port, unsigned** MIBCounterList, size_t* MIBCounterList_len, brp_mempool *mempool);
169 #else
170 brp_errcode brp_Eth_GetMIBCounters(brp_Eth_GetMIBCounters_t params);
171 #endif
172 #endif // BALTECH_SDK_INTERNAL
173 #ifdef BALTECH_SDK_INTERNAL
174 typedef struct {
175  brp_protocol protocol;
176  brp_Eth_GetTcpConnectionStatus_Status* Status;
177 } brp_Eth_GetTcpConnectionStatus_t;
185 #ifdef BRP_SUPPORT_LEGACY_METHODS
186 brp_errcode brp_Eth_GetTcpConnectionStatus(brp_protocol protocol, brp_Eth_GetTcpConnectionStatus_Status* Status);
187 #else
188 brp_errcode brp_Eth_GetTcpConnectionStatus(brp_Eth_GetTcpConnectionStatus_t params);
189 #endif
190 #endif // BALTECH_SDK_INTERNAL
191 #ifdef BALTECH_SDK_INTERNAL
192 typedef struct {
193  brp_protocol protocol;
194  brp_Eth_OpenTcpConnection_ConnectionReason ConnectionReason;
195 } brp_Eth_OpenTcpConnection_t;
203 #ifdef BRP_SUPPORT_LEGACY_METHODS
204 brp_errcode brp_Eth_OpenTcpConnection(brp_protocol protocol, brp_Eth_OpenTcpConnection_ConnectionReason ConnectionReason);
205 #else
206 brp_errcode brp_Eth_OpenTcpConnection(brp_Eth_OpenTcpConnection_t params);
207 #endif
208 #endif // BALTECH_SDK_INTERNAL
209 #ifdef BALTECH_SDK_INTERNAL
210 typedef struct {
211  brp_protocol protocol;
212 } brp_Eth_CloseTcpConnection_t;
219 #ifdef BRP_SUPPORT_LEGACY_METHODS
220 brp_errcode brp_Eth_CloseTcpConnection(brp_protocol protocol);
221 #else
222 brp_errcode brp_Eth_CloseTcpConnection(brp_Eth_CloseTcpConnection_t params);
223 #endif
224 #endif // BALTECH_SDK_INTERNAL
225 #endif
226 
unsigned int brp_errcode
This type is used library-wide for passing error codes in the return value of functions.
Definition: errorcodes.h:23
struct brp_protocol_t * brp_protocol
This is a generic handle of a protocol.
Definition: protocol.h:34
struct brp_mempool_object_t * brp_mempool
mempool handle.
Definition: mempool.h:29
unsigned char * brp_buf
represents a pointer to a protocol data buffer.
Definition: common.h:61