Skip to main content

Pimoroni Badger RP2040

Pimoroni Badger RP2040 image

DeviceScript import

You must import PimoroniBadger2040W to access the shield services.

In Visual Studio Code, click the wand icon on the file menu and select "PimoroniBadger2040W".

import { font8, scaledFont } from "@devicescript/graphics"
import { PimoroniBadger2040W } from "@devicescript/drivers"

const board = new PimoroniBadger2040W()
const disp = await board.startDisplay()
const f = scaledFont(font8(), 3)
disp.image.print("Hello world!", 10, 10, 1, f)