[XBee] Added assert macro

This commit is contained in:
jgromes 2020-01-13 16:37:37 +01:00
parent acd78cb6bb
commit 016fb0d462

View file

@ -173,9 +173,7 @@ int16_t XBee::setPanId(uint8_t* panId) {
// get response code
int16_t state = readApiFrame(frameID, 4);
if(state != ERR_NONE) {
return(state);
}
RADIOLIB_ASSERT(state);
// confirm changes
return(confirmChanges());
@ -343,9 +341,7 @@ int16_t XBee::confirmChanges() {
// get response code
int16_t state = readApiFrame(frameID, 4);
if(state != ERR_NONE) {
return(state);
}
RADIOLIB_ASSERT(state);
// apply changes
frameID = _frameID++;
@ -353,9 +349,6 @@ int16_t XBee::confirmChanges() {
// get response code
state = readApiFrame(frameID, 4);
if(state != ERR_NONE) {
return(state);
}
return(state);
}