Visit phoenix-rtos on GitHub

To get the operating system sources please visit GitHub http://github.com/phoenix-rtos/.

This section contains instructions how to quickly run Phoenix-RTOS on supported hardware platforms. In further examples it is assumed that Phoenix-RTOS modules are downloaded and compiled and reside in the same directory.

ia32

This version is designated for generic PC based on IA32 processor, it supports Intel Galileo platform as well. It could be launched using multiboot compliant loader (e.g. GRUB) or native Phoenix-RTOS loader (plo).

The simplest method to run the Phoenix-RTOS operating system is to load the kernel, console driver, fileserver and shell. To do it using qemu emulator just type:

qemu-system-i386 -kernel phoenix-ia32.elf -nographic -initrd "phoenix-rtos-devices/tty/pc-uart/pc-uart,phoenix-rtos-filesystems/dummyfs/dummyfs,libphoenix/test/psh"  -append "Xpc-uart Xdummyfs Xpsh" -m 1

The example above loads kernel image and other binaries (uart driver, file system and shell) into the memory. The binaries are executed with accordance to the command line in append option. The execution option is marked with an X in front of the file name, e.g. Xpc-uart will execute previously loaded pc-uart binary.

To run the same version with VGA console output please use kernel compiled with the VGA support and pc-tty driver.

qemu-system-i386 -kernel ./phoenix-ia32-vga.elf -serial stdio -initrd "phoenix-rtos-devices/tty/pc-tty/pc-tty,phoenix-rtos-filesystems/dummyfs/dummyfs,libphoenix/test/psh" -append "Xpc-tty Xdummyfs Xpsh" -m 1

Due to microkernel, modular architecture Phoenix-RTOS can easily provide UN*X environment. After changing the fileserver to ext2 with ATA support, operating system starts emulation servers and init application.

qemu-system-i386 -kernel phoenix-ia32.elf -nographic -initrd "phoenix-rtos-devices/tty/pc-uart/pc-uart,phoenix-rtos-filesystems/ext2/ext2,libphoenix/test/psh" -hda ./empty.ext2 -append "Xpc-uart Xext2 Xpsh" -m 1

To run Phoenix-RTOS directly from the image the following command should be used.

qemu-system-i386 --serial stdio -hda ./phoenix-ia32.ext2

Binaries

arm-imx6ull

To run Phoenix-RTOS on development kit the SDP compliant loader is required. Kernel is compiled into the image compliant with iMX ROM loader. It can be loaded via USB using imx-usb-loader but preferred method is to use the phoenixd daemon. It loads kernel and initial applications via USB to OCRAM and supports protocol which allows to fetch binaries by dummyfs file server when DRAM is initialized.

Kernel command line is passed through the append parameter. In the command line you can use X to mark file for execution and F to mark files that are to be fetched via USB. The output log can be viewed in a console using the UART1 interface (available after conversion as USB on development board).

phoenixd/phoenixd -sdp -root ./fs -kernel ./phoenix-arm-imx6ull.bin -initrd "phoenix-rtos-devices/tty/imx6ull-uart/imx6ull-uart,phoenix-rtos-filesystems/dummyfs/dummyfs"
-append "Ximx6ull-uart Xdummyfs F/bin/psh X/bin/psh"

To run Phoenix-RTOS kernel from host computer but with a filesystem mounted from NAND flash.

phoenixd/phoenixd -sdp -root ./fs -kernel ./phoenix-arm-imx6ull.bin
-initrd "phoenix-rtos-devices/tty/imx6ull-uart/imx6ull-uart,phoenix-rtos-filesystems/dummyfs/dummyfs"
-append "Ximx6ull-uart Xdummyfs F/bin/psh F/etc/rc F/bin/init X/bin/init"

To run Phoenix-RTOS kernel from host computer which upgrades the local storage.

phoenixd/phoenixd -sdp -root ./fs -kernel ./phoenix-arm-imx6ull.bin
-initrd "phoenix-rtos-devices/tty/imx6ull-uart/imx6ull-uart,phoenix-rtos-filesystems/dummyfs/dummyfs"
-append "Ximx6ull-uart Xdummyfs F/bin/psh F/upgrade.psh X/upgrade.psh"

Binaries

arm-vybrid

To run Phoenix-RTOS on development kit the SDP compliant loader is required. Kernel is compiled into the image compliant with Vybrid ROM loader. It can be loaded via USB using imx-usb-loader but preferred method is to use the phoenixd daemon. It loads kernel and initial applications via USB to OCRAM and supports protocol which allows to fetch binaries by dummyfs file server when DRAM is initialized.

Kernel command line is passed through the append parameter. In the command line you can use X to mark file for execution and F to mark files that are to be fetched via USB. The output log can be viewed in a console using the UART1 interface (available after conversion as USB on development board).

phoenixd/phoenixd -sdp -root ./fs -kernel ./phoenix-arm-vybrid.bin
  -initrd "phoenix-rtos-devices/tty/vybrid-uart/vybrid-uart,phoenix-rtos-filesystems/dummyfs/dummyfs"
  -append "Xvybrid-uart Xdummyfs F/bin/psh X/bin/psh"
To run Phoenix-RTOS kernel from host computer but with a filesystem mounted from NAND flash.
phoenixd/phoenixd -sdp -root ./fs -kernel ./phoenix-arm-vybrid.bin
  -initrd "phoenix-rtos-devices/vybrid-uart/vybrid-uart,phoenix-rtos-filesystems/dummyfs/dummyfs"
  -append "Xvybrid-uart Xdummyfs F/bin/psh F/etc/rc F/bin/init X/bin/init"
To run Phoenix-RTOS kernel from host computer which upgrades the local storage.
phoenixd/phoenixd -sdp -root ./fs -kernel ./phoenix-arm-vybrid.bin
  -initrd "phoenix-rtos-devices/vybrid-uart/vybrid-uart,phoenix-rtos-filesystems/dummyfs/dummyfs"
  -append "Xvybrid-uart Xdummyfs F/bin/psh F/upgrade.psh X/upgrade.psh"

Binaries

armv7-imxrt

To run Phoenix-RTOS on development kit the SDP compliant loader is required. Kernel is compiled into the image compliant with iMX ROM loader. It can be loaded via USB using imx-usb-loader but preferred method is to use the phoenixd daemon. It loads kernel and initial applications via USB to OCRAM and supports protocol which allows to fetch binaries by dummyfs file server when DRAM is initialized.

Kernel command line is passed through the append parameter. In the command line you can use X to mark file for execution and F to mark files that are to be fetched via USB. The output log can be viewed in a console using the UART1 interface (available after conversion as USB on development board).

phoenixd/phoenixd -sdp -root ./fs -kernel ./phoenix-armv7-imxrt.bin
  -initrd "phoenix-rtos-devices/tty/imxrt-uart/imxrt-uart,phoenix-rtos-filesystems/dummyfs/dummyfs"
  -append "Ximxrt-uart Xdummyfs F/bin/psh X/bin/psh"
To run Phoenix-RTOS kernel from host computer which upgrades the local storage.
phoenixd/phoenixd -sdp -root ./fs -kernel ./phoenix-armv7-imxrt.bin
  -initrd "phoenix-rtos-devices/imxrt-uart/imxrt-uart,phoenix-rtos-filesystems/dummyfs/dummyfs"
  -append "Ximxrt-uart Xdummyfs F/bin/psh F/upgrade.psh Xupgrade.psh"

Binaries

armv7-stm32l152

This is the distribution for STM32L152 architecture. Below an example of binary image upload to the microcontroller using OpenOCD is presented.

openocd -f /usr/local/share/openocd/scripts/interface/jlink.cfg
  -f /usr/local/share/openocd/scripts/target/stm32l1.cfg
  -c "program phoenix-rtos.bin 0x08000000 verify reset exit"

Binaries

riscv64

This port is now under development.

RISC-V is a new open architecture developed at Berkeley becoming the new standard for IoT applications. To compile Phoenix-RTOS for this architecture, tools from http://github.com/riscv/ should be downloaded and compiled.

Two tools are required - Spike, a RISC-V ISA Simulator and bbl (Berkeley Boot Loader) which is the part of RISC-V Proxy Kernel. The bbl loader works in the Machine Mode, prepares the environment for the kernel, switches the processor into the Supervisor Mode and finally passes control to the kernel. The first step before boot is to compile the loader with the proper payload (path to the kernel in ELF format).

cd riscv/riscv-pk/build

CC=/opt/local/bin/riscv64-unknown-elf-gcc RANLIB=/opt/local/bin/riscv64-unknown-elf-ranlib READELF=/opt/local/bin/riscv64-unknown-elf-readelf AR=/opt/local/bin/riscv64-unknown-elf-ar OBJCOPY=/opt/local/bin/riscv64-unknown-elf-objcopy ../configure --prefix=/opt/local --host=riscv64 --with-payload=../../../phoenix-rtos-kernel/phoenix-riscv64.elf

make

The last step of compilation is embedding the kernel into the bbl loader. After compilation the loader with embedded kernel is ready to run in Spike simulator. To run kernel in simulator the following commands shall be used.

cd riscv/riscv-pk/build

spike ./bbl

After each kernel compilation the embedding process should be repeated by remaking the loader.

Kernel can be run in qemu-riscv64 emulator as well. To do it following command should be use:
qemu-system-riscv64 -machine spike_v1.10 -nographic -kernel ./bbl
To run Phoenix-RTOS on VirtIO compatible RISCV platform:
qemu-system-riscv64 -machine virt -nographic -kernel ./bbl

Binaries