Motor 2040

by Pimoroni

Image of Board

A compact 4 channel motor+encoder controller, powered by RP2040. It has RGB and per-motor indicator LEDs plus built in voltage and current sensing. There’s also a Qwiic/STEMMA QT connector for adding breakouts!

Features

  • Powered by RP2040 (Dual Arm Cortex M0+ running at up to 133Mhz with 264kB of SRAM)
  • 2MB of QSPI flash supporting XiP
  • 2 Dual H-Bridge motor drivers (DRV8833)
  • 4 JST-SH connectors (6 pin) for attaching motors
  • Wide voltage range for motors and logic (2.7V to 10V)
  • On-board 3V3 regulator with input up to 13.2V (max regulator current output 150mA)
  • Onboard voltage, current and fault sensing
  • Per motor current limiting (0.5A) *
  • Per motor direction indicator LEDs **
  • Addressable RGB LED/Neopixel
  • Reset and BOOT button (the BOOT button can also be used as a user button)
  • USB-C connector for programming and power (3A max)
  • Qw/ST (Qwiic/STEMMA QT) connector for breakouts

Powering Motor 2040

Motor 2040 can be powered either by plugging the board into a USB-C power source (like a PC or power adapter) or by connecting a battery pack to the EXT PWR or VSYS connections. On an unmodified board, you should only have one power source connected at a time, to avoid back-powering your computer or battery.

If you want to have two power sources connected at the same time, Motor 2040 has two traces on its underside that you can cut to do this safely.

  • Cut EXT PWR to VSYS if you want to provide your motors with a separate power supply (up to 10V) from that used to power the rest of the board. Board power (up to 13.2V) will need to be provided either by USB 5V or VSYS.
  • Cut USB 5V to VSYS if you want to run the board entirely off a separate power supply, without worry of back-powering your computer. Note that this also means the board will not turn on when only connected by USB.

Notes

  • * The current limit of each motor can be disabled by soldering the “high current” pads on the rear (doing this will also disable the current monitoring). The maximum supported output current is 1.2 A continuous (2 A peak) per motor.
  • ** The direction indicators for each motor can be disabled by cutting the “motor LED” traces on the rear.
  • The pinout of the JST-SH motor connectors is M+, M-, 3v3, A, B, GND.

About RP2040

Raspberry Pi’s RP2040 microcontroller is a dual core ARM Cortex M0+ running at up to 133Mhz. It bundles in 264kB of SRAM, 30 multifunction GPIO pins (including a four channel 12-bit ADC), a heap of standard peripherals (I2C, SPI, UART, PWM, clocks, etc), and USB support.

One very exciting feature of RP2040 is the programmable IOs which allow you to execute custom programs that can manipulate GPIO pins and transfer data between peripherals - they can offload tasks that require high data transfer rates or precise timing that traditionally would have required a lot of heavy lifting from the CPU.

Purchase

Contribute

Have some info to add for this board? Edit the source for this page here.

CircuitPython 7.3.3

This is the latest stable release of CircuitPython that will work with the Motor 2040.

Start here if you are new to CircuitPython.

Release Notes for 7.3.3

Built-in modules available: _bleio, adafruit_bus_device, adafruit_pixelbuf, aesio, alarm, analogio, atexit, audiobusio, audiocore, audiomixer, audiomp3, audiopwmio, binascii, bitbangio, bitmaptools, bitops, board, busio, countio, digitalio, displayio, errno, floppyio, fontio, framebufferio, getpass, gifio, imagecapture, json, keypad, math, microcontroller, msgpack, neopixel_write, nvm, onewireio, os, paralleldisplay, pulseio, pwmio, qrio, rainbowio, random, re, rgbmatrix, rotaryio, rtc, sdcardio, sharpdisplay, storage, struct, supervisor, synthio, terminalio, time, touchio, traceback, ulab, usb_cdc, usb_hid, usb_midi, vectorio, watchdog, zlib

CircuitPython 8.0.0-beta.1

This is the latest unstable release of CircuitPython that will work with the Motor 2040.

Unstable builds have the latest features but are more likely to have critical bugs.

Release Notes for 8.0.0-beta.1

Built-in modules available: _bleio, adafruit_bus_device, adafruit_pixelbuf, aesio, alarm, analogbufio, analogio, atexit, audiobusio, audiocore, audiomixer, audiomp3, audiopwmio, binascii, bitbangio, bitmaptools, bitops, board, busio, countio, digitalio, displayio, dotenv, errno, floppyio, fontio, framebufferio, getpass, i2ctarget, imagecapture, json, keypad, math, microcontroller, msgpack, neopixel_write, nvm, onewireio, os, paralleldisplay, pulseio, pwmio, qrio, rainbowio, random, re, rgbmatrix, rotaryio, rtc, sdcardio, sharpdisplay, storage, struct, supervisor, synthio, terminalio, time, touchio, traceback, ulab, usb_cdc, usb_hid, usb_midi, vectorio, watchdog, zlib

Absolute Newest

Every time we commit new code to CircuitPython we automatically build binaries for each board and language. The binaries are stored on Amazon S3, organized by board, and then by language. Try them if you want the absolute latest and are feeling daring or want to see if a problem has been fixed.

Past Releases

All previous releases are listed on GitHub, with release notes, and are available for download from Amazon S3. They are handy for testing, but otherwise we recommend using the latest stable release. Some older GitHub release pages include the same binaries for downloading. But we have discontinued including binaries as assets on newer release pages because of the large number of files for each release.

BROWSE GITHUB