I’m working on getting my network interface working on a custom Zynq PicoZed 7030 project. I have FreeRTOS running on it.
I downloaded the FreeRTOS-Plus-TCP files and added them to my Vitis tool. I added a FreeRTOSIPConfig.h to set up some defines. I’m following the tutorial for this, but I’m getting an error when calling FreeRTOS_IPInit_Multi:
Assert failed in file …/src/FreeRTOS-Plus-TCP-main/source/FreeRTOS_IP.c, line 946
Here’s my FreeRTOSIPConfig.h file:
#ifndef FREERTOS_IP_CONFIG_H
#define FREERTOS_IP_CONFIG_H
#define ipconfigUSE_DHCP 0
#define ipconfigUSE_DHCPv6 0
#define ipconfigUSE_IPv4 1
#define ipconfigUSE_IPv6 0
#define ipconfigNETWORK_MTU 1526
#define ipconfigTCP_MSS 1460
#define ipconfigTCP_TX_BUFFER_LENGTH ( 16 * ipconfigTCP_MSS )
#define ipconfigTCP_RX_BUFFER_LENGTH ( 16 * ipconfigTCP_MSS )
#define ipconfigBYTE_ORDER pdFREERTOS_LITTLE_ENDIAN
#define ipconfigZERO_COPY_RX_DRIVER 1
#define ipconfigZERO_COPY_TX_DRIVER 1
//#define ipconfigPORT_SUPPRESS_WARNING 1
#define ipconfigDRIVER_INCLUDED_RX_IP_CHECKSUM 1
#define ipconfigDRIVER_INCLUDED_TX_IP_CHECKSUM 1
#define ipconfigNIC_N_TX_DESC 4
#define ipconfigNIC_N_RX_DESC 64 // 64 correct?
#define ipconfigUSE_DNS 0
#endif // FREERTOS_IP_CONFIG_H
Here’s my mainline code:
static uint8_t ucMACAddress[6] = { 0x00, 0x0A, 0x35, 0xE5, 0xE5, 0x5E };
static const uint8_t ucIPAddress[4] = { 192, 168, 1, 68 };
static const uint8_t ucNetMask[4] = { 255, 255, 255, 0 };
static const uint8_t ucGatewayAddress[4] = { 10, 10, 10, 1 };
static const uint8_t ucDNSServerAddress[4] = { 208, 67, 222, 222 };
static NetworkInterface_t * xInterfaces;
static NetworkEndPoint_t * xEndPoints;
FreeRTOS_FillEndPoint( &( xInterfaces[ 0 ] ), &( xEndPoints[ 0 ] ), ucIPAddress,
ucNetMask, ucGatewayAddress, ucDNSServerAddress, ucMACAddress );
FreeRTOS_IPInit_Multi();
vTaskStartScheduler();
Do I need to initialize anything else before calling these functions?
Any help would be appreciated.
THANKS!