THINGSTREAM CLICK
PID: MIKROE‐3739
Weight: 28 g
Thingstream Click is an IoT gateway Click board™ with the Thingstream client SDK preinstalled. This
enables the device to connect to the Thingstream global MQTT network and connectivity tools straight out of
the box. Global connectivity is achieved by connecting to the strongest GSM network available across over
600 networks worldwide. This Click board™ makes it easy to bring Thingstream connectivity to embedded
computers and MCUs by simply utilising the UART interface; this can be configured and managed using a
minimal set of well‐documented AT commands.
Thingstream Click is supported by a mikroSDK compliant library, which includes functions that simplify
software development. This Click board™ comes as a fully tested product, ready to be used on a system
equipped with the mikroBUS™ socket.
Thingstream Click enables low‐cost, low‐power IoT connectivity and simple software integration
with the Thingstream MQTT broker and cloud‐based data management platform. It is designed
to be connected to existing production or prototype baseboards with a mikroBUS socket. In
addition, This Click board™ also comes with a start‐up package comprising free Thingstream
account activation, an embedded Thingstream SIM and three months of free global cellular
connectivity. The device is activated by a redemption unique to the embedded SIM.
Each Thingstream click board comes with three months of full access to the Thingstream global
MQTT network and connectivity software tools and Data Flow Manager with up to 500 MQTT
messages per month from the moment of activation.
HOW DOES IT WORK?
The Thingstream Click is equipped with the SIM868, an 802.11b/g/n quad‐band
GPS/GLONASS/GSM location tracking and mobile communication module from SIMCom. This
allows the device to connect to the Thingstream global MQTT network over GSM. Thingstream
Click enables rapid development of intelligent IoT applications and simplified connectivity with
cloud platforms using just a small set of AT commands and a flow‐chart style application builder
(Data Flow Manager), removing the complexities of web, hardware, and communications
related development. This Click board™ is preconfigured with all of the necessary protocols and
communications settings to connect with the Thingstream global MQTT network and Data Flow
Manager. This is implemented via the Thingstream client SDK which can be used for
development of the firmware located on the onboard STM32F407 MCU. Results can be
achieved quickly without a deep understanding of software engineering and web programming.
To find out more about AT commands and how to Click board™ see the following guides:
AT Command Set manual
Quick User Guide
Thingstream Click is equipped with various LED indicators. Separate LEDs are used to indicate
the presence of a power supply, the network status and pulse per second indication (1PPS).
This Click board™ also contains a universal RGB LED for other feedback relating to the status of
the Thingstream Click. This Click board™ requires both 3.3V and 5V power rails for proper
operation.
Besides the onboard USB connector, all of the mikroBUS™ pins on this Click board™, are routed
to the appropriate pins of the onboard STM32F407 MCU. That way, it is ensured that users will
have plenty of space for future upgrades and development. This enables a very broad range of
custom applications including support for I2C and SPI communication interfaces.
All available interfaces can be made available to the mikroBUS header. By default, the board
only supports UART communication using AT commands. Other interfaces like SPI, I2C, PWM
and Analog can be supported by firmware updates. If you require this functionality, please
contact the Thingstream team.
This Click board™ uses 3.3V logic level only. To be able to use it with MCUs that use 5V logic
level on their communication lines, a proper level‐translation circuit should be used.
THINGSTREAM CONNECTIVITY PLATFORM
The Thingstream connectivity platform provides out‐of‐the‐box, global IoT connectivity. As the
only provider of truly global, low‐power IoT connectivity, Thingstream’s platform enables
devices to simply connect to the strongest GSM network available, almost anywhere in the
world and communicate using MQTT Messaging. Thingstream provides coverage for over 190
countries, across 600+ networks worldwide, providing access to the single largest IoT network
of its kind.
Thingstream’s connectivity platform enables two‐way intelligent communication between
device and IoT application and with proven scalability, the platform is ideal for delivering mass
IoT deployments. It doesn’t use TCP‐IP and therefore, with no IP (Internet) dependency, things
are inherently more secure and connectivity is delivered via a proven high availability, high
performance global messaging platform.
Find out more about the Thingstream global MQTT network.
SPECIFICATIONS
Type
GPS/GNSS,Cloud Routers
Applications
A global connectivity solution for easy development of powerful MQTT‐
based intelligent IoT applications
On‐board
modules
SIM868, 802.11b/g/n quad‐band GPS/GLONASS/GSM location tracking and
mobile communication module STM32F407VGT6 – ARM® Cortex®‐M4
based Microcontroller from STMicroelectronics
Key Features
Enables easy and fast connectivity between device and cloud applications,
low power mode, simple serial interface for communication, GSM
connection with coverage for over 190 countries, across 600+ networks
worldwide
Interface
GPIO,UART,SPI,I2C
Click board
size
L (57.15 x 25.4 mm)
Input Voltage
5V
PINOUT DIAGRAM
This table shows how the pinout on Thingstream Click corresponds to the pinout on the
mikroBUS™ socket (the latter shown in the two middle columns).
Notes
Pin
Pin
Notes
Analog Enabled
GPIO
AN
1
AN
PWM
16
PWM
PWM Enabled GPIO
RST
2
RST
INT
15
INT
Interrupt Enabled
GPIO
SPI Chip Enable
CS
3
CS
RX
14
TX
UART Transmit
Serial Clock
SC
4
SCK
TX
13
RX
UART Receive
Serial Data Out
SDO
5
MISO
SCL
12
SCL
I2C Clock
Serial Data In
SDI
6
MOSI
SDA
11
SDA
I2C Data
NC
7
3.3V
5V
10
5V
GND
8
GND
GND
9
GND
Reset
Ground
Power Supply
Ground
ONBOARD SETTINGS AND INDICATORS
Label
Name
Default
LD1
PWR
‐
Power LED Indicator
LD2
NET
‐
Network status LED Indicator
LD3
1PPS
‐
Pulse per second LED Indicator
LD4
RGB
‐
Universal RGB Indicator
J1, J2
‐
3.3V
Description
Active antenna power supply voltage selection
SOFTWARE SUPPORT
We provide a library for the Thingstream Click on our LibStock page, as well as a demo
application (example), developed using MikroElektronika compilers. The demo can run on all
the main MikroElektronika development boards.
Library Description
Library provides functions for powering up device, sending commands and controlling device,
and function for parsing data read from GPS module.
Key functions:
void thingstream_cmd_single ( char *p_cmd ) ‐ Fucntion for sending commands to device
char *thingstream_gps_parser (char *data_in, char *cmd, uint8_t data_pos) ‐ Function for
parsing GPS data
void thingstream_module_power ( uint8_t power_state ) ‐ Function for powering up module
Examples description
The application is composed of three sections :
System Initialization ‐ Initializes necessary GPIO pin, UART used for the communcation with GSM module and
UART used for infromation logging
Application Initialization ‐ Initializes driver, power on module and sends few command for the default module
configuration
Application Task ‐ Waits till GPS module turns on then reads data from buffer parses is and logs it.
void application_task ( )
{
char *p_data;
char rsp_com[ 50 ] = {0};
if ( gps_rsp_ready == 0 )
{
mikrobus_logWrite( " ‐ Waiting to GPS to start... ", _LOG_LINE );
thingstream_cmd_single( &THINGSTREAM_GPS_INFO[ 0 ] );
p_data = thingstream_gps_parser( &demo_buf[ 0 ], &demo_cmd[ 0 ], 1 );
strcpy( &rsp_com[ 0 ], p_data );
while ( rsp_com[ 0 ] != '1' )
{
thingstream_cmd_single( &THINGSTREAM_GPS_INFO[ 0 ] );
p_data = thingstream_gps_parser( &demo_buf[ 0 ], &demo_cmd[ 0 ], 1 );
strcpy( &rsp_com[ 0 ], p_data );
Delay_ms( 1000 );
}
mikrobus_logWrite( " ‐ GPS ‐ ", _LOG_LINE );
gps_rsp_ready = 1;
int_flag = 0;
}
else
{
thingstream_cmd_single( &THINGSTREAM_GPS_INFO[ 0 ] );
while ( int_flag != 1 );
int_flag = 0;
}
mikrobus_logWrite( " ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ ", _LOG_LINE);
p_data = thingstream_gps_parser( &demo_buf[ 0 ], &demo_cmd[ 0 ], 3 );
if ( p_data == 0 )
{
mikrobus_logWrite( " Latitude : No data available!", _LOG_LINE);
}
else
{
strcpy( &rsp_com[ 0 ], p_data );
mikrobus_logWrite( " Latitude : ", _LOG_TEXT );
mikrobus_logWrite( rsp_com, _LOG_LINE );
}
Delay_ms( 500 );
p_data = thingstream_gps_parser( &demo_buf[ 0 ], &demo_cmd[ 0 ], 4 );
if ( p_data == 0 )
{
mikrobus_logWrite( " Longitude : No data available!", _LOG_LINE);
}
else
{
strcpy( &rsp_com[ 0 ], p_data );
mikrobus_logWrite( " Longitude : ", _LOG_TEXT );
mikrobus_logWrite( rsp_com, _LOG_LINE );
}
Delay_ms( 500 );
p_data = thingstream_gps_parser( &demo_buf[ 0 ], &demo_cmd[ 0 ], 5 );
if ( p_data == 0 )
{
mikrobus_logWrite( " Altitude : No data available!", _LOG_LINE);
}
else
{
strcpy( &rsp_com[ 0 ], p_data );
mikrobus_logWrite( " Altitude : ", _LOG_TEXT );
mikrobus_logWrite( rsp_com, _LOG_LINE );
}
mikrobus_logWrite( " ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ ", _LOG_LINE);
mikrobus_logWrite( " ", _LOG_LINE);
Delay_ms( 5000 );
}
Additional Functions :
All additional functions such as timer initialization and default handler.
The full application code, and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in the example:
UART
Conversions
C_String
Additional notes and informations
Depending on the development board you are using, you may need USB UART click, USB
UART 2 click or RS232 click to connect to your PC, for development systems with no UART to
USB interface available on the board. The terminal available in all MikroElektronika compilers,
or any other terminal application of your choice, can be used to read the message.
MIKROSDK
This Click board™ is supported with mikroSDK ‐ MikroElektronika Software Development Kit.
To ensure proper operation of mikroSDK compliant Click board™ demo applications, mikroSDK
should be downloaded from the LibStock and installed for the compiler you are using.
For more information about mikroSDK, visit the official page.
https://www.mikroe.com/thingstream‐click/9‐25‐19