[Article] RISC-V Emulator for Pine64 Oz64 SBC
#1
Earlier this year we made a RISC-V Emulator for Ox64 BL808 SBC. Every day we run it for testing the Daily Build of Apache NuttX RTOS for Ox64, thanks to our customised TinyEMU RISC-V Emulator. (Not the small flightless bird)

Now that NuttX supports Sophgo SG2000 SoC: Let’s create a similar emulator for Pine64 Oz64 SBC…

(1) We take TinyEMU Emulator for Ox64 BL808 SBC
(2) Update the RISC-V Memory Map to match Sophgo SG2000 SoC
(3) Fix the `auipc` Overflow in TinyEMU Boot Code
(4) We emulate the 16550 UART Controller
(5) By intercepting Reads and Writes to the UART I/O Registers
(6) But TinyEMU supports only 32 Interrupts, we bump up to 64
(7) Eventually we’ll emulate SG2000 Peripherals like GPIO
(8) Right now it’s good enough for Daily Automated Testing of NuttX for SG2000

Check out the article: RISC-V Emulator for Sophgo SG2000 SoC (Pine64 Oz64)

Lup

   
  Reply
#2
(07-06-2024, 06:50 PM)lupyuen Wrote: Earlier this year we made a RISC-V Emulator for Ox64 BL808 SBC. Every day we run it for testing the Daily Build of Apache NuttX RTOS for Ox64, thanks to our customised TinyEMU RISC-V Emulator. (Not the small flightless bird)

Now that NuttX supports Sophgo SG2000 SoC: Let’s create a similar emulator for Pine64 Oz64 SBC…

(1) We take TinyEMU Emulator for Ox64 BL808 SBC
(2) Update the RISC-V Memory Map to match Sophgo SG2000 SoC
(3) Fix the `auipc` Overflow in TinyEMU Boot Code
(4) We emulate the 16550 UART Controller
(5) By intercepting Reads and Writes to the UART I/O Registers
(6) But TinyEMU supports only 32 Interrupts, we bump up to 64
(7) Eventually we’ll emulate SG2000 Peripherals like GPIO
(8) Right now it’s good enough for Daily Automated Testing of NuttX for SG2000

Check out the article: RISC-V Emulator for Sophgo SG2000 SoC (Pine64 Oz64)

Lup

Awesome and thumbs up
  Reply
#3
Thank you so much TL! :-)
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  SBC Case Builder and Pine64 SBC hominoid 0 266 07-21-2024, 06:10 PM
Last Post: hominoid
  Registering my 'nick' on Pine64's IRC network diederik 6 2,098 07-19-2024, 04:28 AM
Last Post: GlenMiller15
  [Article] Rust Apps on Ox64 BL808 RISC-V SBC and Apache NuttX RTOS lupyuen 2 743 07-06-2024, 06:51 PM
Last Post: lupyuen
  Risc-V laptop from SpacemiT Der Geist der Maschine 2 1,063 06-26-2024, 02:17 AM
Last Post: Der Geist der Maschine
  [Video] TinyEMU RISC-V Emulator for Ox64 BL808 SBC lupyuen 0 400 06-13-2024, 08:56 PM
Last Post: lupyuen
  [Video] Adventures of Ox64 BL808 RISC-V SBC with Apache NuttX RTOS lupyuen 0 401 06-13-2024, 04:13 AM
Last Post: lupyuen
  [Article] Coding Ox64 BL808 SBC the Drag-n-Drop Way lupyuen 3 1,346 04-02-2024, 07:38 AM
Last Post: Noahstorey
  Unable to connect to Pine64 IRC channel due to certificate error? Must-Borrow 1 994 03-10-2024, 02:43 PM
Last Post: Must-Borrow
  [Article] QuickJS JavaScript Engine on a Real-Time Operating System (Ox64 + NuttX) lupyuen 0 819 02-17-2024, 07:24 PM
Last Post: lupyuen
  [Article] Emulate Ox64 BL808 in the Web Browser: Experiments with TinyEMU lupyuen 3 1,329 02-17-2024, 06:53 PM
Last Post: tllim

Forum Jump:


Users browsing this thread: 1 Guest(s)