* Emulators are useful tools - PC emulator (e.g. Docker on Mac, WSL on Linux) - NES emulator -- fun and games, realtime output - Also have debugging emulators - Renode * Renode Stack - CPU cores written in C - arm, i386, ppc, riscv, sparc, xtensa - Windows, Mac, Linux - Peripherals and UI written in C# - Extensible via Python and C# - Write once. Run anywhere. Using C# to define new peripherals * Three major users - Designers of new boards - Reverse engineering exsisting hardware - Silicon designers * Designers of new boards - One or more chips - How are they connected? - What weird hardware exists? * Concurrent emulation of multiple devices - Can connect multiple devices, e.g. via UART, GPIO, SPI, Ethernet, CAN... - All devices are emulated using the same time source - Helps to debug timing differences with different processors on a board * Board definition format - Easily define memory layout - Easily move blocks around - Only define what's necessary - You don't need to be perfect, just good enough! * Can read SVD files * Hardware has Similarities - Picture of existing register sets - There are only so many combinations - Rip. Mix. Burn. Many chips are just copies of one another. * Tests in CI * Reverse engineering existing hardware * If it's a supported architecture, it's easy to run code * LoadBinary and set PC * Can skip much of the boot ROM * Attach GDB * Reproducible makes it easy to test theories * Developing new Silicon blocks * Betrusted hardware - Create a new design in LiteX / Verilog - Document the design - Create a model - Timing isn't as critical *

What is an Emulator?

  • Desktop
  • CPU
  • Console

Desktop Emulator

  • VirtualBox
  • VMWare
  • Parallels
  • HyperV
  • WSL2/Docker

CPU Emulator

  • qemu on Linux
  • Rosetta on Mac

Console Emulator

  • Wii Virtual Console
Slide 2