Setup servo2040 on Raspberry pi 5

Hello. I am computer literate, but new to Raspberry pi (i have the 5) and new to python.

Working to setup with a servo2040 (motor2040 next). I was able to

  1. Connect the board to the Raspberry pi
  2. See the drive in File Manager
  3. Drop the uf2 file, it rebooted
  4. lsusb now shows “Bus 001 Device 004: ID 2e8a:0005 MicroPython Board in FS mode“
  5. git clone pimoroni-pico
  6. Attempt to run the samples (e.g. led_rainbow.py) on the Raspberry (in Visual Studio)
    1. module not found on “from pimoroni import Button”

That is where I am stuck.

There appears to be two python involved

  1. one on the Raspberry
  2. one on the 2040 board

Since the objective is to get the Raspberry to control the servos, talking to the 2040 board via the USB interface, how do I connect the two? There is a link from the Raspberry’s python to the 2040 board that is missing from any documentation I have been able to find.

apt search pimoroni* finds no library (to possibly install).

Your help is much needed to close the missing link and will be greatly appreciated.
Pierre Cote

You’ll need to have our custom version of MicroPython installed on the Servo 2040 to have access to the pimoroni module. You can download a .uf2 from the Releases page of our pimoroni-pico Github repo - you’ll need the ‘pico’ image for Servo 2040.

Perhaps our Getting Started with Pico guide might be useful if you’re new to working with RP2040 boards? It discusses communicating with the board using the Thonny program rather than VS Code, but if you want to use VS Code instead you might want to check out the micro-pico extension.