![]() |
![]() |
This file contains the type definitions and helper macros for the "null" peripheral interface. More...
#include <stdint.h>
#include <ti/drv/enet/include/core/enet_types.h>
#include <ti/drv/enet/include/core/enet_mod.h>
#include <ti/drv/enet/include/core/enet_per.h>
#include <ti/drv/enet/include/mod/mod_null.h>
Data Structures | |
struct | NullPer_Cfg_s |
Null Peripheral configuration parameters. More... | |
struct | NullPer_Obj_s |
Null Peripheral object. More... | |
Macros | |
#define | ENET_NULLPER_FEAT1 (ENET_BIT(0U)) |
#define | ENET_NULLPER_FEAT2 (ENET_BIT(1U)) |
#define | ENET_NULLPER_ERRATA1 (ENET_BIT(0U)) |
#define | ENET_NULLPER_CLK_MCLK (1U) |
Typedefs | |
typedef struct NullPer_Cfg_s | NullPer_Cfg |
Null Peripheral configuration parameters. | |
typedef struct NullPer_Obj_s | NullPer_Obj |
Null Peripheral object. | |
typedef struct NullPer_Obj_s * | NullPer_Handle |
Null Periperhal handle. | |
Functions | |
void | NullPer_initCfg (EnetPer_Handle hPer, Enet_Type enetType, void *cfg) |
Initialize Null peripheral's configuration parameters. More... | |
int32_t | NullPer_open (EnetPer_Handle hPer, Enet_Type enetType, const void *cfg) |
Open and initialize the Null Peripheral. More... | |
int32_t | NullPer_rejoin (EnetPer_Handle hPer, Enet_Type enetType) |
Rejoin the Null Peripheral. More... | |
int32_t | NullPer_ioctl (EnetPer_Handle hPer, uint32_t cmd, Enet_IoctlPrms *prms) |
Issue an operation on the Null Peripheral. More... | |
void | NullPer_poll (EnetPer_Handle hPer, uint32_t evtMask) |
Poll for Ethernet events on the Null Peripheral. More... | |
void | NullPer_periodicTick (EnetPer_Handle hPer) |
Run periodic tick on the Null Peripheral. More... | |
void | NullPer_close (EnetPer_Handle hPer) |
Close the Null Peripheral. More... | |
This file contains the type definitions and helper macros for the "null" peripheral interface.
#define ENET_NULLPER_CLK_MCLK (1U) |
Null peripheral MCLK id
#define ENET_NULLPER_ERRATA1 (ENET_BIT(0U)) |
Null peripheral dummy errata 1
#define ENET_NULLPER_FEAT1 (ENET_BIT(0U)) |
Null peripheral dummy feature 1
#define ENET_NULLPER_FEAT2 (ENET_BIT(1U)) |
Null peripheral dummy feature 2
void NullPer_close | ( | EnetPer_Handle | hPer | ) |
Close the Null Peripheral.
Closes the Null Peripheral.
hPer | Enet Peripheral handle |
void NullPer_initCfg | ( | EnetPer_Handle | hPer, |
Enet_Type | enetType, | ||
void * | cfg | ||
) |
Initialize Null peripheral's configuration parameters.
Initializes the configuration parameters for a Null periperhal.
hPer | Enet Peripheral handle |
enetType | Enet Peripheral type |
cfg | Configuration parameters to be initialized |
int32_t NullPer_ioctl | ( | EnetPer_Handle | hPer, |
uint32_t | cmd, | ||
Enet_IoctlPrms * | prms | ||
) |
Issue an operation on the Null Peripheral.
Issues a control operation on the Null Peripheral.
hPer | Enet Peripheral handle |
cmd | IOCTL command Id |
prms | IOCTL parameters |
int32_t NullPer_open | ( | EnetPer_Handle | hPer, |
Enet_Type | enetType, | ||
const void * | cfg | ||
) |
Open and initialize the Null Peripheral.
Opens and initializes the Null Peripheral with the configuration parameters provided by the caller.
hPer | Enet Peripheral handle |
enetType | Enet Peripheral type |
cfg | Configuration parameters |
void NullPer_periodicTick | ( | EnetPer_Handle | hPer | ) |
Run periodic tick on the Null Peripheral.
Run PHY periodic tick on the Ethernet peripheral.
hPer | Enet Peripheral handle |
void NullPer_poll | ( | EnetPer_Handle | hPer, |
uint32_t | evtMask | ||
) |
Poll for Ethernet events on the Null Peripheral.
Unblocking poll for the events specified in evtMask
.
hPer | Enet Peripheral handle |
evtMask | Event bit mask |
int32_t NullPer_rejoin | ( | EnetPer_Handle | hPer, |
Enet_Type | enetType | ||
) |
Rejoin the Null Peripheral.
Reopens the Null Peripheral, but doesn't perform any hardware initialization. This function is expected to be called to attach to a running peripheral.
hPer | Enet Peripheral handle |
enetType | Enet Peripheral type |