Hi there,
I am using an nRF9160DK and looking to get accurate Timing Advance numbers from it and also information on neighbouring cells. I believe in order to get an accurate figure for TA from the serving cell, I need my RCC Mode to be 'connected', then to get information about neighbouring cells RCC Mode needs to be 'Idle'. This seems to almost give me the right results with two issues (as detailed below). The sequence of setting things up in the code is:
nrf_modem_lib_init();
lte_lc_connect_async(lte_handler);
lte_lc_connect();
Which shows me connected in RCC Mode whislt I send a few text messages and do my first "AT%NCELLMEAS"
The result of that is:
%NCELLMEAS: 0,"00165701","53001","A320",160,9485,220,50,18,3949,3947
Cell ID, MCC, MNC etc. are correct but I am only about 600m from the tower, yet a TA of 160 puts me at 160*78m = 12.5km. Am I calculating the TA wrong or is there any additional mode's I need to turn on (for example I remember with 2G TA could only be measured whilst in a phone call)?
Second question.
After I do the abouve, I wait till I see 'RCC Mode: Idle' from the handler then do a "AT%NCELLMEAS=3,2" , and get:
%NCELLMEAS: 0,"00165701","53001","A320",160,14267,9485,220,56,21,19043,1,0,"0004A605","53001","A320",65535,0,9485,479,43,8,19043,0,0
[00:00:20.319,580] <err> lte_lc: Parsing of neighbor cells failed, err: -95
[00:00:20.319,580] <err> lte_lc: Parsing of neighbor cells failed, err: -95
Again, the neighbouring cell is in the general area (according to OpenCellID), so that is good, but I am not sure what the error -95 means? My responce buffer is set up as char response[200]; so the 132 character reply fits in it ok.
Any guidance would be great!
Thanks