buserror/simavr
Freesimavr is a lean, mean and hackable AVR simulator for linux & OSX
About buserror/simavr
simavr is a lean, mean and hackable AVR simulator designed for Linux and OSX, but usable on any platform with avr-gcc. It loads ELF files directly and supports multipart HEX files. The core is stable for AVR parts with up to 128KB flash, with preliminary support for larger devices. simavr emulates a wide range of I/O peripherals including EEPROM, watchdog, IO ports, timers (8 and 16-bit), UART with TX/RX interrupts, SPI (master/slave), I2C (master/slave), external interrupts, ADC, and self-programming (bootloaders). It includes many emulated cores such as ATmega2560, AT90USB162, ATmega1281, ATmega1280, ATmega128, ATtiny series, and more. Extras include fully working GDB support, VCD (Value Change Dump) output for waveform analysis with gtkwave, and the ability to source VCD files from external tools. It supports running real-life firmware examples with OpenGL rendering and has Arduino support (no IDE integration). Installation is available via Homebrew on OSX and apt on Ubuntu, or by building from source with make.
Key Features
Pros & Cons
- Lean and hackable codebase, easy to extend or customize
- Supports a wide range of AVR microcontrollers
- GDB integration enables powerful debugging capabilities
- VCD output allows precise timing analysis with gtkwave
- Command-line interface works well in automated workflows
- Free and open source (MIT license)
- Active community with patches welcome via GitHub pull requests
- No built-in graphical IDE or Arduino IDE integration
- Stable only for parts with 128KB flash; larger parts have preliminary support
- Documentation is primarily the README and wiki, may require self-study
- Primarily developed for Linux and OSX; Windows support depends on avr-gcc toolchain
- No official release package for all platforms (e.g., Windows)
- Provided 'AS IS' with limited formal support