Running system on riscv64-generic-spike#

This version is designated for RISC-V 64 processors based spike machine implemented by the Spike (riscv-isa-sim) emulator. To launch this version phoenix.osbi file should be provided - system image with integrated OpenSBI bootloader, containing PLO, kernel, console driver, dummyfs filesystem and the psh shell.

The file is created as the final artifact of the phoenix-rtos-project build and is located in the _boot directory. See how to build the Phoenix-RTOS system image

Running image under the spike#

Firstly, you need to install a spike simulator.

How to install spike simulator (Ubuntu 20.04)
  1. Clone the riscv-isa-sim GitHub repository. System was tested on commit 5fa1cd54 on master branch.

    git clone https://github.com/riscv-software-src/riscv-isa-sim.git --single-branch
    
  2. Enter the downloaded repository

    cd riscv-isa-sim
    
  3. Check out the commit 5fa1cd54

    git checkout 5fa1cd54
    
  4. Install the device-tree-compiler

    sudo apt-get update && \
    sudo apt-get install device-tree-compiler
    
  5. Install the Spike RISC-V ISA Simulator

    mkdir build && \
    cd build && \
    ../configure --prefix=$RISCV && \
    make && \
    sudo make install
    

Then, to run the image under spike you should change the directory to phoenix-rtos-project and type:

./scripts/riscv64-generic-spike.sh

Image
Image

Using Phoenix-RTOS#

Phoenix-RTOS will be launched and the psh shell command prompt will appear in the terminal. To get the available command list please type:

help

Image

To get the list of working processes please type:

ps

Image

See also#

  1. Running system on targets

  2. Table of Contents