I’ve found strange problem. When I use temperature sensor with LMiC library everything goes fine, but as soon as I move to GPS sensor (I2C, version GY-GPS6MV2 with U-blox Neo-6m-0-001) data stop coming from GPS.
I add GPS acquire to the beginning of loop() but seems it is already not getting anything after LMiC os_init() function.
I’ve tried LMiC versions 1.50 and 1.51 and both Arduino Mega and Arduino Uno. Still doesn’t work.
Here’s my test code to make sure that data comes from GPS and it works: GPS_only.ino
Here’s the code taken from LMiC 1.51 ABP example where I’ve added code from ‘GPS only.ino’ : ABP_LoRaWAN_GPS.ino
It does send ‘Hello World’ by LoRaWAN but GPS doesn’t work =(
If I comment out LMIC code GPS data start coming again:
// LMIC init
os_init();
// Reset the MAC state. Session and pending data transfers will be discarded.
LMIC_reset();
// Set static session parameters. Instead of dynamically establishing a session
// by joining the network, precomputed session parameters are be provided.
LMIC_setSession (0x1, msbf4_read(DevAddr), (uint8_t*)NwkSkey, (uint8_t*)AppSkey);
// Disable data rate adaptation
LMIC_setAdrMode(0);
// Disable link check validation
LMIC_setLinkCheckMode(0);
// Disable beacon tracking
LMIC_disableTracking ();
// Stop listening for downstream data (periodical reception)
LMIC_stopPingable();
// Set data rate and transmit power (note: txpow seems to be ignored by the library)
LMIC_setDrTxpow(DR_SF7,14);
Looks like the LMiC library conflicts with TinyGPS++ library.
Did someone managed this somehow?
May be some other libraries should be used to make simple GPS tracker?
Thank you in advance for answers.