mirror of
https://github.com/sandeepmistry/arduino-LoRa.git
synced 2025-04-19 13:02:14 +03:00
Merge branch 'master' of git://github.com/sandeepmistry/arduino-LoRa
This commit is contained in:
commit
1bb95fdd3d
@ -304,10 +304,15 @@ void LoRaClass::onReceive(void(*callback)(int))
|
||||
pinMode(_dio0, INPUT);
|
||||
|
||||
writeRegister(REG_DIO_MAPPING_1, 0x00);
|
||||
|
||||
#ifdef SPI_HAS_NOTUSINGINTERRUPT
|
||||
SPI.usingInterrupt(digitalPinToInterrupt(_dio0));
|
||||
#endif
|
||||
attachInterrupt(digitalPinToInterrupt(_dio0), LoRaClass::onDio0Rise, RISING);
|
||||
} else {
|
||||
detachInterrupt(digitalPinToInterrupt(_dio0));
|
||||
#ifdef SPI_HAS_NOTUSINGINTERRUPT
|
||||
SPI.notUsingInterrupt(digitalPinToInterrupt(_dio0));
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -85,7 +85,7 @@ private:
|
||||
int _ss;
|
||||
int _reset;
|
||||
int _dio0;
|
||||
int _frequency;
|
||||
long _frequency;
|
||||
int _packetIndex;
|
||||
int _implicitHeaderMode;
|
||||
void (*_onReceive)(int);
|
||||
|
Loading…
x
Reference in New Issue
Block a user