#include <liblwm2m.h>
#include <stdio.h>
#include <unistd.h>
#include "openthread/ip6.h"
#include "openthread/udp.h"
#include "ca821x_error.h"
Go to the source code of this file.
|
struct | connection_t |
| The struct for holding information about each connection the lwm2m stack uses. More...
|
|
◆ LWM2M_BSSERVER_PORT
#define LWM2M_BSSERVER_PORT 5685 |
◆ LWM2M_BSSERVER_PORT_STR
#define LWM2M_BSSERVER_PORT_STR "5685" |
◆ LWM2M_DTLS_PORT
#define LWM2M_DTLS_PORT 5684 |
◆ LWM2M_DTLS_PORT_STR
#define LWM2M_DTLS_PORT_STR "5684" |
◆ LWM2M_STANDARD_PORT
#define LWM2M_STANDARD_PORT 5683 |
◆ LWM2M_STANDARD_PORT_STR
#define LWM2M_STANDARD_PORT_STR "5683" |
◆ connection_t
The struct for holding information about each connection the lwm2m stack uses.
◆ anonymous enum
Enumerator |
---|
CONPOOL_SIZE | Maximum number of concurrent connections.
|
LINK_MTU | Maximum Transmission Unit for link.
|
◆ connection_create()
connection_t* connection_create |
( |
otInstance * |
aInstance, |
|
|
lwm2m_context_t * |
lwm2mH, |
|
|
lwm2m_object_t * |
secObjectP, |
|
|
uint16_t |
secObjInstID |
|
) |
| |
Connect to the server defined in the security object.
Note that the actual connection may not be complete when this function returns, due to host resolution.
Called from client code directly to create a connection when connecting to a server.
- Parameters
-
aInstance | Openthread Instance pointer |
lwm2mH | Wakaama instance pointer |
secObjectP | Pointer to the security object |
secObjInstID | Security object instance ID |
- Returns
- A pointer to the new connection, or NULL if error
◆ connection_free()
Free a connection created with connection_create.
- Parameters
-
con | The connection to free |
◆ connection_rx_info_callback()
void connection_rx_info_callback |
( |
uint16_t |
aPktLen | ) |
|
Callback that can be implemented by the application to track receive statistics.
- Parameters
-
aPktLen | Length of the received packet |
◆ connection_tx_info_callback()
void connection_tx_info_callback |
( |
uint16_t |
aPktLen | ) |
|
Callback that can be implemented by the application to track transmit statistics.
- Parameters
-
aPktLen | Length of the received packet |