[LoRaWAN] Added MIC mismatch debug message
This commit is contained in:
parent
3e8636b1f2
commit
b2b176f1c3
1 changed files with 1 additions and 0 deletions
|
@ -778,6 +778,7 @@ bool LoRaWANNode::verifyMIC(uint8_t* msg, size_t len, uint8_t* key) {
|
|||
// calculate the expected value and compare
|
||||
uint32_t micCalculated = generateMIC(msg, len - sizeof(uint32_t), key);
|
||||
if(micCalculated != micReceived) {
|
||||
RADIOLIB_DEBUG_PRINTLN("MIC mismatch, expected %08x, got %08x", micCalculated, micReceived);
|
||||
return(false);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue