Skip to content

Dev boards in the Lab

The bench's development boards are parts of their own in the Lab: drag one from Dev boards onto the schematic and it arrives as a working board. You get:

  • the board itself, a Renode machine built from the board file in the Renode tree, running a demo program;
  • an LED instrument for every LED on the board;
  • a push button for every user button;
  • a serial monitor on the console UART (the board's virtual COM port where it has one);
  • a display card for every screen on the board (OLED, TFT, e-paper, LED matrix);
  • a slider for every physical value a sensor on the board measures (temperature, pressure, tilt...).

All of them are already wired. Press Run: the demo blinks the first LED and counts the blinks on the console, and while you hold the button, the second LED lights (on one-LED boards the first stays on) and the console says so. Boards with a screen show the blink count on it; boards with sensors print their readings after each blink, and the sliders change what the sensors measure while it runs.

Board MCU LEDs Buttons Console Display, sensors Demo
NUCLEO-L476RG STM32L476RG LD2 B1 USART2 — yes
NUCLEO-L476RG + X-NUCLEO-IKS01A2 STM32L476RG LD2 B1 USART2 LSM6DSL, LSM303AGR, HTS221, LPS22HB (8 sliders) yes
32L496GDISCOVERY STM32L496AG LD2 joystick SEL, UP, DOWN USART2 TFT 240×240 (ST7789H2 on FMC) yes
32L0538DISCOVERY STM32L053C8 LD4, LD3 B1 USART1 e-paper 172×72 (GDE021A1) yes
Arduino UNO Q (STM32U585 half) STM32U585AI LED3 red, green — USART1 (Serial1) LED matrix 13×8 yes
nRF52840 SuperMini nRF52840 blue LED — UART0 (P0.06) — yes
Raspberry Pi Pico RP2040 LED (GPIO25) — UART0 — yes
SAMD10 Xplained Mini ATSAMD10D14AM LED0 SW0 SERCOM2 — yes
LP-MSPM0G3507 MSPM0G3507 LED1, LED2 RGB S2, S1 UART0 — yes
LP-MSPM0C1104 MSPM0C1104 LED1 S1 UART0 — yes
EK-LM3S2965 LM3S2965 status select UART0 OLED 128×96 (SSD1329) yes
LPCXpresso LPC812 LPC812M101 RGB SW1 USART0 — yes
FRDM-KL05Z MKL05Z32 RGB — UART0 — yes
Renesas SK-S7G2 Synergy S7G2 LED1, LED2, LED3 S4, S5 SCI3 (RS-232 header) TFT 240×320 (ILI9341V) yes
Renesas YRPBRL78G13 R5F100LEA (RL78/G13) LED D2 (P77) — UART2 (SAU1) — yes
CH32V003F4P6 board CH32V003F4P6 (RISC-V) LED (PD0, assumed) — USART1 — yes
LAUNCHXL-F28069M TMS320F28069M LD2, LD3 — SCI-A — yes
LilyGO T-Beam V1.1 ESP32 LED (GPIO4) IO38 UART0 OLED 128×64 (SSD1306) yes (flash image)

Your own firmware

Select the board and set Firmware in the inspector: an ELF for the ARM boards (a normal flash build; for the Pico an SDK flash build), an EABI ELF from cl2000 for the F28069, and a merged 4 MB flash image for the ESP32 (bootloader at 0x1000, partition table at 0x8000, app at 0x10000). Demo puts the demo back. Paths are relative to the project folder or absolute.

The LEDs read the pin level the firmware drives (lit = 1, active-low LEDs inverted), the buttons drive the pin as the real switch would (active-low ones pulled low while held), and the console shows what the firmware sends. Anything else the board offers is reachable the usual Renode way: add bindings in the options (ADC channels, more pins, sysbus addresses), UARTs, SPI or CAN.

A display card shows what the panel shows (the Lab reads the picture from a Video.DisplayFrame next to the display model, only while the card is open). A slider writes its value into the sensor model (a Miscellaneous.PropertyFeed slot), so the firmware reads it the next time it asks the sensor.

The SK-S7G2's and the YRPBRL78G13's LEDs are assumed active low. The CH32V003 board's LED pin is an assumption (PD0, as on WCH's evaluation board); rebind it in the options if yours is wired elsewhere.

Several boards can sit in one project, even two of the same kind: each launched board gets a free External Control port (port: auto).

Behind the parts

  • embeddyn/mechatronics/devboards.py lists the boards: board file, machine name, console UART, LEDs and buttons with the GPIO block and pin they hang on, the demo and the extra start-up lines (the Pico's and the ESP32's boot ROMs). Shields are board files loaded on top (shields), displays name their model (displays), and sensor values are property paths (feeds).
  • examples/mechatronics/renode/devboards/<board>.resc (and, for boards with displays or sensors, <board>.repl with the frames and the feed) are generated from it: python -m embeddyn.mechatronics.devboards scripts.
  • examples/mechatronics/firmware/devboards/ is the demo: one program (common/demo.c) on a small hardware layer per family (boards/: STM32 L0/L4/U5, nRF52, RP2040 with its own boot stage 2, SAMD10, MSPM0, LM3S, LPC8xx, Kinetis L, Synergy S7G2, CH32V003, C28x, RL78/G13) plus the screens and the shield (epd_l053.c, lcd_l496.c, unoq_matrix.c, iks01a2.c), bare metal, built with make (arm-none-eabi-gcc; the CH32V003 needs the xPack riscv-none-elf-gcc, found on PATH or through RISCV_GCC_HOME; the F28069 TI cl2000, through C2000_CGT; the RL78 GNU rl78-elf-gcc, through RL78_GCC_HOME); the ELFs are kept in bin/. The T-Beam's demo is an Arduino sketch (esp32/tbeam_demo), built by esp32/build.sh with arduino-cli into bin/ttgo_t_beam.bin, a flash image cut after the app.
  • python -m embeddyn.mechatronics.devboards check boots every demo headless in Renode (needs RENODE_BIN) and checks the console counted at least two blinks.

Not there yet

  • The WS2812B 8×8 matrix board is not a part: it needs a board to drive it, and the Lab cannot yet wire one machine's pin into a part on another.
  • The RL78/G13 runs about 25 times slower than real time (its core is an interpreter), and its timer array units, ADC, I2C and DMA are not modelled yet.