Skip to content

Commit 2849ceb

Browse files
committed
Fix #434: wrong FSK detection in LMIC*_isFsk()
1 parent 69501b6 commit 2849ceb

File tree

5 files changed

+5
-5
lines changed

5 files changed

+5
-5
lines changed

src/lmic/lmic_bandplan_as923.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ void LMICas923_init(void);
7272

7373
// override default for LMICbandplan_isFSK()
7474
#undef LMICbandplan_isFSK
75-
#define LMICbandplan_isFSK() (/* TX datarate */LMIC.rxsyms == AS923_DR_FSK)
75+
#define LMICbandplan_isFSK() (/* RX datarate */LMIC.dndr == AS923_DR_FSK)
7676

7777
// txDone handling for FSK.
7878
void

src/lmic/lmic_bandplan_eu868.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ LMICeu868_isValidBeacon1(const uint8_t *d) {
5959

6060
// override default for LMICbandplan_isFSK()
6161
#undef LMICbandplan_isFSK
62-
#define LMICbandplan_isFSK() (/* TX datarate */LMIC.rxsyms == EU868_DR_FSK)
62+
#define LMICbandplan_isFSK() (/* RX datarate */LMIC.dndr == EU868_DR_FSK)
6363

6464
// txDone handling for FSK.
6565
void

src/lmic/lmic_bandplan_in866.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ LMICin866_isValidBeacon1(const uint8_t *d) {
5656

5757
// override default for LMICbandplan_isFSK()
5858
#undef LMICbandplan_isFSK
59-
#define LMICbandplan_isFSK() (/* TX datarate */LMIC.rxsyms == IN866_DR_FSK)
59+
#define LMICbandplan_isFSK() (/* TX datarate */LMIC.dndr == IN866_DR_FSK)
6060

6161
// txDone handling for FSK.
6262
void

src/lmic/lmic_eu868.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ ostime_t LMICeu868_nextJoinState(void) {
247247
}
248248
#endif // !DISABLE_JOIN
249249

250-
// txDone handling for FSK.
250+
// Class A txDone handling for FSK.
251251
void
252252
LMICeu868_txDoneFSK(ostime_t delay, osjobcb_t func) {
253253
LMIC.rxtime = LMIC.txend + delay - PRERX_FSK*us2osticksRound(160);

src/lmic/lmic_in866.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ ostime_t LMICin866_nextJoinState(void) {
212212
}
213213
#endif // !DISABLE_JOIN
214214

215-
// txDone handling for FSK.
215+
// Class A txDone handling for FSK.
216216
void
217217
LMICin866_txDoneFSK(ostime_t delay, osjobcb_t func) {
218218
LMIC.rxtime = LMIC.txend + delay - PRERX_FSK*us2osticksRound(160);

0 commit comments

Comments
 (0)