mirror of
https://github.com/FreeRTOS/FreeRTOS.git
synced 2025-06-01 09:27:07 +08:00

FreeRTOS_send adds the packet to be sent to the IP task's queue for later processing. The packet is sent later by the IP task. When FreeRTOS is used in collaborative mode (i.e. configUSE_PREEMPTION is 0), the Plaintext_FreeRTOS_send function returns without actually sending the packet as the IP task never gets a chance to run. The fact that Plaintext_FreeRTOS_send returns without actually sending the packet causes an issue in the MQTT_Connect which expects the CONNECT packet to be actually sent and waits for CONNACK. This commit adds a taskYIELD call after calling FreeRTOS_send to ensure that the IP task gets a chance to run and send the packet before the Plaintext_FreeRTOS_send function returns.
The 'core' branded application protocols are 'standalone' in that they do not have any dependencies outside of the C library. They use a simple transport interface definition to ensure they are not dependent on the underlying TCP/IP stack. This directory collects together the application protocols that all use the same transport interface definition. Directories: + coreMQTT contains the implementation of the coreMQTT library. See: https://www.freertos.org/mqtt + network_transport contains the transport interface definition. See the comment above and https://www.freertos.org/network-interface.html + coreHTTP contains the implementation of the coreHTTP library. See: https://www.freertos.org/http