[RF69] Added direct reception support
This commit is contained in:
parent
06d40c78bc
commit
536829452f
2 changed files with 22 additions and 0 deletions
|
@ -819,6 +819,14 @@ uint8_t RF69::random() {
|
|||
return(randByte);
|
||||
}
|
||||
|
||||
void RF69::setDirectAction(void (*func)(void)) {
|
||||
setDio1Action(func);
|
||||
}
|
||||
|
||||
void RF69::readBit(RADIOLIB_PIN_TYPE pin) {
|
||||
updateDirectBuffer((uint8_t)digitalRead(pin));
|
||||
}
|
||||
|
||||
int16_t RF69::getChipVersion() {
|
||||
return(_mod->SPIgetRegValue(RF69_REG_VERSION));
|
||||
}
|
||||
|
|
|
@ -869,6 +869,20 @@ class RF69: public PhysicalLayer {
|
|||
*/
|
||||
int16_t getChipVersion();
|
||||
|
||||
/*!
|
||||
\brief Set interrupt service routine function to call when data bit is receveid in direct mode.
|
||||
|
||||
\param func Pointer to interrupt service routine.
|
||||
*/
|
||||
void setDirectAction(void (*func)(void));
|
||||
|
||||
/*!
|
||||
\brief Function to read and process data bit in direct reception mode.
|
||||
|
||||
\param pin Pin on which to read.
|
||||
*/
|
||||
void readBit(RADIOLIB_PIN_TYPE pin);
|
||||
|
||||
#if !defined(RADIOLIB_GODMODE) && !defined(RADIOLIB_LOW_LEVEL)
|
||||
protected:
|
||||
#endif
|
||||
|
|
Loading…
Add table
Reference in a new issue