Generic TTEthernet API. More...
Go to the source code of this file.
Classes | |
struct | __attribute__ |
struct | tte_buf_status_t |
struct | tte_buffer_t |
struct | tte_frame_t |
struct | tte_conf_t |
Defines | |
#define | TTE_INLINE |
#define | TTE_API_HDR_VER ( (int32_t) (0x02<<16 | 0x0000) ) |
#define | TTE_STAT_RUNNING ((uint32_t)1) |
#define | TTE_STAT_CONFIGURED ((uint32_t)2) |
#define | TTE_STAT_BOOTSTRAP ((uint32_t)4) |
#define | TTE_STAT_SYNCHRONIZED ((uint32_t)8) |
#define | TTE_STAT_ERROR ((uint32_t)16) |
Typedefs | |
typedef uint64_t | tte_time_t |
typedef uint32_t | tte_ctrl_status_t |
Enumerations | |
enum | tte_direction_t { TTE_DIR_INPUT = 1, TTE_DIR_OUTPUT = 2, TTE_DIR_INOUT = 3 } |
enum | tte_traffic_type_t { TTE_TT_TRAFFIC = 0, TTE_BG_TRAFFIC = 2, TTE_CT_TRAFFIC = 3 } |
enum | tte_var_id_t { TTE_VAR_LINK_STATUS = 4096, TTE_VAR_CTRL_STATUS, TTE_VAR_CTRL_COUNT, TTE_VAR_CHANNEL_COUNT, TTE_VAR_TIME_RESOLUTION, TTE_VAR_API_VERSION, TTE_VAR_THREAD_SAFE, TTE_VAR_MAC_ADDRESS } |
enum | tte_buf_var_id_t { TTE_BUFVAR_RECEIVE_CB = 8192, TTE_BUFVAR_TRANSMIT_CB, TTE_BUFVAR_CB_ARG, TTE_BUFVAR_DMA_OUTPUT, TTE_BUFVAR_DMA_INPUT } |
enum | tte_retval_t { ETT_NULLPTR = -9999, ETT_NOMEM = -9998, ETT_INVCTRL = -9997, ETT_IO = -9996, ETT_INVCHAN = -9995, ETT_INVMSGID = -9994, ETT_FAILED = -9992, ETT_CONFIG = -9991, ETT_INVSIZE = -9989, ETT_NOMSG = -9988, ETT_LINKLOST = -9987, ETT_SYNC = -9984, ETT_NOINIT = -9979, ETT_NOTSUPPORTED = -9978, ETT_DEADLINE = -9977, ETT_TIMEOUT = -9976, ETT_NOSPC = -9975, ETT_AGAIN = -9974, ETT_INITIALIZED = -9973, ETT_DMA_NOT_DONE = -9972, ETT_NO_DMA_MEM = -9971, ETT_DMA_BUF_BUSY = -9970, ETT_DMA_BUSY = -9969, ETT_SUCCESS = 0 } |
Functions | |
int32_t | tte_init (void) |
int32_t | tte_start (const uint8_t ctrl_id) |
int32_t | tte_stop (const uint8_t ctrl_id) |
int32_t | tte_exit (void) |
int32_t | tte_configure (const uint8_t ctrl_id, const tte_conf_t *const conf) |
int32_t | tte_set_var (const uint8_t ctrl_id, const tte_var_id_t var_id, const uint32_t var_size, const void *const value) |
int32_t | tte_get_var (const uint8_t ctrl_id, const tte_var_id_t var_id, const uint32_t var_size, void *const value) |
__attribute__ ((__unused__)) static TTE_INLINE uint32_t tte_get_api_version(void) | |
int32_t | tte_get_ct_output_buf (const uint8_t ctrl_id, const uint16_t ct_id, tte_buffer_t *const buf) |
int32_t | tte_get_bg_input_buf (const uint8_t ctrl_id, const uint8_t channel, tte_buffer_t *const buf) |
int32_t | tte_get_bg_output_buf (const uint8_t ctrl_id, const uint8_t channel, tte_buffer_t *const buf) |
int32_t | tte_write_output_buf (tte_buffer_t *const buf, tte_frame_t *const frame) |
int32_t | tte_read_input_buf (tte_buffer_t *const buf, tte_frame_t *const frame, tte_buf_status_t *const status) |
int32_t | tte_open_input_buf (tte_buffer_t *const buf, tte_frame_t *const frame, tte_buf_status_t *const status) |
int32_t | tte_close_input_buf (tte_buffer_t *const buf) |
int32_t | tte_open_output_buf (tte_buffer_t *const buf, tte_frame_t *const frame) |
int32_t | tte_close_output_buf (tte_buffer_t *const buf) |
int32_t | tte_get_buf_var (const tte_buffer_t *const buf, const tte_buf_var_id_t var_id, const uint32_t var_size, void *const value) |
int32_t | tte_set_buf_var (tte_buffer_t *const buf, const tte_buf_var_id_t var_id, const uint32_t var_size, const void *const value) |
int32_t | tte_flush_buffers (const uint8_t ctrl_id) |
int32_t | tte_flush_tt_buffers (const uint8_t ctrl_id) |
int32_t | tte_flush_bg_buffers (const uint8_t ctrl_id, const uint8_t channel) |
Variables | |
const uint16_t | ct_id |
Generic TTEthernet API.
This header file describes the generic programming interface of a TTEthernet communication controller. The API is implementation independent -- it can be used on any target platform with any TTEthernet controller implementation.
Definition in file tte_api.h.