PLC Service Universal Serial Interface.
Copyright (c) 2014-2018 Microchip Technology Inc. and its subsidiaries.
#include "conf_usi.h"
Data Structures | |
struct | x_usi_serial_cmd_params_t |
Macros | |
#define | CMD_PRIME_PROTOCOL(A) ((A)&CMD_PRIME_PROTOCOL_MSK) |
#define | CMD_PRIME_PROTOCOL_MSK 0x3F |
#define | MNGP_PRIME_EN_PIBQRY 0x06 |
#define | MNGP_PRIME_EN_PIBRSP 0x07 |
#define | MNGP_PRIME_FU 0x05 |
#define | MNGP_PRIME_GETQRY 0x00 |
#define | MNGP_PRIME_GETRSP 0x01 |
#define | MNGP_PRIME_PROT 0x00 |
#define | MNGP_PRIME_REBOOT 0x04 |
#define | MNGP_PRIME_RESET 0x03 |
#define | MNGP_PRIME_SET 0x02 |
Typedefs | |
typedef uint8_t(* | pf_usi_decode_cmd )(uint8_t *, uint16_t) |
typedef uint8_t(* | pf_usi_get_cmd )(void) |
typedef void(* | pf_usi_set_cmd )(uint8_t) |
Enumerations | |
enum | usi_protocol_t { PROTOCOL_SNIF_PRIME = 0x13, PROTOCOL_MAC_PRIME = 0x17, PROTOCOL_MLME_PRIME = 0x18, PROTOCOL_PLME_PRIME = 0x19, PROTOCOL_432_PRIME = 0x1A, PROTOCOL_BASEMNG_PRIME = 0x1D, PROTOCOL_PRIME_SERIAL = 0x1F, PROTOCOL_ATPL230 = 0x22, PROTOCOL_USER_DEFINED = 0xFE, PROTOCOL_INVALID = 0xFF } |
enum | usi_status_t { USI_STATUS_PROTOCOL_NOT_FOUND = 0xFF, USI_STATUS_TX_BUFFER_OVERFLOW, USI_STATUS_TX_BUSY, USI_STATUS_TX_BLOCKED, USI_STATUS_RX_BUFFER_OVERFLOW, USI_STATUS_RX_BLOCKED, USI_STATUS_UART_ERROR, USI_STATUS_FORMAT_ERROR, USI_STATUS_OK, USI_STATUS_INVALID } |
Functions | |
usi_status_t | usi_send_cmd (void *msg) |
Function to transmit data through USI. More... | |
Universal Serial Interface API functions | |
void | usi_init (void) |
Create RX and TX USI tasks, and timer to update internal counters. More... | |
void | usi_process (void) |
Function to perform the USI RX process. More... | |
void | usi_txrx_block_timer (void) |
Function that updates the USI flow control timers. More... | |