Hardware Abstraction Layer, permitting any LoRa application to use any LoRa radio chip

Dependents:   alarm_slave alarm_master lora_p2p lorawan1v1 ... more

radio chip selection

Radio chip driver is not included, allowing choice of radio device.
If you're using SX1272 or SX1276, then import sx127x driver into your program.
if you're using SX1261 or SX1262, then import sx126x driver into your program.
if you're using SX1280, then import sx1280 driver into your program.
if you're using LR1110, then import LR1110 driver into your program.
If you're using NAmote72 or Murata discovery, then you must import only sx127x driver.
If you're using Type1SJ select target DISCO_L072CZ_LRWAN1 and import sx126x driver into your program.

Pin assigned to arduino LoRa radio shield form-factor

Revision:
13:a354f82d12d9
Parent:
11:5111788c4298
Child:
15:e1c04ec39aa4
--- a/radio_sx126x.cpp	Wed May 29 09:55:12 2019 -0700
+++ b/radio_sx126x.cpp	Fri May 31 10:21:30 2019 -0700
@@ -313,13 +313,13 @@
 
 }
 
-void Radio::SetLoRaSymbolTimeout(uint8_t symbs)
+void Radio::SetLoRaSymbolTimeout(uint16_t symbs)
 {
     if (radio.getPacketType() != PACKET_TYPE_LORA)
         radio.setPacketType(PACKET_TYPE_LORA);
 
-    radio.xfer(OPCODE_SET_LORA_SYMBOL_TIMEOUT, 1, 0, &symbs);
     loraTimeoutSymbols = symbs;
+    radio.xfer(OPCODE_SET_LORA_SYMBOL_TIMEOUT, 1, 0, &loraTimeoutSymbols);
 }
 
 float Radio::GetRssiInst()
@@ -458,7 +458,7 @@
         RadioEvents->TxDone_botHalf();
 }
 
-void Radio::Init(const RadioEvents_t* e)
+void Radio::Init(const RadioEvents_t* e, unsigned spi_hz)
 {
     radio.txDone = txDoneBottom;
     radio.rxDone = rx_done;
@@ -469,6 +469,7 @@
     RadioEvents = e;
     lpt.start();
 
+    spi.frequency(spi_hz);
     radio.SetDIO2AsRfSwitchCtrl(1);
 }