4 ms·
Is there much in the way of FOSS statechart implementations? It's been a while since I looked into the ecosystem. I remember that the canonical one was always
by nrclark 9y ago
Is there much in the way of FOSS statechart implementations? It's been a while since I looked into the ecosystem.
I remember that the canonical one was always the Quantum framework, but I never wanted to deal with the licensing aspect of it.
- Serow225 9y agoDefinitely not FOSS, but Stateflow is used a ton in scientific computing (Automotive, Control Systems, etc): https://www.mathworks.com/products/stateflow.html https://www.mathworks.com/products/stateflow.html
- davidkpiano 9y agoHey! I'm the creator of xstate: https://github.com/davidkpiano/xstate https://github.com/davidkpiano/xstate - a pure, functional, declarative implementation of statecharts in TypeScript. It has zero dependencies, is frameworkless, and fast (O(n) state and transition look-up time for most cases). I have some important updates to announce at JSConf Iceland, including the ability to translate to/from SCXML, and an improved visualizer. Let me know what you think!
- nrclark 9y agoI think that looks awesome! Makes me wish I was a JS programmer so I could try it out :)
- keithnz 9y agoI use statemachines a lot in embedded systems and decorate the code with comments that are easy to translate into graphvizs "dot" languge. Also played around with doing dynamic charts as the code runs, but stopped doing that as it was more novelty value than any other kind of value :)
- ahartmetz 9y agoQt has QStateMachine http://doc.qt.io/qt-5/qstatemachine.html http://doc.qt.io/qt-5/qstatemachine.html which is modeled after State Chart XML https://www.w3.org/TR/scxml/ https://www.w3.org/TR/scxml/ (but no XML is required to use it) It's LGPLv3 if you use Qt > 5.6 (LGPLv2 earlier), and 5.6 is getting old now.
- macspoofing 9y agoThough you should always have NIHS in the back of your mind, state machines aren't very difficult to implement which means when you write yours you can really tailor it to your use case.
- nrclark 9y agoStatecharts are a very different beast than a traditional state machine. Putting together a good statechart implementation is a boatload of work.
- macspoofing 9y agoMissed that part. You're correct.
- asangha 9y agoJS Harel Statecharts: https://github.com/burrows/statechart.js https://github.com/burrows/statechart.js