Recently one of my customers brought to my attention Nerves Project
Nerves defines a new way to build embedded systems using Elixir. It is specifically designed for embedded systems, not desktop or server systems. You can think of Nerves as containing three parts:
Taken together, the Nerves platform, framework, and tooling provide a highly specialized environment for using Elixir to build advanced embedded devices.
Above is from Getting Started — nerves v1.9.1
Mix is a build tool that provides tasks for creating, compiling, and testing Elixir projects, managing its dependencies, and more.
More here: https://hexdocs.pm/mix/Mix.html
Nerves support various targets and cross compiling for this on Mac/Windows/Linux. Below are steps to compile using Ubuntu for beagle bone.
sudo apt install build-essential automake autoconf git squashfs-tools ssh-askpass pkg-config curl
git clone https://github.com/asdf-vm/asdf.git ~/.asdf — branch v0.10.0
echo -e ‘\n. $HOME/.asdf/asdf.sh’ >> ~/.bashrc
echo -e ‘\n. $HOME/.asdf/completions/asdf.bash’ >> ~/.bashrc # optional
source ~/.bashrc
asdf install erlang 25.0.3
asdf install elixir 1.13.4-otp-25
asdf global erlang 25.0.3
asdf global elixir 1.13.4-otp-25
mix local.hex
mix local.rebar
mix archive.install hex nerves_bootstrap
git clone git@github.com:nerves-project/nerves_system_bbb.git
cd nerves_system_bbb
mix deps.get
mix compile
mix nerves.new test_bb
unset MIX_ENV
unset MIX_TARGET
export MIX_TARGET=bbb
cd test_bb
mix local.hex
mix local.rebar
mix local.nerves
mix archive.install hex nerves_bootstrap
mix deps.get
mix firmware
The last step mix.firmware writes the firmware to SD card. I have been able to successfully boot this on both SeedStudio-BeagleBoard & Beagle Bone Black