Well, easy assumption but as engineer who’s spent the last 7 years writing machine code, developing industrial automation systems from the ground up for municipal water treatment, oil refineries and other industries and being intimately familiar with the electronics, software and mechanical aspects of industrial automation. I’m completely baffled and underwhelmed with the experience I’ve had, particularly the performance and reliability of the automations and I didn’t expect much to begin with.
Maybe the types of automations your doing aren’t plagued by the out of order sequencing issues i cant resolve given the available tools in the GUI. Or maybe im just clueless, but if I cant get anywhere with automations for my use-case, then im definitely not alone.
Once-per-second polling is your better alternative?!
This simple test has now become the ThingWerks IoT Framework, a general purpose industrial control system that can integrate with Home Assistant using its native websocket API.
The issues im having are partly a result of the HA core being multi threaded and that alone is presenting a huge coding challenge just to deal with and doing it in YAML doesnt alleviate that caveat. Also the implementation leaves a lot to be desired for in terms of state management and logic which makes overcoming the aforementioned challenges all the more difficult. It’s a far better approach to use NodeJS for the logic but i agree fetching once a second isn’t particularly elegant and might not work for some use cases.
I think the possibility of using NodeJS seamlessly with HA using a more elegant API that uses websocket for example is very exciting. I never used python in automation because i just dont trust it when a lot of money is on the line (go figure) but purely as a GUI i think is where HA and python really shine.
If anyone can provide an example of using NodeJS with websocket and HA please share.