modelBlink
Raspberry Pi Pico supplied by USB: on-board LED and external LED on GP15, VSYS and temperature read by the ADC
Extends from Modelica.Icons.Example (Icon for runnable examples).
Information
The Pico is supplied by its USB cable (usbConnected, default): 5 V on VBUS, about 4.7 V on VSYS after the Schottky diode, 3.3 V on the rail. Expected result: pico.GP15.v is a 0 V / ≈3 V square wave with a 2 s period, in phase with the on-board LED (icon); the log prints VSYS ≈ 4.7 V (read on ADC(3)) and 27 °C (ADC(4), dieTemperature).
Components
| Type | Name | Default | Description |
|---|---|---|---|
| RPi_Pico | pico | USB cable plugged in (default): nothing to wire for the supply | |
| Modelica.Electrical.Analog.Basic.Ground | ground | ||
| Modelica.Electrical.Analog.Basic.Resistor | r15 | limits the current of led15 | |
| MicroPythonMCU.Peripherals.LED | led15 | GP15 (physical pin 20) |