Infuse-IoT SDK API 0.0.1
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
epacket_interface_api Struct Reference

#include <interface.h>

Data Fields

void(* send )(const struct device *dev, struct net_buf *buf)
 Send a packet over the interface.
 
void(* decrypt_result )(const struct device *dev, struct net_buf *buf, int decrypt_result)
 Callback for packet decryption result.
 
int(* receive_ctrl )(const struct device *dev, bool enable)
 Control receiving on the interface.
 
uint16_t(* max_packet_size )(const struct device *dev)
 Get current maximum packet size.
 

Field Documentation

◆ decrypt_result

void(* epacket_interface_api::decrypt_result) (const struct device *dev, struct net_buf *buf, int decrypt_result)

Callback for packet decryption result.

Can be used for downlink tracking in backend drivers.

Parameters
devInterface device
bufPacket buffer
decrypt_result0 if successfully decrypted, -1 otherwise

◆ max_packet_size

uint16_t(* epacket_interface_api::max_packet_size) (const struct device *dev)

Get current maximum packet size.

If not defined, max_packet_size from epacket_interface_common_config is used

Parameters
devInterface device
Returns
Maximum packet size

◆ receive_ctrl

int(* epacket_interface_api::receive_ctrl) (const struct device *dev, bool enable)

Control receiving on the interface.

Parameters
devInterface device
enableTrue to enable receiving, false to disable
Return values
0on success
-errnoon failure

◆ send

void(* epacket_interface_api::send) (const struct device *dev, struct net_buf *buf)

Send a packet over the interface.

Note
Transmission errors can be detected through epacket_interface_cb
Parameters
devInterface device
bufPacket to send

The documentation for this struct was generated from the following file: