3 ms·
How does this differ from Nerves?
by mrpf1ster 3y ago
How does this differ from Nerves?
- voicedYoda 3y agoI think it's that AtomVM is erlang specific, while nerves is elixir and erlang. I could be very wrong, but that's my initial read from the docs
- bhaney 3y ago> I think it's that AtomVM is erlang specific I see plenty of references to Elixir in the docs, and this official AtomVM project to provide some tooling to target AtomVM from Elixir https://github.com/atomvm/ExAtomVM https://github.com/atomvm/ExAtomVM
- magicalhippo 3y agoAs someone who's yet to play with Erlang and Elixir, is the bytecode lean or fluffy? Microcontrollers often have somewhat limited Flash storage, and I see they have 512kB as bare minimum with 1MB recommended for the VM itself. Will that extra 512kB be enough for fun stuff?
- unwind 3y agoGood question! I'm not a BEAM developer, but a quick search found this [1] which was very informative. My classification would be "quite fluffy", but that's of course highly subjective and the language/platform has quite a lot of features that it needs to support so I wasn't expecting CHIP-8, exactly. [1]: https://gomoripeti.github.io/beam_by_example/ https://gomoripeti.github.io/beam_by_example/
- benpacker 3y agoIt implements the BEAM, so any language that shares the runtime can be made to work (Elixir, Gleam, etc)
- jocaal 3y agoIf I understand correctly, Elixir builds an Erlang syntax tree and then the erlang toolchain takes over. If it runs Erlang, it should be able to run elixir
- joggodoggo 3y agoI think you have it the other way around. Elixir is built on top of Erlang, no? So if it runs Elixir it can run Erlang in the same way React can run JavaScript, but not necessarily the other way around.
- klibertp 3y agoNo, the GP is correct: Erlang and Elixir are 100% equivalent on the BEAM, because Elixir compiles to Erlang AST, then that is compiled with Erlang compiler to BEAM bytecode. I honestly don't know what you mean by the React example, but it's more like JavaScript and TypeScript, or Java and Kotlin. At runtime, there's no difference between the code compiled directly from Erlang and code compiled from Elixir.
- transfire 3y agoNerves doesn’t support microcontrollers, e.g. Raspberry Pico.
- bhaney 3y agoNerves is a framework meant to run on relatively beefy embedded systems (not microcontrollers) and uses the normal BEAM. AtomVM is its own VM suitable for running on microcontrollers in much more resource constrained environments than Nerves could ever get close to running on.
- davidw 3y agoIt'd be nice to have an 'at a glance' comparison between standard Erlang and this, to get a better idea of what's going on. I don't know if "kind of like language X, but cut down and missing some stuff" environments have a great track record. Especially if the runtime is not the tried and true one with a lot of the kinks worked out.