Oscar Michael Abrina 6a8bb87dec Add MQTT keep-alive demo (#182)
The MQTT keep-alive demo is similar to the plaintext demo with QoS0. The only difference is that it creates an auto-reload timer that invokes a callback responsible for sending a PINGREQ packet. The timer is reset whenever a control packet is sent. Because the keep-alive mechanism is handled by the application, MQTT_ReceiveLoop is used in place of MQTT_ProcessLoop.

* Add keep alive demo (no timer thread yet)

* feat: Add software timer that uses mutex for MQTT context (bad approach)

* feat: Serialize PINGREQ in separate buffer to avoid use of mutex

* fix: Use hungarian notation instead of _ for private vars

* fix: Remove unnecessary comment

* Address PR comments

* Reduce ulPingRespTimeoutMs to be as much as the timer interval

* Add wrapper function to check xWaitingForPingResp before resetting the timer
2020-08-28 09:49:11 -07:00

Getting started

The easiest way to use FreeRTOS is to start with one of the pre-configured demo application projects (found in the FreeRTOS/Demo directory). That way you will have the correct FreeRTOS source files included, and the correct include paths configured. Once a demo application is building and executing you can remove the demo application files, and start to add in your own application source files. See the FreeRTOS Kernel Quick Start Guide for detailed instructions and other useful links.

Additionally, for FreeRTOS kernel feature information refer to the Developer Documentation, and API Reference.

Getting help

The FreeRTOS Support Forum is an excellent way to get rapid help from the FreeRTOS maintainers and wider FreeRTOS community.

Repository structure

This repository contains the FreeRTOS Kernel, a number of supplementary libraries, and a comprehensive set of example applications.

Kernel sources

The FreeRTOS Kernel Source is located under FreeRTOS/Source

Hardware specific ports can be found under FreeRTOS/Source/portable

A number of Demo projects can be found under FreeRTOS/Demo

Supplementary library sources

The FreeRTOS-Plus/Source directory contains source code for some of the FreeRTOS+ components, as well as select partner provided libraries. These subdirectories contain further readme files and links to documentation.

FreeRTOS-Labs contains libraries and demos that are fully functional, but undergoing optimizations or refactorization to improve memory usage, modularity, documentation, demo usability, or test coverage. At this time the projects ARE A WORK IN PROGRESS and will be released in the main FreeRTOS directories of the download following full review and completion of the documentation.

Cloning this repository

This repo uses Git Submodules to bring in dependent components.

Note: If you download the ZIP file provided by GitHub UI, you will not get the contents of the submodules. (The ZIP file is also not a valid git repository)

To clone using HTTPS:

git clone https://github.com/FreeRTOS/FreeRTOS.git --recurse-submodules

Using SSH:

git clone git@github.com:FreeRTOS/FreeRTOS.git --recurse-submodules

If you have downloaded the repo without using the --recurse-submodules argument, you need to run:

git submodule update --init --recursive

Previous releases

Previous releases are available for download under releases.

Description
No description provided
Readme 274 MiB
Languages
C 96.7%
Assembly 1.6%
Tcl 0.9%
Makefile 0.4%
HTML 0.1%