NXP LPC LWIP port documentation  v0.80
LWIP port for LPC devices
LWIP EMAC configuration

Defines

#define LPC_EMAC_RMII   1
 Selects RMII or MII connection type in the EMAC peripheral.
#define LPC_PBUF_RX_ZEROCOPY   1
 Set this define to '0' to use traditional copied buffers. If set to 0, receive buffers will be allocated statically for the EMAC interface per descriptor (LPC_NUM_BUFF_RXDESCS) and then copied into another allocated buffer that is passed to the network layer. If set to 1, receive buffers are allocated when needed for an empty receive descriptor and then sent directly to the network layer without a copy when a packet is received. New buffers must be allocated and re-queued for receive by periodically calling the lpc_rx_requeue() function.
#define LPC_NUM_BUFF_RXDESCS   4
 Defines the number of descriptors used for RX. A higher number of descriptors allows for more receive packets before rejecting them, but uses more memory. 1 buffer is allocated per descriptor. This must be a minimum value of 2.
#define LPC_PBUF_TX_ZEROCOPY   1
 Set this define to '1' to enable zero-copy pbufs for transmit. If this is used, the EMAC driver will not create or use any local buffers - this can save lots of memory.
#define LPC_NUM_BUFF_TXDESCS   4
 Defines the number of descriptors used for TX. In zero-copy mode, this value designates the number of descriptors that can be assigned to buffers for transmit. When not in zero-copy mode, a buffer is also assigned to the descriptor, so memory use can be high if this value is set high. Use a low count when LPC_PBUF_TX_ZEROCOPY=0. Must be a minimum value of 2.
#define LPC_TX_PBUF_BOUNCE_EN   0
 Set this define to 1 to enable bounce buffers for transmit pbufs that cannot be sent via the zero-copy method. Some chained pbufs may have a payload address that links to an area of memory that cannot be used for transmit DMA operations. If this define is set to 1, an extra check will be made with the pbufs. If a buffer is determined to be non-usable for zero-copy, a temporary bounce buffer will be created and used instead.

Detailed Description

Configuration options for the LPC EMAC.


Define Documentation

#define LPC_EMAC_RMII   1

Selects RMII or MII connection type in the EMAC peripheral.

Use the RMII or MII driver variant .

#define LPC_PBUF_RX_ZEROCOPY   1

Set this define to '0' to use traditional copied buffers. If set to 0, receive buffers will be allocated statically for the EMAC interface per descriptor (LPC_NUM_BUFF_RXDESCS) and then copied into another allocated buffer that is passed to the network layer. If set to 1, receive buffers are allocated when needed for an empty receive descriptor and then sent directly to the network layer without a copy when a packet is received. New buffers must be allocated and re-queued for receive by periodically calling the lpc_rx_requeue() function.

Set to '1' to use zero-copy pbufs for receive.

#define LPC_PBUF_TX_ZEROCOPY   1

Set this define to '1' to enable zero-copy pbufs for transmit. If this is used, the EMAC driver will not create or use any local buffers - this can save lots of memory.

Set to '1' to use no-copy pbufs for transmit.