This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Switching between GPS and LTE

Hi 

I'm trying to ackquire a GPS fix, and then transmit it to my server as a UDP packet. 

First, i enable the GPS with the AT%XSYSTMMODE at command, and then try to enable LTE mode (CatM1/NB-IOT) with the same command

This is not working as expected; I've tried 2 approaches: 

1) Having the modem turned on during mode switch

2) Turning modem on/off using AT+CFUN between mode switches

In case 1, when I do the AT command to switch the modes, AT%XSYSTEMMODE returns ERROR without further explanations, and in case 2, the reoverable error callback is thrown. 

THe at modem sequence is 

AT%XSYSTEMMODE=0,0,1,0, returns OK

AT+CFUN=1, returns OK

Now the GPS is acquiring a position. When I try to switch to LTE mode, the following commands are issued: 

AT+CFUN=0, returns OK

AT%XSYSTEMMODE=1,x,0,y, (x, y) 0 or 1 (tried all combos), and a bsd recoverable error 3 is thrown. 

If I leave out the last AT+CFUN command, the last AT%XSYSTEMMODE returns ERROR., and transmitting data is not possible. 

I assume acquiring positions and then sending them is one of the key features of the nRF9160, so what am I doing wrong?

The modem FW is 0.7.0-29-alpha

 

Related