mirror of
https://github.com/tinygo-org/drivers.git
synced 2026-08-21 06:59:00 +00:00
lorawan/sx12xx : Code cleanup
This commit is contained in:
committed by
Ron Evans
parent
d473b9e1dc
commit
02d808a6fb
+13
-1
@@ -558,12 +558,24 @@ func (d *Device) SetCrc(enable bool) {
|
||||
}
|
||||
}
|
||||
|
||||
// SetSpreadingFactor setc surrent Lora Spreading Factor
|
||||
// SetSpreadingFactor sets current Lora Spreading Factor
|
||||
// NB: Change will be applied at next RX / TX
|
||||
func (d *Device) SetSpreadingFactor(sf uint8) {
|
||||
d.loraConf.Sf = sf
|
||||
}
|
||||
|
||||
// SetPreambleLength sets current Lora Preamble Length
|
||||
// NB: Change will be applied at next RX / TX
|
||||
func (d *Device) SetPreambleLength(pl uint16) {
|
||||
d.loraConf.Preamble = pl
|
||||
}
|
||||
|
||||
// SetTxPowerDbm sets current Lora TX Power in DBm
|
||||
// NB: Change will be applied at next RX / TX
|
||||
func (d *Device) SetTxPower(txpow int8) {
|
||||
d.loraConf.LoraTxPowerDBm = txpow
|
||||
}
|
||||
|
||||
//
|
||||
// Lora functions
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user