From 58cb44f3f6bec1cef381f2a449f0b944bd910101 Mon Sep 17 00:00:00 2001 From: Olivier Fauchon Date: Sun, 29 Jan 2023 10:22:12 +0100 Subject: [PATCH] sx126x driver: fix in SetBandwidth function --- sx126x/sx126x.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sx126x/sx126x.go b/sx126x/sx126x.go index 0cc4680..bd30d7a 100644 --- a/sx126x/sx126x.go +++ b/sx126x/sx126x.go @@ -545,7 +545,7 @@ func (d *Device) SetCodingRate(cr uint8) { // SetBandwidth() sets current Lora Bandwidth // NB: Change will be applied at next RX / TX func (d *Device) SetBandwidth(bw uint8) { - d.loraConf.Cr = bw + d.loraConf.Bw = bw } // SetCrc() sets current CRC mode (ON/OFF)