Your first photo shows the Encoder Motor Module V1.4, with four motor cables already plugged in. The connection you need next is between that module and the Pi’s 40-pin header. The motors stay connected to the module.
1. Switch off and disconnect power first.
Shut down the Pi and unplug its power supply. Disconnect any battery from the motor module before adding wires.
2. Connect three communication wires.
In your module photo, near the bottom edge, you can see a connector labelled SCL SDA GND 5V, below the separate GND TX RX NC connector. Use the SCL/SDA/GND connector for this connection—not TX/RX.
| Motor-module label |
Raspberry Pi 5 connection |
| SDA |
Physical pin 3, GPIO2 / SDA |
| SCL |
Physical pin 5, GPIO3 / SCL |
| GND |
Physical pin 6, GND |
Use jumper leads with ends that fit the pins. Follow the printed labels on the module rather than cable colours.
The numbers 3, 5 and 6 are physical header-pin positions, not GPIO numbers. If you are unsure which end of the Pi header is pin 1, send a close-up of the header before powering anything on; your current Pi photo is too distant to check individual connections reliably.
Leave the module’s I²C 5V pin unconnected for this separately powered arrangement. It is an input, not a power output for the Pi. Leave GND TX RX NC unused for this I²C connection.
3. Provide separate motor power.
Keep powering the Pi through its USB-C power input. The motor module needs its own supply connected to its power input, observing the printed + and − markings. The supply voltage must match the motors’ rated voltage—please do not choose a voltage from the board’s appearance alone.
On V1.4, a flashing PWR indicator is normal when powered.
4. Set up the software after checking the wiring.
Connecting the wires alone will not start the motors. The official Raspberry Pi example supports Pi 4 and Pi 5 and controls this module over I²C at 0x34.
Please send the motor label/model, the battery or power-supply label, and the operating system installed on your Pi. A photo of the three wires connected, with power still off, will also let us check the wiring before proceeding.
These steps follow the official Motor Driver Module Introduction, Raspberry Pi Example, and Raspberry Pi header reference.
If this reply was helpful, you can mark it as the solution using the button below.