4 ms·
Its not really „on RTEMS“, its more side by side. RTEMS is not a layer between the BEAM and te hardware its just helping by providing threads, TCP stack and fi
by peerst 8y ago
Its not really „on RTEMS“, its more side by side. RTEMS is not a layer between the BEAM and te hardware its just helping by providing threads, TCP stack and file access. From a Erlang NIF or port driver (thats what we use to access the outside world in Erlang and Elxir) you have direct access to hardware registers and e.g. CPU interrupts.
- deleted 8y ago[deleted]
- TickleSteve 8y agoIf RTEMS is controlling the execution of your code, your running on or in RTEMS. Direct hardware access isn't really "bare metal" in the same manner as software running in DOS is not bare-metal. direct-hardware access is provided in both.
- e_proxus 8y agoRTEMS isn't "controlling" the execution of the code, it just supplies implementation for OS-specific utilities (effectively the POSIX API). The BEAM VM code is compiled to machine code and runs directly on the CPU. As peerst explained, if you write your own C code in an Erlang port driver for example, you don't have to use RTEMS at all.
- anonymousDan 8y agoIs there the ability to run multiple OS processes or is the BEAM VM the only thing running after boot?
- e_proxus 8y agoYou can only run one process in RTEMS (hence the name The Real-Time Executive for Multiprocessor Systems), however you can simulate other processes via threads. This is how we run the network stack and Wi-Fi configuration tools among other things.