52 ms·
Exceptions are the wrong model for embedded systems, generally if something exceptional happens, you need a reset. Attempting to "handle" exceptional cases is i
by TickleSteve 10y ago
Exceptions are the wrong model for embedded systems, generally if something exceptional happens, you need a reset.
Attempting to "handle" exceptional cases is incorrect, a reset is the correct option.
Exceptions != normal program flow.
- prashnts 10y agoTrue, however people who come from languages such as Python, where it is much common to handle exception rather than using `if else` checks. I think this is kind of stubbornness on dev's part not to change their coding patterns depending upon the platform.
- junke 10y agoAda (Ravenscar profile) allows exceptions: http://www.sigada.org/ada_letters/jun2004/ravenscar_article.pdf http://www.sigada.org/ada_letters/jun2004/ravenscar_article....
- tremon 10y agoYou can divide embedded systems between industrial control systems and headless consumer devices, like set-top boxes or smart TVs. For the latter, you really don't want to invoke a device reset every time the input stream is malformed.
- TickleSteve 10y agotrue, but I would not consider a set-top tv a true embedded system, rather a specialised user-facing system. So yes, you wouldn't reset a user facing system. I would characterise embedded systems as those having to maintain functionality without user intervention. (also, comms issues such as input stream errors are the normal program logic, i.e. defined error cases).
- TorKlingberg 10y agoThat depends entirely on what your embedded system is doing.