Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: Telemetria_RX_SD_GPS_copy Telemetria_RX_SD_GPS Telemetria_TX Telemetria_TX ... more
SX1276Generic Class Reference
#include <sx1276-mbed-hal.h>
Inherits SX1276.
Public Member Functions | |
| virtual uint8_t | DetectBoardType (void) |
| Detect the board connected by reading the value of the antenna switch pin. | |
| virtual bool | CheckRfFrequency (uint32_t frequency) |
| Checks if the given RF frequency is supported by the hardware. | |
| virtual void | Write (uint8_t addr, uint8_t data) |
| Writes the radio register at the specified address. | |
| virtual uint8_t | Read (uint8_t addr) |
| Reads the radio register at the specified address. | |
| virtual void | Write (uint8_t addr, void *buffer, uint8_t size) |
| Writes multiple radio registers starting at address. | |
| virtual void | Read (uint8_t addr, void *buffer, uint8_t size) |
| Reads multiple radio registers starting at address. | |
| virtual void | WriteFifo (void *buffer, uint8_t size) |
| Writes the buffer contents to the SX1276 FIFO. | |
| virtual void | ReadFifo (void *buffer, uint8_t size) |
| Reads the contents of the SX1276 FIFO. | |
| virtual void | Reset (void) |
| Reset the SX1276. | |
| virtual void | SetRfTxPower (int8_t power) |
| Sets the radio output power. | |
| virtual bool | Init (RadioEvents_t *events) |
| Return current radio status, returns true if a radios has been found. | |
| virtual void | RadioRegistersInit (void) |
| Initializes the radio registers. | |
| virtual RadioState | GetStatus (void) |
| virtual void | SetModem (RadioModems_t modem) |
| Configures the SX1276 with the given modem. | |
| virtual void | SetChannel (uint32_t freq) |
| Sets the channel frequency. | |
| virtual bool | IsChannelFree (RadioModems_t modem, uint32_t freq, int16_t rssiThresh) |
| Sets the channels configuration. | |
| virtual uint32_t | Random (void) |
| Generates a 32 bits random value based on the RSSI readings. | |
| virtual void | SetRxConfig (RadioModems_t modem, uint32_t bandwidth, uint32_t datarate, uint8_t coderate, uint32_t bandwidthAfc, uint16_t preambleLen, uint16_t symbTimeout, bool fixLen, uint8_t payloadLen, bool crcOn, bool freqHopOn, uint8_t hopPeriod, bool iqInverted, bool rxContinuous) |
| Sets the reception parameters. | |
| virtual void | SetTxConfig (RadioModems_t modem, int8_t power, uint32_t fdev, uint32_t bandwidth, uint32_t datarate, uint8_t coderate, uint16_t preambleLen, bool fixLen, bool crcOn, bool freqHopOn, uint8_t hopPeriod, bool iqInverted, uint32_t timeout) |
| Sets the transmission parameters. | |
| virtual uint32_t | TimeOnAir (RadioModems_t modem, int16_t pktLen) |
| Computes the packet time on air for the given payload. | |
| virtual void | Send (void *buffer, int16_t size, void *header=NULL, int16_t hsize=0) |
| Sends the buffer of size. Prepares the packet to be sent and sets the radio in transmission. | |
| virtual void | Sleep (void) |
| Sets the radio in sleep mode. | |
| virtual void | Standby (void) |
| Sets the radio in standby mode. | |
| virtual void | StartCad (void) |
| Sets the radio in CAD mode. | |
| virtual void | Rx (uint32_t timeout) |
| Sets the radio in reception mode for the given time. | |
| virtual bool | RxSignalPending () |
| Check is radio receives a signal. | |
| virtual void | Tx (uint32_t timeout) |
| Sets the radio in transmission mode for the given time. | |
| virtual void | SetTxContinuousWave (uint32_t freq, int8_t power, uint16_t time) |
| Sets the radio in continuous wave transmission mode. | |
| virtual int16_t | MaxMTUSize (RadioModems_t modem) |
| Returns the maximal transfer unit for a given modem. | |
| virtual int16_t | GetRssi (RadioModems_t modem) |
| Reads the current RSSI value. | |
| virtual int32_t | GetFrequencyError (RadioModems_t modem) |
| Reads the current frequency error. | |
| virtual void | SetMaxPayloadLength (RadioModems_t modem, uint8_t max) |
| Sets the maximum payload length. | |
| virtual void | SetPublicNetwork (bool enable) |
| Sets the network to public or private. Updates the sync byte. | |
Static Public Attributes | |
| static struct RadioRegisters | RadioRegsInit [] |
| Radio hardware registers initialization definition. | |
Protected Types | |
| typedef void(SX1276::* | DioIrqHandler )(void) |
Protected Member Functions | |
| virtual void | IoInit (void) |
| Initializes the radio I/Os pins interface. | |
| virtual void | SpiInit (void) |
| Initializes the radio SPI. | |
| virtual void | IoIrqInit (DioIrqHandler *irqHandlers) |
| Initializes DIO IRQ handlers. | |
| virtual void | IoDeInit (void) |
| De-initializes the radio I/Os pins interface. | |
| virtual uint8_t | GetPaSelect (uint32_t channel) |
| Gets the board PA selection configuration. | |
| virtual void | SetAntSwLowPower (bool status) |
| Set the RF Switch I/Os pins in Low Power mode. | |
| virtual void | AntSwInit (void) |
| Initializes the RF Switch I/Os pins interface. | |
| virtual void | AntSwDeInit (void) |
| De-initializes the RF Switch I/Os pins interface. | |
| virtual void | SetAntSw (uint8_t opMode) |
| Controls the antena switch if necessary. | |
| void | RxChainCalibration (void) |
| virtual void | SetOpMode (uint8_t opMode) |
| Sets the SX1276 operating mode. | |
| virtual void | OnDio0Irq (void) |
| DIO 0 IRQ callback. | |
| virtual void | OnDio1Irq (void) |
| DIO 1 IRQ callback. | |
| virtual void | OnDio2Irq (void) |
| DIO 2 IRQ callback. | |
| virtual void | OnDio3Irq (void) |
| DIO 3 IRQ callback. | |
| virtual void | OnDio4Irq (void) |
| DIO 4 IRQ callback. | |
| virtual void | OnDio5Irq (void) |
| DIO 5 IRQ callback. | |
| virtual void | OnTimeoutIrq (void) |
| Tx & Rx timeout timer callback. | |
Static Protected Member Functions | |
| static uint8_t | GetFskBandwidthRegValue (uint32_t bandwidth) |
| static uint8_t | GetLoRaBandwidthRegValue (uint32_t bandwidth) |
Protected Attributes | |
| DigitalOut * | _antSwitch |
| DigitalInOut * | _reset |
| DigitalOut * | _tcxo |
| XSPI * | _spi |
| InterruptIn * | _dio0 |
| Timeout | txTimeoutTimer |
| DioIrqHandler * | dioIrq |
Detailed Description
Actual implementation of a SX1276 radio, includes some modifications to make it compatible with the MB1 LAS board
Definition at line 38 of file sx1276-mbed-hal.h.
Member Typedef Documentation
typedef void( SX1276::* DioIrqHandler)(void) [protected, inherited] |
Member Function Documentation
| void AntSwDeInit | ( | void | ) | [protected, virtual] |
De-initializes the RF Switch I/Os pins interface.
- Remarks:
- Needed to decrease the power consumption in MCU lowpower modes
Implements SX1276.
Definition at line 292 of file sx1276-mbed-hal.cpp.
| void AntSwInit | ( | void | ) | [protected, virtual] |
Initializes the RF Switch I/Os pins interface.
Implements SX1276.
Definition at line 282 of file sx1276-mbed-hal.cpp.
| bool CheckRfFrequency | ( | uint32_t | frequency ) | [virtual] |
Checks if the given RF frequency is supported by the hardware.
- Parameters:
-
[IN] frequency RF frequency to be checked
- Return values:
-
isSupported [true: supported, false: unsupported]
Implements SX1276.
Definition at line 376 of file sx1276-mbed-hal.cpp.
| uint8_t DetectBoardType | ( | void | ) | [virtual] |
Detect the board connected by reading the value of the antenna switch pin.
Definition at line 137 of file sx1276-mbed-hal.cpp.
| int32_t GetFrequencyError | ( | RadioModems_t | modem ) | [virtual, inherited] |
Reads the current frequency error.
- Return values:
-
frequency error value in [Hz]
Implements Radio.
Definition at line 1116 of file sx1276.cpp.
| uint8_t GetFskBandwidthRegValue | ( | uint32_t | bandwidth ) | [static, protected, inherited] |
Returns the known FSK bandwidth registers value
- Parameters:
-
[IN] bandwidth Bandwidth value in Hz
- Return values:
-
regValue Bandwidth register value.
Definition at line 259 of file sx1276.cpp.
| uint8_t GetLoRaBandwidthRegValue | ( | uint32_t | bandwidth ) | [static, protected, inherited] |
Returns the known LoRa bandwidth registers value
- Parameters:
-
[IN] bandwidth Bandwidth value in Hz
- Return values:
-
regValue Bandwidth register value.
Definition at line 280 of file sx1276.cpp.
| uint8_t GetPaSelect | ( | uint32_t | channel ) | [protected, virtual] |
Gets the board PA selection configuration.
- Parameters:
-
[IN] channel Channel frequency in Hz
- Return values:
-
PaSelect RegPaConfig PaSelect value
Implements SX1276.
Definition at line 246 of file sx1276-mbed-hal.cpp.
| int16_t GetRssi | ( | RadioModems_t | modem ) | [virtual, inherited] |
Reads the current RSSI value.
- Return values:
-
rssiValue Current RSSI value in [dBm]
Implements Radio.
Definition at line 1090 of file sx1276.cpp.
| RadioState GetStatus | ( | void | ) | [virtual, inherited] |
Return current radio status
- Parameters:
-
status Radio status. [RF_IDLE, RX_RUNNING, TX_RUNNING, CAD_RUNNING]
Implements Radio.
Definition at line 141 of file sx1276.cpp.
| bool Init | ( | RadioEvents_t * | events ) | [virtual, inherited] |
Return current radio status, returns true if a radios has been found.
- Parameters:
-
[IN] events Structure containing the driver callback functions
Implements Radio.
Definition at line 120 of file sx1276.cpp.
| void IoDeInit | ( | void | ) | [protected, virtual] |
De-initializes the radio I/Os pins interface.
- Remarks:
- Useful when going in MCU lowpower modes
Implements SX1276.
Definition at line 178 of file sx1276-mbed-hal.cpp.
| void IoInit | ( | void | ) | [protected, virtual] |
Initializes the radio I/Os pins interface.
Implements SX1276.
Definition at line 142 of file sx1276-mbed-hal.cpp.
| void IoIrqInit | ( | DioIrqHandler * | irqHandlers ) | [protected, virtual] |
Initializes DIO IRQ handlers.
- Parameters:
-
[IN] irqHandlers Array containing the IRQ callback functions
Implements SX1276.
Definition at line 164 of file sx1276-mbed-hal.cpp.
| bool IsChannelFree | ( | RadioModems_t | modem, |
| uint32_t | freq, | ||
| int16_t | rssiThresh | ||
| ) | [virtual, inherited] |
Sets the channels configuration.
- Parameters:
-
[IN] modem Radio modem to be used [0: FSK, 1: LoRa] [IN] freq Channel RF frequency [IN] rssiThresh RSSI threshold
- Return values:
-
isFree [true: Channel is free, false: Channel is not free]
Implements Radio.
Definition at line 155 of file sx1276.cpp.
| int16_t MaxMTUSize | ( | RadioModems_t | modem ) | [virtual, inherited] |
Returns the maximal transfer unit for a given modem.
- Return values:
-
MTU size in bytes
Implements Radio.
Definition at line 1072 of file sx1276.cpp.
| void OnDio0Irq | ( | void | ) | [protected, virtual, inherited] |
DIO 0 IRQ callback.
Definition at line 1303 of file sx1276.cpp.
| void OnDio1Irq | ( | void | ) | [protected, virtual, inherited] |
DIO 1 IRQ callback.
Definition at line 1503 of file sx1276.cpp.
| void OnDio2Irq | ( | void | ) | [protected, virtual, inherited] |
DIO 2 IRQ callback.
Definition at line 1580 of file sx1276.cpp.
| void OnDio3Irq | ( | void | ) | [protected, virtual, inherited] |
DIO 3 IRQ callback.
Definition at line 1650 of file sx1276.cpp.
| void OnDio4Irq | ( | void | ) | [protected, virtual, inherited] |
DIO 4 IRQ callback.
Definition at line 1681 of file sx1276.cpp.
| void OnDio5Irq | ( | void | ) | [protected, virtual, inherited] |
DIO 5 IRQ callback.
Definition at line 1700 of file sx1276.cpp.
| void OnTimeoutIrq | ( | void | ) | [protected, virtual, inherited] |
Tx & Rx timeout timer callback.
Definition at line 1232 of file sx1276.cpp.
| void RadioRegistersInit | ( | void | ) | [virtual, inherited] |
Initializes the radio registers.
Definition at line 130 of file sx1276.cpp.
| uint32_t Random | ( | void | ) | [virtual, inherited] |
Generates a 32 bits random value based on the RSSI readings.
- Remarks:
- This function sets the radio in LoRa modem mode and disables all interrupts. After calling this function either Radio.SetRxConfig or Radio.SetTxConfig functions must be called.
- Return values:
-
randomValue 32 bits random value
Implements Radio.
Definition at line 178 of file sx1276.cpp.
| void Read | ( | uint8_t | addr, |
| void * | buffer, | ||
| uint8_t | size | ||
| ) | [virtual] |
Reads multiple radio registers starting at address.
- Parameters:
-
[IN] addr First Radio register address [OUT] buffer Buffer where to copy the registers data [IN] size Number of registers to be read
Implements SX1276.
Definition at line 420 of file sx1276-mbed-hal.cpp.
| uint8_t Read | ( | uint8_t | addr ) | [virtual] |
Reads the radio register at the specified address.
- Parameters:
-
[IN],: addr Register address
- Return values:
-
data Register value
Implements SX1276.
Definition at line 399 of file sx1276-mbed-hal.cpp.
| void ReadFifo | ( | void * | buffer, |
| uint8_t | size | ||
| ) | [virtual] |
Reads the contents of the SX1276 FIFO.
- Parameters:
-
[OUT] buffer Buffer where to copy the FIFO read data. [IN] size Number of bytes to be read from the FIFO
Implements SX1276.
Definition at line 439 of file sx1276-mbed-hal.cpp.
| void Reset | ( | void | ) | [virtual] |
| void Rx | ( | uint32_t | timeout ) | [virtual, inherited] |
Sets the radio in reception mode for the given time.
- Parameters:
-
[IN] timeout Reception timeout [ms] [0: continuous, others timeout]
Implements Radio.
Definition at line 780 of file sx1276.cpp.
| void RxChainCalibration | ( | void | ) | [protected, inherited] |
Performs the Rx chain calibration for LF and HF bands
- Remarks:
- Must be called just after the reset so all registers are at their default values
Definition at line 219 of file sx1276.cpp.
| bool RxSignalPending | ( | ) | [virtual, inherited] |
| void Send | ( | void * | buffer, |
| int16_t | size, | ||
| void * | header = NULL, |
||
| int16_t | hsize = 0 |
||
| ) | [virtual, inherited] |
Sends the buffer of size. Prepares the packet to be sent and sets the radio in transmission.
- Parameters:
-
[IN],: buffer Buffer pointer [IN],: size Buffer size [IN],: buffer Header pointer [IN],: size Header size
Implements Radio.
Definition at line 679 of file sx1276.cpp.
| void SetAntSw | ( | uint8_t | opMode ) | [protected, virtual] |
Controls the antena switch if necessary.
- Remarks:
- see errata note
- Parameters:
-
[IN] opMode Current radio operating mode
Implements SX1276.
Definition at line 303 of file sx1276-mbed-hal.cpp.
| void SetAntSwLowPower | ( | bool | status ) | [protected, virtual] |
Set the RF Switch I/Os pins in Low Power mode.
- Parameters:
-
[IN] status enable or disable
Implements SX1276.
Definition at line 265 of file sx1276-mbed-hal.cpp.
| void SetChannel | ( | uint32_t | freq ) | [virtual, inherited] |
Sets the channel frequency.
- Parameters:
-
[IN] freq Channel RF frequency
Implements Radio.
Definition at line 146 of file sx1276.cpp.
| void SetMaxPayloadLength | ( | RadioModems_t | modem, |
| uint8_t | max | ||
| ) | [virtual, inherited] |
Sets the maximum payload length.
- Parameters:
-
[IN] modem Radio modem to be used [0: FSK, 1: LoRa] [IN] max Maximum payload length in bytes
Implements Radio.
Definition at line 1197 of file sx1276.cpp.
| void SetModem | ( | RadioModems_t | modem ) | [virtual, inherited] |
Configures the SX1276 with the given modem.
- Parameters:
-
[IN] modem Modem to be used [0: FSK, 1: LoRa]
Implements Radio.
Definition at line 1160 of file sx1276.cpp.
| void SetOpMode | ( | uint8_t | opMode ) | [protected, virtual, inherited] |
Sets the SX1276 operating mode.
- Parameters:
-
[IN] opMode New operating mode
Definition at line 1146 of file sx1276.cpp.
| void SetPublicNetwork | ( | bool | enable ) | [virtual, inherited] |
Sets the network to public or private. Updates the sync byte.
- Remarks:
- Applies to LoRa modem only
- Parameters:
-
[IN] enable if true, it enables a public network
Implements Radio.
Definition at line 1215 of file sx1276.cpp.
| void SetRfTxPower | ( | int8_t | power ) | [virtual] |
Sets the radio output power.
- Parameters:
-
[IN] power Sets the RF output power
Implements SX1276.
Definition at line 183 of file sx1276-mbed-hal.cpp.
| void SetRxConfig | ( | RadioModems_t | modem, |
| uint32_t | bandwidth, | ||
| uint32_t | datarate, | ||
| uint8_t | coderate, | ||
| uint32_t | bandwidthAfc, | ||
| uint16_t | preambleLen, | ||
| uint16_t | symbTimeout, | ||
| bool | fixLen, | ||
| uint8_t | payloadLen, | ||
| bool | crcOn, | ||
| bool | freqHopOn, | ||
| uint8_t | hopPeriod, | ||
| bool | iqInverted, | ||
| bool | rxContinuous | ||
| ) | [virtual, inherited] |
Sets the reception parameters.
- Parameters:
-
[IN] modem Radio modem to be used [0: FSK, 1: LoRa] [IN] bandwidth Sets the bandwidth FSK : >= 2600 and <= 250000 Hz LoRa: [0: 125 kHz, 1: 250 kHz, 2: 500 kHz, 3: Reserved] [IN] datarate Sets the Datarate FSK : 600..300000 bits/s LoRa: [6: 64, 7: 128, 8: 256, 9: 512, 10: 1024, 11: 2048, 12: 4096 chips] [IN] coderate Sets the coding rate ( LoRa only ) FSK : N/A ( set to 0 ) LoRa: [1: 4/5, 2: 4/6, 3: 4/7, 4: 4/8] [IN] bandwidthAfc Sets the AFC Bandwidth ( FSK only ) FSK : >= 2600 and <= 250000 Hz LoRa: N/A ( set to 0 ) [IN] preambleLen Sets the Preamble length ( LoRa only ) FSK : N/A ( set to 0 ) LoRa: Length in symbols ( the hardware adds 4 more symbols ) [IN] symbTimeout Sets the RxSingle timeout value FSK : timeout number of bytes LoRa: timeout in symbols [IN] fixLen Fixed length packets [0: variable, 1: fixed] [IN] payloadLen Sets payload length when fixed lenght is used [IN] crcOn Enables/Disables the CRC [0: OFF, 1: ON] [IN] freqHopOn Enables disables the intra-packet frequency hopping [0: OFF, 1: ON] (LoRa only) [IN] hopPeriod Number of symbols bewteen each hop (LoRa only) [IN] iqInverted Inverts IQ signals ( LoRa only ) FSK : N/A ( set to 0 ) LoRa: [0: not inverted, 1: inverted] [IN] rxContinuous Sets the reception in continuous mode [false: single mode, true: continuous mode]
Implements Radio.
Definition at line 295 of file sx1276.cpp.
| void SetTxConfig | ( | RadioModems_t | modem, |
| int8_t | power, | ||
| uint32_t | fdev, | ||
| uint32_t | bandwidth, | ||
| uint32_t | datarate, | ||
| uint8_t | coderate, | ||
| uint16_t | preambleLen, | ||
| bool | fixLen, | ||
| bool | crcOn, | ||
| bool | freqHopOn, | ||
| uint8_t | hopPeriod, | ||
| bool | iqInverted, | ||
| uint32_t | timeout | ||
| ) | [virtual, inherited] |
Sets the transmission parameters.
- Parameters:
-
[IN] modem Radio modem to be used [0: FSK, 1: LoRa] [IN] power Sets the output power [dBm] [IN] fdev Sets the frequency deviation ( FSK only ) FSK : [Hz] LoRa: 0 [IN] bandwidth Sets the bandwidth ( LoRa only ) FSK : 0 LoRa: [0: 125 kHz, 1: 250 kHz, 2: 500 kHz, 3: Reserved] [IN] datarate Sets the Datarate FSK : 600..300000 bits/s LoRa: [6: 64, 7: 128, 8: 256, 9: 512, 10: 1024, 11: 2048, 12: 4096 chips] [IN] coderate Sets the coding rate ( LoRa only ) FSK : N/A ( set to 0 ) LoRa: [1: 4/5, 2: 4/6, 3: 4/7, 4: 4/8] [IN] preambleLen Sets the preamble length [IN] fixLen Fixed length packets [0: variable, 1: fixed] [IN] crcOn Enables disables the CRC [0: OFF, 1: ON] [IN] freqHopOn Enables disables the intra-packet frequency hopping [0: OFF, 1: ON] (LoRa only) [IN] hopPeriod Number of symbols bewteen each hop (LoRa only) [IN] iqInverted Inverts IQ signals ( LoRa only ) FSK : N/A ( set to 0 ) LoRa: [0: not inverted, 1: inverted] [IN] timeout Transmission timeout [ms]
Implements Radio.
Definition at line 467 of file sx1276.cpp.
| void SetTxContinuousWave | ( | uint32_t | freq, |
| int8_t | power, | ||
| uint16_t | time | ||
| ) | [virtual, inherited] |
Sets the radio in continuous wave transmission mode.
- Parameters:
-
[IN],: freq Channel RF frequency [IN],: power Sets the output power [dBm] [IN],: time Transmission mode timeout [s]
Implements Radio.
Definition at line 1054 of file sx1276.cpp.
| void Sleep | ( | void | ) | [virtual, inherited] |
| void SpiInit | ( | void | ) | [protected, virtual] |
| void Standby | ( | void | ) | [virtual, inherited] |
| void StartCad | ( | void | ) | [virtual, inherited] |
| uint32_t TimeOnAir | ( | RadioModems_t | modem, |
| int16_t | pktLen | ||
| ) | [virtual, inherited] |
Computes the packet time on air for the given payload.
Can only be called once SetRxConfig or SetTxConfig have been called
- Parameters:
-
[IN] modem Radio modem to be used [0: FSK, 1: LoRa] [IN] pktLen Packet payload length
- Return values:
-
airTime Computed airTime for the given packet payload length
Implements Radio.
Definition at line 600 of file sx1276.cpp.
| void Tx | ( | uint32_t | timeout ) | [virtual, inherited] |
Sets the radio in transmission mode for the given time.
- Parameters:
-
[IN] timeout Transmission timeout [ms] [0: continuous, others timeout]
Implements Radio.
Definition at line 959 of file sx1276.cpp.
| void Write | ( | uint8_t | addr, |
| void * | buffer, | ||
| uint8_t | size | ||
| ) | [virtual] |
Writes multiple radio registers starting at address.
- Parameters:
-
[IN] addr First Radio register address [IN] buffer Buffer containing the new register's values [IN] size Number of registers to be written
Implements SX1276.
Definition at line 406 of file sx1276-mbed-hal.cpp.
| void Write | ( | uint8_t | addr, |
| uint8_t | data | ||
| ) | [virtual] |
Writes the radio register at the specified address.
- Parameters:
-
[IN],: addr Register address [IN],: data New register value
Implements SX1276.
Definition at line 394 of file sx1276-mbed-hal.cpp.
| void WriteFifo | ( | void * | buffer, |
| uint8_t | size | ||
| ) | [virtual] |
Writes the buffer contents to the SX1276 FIFO.
- Parameters:
-
[IN] buffer Buffer containing data to be put on the FIFO. [IN] size Number of bytes to be written to the FIFO
Implements SX1276.
Definition at line 434 of file sx1276-mbed-hal.cpp.
Field Documentation
DigitalOut* _antSwitch [protected] |
Antenna switch GPIO pins objects
Definition at line 44 of file sx1276-mbed-hal.h.
InterruptIn* _dio0 [protected] |
SX1276 DIO pins
Definition at line 67 of file sx1276-mbed-hal.h.
DigitalInOut* _reset [protected] |
SX1276 Reset pin
Definition at line 51 of file sx1276-mbed-hal.h.
XSPI* _spi [protected] |
SPI Interface
Definition at line 61 of file sx1276-mbed-hal.h.
DigitalOut* _tcxo [protected] |
TCXO being used with the Murata Module
Definition at line 56 of file sx1276-mbed-hal.h.
DioIrqHandler* dioIrq [protected, inherited] |
const SX1276::RadioRegisters RadioRegsInit [static, inherited] |
{
{ MODEM_FSK , REG_LNA , 0x23 },
{ MODEM_FSK , REG_RXCONFIG , 0x1E },
{ MODEM_FSK , REG_RSSICONFIG , 0xD2 },
{ MODEM_FSK , REG_AFCFEI , 0x01 },
{ MODEM_FSK , REG_PREAMBLEDETECT , 0xAA },
{ MODEM_FSK , REG_OSC , 0x07 },
{ MODEM_FSK , REG_SYNCCONFIG , 0x12 },
{ MODEM_FSK , REG_SYNCVALUE1 , 0xC1 },
{ MODEM_FSK , REG_SYNCVALUE2 , 0x94 },
{ MODEM_FSK , REG_SYNCVALUE3 , 0xC1 },
{ MODEM_FSK , REG_PACKETCONFIG1 , 0xD8 },
{ MODEM_FSK , REG_FIFOTHRESH , 0x8F },
{ MODEM_FSK , REG_IMAGECAL , 0x02 },
{ MODEM_FSK , REG_DIOMAPPING1 , 0x00 },
{ MODEM_FSK , REG_DIOMAPPING2 , 0x30 },
{ MODEM_LORA, REG_LR_PAYLOADMAXLENGTH, 0x40 },
}
Radio hardware registers initialization definition.
- Remarks:
- Can be automatically generated by the SX1276 GUI (not yet implemented)
Timeout txTimeoutTimer [protected] |
Tx and Rx timers
Definition at line 77 of file sx1276-mbed-hal.h.
Generated on Tue Jul 12 2022 13:55:05 by
1.7.2