mirror of
https://github.com/meshtastic/firmware.git
synced 2025-08-07 22:24:41 +00:00
properly set the RF95 iface
This commit is contained in:
parent
48c045a253
commit
22bca31ce3
@ -24,14 +24,13 @@ bool RF95Interface::init()
|
|||||||
*/
|
*/
|
||||||
if (CH0 < 500.0) {
|
if (CH0 < 500.0) {
|
||||||
auto dev = new RFM96(&module);
|
auto dev = new RFM96(&module);
|
||||||
lora = dev;
|
iface = lora = dev;
|
||||||
res = dev->begin(freq, bw, sf, cr, syncWord, power, currentLimit, preambleLength);
|
res = dev->begin(freq, bw, sf, cr, syncWord, power, currentLimit, preambleLength);
|
||||||
} else {
|
} else {
|
||||||
auto dev = new RFM95(&module);
|
auto dev = new RFM95(&module);
|
||||||
lora = dev;
|
iface = lora = dev;
|
||||||
res = dev->begin(freq, bw, sf, cr, syncWord, power, currentLimit, preambleLength);
|
res = dev->begin(freq, bw, sf, cr, syncWord, power, currentLimit, preambleLength);
|
||||||
}
|
}
|
||||||
|
|
||||||
DEBUG_MSG("LORA init result %d\n", res);
|
DEBUG_MSG("LORA init result %d\n", res);
|
||||||
|
|
||||||
if (res == ERR_NONE)
|
if (res == ERR_NONE)
|
||||||
|
Loading…
Reference in New Issue
Block a user