diff --git a/src/lorawan.cpp b/src/lorawan.cpp index ca4425f1..c4ef37e3 100644 --- a/src/lorawan.cpp +++ b/src/lorawan.cpp @@ -265,7 +265,7 @@ void onEvent(ev_t ev) { #if (TIME_SYNC_LORASERVER) // timesync answer -> call timesync processor - if ((LMIC.frame[LMIC.dataBeg] == TIMEPORT) { + if (LMIC.frame[LMIC.dataBeg - 1] == TIMEPORT) { recv_timesync_ans(LMIC.frame + LMIC.dataBeg, LMIC.dataLen); break; }