RISC-V, Web, Emulation and Assembly

Date: 2024-09-19
Tags: assembly, emulation, risc-v, web
RISC-V Logo

This page contains resources about RISC-V emulators, simulators, available distributions and simple and cheap solution to have displayed output

There are a lot of possibilities in this, inluding, for hardware RISC−V display, some LCD screen, HDMI output with closed driver or open driver, with often limited GPU support (work in progress). There are some FGPA based solution with open sources solution.

Main emulators

HDL implementations for FPGA

Simulators for RISC−V assembly prupose

-Not toally complete basic function ones but can help to train in bases of RISC-V*

Embedded

ESP32-VGA

A minimal interesting solution is to connect RISC−V version of ESP32 with VGA connector as done with this ESP32-S3 (this model is not RISC-V, ESP32-C2, C3, all the H* models and the far more expansive P4, are RISC-V):

Desktop and server operating systems:

Simple way to have a desktop Linux simulation is with TinyEmu, here with Barbox:

BareBox_V=2024.12.0
curl -oR https://git.pengutronix.de/cgit/barebox/snapshot/barebox-${BareBox_V}.tar.gz
tar xf barebox-${BareBox_V}.tar.gz
cd barebox-${BareBox_V}/
make ARCH=riscv rv64i_defconfig         # for building tdt-2nd (Tinyemu), HiFive, D1, Enzo (Qemu) images
ARCH=riscv CROSS_COMPILE=riscv64-linux-gnu- make #-j4 for 4 cores compilation don't need cross compile if you compile on RISC-V OS

make ARCH=riscv litex_linux_defconfig   # for building LiteX image
ARCH=riscv CROSS_COMPILE=riscv64-linux-gnu- make #-j4 for 4 cores compilation don't need cross compile if you compile on RISC-V OS

# get bootloaders from bellard.org
wget https://bellard.org/tinyemu/diskimage-linux-riscv-2018-09-23.tar.gz
tar xf diskimage-linux-riscv-2018-09-23.tar.gz
cp -a diskimage-linux-riscv-2018-09-23/bbl{32,64}.bin .

cat >tinyemu_gfx.cfg <<EOF
{
    version: 1,
    machine: "riscv64",
    memory_size: 256,
    bios: "bbl64.bin",
    kernel: "images/barebox-dt-2nd.img",
    display0: { device: "simplefb", width: 800, height: 600 },
    input_device: "virtio",
}
EOF
sudo pacman -S tinyemu
temu tinyemu_gfx.cfg

Linux

GNU/Linux

Autres

Embedded systems:

Assembly courses

Tags: assembly, emulation, risc-v, web