Skip to content

Fixes the build issue with unit tests for tcp reception #629

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions test/unit-test/FreeRTOS_TCP_IP_DiffConfig/FreeRTOSIPConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@

#define TEST 1

#define ipconfigUSE_IPV4 ( 1 )

/* Set to 1 to print out debug messages. If ipconfigHAS_DEBUG_PRINTF is set to
* 1 then FreeRTOS_debug_printf should be defined to the function used to print
* out the debugging messages. */
Expand Down Expand Up @@ -138,6 +140,8 @@ extern uint32_t ulRand();
#define ipconfigDHCP_REGISTER_HOSTNAME 1
#define ipconfigDHCP_USES_UNICAST 1

#define ipconfigENDPOINT_DNS_ADDRESS_COUNT 5

/* If ipconfigDHCP_USES_USER_HOOK is set to 1 then the application writer must
* provide an implementation of the DHCP callback function,
* xApplicationDHCPUserHook(). */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,50 @@ void vSocketWakeUpUser( FreeRTOS_Socket_t * pxSocket );
*/
FreeRTOS_Socket_t * pxTCPSocketLookup( uint32_t ulLocalIP,
UBaseType_t uxLocalPort,
uint32_t ulRemoteIP,
IP_Address_t ulRemoteIP,
UBaseType_t uxRemotePort );

/* Get the size of the IP-header.
* The socket is checked for its type: IPv4 or IPv6. */
size_t uxIPHeaderSizeSocket( const FreeRTOS_Socket_t * pxSocket );

/**
* @brief Process the received TCP packet.
*
* @param[in] pxDescriptor: The descriptor in which the TCP packet is held.
*
* @return If the processing of the packet was successful, then pdPASS is returned
* or else pdFAIL.
*
* @note FreeRTOS_TCP_IP has only 2 public functions, this is the second one:
* xProcessReceivedTCPPacket()
* prvTCPHandleState()
* prvTCPPrepareSend()
* prvTCPReturnPacket()
* xNetworkInterfaceOutput() // Sends data to the NIC
* prvTCPSendRepeated()
* prvTCPReturnPacket() // Prepare for returning
* xNetworkInterfaceOutput() // Sends data to the NIC
*/
BaseType_t xProcessReceivedTCPPacket_IPV6( NetworkBufferDescriptor_t * pxDescriptor );

/**
* @brief Process the received TCP packet.
*
* @param[in] pxDescriptor: The descriptor in which the TCP packet is held.
*
* @return If the processing of the packet was successful, then pdPASS is returned
* or else pdFAIL.
*
* @note FreeRTOS_TCP_IP has only 2 public functions, this is the second one:
* xProcessReceivedTCPPacket()
* prvTCPHandleState()
* prvTCPPrepareSend()
* prvTCPReturnPacket()
* xNetworkInterfaceOutput() // Sends data to the NIC
* prvTCPSendRepeated()
* prvTCPReturnPacket() // Prepare for returning
* xNetworkInterfaceOutput() // Sends data to the NIC
*/
BaseType_t xProcessReceivedTCPPacket_IPV4( NetworkBufferDescriptor_t * pxDescriptor );
#endif /* ifndef LIST_MACRO_H */