SPIRIT click carries the SP1ML 868MHz ultra low-power RF module. The board is designed to use 3.3V power supply and 3.3V or 5V I/O voltage levels. It communicates with the target MCU over UART interface, with additional functionality provided by the following pins on the mikroBUS™ line: PWM, RST, CS.
It can be used to wirelessly send and receive UART data.
SP1ML is based on the SPIRIT1 RF sub-GHz transceiver (with integrated SMPS), STM32L1 microcontroller, integrated filter/balun, and chip antenna.
There are two operational modes, command mode and operating mode. The command mode allows module configuration and status interrogation using an extended ‘AT’ style command set. In operating mode the module serves its primary purpose as a wireless transceiver.
In operating mode the module uses only 13.5mA, 2.2mA in command mode, and even lower in stanby with just 1.4µA. This kind of power consumption makes it ideal for smart devices that send small amounts of data.
The module has an integrated antenna and crystal.
Type | RF Sub 1GHz |
Applications | Security systems, mobile health and medicine applications, IoT, wireless metering, etc. |
MCU | SP1ML 868MHz ultra low-power RF module |
MCU Memory | 16 kB RAM and 128 kB Flash |
Key Features | Low data rate, low power sub-GHz transceiver |
Interface | GPIO,UART |
Input Voltage | 3.3V or 5V |
Compatibility | mikroBUS |
Click board size | M (42.9 x 25.4 mm) |
This table shows how the pinout on SPIRIT click corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Code examples for SPIRIT click, written for MikroElektronika hardware and compilers are available on Libstock.
The library implements communication protocol between the MCU host and SPIRIT click module. It can work in two modes, command mode and operating mode. The command mode allows module configuration and status interrogation using an extended ‘AT’ style command set. In operating mode the module serves its primary purpose as a wireless transceiver. It uses asynchronous approach to issue commands and receive responses via callback functions.
The code snippet shows an example callback function for the ATO command. It checks if the response is OK to change from library state to operating mode.
01 static bool on_ato(char* response) 02 { 03 if(strcmp(response, "OK") == 0) 04 { 05 LOG_INFO("Entered operating mode."); 06 07 spirit_mode(SPIRIT_OPERATING_MODE); 08 } 09 else 10 { 11 LOG_ERROR("Failed to enter to operation mode..."); 12 } 13 14 return true; 15 }