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

GPS+HTTP POST

Dear , 

I tried to use HTTP POST to POST the information from GPS to my webserver. 

But I couldn't combine 2 of them together. ( they, GPS and HTTP POST, worked well separately). 

Could you please help me. 

1. GPS: (works)

gps.7z

2. LTE HTTP POST (works)

LTE_Debug.7z

3. GPS+LTE HTTP POST: ( DOES NOT WORK)

GPS_LTE_debug.7z

Peripheral		Domain		Status
00 NRF_P0		Non-Secure	OK
01 NRF_CLOCK		Non-Secure	OK
02 NRF_RTC1		Non-Secure	OK
03 NRF_NVMC		Non-Secure	OK
04 NRF_UARTE1		Non-Secure	OK
05 NRF_UARTE2		Secure		SKIP
06 NRF_IPC		Non-Secure	OK
07 NRF_VMC		Non-Secure	OK
08 NRF_FPU		Non-Secure	OK
09 NRF_EGU1		Non-Secure	OK
10 NRF_EGU2		Non-Secure	OK
11 NRF_TWIM2		Non-Secure	OK
12 NRF_SPIM3		Non-Secure	OK
13 NRF_TIMER0		Non-Secure	OK
14 NRF_TIMER1		Non-Secure	OK
15 NRF_TIMER2		Non-Secure	OK
16 NRF_SAADC		Non-Secure	OK
17 NRF_GPIOTE1		Non-Secure	OK

SPM: NS image at 0x8000
SPM: NS MSP at 0x20023ab8
SPM: NS reset vector at 0xf9e5
SPM: prepare to jump to Non-Secure image.
***** Booting Zephyr OS v1.14.99-ncs1 *****
Test is starting 
Staring GPS application
Failed to enable GPS

I couldnt enable GPS when I set: 

# LTE link control
CONFIG_LTE_LINK_CONTROL=y

in prj.conf file. 

Plz help me. 

Thanks so much 

Regards, 

Hng

I am using: 

ncs_ version:

 v0.4.0 

SES 4.16 

firmware: mfwnrf916007029alpha

Hardware: nRF9160 DK v: 0.8.5

Parents Reply
  • Dear 

    Thanks, I will wait, 

    Another thing, with NB_IOT, I have lit problem:

    1. I use LTE_M to POST to my webserver: it works

    nRF9160-SICA
    
    OK
    
    +CGDCONT: 0,"IP","ibasis.iot","10.160.52.35",0,0
    
    OK
    
    %XCBAND: (1,2,3,4,5,8,12,13,14,17,20,25,26,28,66)
    
    OK
    
    +CGSN: "352656100266454"
    
    OK
    
    +CESQ: 99,99,255,255,255,78
    
    OK
    
    +CFUN: 1
    
    OK
    
    %XSYSTEMMODE: 1,0,0,0
    
    OK
    
    Checking LTE_M signal.............
    
    +COPS: 0,2,"24201",7
    
    OK
    
    OK
    
    +CEREG: 2,5,"765D","0110C303",7
    
    OK
    
    
    Original String is: +CEREG: 2,5,"765D","0110C303",7
    
    OK
    
    
    getaddrinfo err: 0
    
    send err: 150
    
    client_fd: 3
    
    bind err: 0
    
    connect err: 0
    
     HTTP POST Finished. 
    

    I changed to NB_IoT:

    AT%XEPCO=0
    AT+CFUN=4
    AT%XSYSTEMMODE=0,1,0,0

    I got reply:

    OK
    
    OK
    
    OK
    
    +CFUN: 4
    
    OK
    
    %XSYSTEMMODE: 0,1,0,0
    
    OK
    
    ------------------
    Checking  signal.............
    
    +COPS: 0
    
    OK
    
    OK
    
    +CEREG: 2,0,"765D","0110C303",9
    
    OK
    
    
    Original String is: +CEREG: 2,0,"765D","0110C303",9
    

    COPS:0 ----------------!!??

    then, I couldnt POST by NB_IoT

    What is wrong with my NB_IoT?

    My code:

    LTE_M_NB-IoT_debug.7z

    Thanks

    Regards, 

    hng

Children
  • It looks like you are disabling the modem, then enabling NB-IoT, as per the specification for XSYSTEMMODE:

    Only one supported mode allowed at a time. Use this command before activating the
    modem using the CFUN=1 command. If the mode needs to be changed, deactivate the modem
    first using the CFUN=4 command.

     

    Have you checked if you have NB-IoT coverage in your area?

    Are you able to successfully get a connection with at_client using NB-IoT?

     

    Kind regards,

    Håkon

  • Dear

    I am using iBASIS sim card, my location i Horten, Vestfold, Norway

    And  I tried with at_client:

    AT+CFUN?
    +CFUN: 1
    OK
    AT+CGSN=1
    +CGSN: "352656100266454"
    OK
    AT+CGMI
    Nordic Semiconductor ASA
    OK
    AT+CGMM
    nRF9160-SICA
    OK
    AT+CGMR
    mfw_nrf9160_0.7.0-29.alpha
    OK
    AT+CEMODE?
    +CEMODE: 0
    OK
    AT%XCBAND=?
    %XCBAND: (1,2,3,4,5,8,12,13,17,20,25,26,28,66)
    OK
    AT+CMEE?
    +CMEE: 1
    OK
    AT+CNEC?
    +CNEC: 24
    OK
    AT+CGEREP?
    +CGEREP: 1,0
    OK
    AT+CIND=1,1,1
    OK
    AT+CEREG=2
    OK
    AT+CEREG?
    +CEREG: 2,4,"FFFE","FFFFFFFF",9
    OK
    AT%CESQ=1
    OK
    AT+CESQ
    +CESQ: 99,99,255,255,255,255
    OK
    AT%XSIM=1
    OK
    AT%XSIM?
    %XSIM: 1
    OK
    AT+CPIN?
    +CPIN: READY
    OK
    AT+CPINR="SIM PIN"
    +CPINR: "SIM PIN",3
    OK
    AT+CIMI
    204080813512530
    OK
    %CESQ: 74,3
    +CEREG: 2,"9D6D","0110C367",9
    +CNEC_ESM: 111,0
    +CNEC_EMM: 19
    AT+CFUN=1
    OK
    AT%XSYSTEMMODE?
    %XSYSTEMMODE: 0,1,0,0
    OK
    AT+COPS=?

    and AT+COPS=? /At+COPS?

    AT+COPS=?
    +COPS: (1,"","","24201",9),(1,"","","24202",9)
    OK
    %CESQ: 69,3
    AT+COPS?
    +COPS: 0
    OK

    It took for about 4mn to respond this info, 

    Thanks, 

    Regards,

    hng

  • Hi Hng,

     

    It's a bit unclear for me, do you get nb-iot connectivity in at_client?

     

    COPS will do a search, and return the operators in your area.

    24201 holds two things, country code and operator.

    242 = Norway, 01 = Telenor.

    02 = Telia.

     

    Using the iBasis SIM, you can choose the network. If you want to check with Telia, this is the command:

    AT+COPS=1,2,"24202"

     

    Kind regards,

    Håkon

  • Dear

    Thanks for your support, 

    I was confusing about nb-iot connectivity in at_client also, so I tried to show you the report, i hope you can help Slight smile

    When I tried to enable nb-iot:  %XSYSTEMMODE: 0,1,0,0

    and I check the network: 

    AT+COPS?

    +COPS:0

    AT+COPS=?

    +COPS: (1,"","","24201",9),(1,"","","24202",9)
    
    
    
    
    OK


    I see: NB-IoT is connected, but
    
    
    
    
     
    LTE & PDN
    and
    Show serving station location: NOt availbe

    Is it correct?

    Thanks,

    Regards,
    hng
    
    
    
    
  • Did you finally found how to send GPS data to your host over the http post? I'm trying to achieve the same thing, however...

    I'm starting to test this with a Thingy:91 so I was looking for some example here to test it

Related