MKRGSM

Communication

Enables GSM/GRPS network connection using the Arduino MKR GSM 1400 board.
Use this library to make/receive voice calls, to send and receive SMS with the u-blox SARA-U201 module.This library also allows you to connect to internet through the GPRS networks. You can either use web Clients and Servers.

Go to repository

Compatibility

This library is compatible with the samd architecture so you should be able to use it on the following Arduino boards:

Releases

To use this library, open the Library Manager in the Arduino IDE and install it from there.

Usage

The MKR GSM library can be installed using the Arduino library manager.

With the Arduino MKR GSM 1400 and this library you can do most of the operations you can do with a GSM phone: place and receive voice calls, send and receive SMS, and connect to the internet over a GPRS network. The on board module, operates in 3G with a 2G fallback.

Arduino MKR GSM 1400 has a modem that transfers data from a serial port to the GSM network. The modem executes operations via a series of AT commands. The library abstracts low level communications between the modem and SIM card. It relies on the Serial library for communication between the modem and Arduino.

Typically, each individual command is part of a larger series necessary to execute a particular function. The library can also receive information and return it to you when necessary.

This library is based on the GSM library of the Arduino GSM shield, adding new features like UDP, SSL and DTMF tone recognition.

To use this library

#include <MKRGSM.h>

Library structure

As the library enables multiple types of functionality, there are a number of different classes.

  • The GSM class takes care of commands to the radio modem. This handles the connectivity aspects of the module and registers your system in the GSM infrastructure. All of your GSM/GPRS programs will need to include an object of this class to handle the necessary low level communication.
  • Voice call handling, managed by the GSMVoiceCall class.
  • Send/receive SMS messages, managed by the GSM_SMS class.
  • The GPRSClass is for connecting to the internet.
  • GSMClient includes implementations for a client, similar to the Ethernet and WiFi libraries.
  • GSMServer includes implementations for a server, similar to the Ethernet and WiFi libraries. NB : A number of network operators do not allow for incoming connections from the public internet, but will allow them from inside their own. Check with your operator to see what restrictions there are on data use.
  • A number of utility classes such as GSMScanner and GSMModem

Library compatibility

The library tries to be as compatible as possible with the current Ethernet and WiFi101 library. Porting a program from an Arduino Ethernet or WiFi101 library to an Arduino with the MKR GSM 1400 should be fairly easy. While it is not possible to simply run Ethernet or WiFi101 compatible code on the MKR GSM 1400 as-is, some minor, library specific, modifications will be necessary, like including the GSM and GPRS specific libraries and getting network configuration settings from your cellular network provider.

GSM class

GSMVoiceCall class

GSM_SMS Class

GPRS Class

GSMClient and GSMSSLClient Class

GSMServer Class

GSMModem Class

GSMScanner Class

GSMPIN Class

GSMBand Class

UDP Class