Elixir language potential evaluation

Yes I did. (Go was also on the list). I do not see any system out there coming even close to Elixir/OTP/Nerves. Only drawback is: small community, dynamically typed (but there is sth gleaming at the end of the tunnel).

Yes, it will be a complete rewrite. But as I said, fast-hard-realtime stuff has to be in C. But Elixir is not the problem here, but Linux. So it also has to be on a separate microcontroller. (Which we could drop when using Erlang under RTEMS, then we could most likely also drop the the C code and use Erlang, not sure).

I do not know what “run cold” means.
The IMX6ULL will have enough resources to handle our requirements.
The server just has to handle the smart-home traffic of one house. That is about 1 frame/sec. Most of it is KNX which has 9600bps.

I read Elixir in Action, which is a great book and a great starting point if you have some experience. Then I started to implement the KNX stack - and failed. But I was put back on track by this great response from Sasa Juric: The GenServer from hell (needs some refactoring) - #8 by sasajuric

Core point is, that when using a functional language you have to structure your code and data(!) differently, here I followed the advise to implement the functional core, imperative shell pattern.

When coming from JS, you’ll (like me) have some trouble adjusting to functional programming. But I’m sure its worth it.

2 Likes