[SX126x] Added default channel scan override
This commit is contained in:
parent
f589d77e09
commit
86724197ec
2 changed files with 11 additions and 1 deletions
|
@ -429,6 +429,10 @@ int16_t SX126x::packetMode() {
|
||||||
return(state);
|
return(state);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int16_t SX126x::scanChannel() {
|
||||||
|
return(this->scanChannel(RADIOLIB_SX126X_CAD_PARAM_DEFAULT, RADIOLIB_SX126X_CAD_PARAM_DEFAULT, RADIOLIB_SX126X_CAD_PARAM_DEFAULT));
|
||||||
|
}
|
||||||
|
|
||||||
int16_t SX126x::scanChannel(uint8_t symbolNum, uint8_t detPeak, uint8_t detMin) {
|
int16_t SX126x::scanChannel(uint8_t symbolNum, uint8_t detPeak, uint8_t detMin) {
|
||||||
// set mode to CAD
|
// set mode to CAD
|
||||||
int state = startChannelScan(symbolNum, detPeak, detMin);
|
int state = startChannelScan(symbolNum, detPeak, detMin);
|
||||||
|
|
|
@ -528,6 +528,12 @@ class SX126x: public PhysicalLayer {
|
||||||
*/
|
*/
|
||||||
int16_t receiveDirect() override;
|
int16_t receiveDirect() override;
|
||||||
|
|
||||||
|
/*!
|
||||||
|
\brief Performs scan for LoRa transmission in the current channel. Detects both preamble and payload.
|
||||||
|
\returns \ref status_codes
|
||||||
|
*/
|
||||||
|
int16_t scanChannel() override;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\brief Performs scan for LoRa transmission in the current channel. Detects both preamble and payload.
|
\brief Performs scan for LoRa transmission in the current channel. Detects both preamble and payload.
|
||||||
\param symbolNum Number of symbols for CAD detection. Defaults to the value recommended by AN1200.48.
|
\param symbolNum Number of symbols for CAD detection. Defaults to the value recommended by AN1200.48.
|
||||||
|
@ -535,7 +541,7 @@ class SX126x: public PhysicalLayer {
|
||||||
\param detMin Minimum value for CAD detection. Defaults to the value recommended by AN1200.48.
|
\param detMin Minimum value for CAD detection. Defaults to the value recommended by AN1200.48.
|
||||||
\returns \ref status_codes
|
\returns \ref status_codes
|
||||||
*/
|
*/
|
||||||
int16_t scanChannel(uint8_t symbolNum = RADIOLIB_SX126X_CAD_PARAM_DEFAULT, uint8_t detPeak = RADIOLIB_SX126X_CAD_PARAM_DEFAULT, uint8_t detMin = RADIOLIB_SX126X_CAD_PARAM_DEFAULT);
|
int16_t scanChannel(uint8_t symbolNum, uint8_t detPeak, uint8_t detMin);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\brief Sets the module to sleep mode. To wake the device up, call standby().
|
\brief Sets the module to sleep mode. To wake the device up, call standby().
|
||||||
|
|
Loading…
Add table
Reference in a new issue