Attach packet RSSI and SNR to packet queue entry structs. Disable ISR spinlocks on ESP32 until tested.

This commit is contained in:
Mark Qvist 2024-10-11 16:29:17 +02:00
parent 1de5f3c796
commit 389745ad33
7 changed files with 86 additions and 47 deletions

View file

@ -523,6 +523,14 @@ int ISR_VECT sx128x::packetRssi() {
return pkt_rssi;
}
int ISR_VECT sx128x::packetRssi(uint8_t pkt_snr_raw) {
// may need more calculations here
uint8_t buf[5] = {0};
executeOpcodeRead(OP_PACKET_STATUS_8X, buf, 5);
int pkt_rssi = -buf[0] / 2;
return pkt_rssi;
}
uint8_t ISR_VECT sx128x::packetSnrRaw() {
uint8_t buf[5] = {0};
executeOpcodeRead(OP_PACKET_STATUS_8X, buf, 5);