Typo fixes
This commit is contained in:
parent
5974da27de
commit
8fd0a67a78
16 changed files with 60 additions and 55 deletions
|
@ -348,7 +348,7 @@
|
|||
/*
|
||||
* Uncomment to enable "paranoid" SPI mode
|
||||
* Every write to an SPI register using SPI set function will be verified by a subsequent read operation.
|
||||
* This improves reliablility, but slightly slows down communication.
|
||||
* This improves reliability, but slightly slows down communication.
|
||||
* Note: Enabled by default.
|
||||
*/
|
||||
#if !defined(RADIOLIB_SPI_PARANOID)
|
||||
|
|
13
src/Hal.h
13
src/Hal.h
|
@ -193,13 +193,13 @@ class RadioLibHal {
|
|||
/*!
|
||||
\brief Module initialization method.
|
||||
This will be called by all radio modules at the beginning of startup.
|
||||
Can be used to e.g., initalize SPI interface.
|
||||
Can be used to e.g., initialize SPI interface.
|
||||
*/
|
||||
virtual void init();
|
||||
|
||||
/*!
|
||||
\brief Module termination method.
|
||||
This will be called by all radio modules when the desctructor is called.
|
||||
This will be called by all radio modules when the destructor is called.
|
||||
Can be used to e.g., stop SPI interface.
|
||||
*/
|
||||
virtual void term();
|
||||
|
@ -251,7 +251,12 @@ class RadioLibHal {
|
|||
Will write at most RADIOLIB_HAL_PERSISTENT_STORAGE_SIZE bytes.
|
||||
*/
|
||||
void wipePersistentStorage();
|
||||
|
||||
|
||||
/*!
|
||||
\brief Method to convert from persistent parameter ID to its physical address.
|
||||
\param id Parameter ID.
|
||||
\returns Parameter physical address.
|
||||
*/
|
||||
uint32_t getPersistentAddr(uint32_t id);
|
||||
|
||||
/*!
|
||||
|
@ -269,7 +274,7 @@ class RadioLibHal {
|
|||
This method DOES NOT perform any endianness conversion, so the value
|
||||
will be retrieved in the system endian!
|
||||
\param id Parameter ID to load from.
|
||||
\returns The lodaded value.
|
||||
\returns The loaded value.
|
||||
*/
|
||||
template<typename T>
|
||||
T getPersistentParameter(uint32_t id);
|
||||
|
|
|
@ -256,8 +256,8 @@ class Module {
|
|||
\brief SPI single transfer method.
|
||||
\param cmd SPI access command (read/write/burst/...).
|
||||
\param reg Address of SPI register to transfer to/from.
|
||||
\param dataOut Data that will be transfered from master to slave.
|
||||
\param dataIn Data that was transfered from slave to master.
|
||||
\param dataOut Data that will be transferred from master to slave.
|
||||
\param dataIn Data that was transferred from slave to master.
|
||||
\param numBytes Number of bytes to transfer.
|
||||
*/
|
||||
void SPItransfer(uint8_t cmd, uint16_t reg, uint8_t* dataOut, uint8_t* dataIn, size_t numBytes);
|
||||
|
@ -319,8 +319,8 @@ class Module {
|
|||
\param cmd SPI operation command.
|
||||
\param cmdLen SPI command length in bytes.
|
||||
\param write Set to true for write commands, false for read commands.
|
||||
\param dataOut Data that will be transfered from master to slave.
|
||||
\param dataIn Data that was transfered from slave to master.
|
||||
\param dataOut Data that will be transferred from master to slave.
|
||||
\param dataIn Data that was transferred from slave to master.
|
||||
\param numBytes Number of bytes to transfer.
|
||||
\param waitForGpio Whether to wait for some GPIO at the end of transfer (e.g. BUSY line on SX126x/SX128x).
|
||||
\param timeout GPIO wait period timeout in milliseconds.
|
||||
|
|
|
@ -17,22 +17,22 @@
|
|||
#define RADIOLIB_SHAPING_NONE (0x00)
|
||||
|
||||
/*!
|
||||
\brief Gaussin shaping filter, BT = 0.3
|
||||
\brief Gaussian shaping filter, BT = 0.3
|
||||
*/
|
||||
#define RADIOLIB_SHAPING_0_3 (0x01)
|
||||
|
||||
/*!
|
||||
\brief Gaussin shaping filter, BT = 0.5
|
||||
\brief Gaussian shaping filter, BT = 0.5
|
||||
*/
|
||||
#define RADIOLIB_SHAPING_0_5 (0x02)
|
||||
|
||||
/*!
|
||||
\brief Gaussin shaping filter, BT = 0.7
|
||||
\brief Gaussian shaping filter, BT = 0.7
|
||||
*/
|
||||
#define RADIOLIB_SHAPING_0_7 (0x03)
|
||||
|
||||
/*!
|
||||
\brief Gaussin shaping filter, BT = 1.0
|
||||
\brief Gaussian shaping filter, BT = 1.0
|
||||
*/
|
||||
#define RADIOLIB_SHAPING_1_0 (0x04)
|
||||
|
||||
|
@ -310,7 +310,7 @@
|
|||
#define RADIOLIB_ERR_INVALID_MIC_E_TELEMETRY_LENGTH (-203)
|
||||
|
||||
/*!
|
||||
\brief Mic-E message cannot contaion both telemetry and status text.
|
||||
\brief Mic-E message cannot contain both telemetry and status text.
|
||||
*/
|
||||
#define RADIOLIB_ERR_MIC_E_TELEMETRY_STATUS (-204)
|
||||
|
||||
|
|
|
@ -124,7 +124,7 @@
|
|||
|
||||
// RADIOLIB_RF69_REG_BITRATE_MSB + REG_BITRATE_LSB
|
||||
#define RADIOLIB_RF69_BITRATE_MSB 0x1A // 7 0 bit rate setting: rate = F(XOSC) / BITRATE
|
||||
#define RADIOLIB_RF69_BITRATE_LSB 0x0B // 7 0 default value: 4.8 kbps 0x40 // 7 0
|
||||
#define RADIOLIB_RF69_BITRATE_LSB 0x0B // 7 0 default value: 4.8 kbps
|
||||
|
||||
// RADIOLIB_RF69_REG_FDEV_MSB + REG_FDEV_LSB
|
||||
#define RADIOLIB_RF69_FDEV_MSB 0x00 // 5 0 frequency deviation: f_dev = f_step * FDEV
|
||||
|
@ -671,7 +671,7 @@ class RF69: public PhysicalLayer {
|
|||
bool fifoAdd(uint8_t* data, int totalLen, int* remLen);
|
||||
|
||||
/*!
|
||||
\brief Set interrupt service routine function to call when FIFO is sufficently full to read.
|
||||
\brief Set interrupt service routine function to call when FIFO is sufficiently full to read.
|
||||
\param data Pointer to a buffer that stores the receive data.
|
||||
\param totalLen Total number of bytes to receive.
|
||||
\param rcvLen Pointer to a counter holding the number of bytes that have been received so far.
|
||||
|
@ -714,7 +714,7 @@ class RF69: public PhysicalLayer {
|
|||
/*!
|
||||
\brief Reads data received after calling startReceive method.
|
||||
\param data Pointer to array to save the received binary data.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retreived automatically.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retrieved automatically.
|
||||
When more bytes than received are requested, only the number of bytes requested will be returned.
|
||||
\returns \ref status_codes
|
||||
*/
|
||||
|
@ -974,7 +974,7 @@ class RF69: public PhysicalLayer {
|
|||
|
||||
#if !defined(RADIOLIB_EXCLUDE_DIRECT_RECEIVE)
|
||||
/*!
|
||||
\brief Set interrupt service routine function to call when data bit is receveid in direct mode.
|
||||
\brief Set interrupt service routine function to call when data bit is received in direct mode.
|
||||
\param func Pointer to interrupt service routine.
|
||||
*/
|
||||
void setDirectAction(void (*func)(void));
|
||||
|
|
|
@ -81,7 +81,7 @@ class STM32WLx : public SX1262 {
|
|||
This automatically switches between the low-power (LP) and high-power (HP) amplifier.
|
||||
|
||||
LP is preferred and supports -17 to +14dBm. When a higher power is
|
||||
requested (or the LP amplifier is marked as unvailable using
|
||||
requested (or the LP amplifier is marked as unavailable using
|
||||
setRfSwitchTable()), HP is used, which supports -9 to +22dBm.
|
||||
|
||||
\param power Output power to be set in dBm.
|
||||
|
|
|
@ -35,10 +35,10 @@
|
|||
#define RADIOLIB_SX126X_CMD_SET_RX_TX_FALLBACK_MODE 0x93
|
||||
|
||||
// register and buffer access commands
|
||||
#define RADIOLIB_SX126X_CMD_WRITE_REGISTER 0x0D
|
||||
#define RADIOLIB_SX126X_CMD_READ_REGISTER 0x1D
|
||||
#define RADIOLIB_SX126X_CMD_WRITE_BUFFER 0x0E
|
||||
#define RADIOLIB_SX126X_CMD_READ_BUFFER 0x1E
|
||||
#define RADIOLIB_SX126X_CMD_WRITE_REGISTER 0x0D
|
||||
#define RADIOLIB_SX126X_CMD_READ_REGISTER 0x1D
|
||||
#define RADIOLIB_SX126X_CMD_WRITE_BUFFER 0x0E
|
||||
#define RADIOLIB_SX126X_CMD_READ_BUFFER 0x1E
|
||||
|
||||
// DIO and IRQ control
|
||||
#define RADIOLIB_SX126X_CMD_SET_DIO_IRQ_PARAMS 0x08
|
||||
|
@ -673,7 +673,7 @@ class SX126x: public PhysicalLayer {
|
|||
/*!
|
||||
\brief Reads data received after calling startReceive method.
|
||||
\param data Pointer to array to save the received binary data.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retreived automatically.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retrieved automatically.
|
||||
When more bytes than received are requested, only the number of bytes requested will be returned.
|
||||
\returns \ref status_codes
|
||||
*/
|
||||
|
|
|
@ -770,7 +770,7 @@ class SX127x: public PhysicalLayer {
|
|||
bool fifoAdd(uint8_t* data, int totalLen, int* remLen);
|
||||
|
||||
/*!
|
||||
\brief Set interrupt service routine function to call when FIFO is sufficently full to read.
|
||||
\brief Set interrupt service routine function to call when FIFO is sufficiently full to read.
|
||||
\param data Pointer to a buffer that stores the receive data.
|
||||
\param totalLen Total number of bytes to receive.
|
||||
\param rcvLen Pointer to a counter holding the number of bytes that have been received so far.
|
||||
|
@ -822,7 +822,7 @@ class SX127x: public PhysicalLayer {
|
|||
/*!
|
||||
\brief Reads data that was received after calling startReceive method. This method reads len characters.
|
||||
\param data Pointer to array to save the received binary data.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retreived automatically.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retrieved automatically.
|
||||
When more bytes than received are requested, only the number of bytes requested will be returned.
|
||||
\returns \ref status_codes
|
||||
*/
|
||||
|
@ -1093,7 +1093,7 @@ class SX127x: public PhysicalLayer {
|
|||
|
||||
#if !defined(RADIOLIB_EXCLUDE_DIRECT_RECEIVE)
|
||||
/*!
|
||||
\brief Set interrupt service routine function to call when data bit is receveid in direct mode.
|
||||
\brief Set interrupt service routine function to call when data bit is received in direct mode.
|
||||
\param func Pointer to interrupt service routine.
|
||||
*/
|
||||
void setDirectAction(void (*func)(void));
|
||||
|
@ -1202,7 +1202,7 @@ class SX127x: public PhysicalLayer {
|
|||
/*!
|
||||
\brief Calculate exponent and mantissa values for receiver bandwidth and AFC
|
||||
\param bandwidth bandwidth to be set (in kHz).
|
||||
\returns bandwidth in manitsa and exponent format
|
||||
\returns bandwidth in mantissa and exponent format
|
||||
*/
|
||||
static uint8_t calculateBWManExp(float bandwidth);
|
||||
|
||||
|
|
|
@ -564,7 +564,7 @@ class SX128x: public PhysicalLayer {
|
|||
/*!
|
||||
\brief Reads data received after calling startReceive method.
|
||||
\param data Pointer to array to save the received binary data.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retreived automatically.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retrieved automatically.
|
||||
When more bytes than received are requested, only the number of bytes requested will be returned.
|
||||
\returns \ref status_codes
|
||||
*/
|
||||
|
|
|
@ -712,7 +712,7 @@ class Si443x: public PhysicalLayer {
|
|||
/*!
|
||||
\brief Reads data that was received after calling startReceive method. This method reads len characters.
|
||||
\param data Pointer to array to save the received binary data.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retreived automatically.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retrieved automatically.
|
||||
When more bytes than received are requested, only the number of bytes requested will be returned.
|
||||
\returns \ref status_codes
|
||||
*/
|
||||
|
@ -798,7 +798,7 @@ class Si443x: public PhysicalLayer {
|
|||
|
||||
#if !defined(RADIOLIB_EXCLUDE_DIRECT_RECEIVE)
|
||||
/*!
|
||||
\brief Set interrupt service routine function to call when data bit is receveid in direct mode.
|
||||
\brief Set interrupt service routine function to call when data bit is received in direct mode.
|
||||
\param func Pointer to interrupt service routine.
|
||||
*/
|
||||
void setDirectAction(void (*func)(void));
|
||||
|
|
|
@ -165,10 +165,10 @@ struct LoRaWANChannelSpan_t {
|
|||
\brief Structure to save information about LoRaWAN band
|
||||
*/
|
||||
struct LoRaWANBand_t {
|
||||
/*! \brief The base downlik data rate. Used to calculate data rate changes for adaptive data rate */
|
||||
/*! \brief The base downlink data rate. Used to calculate data rate changes for adaptive data rate */
|
||||
uint8_t downlinkDataRateBase;
|
||||
|
||||
/*! \brief The minimum allowed downlik data rate. Used to calculate data rate changes for adaptive data rate */
|
||||
/*! \brief The minimum allowed downlink data rate. Used to calculate data rate changes for adaptive data rate */
|
||||
uint8_t downlinkDataRateMin;
|
||||
|
||||
/*! \brief Array of allowed maximum payload lengths for each data rate */
|
||||
|
@ -326,7 +326,7 @@ class LoRaWANNode {
|
|||
template<typename T>
|
||||
static T ntoh(uint8_t* buff, size_t size = 0);
|
||||
|
||||
// host-to-network conversion method - takes data from host variable and and converts it to network packet endiands
|
||||
// host-to-network conversion method - takes data from host variable and and converts it to network packet endians
|
||||
template<typename T>
|
||||
static void hton(uint8_t* buff, T val, size_t size = 0);
|
||||
};
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
#define RADIOLIB_MORSE_DOT 0b0
|
||||
#define RADIOLIB_MORSE_DASH 0b1
|
||||
#define RADIOLIB_MORSE_GUARDBIT 0b1
|
||||
#define RADIOLIB_MORSE_UNSUPORTED 0xFF
|
||||
#define RADIOLIB_MORSE_UNSUPPORTED 0xFF
|
||||
#define RADIOLIB_MORSE_ASCII_OFFSET 32
|
||||
#define RADIOLIB_MORSE_INTER_SYMBOL 0x00
|
||||
#define RADIOLIB_MORSE_CHAR_COMPLETE 0x01
|
||||
|
@ -18,19 +18,19 @@
|
|||
// Morse character table: - using codes defined in ITU-R M.1677-1
|
||||
// - Morse code representation is saved LSb first, using additional bit as guard
|
||||
// - position in array corresponds ASCII code minus RADIOLIB_MORSE_ASCII_OFFSET
|
||||
// - ASCII characters marked RADIOLIB_MORSE_UNSUPORTED do not have ITU-R M.1677-1 equivalent
|
||||
// - ASCII characters marked RADIOLIB_MORSE_UNSUPPORTED do not have ITU-R M.1677-1 equivalent
|
||||
static const uint8_t MorseTable[] RADIOLIB_NONVOLATILE = {
|
||||
0b00, // space
|
||||
0b110101, // ! (unsupported)
|
||||
0b1010010, // "
|
||||
RADIOLIB_MORSE_UNSUPORTED, // # (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPORTED, // $ (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPORTED, // % (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPORTED, // & (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // # (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // $ (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // % (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // & (unsupported)
|
||||
0b1011110, // '
|
||||
0b101101, // (
|
||||
0b1101101, // )
|
||||
RADIOLIB_MORSE_UNSUPORTED, // * (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // * (unsupported)
|
||||
0b101010, // +
|
||||
0b1110011, // ,
|
||||
0b1100001, // -
|
||||
|
@ -47,10 +47,10 @@ static const uint8_t MorseTable[] RADIOLIB_NONVOLATILE = {
|
|||
0b100111, // 8
|
||||
0b101111, // 9
|
||||
0b1000111, // :
|
||||
RADIOLIB_MORSE_UNSUPORTED, // ; (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPORTED, // < (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // ; (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // < (unsupported)
|
||||
0b110001, // =
|
||||
RADIOLIB_MORSE_UNSUPORTED, // > (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // > (unsupported)
|
||||
0b1001100, // ?
|
||||
0b1010110, // @
|
||||
0b110, // A
|
||||
|
@ -79,9 +79,9 @@ static const uint8_t MorseTable[] RADIOLIB_NONVOLATILE = {
|
|||
0b11001, // X
|
||||
0b11101, // Y
|
||||
0b10011, // Z
|
||||
RADIOLIB_MORSE_UNSUPORTED, // [ (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPORTED, // \ (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPORTED, // ] (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // [ (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // \ (unsupported)
|
||||
RADIOLIB_MORSE_UNSUPPORTED, // ] (unsupported)
|
||||
0b1101000, // ^ (unsupported, used as alias for end of work)
|
||||
0b110101 // _ (unsupported, used as alias for starting signal)
|
||||
};
|
||||
|
@ -124,7 +124,7 @@ class MorseClient: public RadioLibPrint {
|
|||
|
||||
/*!
|
||||
\brief Decode Morse symbol to ASCII.
|
||||
\param symbol Morse code symbol, respresented as outlined in MorseTable.
|
||||
\param symbol Morse code symbol, represented as outlined in MorseTable.
|
||||
\param len Symbol length (number of dots and dashes).
|
||||
\returns ASCII character matching the symbol, or 0xFF if no match is found.
|
||||
*/
|
||||
|
|
|
@ -140,7 +140,7 @@ class PagerClient {
|
|||
/*!
|
||||
\brief Reads data that was received after calling startReceive method.
|
||||
\param str Address of Arduino String to save the received data.
|
||||
\param len Expected number of characters in the message. When set to 0, the message lengthwill be retreived
|
||||
\param len Expected number of characters in the message. When set to 0, the message length will be retrieved
|
||||
automatically. When more bytes than received are requested, only the number of bytes requested will be returned.
|
||||
\param addr Pointer to variable holding the address of the received pager message.
|
||||
Set to NULL to not retrieve address.
|
||||
|
@ -153,7 +153,7 @@ class PagerClient {
|
|||
\brief Reads data that was received after calling startReceive method.
|
||||
\param data Pointer to array to save the received message.
|
||||
\param len Pointer to variable holding the number of bytes that will be read. When set to 0, the packet length
|
||||
will be retreived automatically. When more bytes than received are requested, only the number of bytes
|
||||
will be retrieved automatically. When more bytes than received are requested, only the number of bytes
|
||||
requested will be returned. Upon completion, the number of bytes received will be written to this variable.
|
||||
\param addr Pointer to variable holding the address of the received pager message.
|
||||
Set to NULL to not retrieve address.
|
||||
|
|
|
@ -172,7 +172,7 @@ class PhysicalLayer {
|
|||
/*!
|
||||
\brief Reads data that was received after calling startReceive method.
|
||||
\param str Address of Arduino String to save the received data.
|
||||
\param len Expected number of characters in the message. When set to 0, the packet length will be retreived
|
||||
\param len Expected number of characters in the message. When set to 0, the packet length will be retrieved
|
||||
automatically. When more bytes than received are requested, only the number of bytes requested will be returned.
|
||||
\returns \ref status_codes
|
||||
*/
|
||||
|
@ -182,7 +182,7 @@ class PhysicalLayer {
|
|||
/*!
|
||||
\brief Reads data that was received after calling startReceive method.
|
||||
\param data Pointer to array to save the received binary data.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retreived automatically.
|
||||
\param len Number of bytes that will be read. When set to 0, the packet length will be retrieved automatically.
|
||||
When more bytes than received are requested, only the number of bytes requested will be returned.
|
||||
\returns \ref status_codes
|
||||
*/
|
||||
|
@ -340,7 +340,7 @@ class PhysicalLayer {
|
|||
int16_t setDirectSyncWord(uint32_t syncWord, uint8_t len);
|
||||
|
||||
/*!
|
||||
\brief Set interrupt service routine function to call when data bit is receveid in direct mode.
|
||||
\brief Set interrupt service routine function to call when data bit is received in direct mode.
|
||||
Must be implemented in module class.
|
||||
\param func Pointer to interrupt service routine.
|
||||
*/
|
||||
|
|
|
@ -54,7 +54,7 @@ class RadioLibCRC {
|
|||
RadioLibCRC();
|
||||
|
||||
/*!
|
||||
\brief Calcualte checksum of a buffer.
|
||||
\brief Calculate checksum of a buffer.
|
||||
\param buff Buffer to calculate the checksum over.
|
||||
\param len Size of the buffer in bytes.
|
||||
\returns The resulting checksum.
|
||||
|
|
|
@ -136,7 +136,7 @@ class RadioLibAES128 {
|
|||
void generateCMAC(uint8_t* in, size_t len, uint8_t* cmac);
|
||||
|
||||
/*!
|
||||
\brief Verify the recevied CMAC. This just calculates the CMAC again and compares the results.
|
||||
\brief Verify the received CMAC. This just calculates the CMAC again and compares the results.
|
||||
\param in Input data (unpadded).
|
||||
\param len Length of the input data.
|
||||
\param cmac CMAC to verify.
|
||||
|
|
Loading…
Add table
Reference in a new issue