RadioLib Universal wireless communication library for Arduino

Macros
Status Codes

## Macros
#define | RADIOLIB_ERR_NONE (0)
| No error, method executed successfully.
#define | RADIOLIB_ERR_UNKNOWN (-1)
| There was an unexpected, unknown error. If you see this, something went incredibly wrong. Your Arduino may be possessed, contact your local exorcist to resolve this error.
#define | RADIOLIB_ERR_CHIP_NOT_FOUND (-2)
| Radio chip was not found during initialization. This can be caused by specifying wrong chip type in the constructor (i.e. calling SX1272 constructor for SX1278 chip) or by a fault in your wiring (incorrect slave select pin).
#define | RADIOLIB_ERR_MEMORY_ALLOCATION_FAILED (-3)
| Failed to allocate memory for temporary buffer. This can be cause by not enough RAM or by passing invalid pointer.
#define | RADIOLIB_ERR_PACKET_TOO_LONG (-4)
| Packet supplied to transmission method was longer than limit.
#define | RADIOLIB_ERR_TX_TIMEOUT (-5)
| Timed out waiting for transmission finish.
#define | RADIOLIB_ERR_RX_TIMEOUT (-6)
| Timed out waiting for incoming transmission.
#define | RADIOLIB_ERR_CRC_MISMATCH (-7)
| The calculated and expected CRCs of received packet do not match. This means that the packet was damaged during transmission and should be sent again.
#define | RADIOLIB_ERR_INVALID_BANDWIDTH (-8)
| The supplied bandwidth value is invalid for this module.
#define | RADIOLIB_ERR_INVALID_SPREADING_FACTOR (-9)
| The supplied spreading factor value is invalid for this module.
#define | RADIOLIB_ERR_INVALID_CODING_RATE (-10)
| The supplied coding rate value is invalid for this module.
#define | RADIOLIB_ERR_INVALID_BIT_RANGE (-11)
| Internal only.
#define | RADIOLIB_ERR_INVALID_FREQUENCY (-12)
| The supplied frequency value is invalid for this module.
#define | RADIOLIB_ERR_INVALID_OUTPUT_POWER (-13)
| The supplied output power value is invalid for this module.
#define | RADIOLIB_PREAMBLE_DETECTED (-14)
| LoRa preamble was detected during channel activity detection. This means that there is some LoRa device currently transmitting in your channel.
#define | RADIOLIB_CHANNEL_FREE (-15)
| No LoRa preambles were detected during channel activity detection. Your channel is free.
#define | RADIOLIB_ERR_SPI_WRITE_FAILED (-16)
| Real value in SPI register does not match the expected one. This can be caused by faulty SPI wiring.
#define | RADIOLIB_ERR_INVALID_CURRENT_LIMIT (-17)
| The supplied current limit value is invalid.
#define | RADIOLIB_ERR_INVALID_PREAMBLE_LENGTH (-18)
| The supplied preamble length is invalid.
#define | RADIOLIB_ERR_INVALID_GAIN (-19)
| The supplied gain value is invalid.
#define | RADIOLIB_ERR_WRONG_MODEM (-20)
| User tried to execute modem-exclusive method on a wrong modem. For example, this can happen when you try to change LoRa configuration when FSK modem is active.
#define | RADIOLIB_ERR_INVALID_NUM_SAMPLES (-21)
| The supplied number of RSSI samples is invalid.
#define | RADIOLIB_ERR_INVALID_RSSI_OFFSET (-22)
| The supplied RSSI offset is invalid.
#define | RADIOLIB_ERR_INVALID_ENCODING (-23)
| The supplied encoding is invalid.
#define | RADIOLIB_ERR_LORA_HEADER_DAMAGED (-24)
| LoRa packet header has been damaged.
#define | RADIOLIB_ERR_UNSUPPORTED (-25)
| The requested functionality is not supported for this device.
#define | RADIOLIB_ERR_INVALID_DIO_PIN (-26)
| The specified DIO pin does not exist on this device.
#define | RADIOLIB_ERR_INVALID_RSSI_THRESHOLD (-27)
| The supplied RSSI threshold is invalid.
#define | RADIOLIB_ERR_NULL_POINTER (-28)
| A `NULL` pointer has been encountered. If you see this, there may be a potential security vulnerability.
#define | RADIOLIB_ERR_INVALID_BIT_RATE (-101)
| The supplied bit rate value is invalid.
#define | RADIOLIB_ERR_INVALID_FREQUENCY_DEVIATION (-102)
| The supplied frequency deviation value is invalid.
#define | RADIOLIB_ERR_INVALID_BIT_RATE_BW_RATIO (-103)
| The supplied bit rate to bandwidth ratio is invalid. See the module datasheet for more information.
#define | RADIOLIB_ERR_INVALID_RX_BANDWIDTH (-104)
| The supplied receiver bandwidth value is invalid.
#define | RADIOLIB_ERR_INVALID_SYNC_WORD (-105)
| The supplied FSK sync word is invalid.
#define | RADIOLIB_ERR_INVALID_DATA_SHAPING (-106)
| The supplied FSK data shaping option is invalid.
#define | RADIOLIB_ERR_INVALID_MODULATION (-107)
| The current modulation is invalid for the requested operation.
#define | RADIOLIB_ERR_INVALID_OOK_RSSI_PEAK_TYPE (-108)
| Supplied Peak type is invalid.
#define | RADIOLIB_ERR_INVALID_SYMBOL (-201)
| Supplied APRS symbol is invalid.
#define | RADIOLIB_ERR_INVALID_MIC_E_TELEMETRY (-202)
| Mic-E Telemetry is invalid.
#define | RADIOLIB_ERR_INVALID_MIC_E_TELEMETRY_LENGTH (-203)
| Mic-E Telemetry length is invalid (only 0, 2 or 5 is allowed).
#define | RADIOLIB_ERR_MIC_E_TELEMETRY_STATUS (-204)
| Mic-E message cannot contain both telemetry and status text.
#define | RADIOLIB_ERR_INVALID_SSDV_MODE (-301)
| SSDV mode is invalid.
#define | RADIOLIB_ERR_INVALID_IMAGE_SIZE (-302)
| Image size is invalid.
#define | RADIOLIB_ERR_INVALID_IMAGE_QUALITY (-303)
| Image quality is invalid.
#define | RADIOLIB_ERR_INVALID_SUBSAMPLING (-304)
| Image subsampling is invalid.
#define | RADIOLIB_ERR_INVALID_RTTY_SHIFT (-401)
| Supplied RTTY frequency shift is invalid for this module.
#define | RADIOLIB_ERR_UNSUPPORTED_ENCODING (-402)
| Supplied RTTY encoding is invalid.
#define | RADIOLIB_ERR_INVALID_DATA_RATE (-501)
| Supplied data rate is invalid.
#define | RADIOLIB_ERR_INVALID_ADDRESS_WIDTH (-502)
| Supplied address width is invalid.
#define | RADIOLIB_ERR_INVALID_PIPE_NUMBER (-503)
| Supplied data pipe number is invalid.
#define | RADIOLIB_ERR_ACK_NOT_RECEIVED (-504)
| ACK packet from destination module was not received within 15 retries.
#define | RADIOLIB_ERR_INVALID_NUM_BROAD_ADDRS (-601)
| Supplied number of broadcast addresses is invalid.
#define | RADIOLIB_ERR_INVALID_CRC_CONFIGURATION (-701)
| Supplied CRC configuration is invalid.
#define | RADIOLIB_LORA_DETECTED (-702)
| Detected LoRa transmission while scanning channel.
#define | RADIOLIB_ERR_INVALID_TCXO_VOLTAGE (-703)
| Supplied TCXO reference voltage is invalid.
#define | RADIOLIB_ERR_INVALID_MODULATION_PARAMETERS (-704)
| Bit rate / bandwidth / frequency deviation ratio is invalid. See SX126x datasheet for details.
#define | RADIOLIB_ERR_SPI_CMD_TIMEOUT (-705)
| SX126x timed out while waiting for complete SPI command.
#define | RADIOLIB_ERR_SPI_CMD_INVALID (-706)
| SX126x received invalid SPI command.
#define | RADIOLIB_ERR_SPI_CMD_FAILED (-707)
| SX126x failed to execute SPI command. Often this means that the module is trying to use TCXO while XTAL is connected (or vice versa). Make sure your crystal setup (e.g. TCXO reference voltage) matches your hardware by setting "tcxoVoltage" to 0 when using XTAL module, or to appropriate value when using TCXO module.
#define | RADIOLIB_ERR_INVALID_SLEEP_PERIOD (-708)
| The supplied sleep period is invalid. More...
#define | RADIOLIB_ERR_INVALID_RX_PERIOD (-709)
| The supplied Rx period is invalid. More...
#define | RADIOLIB_ERR_INVALID_CALLSIGN (-801)
| The provided callsign is invalid. More...
#define | RADIOLIB_ERR_INVALID_NUM_REPEATERS (-802)
| The provided repeater configuration is invalid. More...
#define | RADIOLIB_ERR_INVALID_REPEATER_CALLSIGN (-803)
| One of the provided repeater callsigns is invalid. More...
#define | RADIOLIB_ERR_RANGING_TIMEOUT (-901)
| Timed out waiting for ranging exchange finish.
#define | RADIOLIB_ERR_INVALID_PAYLOAD (-1001)
| The provided payload data configuration is invalid.
#define | RADIOLIB_ERR_ADDRESS_NOT_FOUND (-1002)
| The requested address was not found in the received data.
#define | RADIOLIB_ERR_INVALID_FUNCTION (-1003)
| The function code is invalid. 2 Bits only.
#define | RADIOLIB_ERR_NETWORK_NOT_JOINED (-1101)
| Unable to restore existing LoRaWAN session because this node did not join any network yet.
#define | RADIOLIB_ERR_DOWNLINK_MALFORMED (-1102)
| Malformed downlink packet received from network server.
#define | RADIOLIB_ERR_INVALID_REVISION (-1103)
| Network server requested switch to unsupported LoRaWAN revision.
#define | RADIOLIB_ERR_INVALID_PORT (-1104)
| Invalid LoRaWAN uplink port requested by user.
#define | RADIOLIB_ERR_NO_RX_WINDOW (-1105)
| User did not enable downlink in time.
#define | RADIOLIB_ERR_INVALID_CHANNEL (-1106)
| No valid channel for the currently active LoRaWAN band was found.
#define | RADIOLIB_ERR_INVALID_CID (-1107)
| Invalid LoRaWAN MAC command ID.
#define | RADIOLIB_ERR_UPLINK_UNAVAILABLE (-1108)
| User requested to start uplink while still inside RX window.
#define | RADIOLIB_ERR_COMMAND_QUEUE_FULL (-1109)
| Unable to push new MAC command because the queue is full.
#define | RADIOLIB_ERR_COMMAND_QUEUE_EMPTY (-1110)
| Unable to pop existing MAC command because the queue is empty.
#define | RADIOLIB_ERR_COMMAND_QUEUE_ITEM_NOT_FOUND (-1111)
| Unable to delete MAC command because it was not found in the queue.
#define | RADIOLIB_ERR_JOIN_NONCE_INVALID (-1112)
| Unable to join network because JoinNonce is not higher than saved value.
#define | RADIOLIB_ERR_N_FCNT_DOWN_INVALID (-1113)
| Received downlink Network frame counter is invalid (lower than last heard value).
#define | RADIOLIB_ERR_A_FCNT_DOWN_INVALID (-1114)
| Received downlink Application frame counter is invalid (lower than last heard value).

## Detailed Description

## Macro Definition Documentation

## ◆ RADIOLIB_ERR_INVALID_CALLSIGN

#define RADIOLIB_ERR_INVALID_CALLSIGN (-801)

The provided callsign is invalid.

The specified callsign is longer than 6 ASCII characters.

## ◆ RADIOLIB_ERR_INVALID_NUM_REPEATERS

#define RADIOLIB_ERR_INVALID_NUM_REPEATERS (-802)

The provided repeater configuration is invalid.

The specified number of repeaters does not match number of repeater IDs or their callsigns.

## ◆ RADIOLIB_ERR_INVALID_REPEATER_CALLSIGN

#define RADIOLIB_ERR_INVALID_REPEATER_CALLSIGN (-803)

One of the provided repeater callsigns is invalid.

The specified callsign is longer than 6 ASCII characters.

## ◆ RADIOLIB_ERR_INVALID_RX_PERIOD

#define RADIOLIB_ERR_INVALID_RX_PERIOD (-709)

The supplied Rx period is invalid.

The specified Rx period is shorter or longer than the hardware can handle.

## ◆ RADIOLIB_ERR_INVALID_SLEEP_PERIOD

#define RADIOLIB_ERR_INVALID_SLEEP_PERIOD (-708)

The supplied sleep period is invalid.

The specified sleep period is shorter than the time necessary to sleep and wake the hardware including TCXO delay, or longer than the maximum possible