API Overview
1.5
API Overview
1-10
backing off any odd byte header size, and adding it to the header padding
specified to the stack. For Ethernet and peer-to-peer protocol (PPP), the
only requirement is that the Ethernet or PPP packet not start on an odd
byte boundary.
In addition, some drivers in the NDK are set up to have a 22-byte header.
This is the header size of a PPPoE packet when sent using a 14-byte
Ethernet header. When all arriving packets use the 22-byte header, it
guarantees that they can be routed to any egress device with a header
requirement up to that size. For Ethernet operation, this requires that a
packet has 8 bytes of pre-pad to make its total header size 22 bytes.
The value of this pre-pad is #defined as PKT_PREPAD in the Ethernet
driver include files.
The various APIs exposed by the three main layers—the NIMU-specific
layer, mini-driver, and generic EMAC/MDIO CSL layer—can be classified
based on their functionality into the following categories:
❏ Initialization and Shutdown APIs. These APIs are called during
Ethernet device start up to initialize the EMAC environment or during
shutdown to bring down the Ethernet controller and its subsystems.
❏ Configuration APIs. These APIs are called to get/set the EMAC
configuration. The configuration APIs are generally useful in setting
the following parameters:
■ multicast configuration
■ receive filters on the Ethernet device
❏ Transmit APIs. These APIs provide a well-defined interface for the
NDK stack to pass down any available Ethernet packets onto the wire
using the Ethernet driver.
❏ Receive APIs. These APIs provide a well-defined interface for the
driver to pass up an Ethernet packet to the NDK stack and into an
application.
❏ Polling APIs. These APIs provide an interface for the NDK core
stack to monitor the status of the Ethernet link on a periodic basis and
to perform any necessary configuration of the EMAC depending on a
change of state, if any.
Need help?
Do you have a question about the TMS320C6000 and is the answer not in the manual?
Questions and answers