u-blox SARA R410

In this guide, we go over the setup required to get the u-blox SARA R410 modem working on the Hologram network using our global IoT SIM.

We are using the Hologram Nova LTE-M/NB-IoT USB Modem but are sending commands directly to the modem. Therefore, you can follow these instructions for any device with the SARA R410.

Before we begin, please make sure that you have a Hologram account.

Setup: SIM

First, we need to make sure to activate our Hologram SIM on the Dashboard. Here is a link that walks you through that process. 
mceclip0.png

 

Setup: Device

Next, we need to insert the SIM into the device. Ensure that the SIM is inserted properly. Attach the provided antenna.

IMG_4344.png

We can use the USB port to connect directly to a PC or Linux device and communicate with the module using Serial.

Once you connect the board to a power source, ensure that it's powered on properly. There are LED lights to indicate the device is powered on.

Setup: PC/Linux Device

Plug the device into your PC or Linux device. In this guide, we will be connecting to a Raspberry Pi. However, you can communicate with your modem on a PC using SIMCOM's USB drivers and PuTTy or Tera Term.

Run the following command to view all devices connected via USB to your Linux device:

ls /dev/tty*

tty.png

Set up a Serial Terminal with the device using the following command:

screen /dev/ttyUSB0

A new Terminal window will open. Use the following command to determine if the correct dev path was chosen:

AT

Expected Response:
OK

If we don't see the expected response, we can try to the other ttyUSB paths. To close the Screen, use CTRL-A, SHIFT-K.

Determine R410 firmware version

Determine the firmware version your device is running:

ATI

Expected Response:
Manufacturer: u-blox
Model: SARA-R410M-02B
Revision: L0.0.00.00.05.08 [Apr 17 2019 19:34:02]

Note: If the revision version is less than 05.08, update the firmware before proceeding. The firmware update includes improved TCP performance.

Set UMNOPROF and UBANDMASK

Run the following commands to set the UMNOPROF and bands.

Turn off the radio. Always do this before changing UMNOPROF:

AT+CFUN=0

Expected Response:
OK


Set the profile to 100 (Standard Europe), which is the appropriate setting for the Hologram SIM worldwide:

Note: This is the only setting to use a Hologram SIM. Using a carrier-specific profile prevents the device from taking advantage of carrier fallback, which is one of the main advantages of using Hologram. In some cases, it can also lead to the carrier permanently banning your device. 

AT+UMNOPROF=100

Expected Response:
OK


Restart the device. Always do this after changing UMNOPROF:

AT+CFUN=15

Expected Response:
Device will restart.


Reopen the Serial connection:

screen /dev/ttyUSB0


Turn off the radio. Always do this before changing UBANDMASK:

AT+CFUN=0

Expected Response:
OK


Set the compatible bands to the default or undefined value, which allows your device to scan all compatible bands and take full advantage of the Hologram network. This value is a bitmask.

Note: Refer to Appendix B.5 in the u-blox SARA-R4 AT command manual for the correct default UBANDMASK bitmask value for your specific module. Replace the second parameters in the commands below with the values specified in u-blox's documentation.

AT+UBANDMASK=0,185473183

Expected Response:
OK
AT+UBANDMASK=1,923806

Expected Response:
OK


 Restart the device:

AT+CFUN=15

Expected Response:
Device will restart.


Reopen the Serial connection:

screen /dev/ttyUSB0 

 

Connect to a network using the Hologram SIM

Set the APN:

AT+CGDCONT=1,"IP","hologram"

Expected Response:
OK


Ensure the device is set to automatic operator selection:

AT+COPS=0

Expected Response:
OK

 

Establish a TCP connection with the Hologram Cloud (Optional)

Create a TCP socket:

AT+USOCR=6

Expected Response:
OK


Connect to the Hologram Cloud:

AT+USOCO=0,"cloudsocket.hologram.io",9999

Expected Response:
OK

 

Send a message to the Hologram Cloud (Optional)

We can use Hologram's Embedded API to send messages in hexadecimal to the Hologram Cloud. 

First, set the device to use hexadecimal:

AT+UDCONF=1,1

Expected Response:
OK


The message structure for the Hologram Embedded API includes the device key, the message, and any topics. Do not include the square brackets.

{"k":"[DEVICE_KEY]","d":"[MESSAGE_BODY]","t":"TOPIC_NAME"}

Example:
{"k":"ABCD1234","d":"Hello from my R410!","t":"Nova_Article"}


Convert the above message structure including the curly brackets to hexadecimal. Replace [LENGTH_OF_DATA] with the length of your original string, not the hexadecimal conversion. Do not include the square brackets:

AT+USOWR=0,[LENGTH_OF_DATA],[HEXADECIMAL_DATA]

Example:
AT+USOWR=0,61,"7B226B223A224142434431323334222C2264223A2248656C6C6F2066726F6D206D79205234313021222C2274223A224E6F76615F41727469636C65227D"

Expected Response:
+USOWR: 0,61
OK
+UUSORD: 0,5


The sent message will appear in the Activity Log drawer on the Dashboard:

r410_message.png 


Turn off hexadecimal mode:

AT+UDCONF=1,0

Expected Response:
OK


Close the socket:

AT+USOCL=0


Here is a full example from Screen:

nova_tcp.png 

Was this article helpful?
0 out of 0 found this helpful