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/SetpointControl.cpp
- Revision:
- 33:cb765aefa1b5
- Parent:
- 30:738359dfdab1
diff -r 738359dfdab1 -r cb765aefa1b5 src/ConfigurationHandler/Controls/SetpointControl.cpp --- a/src/ConfigurationHandler/Controls/SetpointControl.cpp Thu Sep 08 21:07:47 2016 +0000 +++ b/src/ConfigurationHandler/Controls/SetpointControl.cpp Thu Sep 08 21:24:34 2016 +0000 @@ -14,8 +14,8 @@ bool SetpointControl::load(string _controlFile) { MbedJSONValue json_value; - controlFile = _controlFile; - + controlFile = _controlFile; + // try to open the control file mDot::mdot_file file = GLOBAL_mdot->openUserFile(controlFile.c_str(), mDot::FM_RDONLY); if ( file.fd < 0 ) @@ -23,7 +23,6 @@ // read the data into a buffer char dataBuf[1024]; - int bytes_read = GLOBAL_mdot->readUserFile(file, (void *)dataBuf, sizeof(dataBuf)); if ( bytes_read != sizeof(dataBuf) ) { logError("%s: failed to read %d bytes from %s", __func__, sizeof(dataBuf), controlFile.c_str());