Simulator

Seeed XIAO SAMD21 simulator, running in this tab

Mokxi is a free Seeed XIAO SAMD21 simulator that runs in your browser, with nothing to install and no account needed. The XIAO SAMD21 is the smallest board here: 21 by 17.8 mm, a Cortex-M0+ at 48 MHz, and eleven pads of which every one is an analog input. Wire the circuit, write the sketch, press Run.

  • 192parts on the bench
  • 25boards running now
  • 1.00xreal time, on every board
Seeed XIAO SAMD21: blinklive0.000 s 0.00x
Click to open it in the editor
Real firmware, running right now on our own core. Click it to open the circuit in the editor.
What is modeled

The numbers, not the marketing

Taken from the board's own contract document and put in plain words.

The core
An ATSAMD21G18A on our own Cortex-M0+ core at 48 MHz, with the datasheet cycle count of every instruction.
Eleven pads, all analog
A0 to A10 are the same pads as D0 to D10, so analogRead works on every one of them. Ten of the eleven reach a timer as well, which is what analogWrite needs.
Two serial ports, and they are different things
Serial is the chip’s own USB, modeled as a byte pipe at the real endpoint registers with no stack above it. Serial1 is SERCOM4 on D6 and D7, shifting real 8N1 frames.
Go further

The full board page

Every peripheral area, every example and the wiring notes, in one place.

Seeed XIAO SAMD21 simulatorBlink, a button and the serial monitor, running.

Questions

Is it free?

Yes, all of it, with no card and no account needed to try it.

Why does analogWrite do nothing on D0?

D0 is PA02, which is the DAC’s pin and reaches no timer at all. That is the chip rather than the model; use any of the other ten pads for a fade.

Can it act as a keyboard?

Not in Mokxi. Keyboard and Mouse need the USB stack above the byte pipe, and the model does not have one. The board page says so plainly.

Will my firmware run on a real XIAO?

The core and most of the peripherals will. Two things in the model are believed rather than verified (the TC register offsets and the pad multiplexing table), and section 7 of the contract is the short list to check.

Try your own firmware on the XIAO SAMD21

What you build here runs on the board on your desk, unchanged. Nothing to install and no account needed.