[SX127x] Added common CAD methods
This commit is contained in:
parent
58da2a28ac
commit
ea4018d310
2 changed files with 19 additions and 0 deletions
|
@ -472,6 +472,14 @@ void SX127x::clearPacketSentAction() {
|
||||||
this->clearDio0Action();
|
this->clearDio0Action();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void SX127x::setChannelScanAction(void (*func)(void)) {
|
||||||
|
this->setDio0Action(func, this->mod->hal->GpioInterruptRising);
|
||||||
|
}
|
||||||
|
|
||||||
|
void SX127x::clearChannelScanAction() {
|
||||||
|
this->clearDio0Action();
|
||||||
|
}
|
||||||
|
|
||||||
void SX127x::setFifoEmptyAction(void (*func)(void)) {
|
void SX127x::setFifoEmptyAction(void (*func)(void)) {
|
||||||
// set DIO1 to the FIFO empty event (the register setting is done in startTransmit)
|
// set DIO1 to the FIFO empty event (the register setting is done in startTransmit)
|
||||||
setDio1Action(func, this->mod->hal->GpioInterruptRising);
|
setDio1Action(func, this->mod->hal->GpioInterruptRising);
|
||||||
|
|
|
@ -738,6 +738,17 @@ class SX127x: public PhysicalLayer {
|
||||||
*/
|
*/
|
||||||
void clearPacketSentAction();
|
void clearPacketSentAction();
|
||||||
|
|
||||||
|
/*!
|
||||||
|
\brief Sets interrupt service routine to call when a channel scan is finished.
|
||||||
|
\param func ISR to call.
|
||||||
|
*/
|
||||||
|
void setChannelScanAction(void (*func)(void));
|
||||||
|
|
||||||
|
/*!
|
||||||
|
\brief Clears interrupt service routine to call when a channel scan is finished.
|
||||||
|
*/
|
||||||
|
void clearChannelScanAction();
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\brief Set interrupt service routine function to call when FIFO is empty.
|
\brief Set interrupt service routine function to call when FIFO is empty.
|
||||||
\param func Pointer to interrupt service routine.
|
\param func Pointer to interrupt service routine.
|
||||||
|
|
Loading…
Add table
Reference in a new issue