: The FreeRTOS Cellular Interface Library is in the FreeRTOS Labs
. It is fully functional, but undergoing optimizations or refactoring to improve memory usage, modularity, documentation, demo usability, or test coverage. It is available from its own Git repository in Github
FreeRTOS Cellular Interface Library
On this page:
The FreeRTOS Cellular Library exposes the capability of a few popular cellular modems through a uniform API. Currently, this Labs project contains libraries for these three cellular modems.
The current version of the Cellular Library encapsulates the TCP stack offered by those cellular modems. They all implement the same uniform Cellular Library API . That API hides the complexity of AT commands, and exposes a socket-like interface to C programmers.
Even though applications can choose to use the Cellular API directly, the API is not designed for such a purpose. In a typical FreeRTOS system, applications use higher level libraries, such as the coreMQTT library and the coreHTTP library, to communicate with other end points. These higher level libraries use an abstract interface, the Transport Interface, to send and receive data. A Transport Interface can be implemented on top of the Cellular Library . The FreeRTOS Cellular Demo project uses such an implementation.
Most cellular modems implement more or less of the AT commands defined by the 3GPP TS v27.007 standard. This project provides an implementation of such standard AT commands in a reusable common component. The three Cellular libraries in this project all take advantage of that common code. The library for each modem only implements the vendor-specific AT commands, then exposes the complete Cellular API.
The common component that implements the 3GPP TS v27.007 standard has been written in compliance of the following code quality criteria:
- GNU Complexity scores are not over 8
- MISRA C:2012 coding standard. Any deviations from the are documented in source code comments marked by “coverity”.
Download the source code
The source code can be downloaded from the FreeRTOS labs or by itself.
To clone from Github using HTTPS:
git clone https://github.com/FreeRTOS/Lab-Project-FreeRTOS-Cellular-Library.git
git clone email@example.com/FreeRTOS/Lab-Project-FreeRTOS-Cellular-Library.git
At the root of this repository are these folders:
- include : Cellular API definitions
- common : reusable common code that implements the standard AT commands defined by 3GPP TS v27.007
- modules : vendor-specific code that implements non-3GPP AT commands for each cellular modem
- doc : documentations
Configure and build the Library
The FreeRTOS Cellular Library should be built as part of an application. In order to build a library as part of an application, certain configurations must be provided. The Lab-Project-FreeRTOS-Cellular-Demo project provides an example of how to configure the build. More information can be found within the Cellular API References.
Please refer to the README of Lab-Project-FreeRTOS-Cellular-Demo project for more information.
Integrate FreeRTOS Cellular Library with MCU platforms
The FreeRTOS Cellular Library runs on MCUs. They use an abstracted interface - the Comm Interface, to communicate with cellular modems. A Comm Interface must be implemented as well on the MCU platform. The most common implementations of the Comm Interface are over UART hardware, but it can be implemented over other physical interfaces such as SPI as well. The documentation of the Comm Interface is found within the Cellular API References. These are example implementations of the Comm Interface:
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.