Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: NaturalTinyShell_ice libmDot-12Sept mbed-rtos mbed
Fork of ICE by
Diff: src/ConfigurationHandler/Controls/FailsafeControl.cpp
- Revision:
- 273:0373b2a15f8a
- Parent:
- 271:19948511cd3f
- Child:
- 274:e2caebc7c65e
--- a/src/ConfigurationHandler/Controls/FailsafeControl.cpp Wed Oct 26 19:05:44 2016 +0000
+++ b/src/ConfigurationHandler/Controls/FailsafeControl.cpp Wed Oct 26 19:29:50 2016 +0000
@@ -191,7 +191,9 @@
break;
case STATE_CONTROL_SENSOR_ERROR:
if ( !this->sensorError() ) {
+ printf("\rDEBUG: UNREGISTERING THE CONTROL!\n");
this->currentState = STATE_CONTROL_OFF;
+ this->unregisterControl();
} else {
// do nothing
}
@@ -355,13 +357,11 @@
{
ModbusValue value;
ModbusMasterReadRegister(input, &value);
- // TODO: uncomment when real sensors are available
- #if 0
+
if ( value.errflag ) {
logInfo("%s: %s is in error\n", __func__, input.c_str());
return true;
}
- #endif
return false;
}
