How to connect the hiwonder encoder motor module v 1.4 to pi 5

:light_bulb: Using this template is recommended — you may also edit it freely, but you must fully describe your product and the problem (at least: product name, version, and problem description).

Product and Purchase

  • Product model: Hiwonder 4WD
  • SKU or kit name:
  • Purchase channel:
  • Controller board: Encoder Motor Module 1.4

Software and Environment

  • Operating system:
  • Connection method:
  • Software version:
  • Firmware version:
  • Image version:
  • Tutorial step:

Issue Description

I am not able to connect the motors to my pi 5.

Reproduction Steps

Evidence

  1. Photos or short video:
  2. Wiring photo:
  3. Screenshot:

What You Have Tried

Urgency

  • Is this for a class, competition, or deadline?
    • This is a personal project with a deadline within 7 days so I would like to fix this isuue as soon as possible.

The Encoder Motor Module V1.4 is controlled over I²C, and its official Raspberry Pi example supports both Raspberry Pi 4 and 5. The motors connect to the motor module; the Pi sends commands to that module.

With power disconnected, check the following:

  1. Motor connections: Connect encoder motors to the module’s 6P-PH2.0/2.0mm encoder-motor connectors. The TT-motor connectors use a different wire order, so they are not interchangeable.
  2. Communication: Use the module’s SDA, SCL and GND connections to connect to the Pi’s corresponding SDA, SCL and GND connections. The documented I²C address is 0x34. Please share a wiring photo before we confirm the physical header-pin positions for your setup.
  3. Power: Power the Pi and motor module separately, as recommended in the module guide. The module’s supply voltage must match your motors’ rated voltage. Do not try to power the Pi from the module’s I²C 5V pin—it is input-only. On V1.4, the former 5V output on the serial connector is NC and cannot supply power.
  4. Power indicator: A flashing PWR LED is normal on V1.4; an unlit PWR LED indicates that the module is not powered.

The official Raspberry Pi example uses Python’s smbus module. Its motor-type setting must match the installed motors, so we should identify those before choosing that setting.

Please post a clear photo of the module and your Pi wiring, the motor model or label, the motor-module power-supply voltage, and your Pi’s operating system. Also let us know whether you are stuck on the physical wiring, getting a software error, or running code successfully but seeing no motor movement.

These checks follow the official Motor Driver Module Introduction and Raspberry Pi Example guides.


If this reply was helpful, you can mark it as the solution using the button below.

The pi 5 and the motors are not connected right now (also i have very limited knowledge on this so detailed explanations will be appreciated)

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.

The HiWonder Product name is “Hiwonder large metal 4WD vehicle chassis for Arduino/Raspberry Pi/ROS Robot with 8V encoder Geared Motor x 1”

OS in Pi 5 is Debian GNU/Linux 13 (Trixie)

This picture below is my current plan for providing power:

The battery splits off into 2 pwr sources: 1 sides goes through a converter which reduces the power to 5 V for the pi and it connects through a USB C to the pi and the other does not reduce the power and I was going to use it for the motors (to plug into the encoder module).

Your proposed battery split matches one of the power arrangements recommended for the Encoder Motor Module V1.4:

  • Motor branch: Battery → module’s motor-power input.
  • Pi branch: Battery → DC–DC converter → Pi’s USB-C power input.

My earlier reply was too restrictive about separate supplies: two separate batteries are not required. The official Motor Driver Module Introduction also allows one battery with a DC–DC converter supplying the controller.

However, the photo does not establish that this particular battery and converter are suitable. Before connecting power:

  1. Check the motor-branch voltage. The module accepts DC 3–12 V, but its supply must also suit the connected motors. Your product description specifies 8 V motors; the module’s 12 V maximum does not mean those motors should receive 12 V. Please provide a readable battery-label photo, including its nominal voltage, and its fully charged voltage if specified.
  2. Check the converter. Please provide a close-up of its label showing input range, output voltage and output-current rating. A “5 V” output alone is not enough to confirm suitability for your Pi 5 and connected accessories. The module documentation does not verify this converter or its USB-C connection.
  3. Check polarity and insulate the loose ends. The photo shows exposed wire ends at the unused branch. Keep the battery disconnected while wiring, and terminate or individually insulate those ends before powering anything. Connect motor power only to the module’s marked + / − power input, observing polarity—not to its I²C connector.
  4. Keep the communication ground connection. Connect the module’s I²C GND to the Pi’s GND, along with SDA and SCL. Leave the module’s I²C 5V pin unconnected in this arrangement; it is input-only.

For a third-party battery, the module guide also requires a discharge rating of at least 3C.

Please send clear photos of the battery label, converter label, and intended module power connector. That will let us check the power arrangement before proceeding. The official Raspberry Pi example covers Pi 4 and Pi 5, but the documentation reviewed does not establish compatibility with Debian 13 Trixie, so software setup still needs to be checked separately.


If this reply was helpful, you can mark it as the solution using the button below.

THe first image is the main battery I plan on using:

The second image is the converter that reduces the batteries power so its safe for the Pi 5:

Do not connect this battery directly to the motor module yet. The battery label shows 11.1 V, 5200 mAh, 50C, while the chassis description you supplied specifies 8 V motors.

The official Motor Driver Module Introduction states that the module accepts DC 3–12 V, but the supply must also match the connected motors’ voltage. The board’s voltage range does not establish that 11.1 V is suitable for your 8 V motors. My earlier approval applied to the split-power arrangement, not this particular battery.

  • Battery: Its labelled 50C discharge rating exceeds the guide’s minimum 3C requirement, but that does not resolve the motor-voltage mismatch.
  • Motor branch: Your planned direct battery branch supplies the battery voltage to the module. The converter on the Pi branch does not reduce the motor branch’s voltage. Please provide the motor label or the product’s motor-specification section so we can confirm the required supply before proceeding.
  • Pi branch: I cannot read a converter specification label in the supplied images. Please send a close-up showing its input-voltage range, output voltage, and output-current rating. Reducing the voltage to 5 V alone does not establish that the converter and its USB-C connection are suitable for the Pi 5.

Keep the battery disconnected while checking these details, and individually insulate the exposed wire ends shown in your earlier photo. The module guide supports splitting one battery supply through a DC–DC converter, but the voltage and converter suitability still need to be checked for your components.


If this reply was helpful, you can mark it as the solution using the button below.

THe converter input is DC 12V/2V

The converter output is 5V(5A Max)

It is a YIPIN HEXHA and that label also says “25W DC TO DC CONVERTER”

The main battery label says:

Zeee Power to Be Enjoyed
5200 mAh

50C 11.1V 57.72Wh

High Performance Lithium Ion Battery

The converter’s stated 5 V, 5 A maximum output gives us more information, but please keep the battery disconnected for now. Two points still need checking:

  1. The motor branch still has a voltage mismatch. Your chassis description specifies 8 V motors, while the battery is labelled 11.1 V. The converter on the Pi branch does not reduce the voltage supplied to the motor module. The official Motor Driver Module Introduction specifies DC 3–12 V for the module and requires the supply voltage to match the motors. For the stated 8 V motors, use a suitable 8 V motor supply unless their specifications explicitly permit another voltage. The battery’s maximum charged voltage must also be checked against the module’s 12 V limit.

  2. The converter input rating is unclear. Please send a readable close-up of its label or its manufacturer’s specification. The text “DC 12V/2V” does not establish its supported input-voltage range. Its 5 V / 5 A / 25 W output rating alone also does not confirm that this converter and its USB-C connection are suitable for the Pi 5; the module documentation does not verify that third-party converter.

The module guide permits one battery split between the motor supply and a DC–DC converter for the controller, so the overall arrangement is supported—but the voltage requirements of both branches must be satisfied first. The battery’s 50C rating exceeds the guide’s minimum 3C requirement; it does not resolve the voltage mismatch.

Please provide the converter-label close-up and the motor label or motor-specification section. Keep the exposed wire ends individually insulated while checking.


If this reply was helpful, you can mark it as the solution using the button below.

Battery: About this item

  • 【Zeee 3S 5200mAh Lipo Specification】- Battery Voltage: 11.1V; Configuration:3S1P; Capacity: 5200mAh; Discharge: 50C; Connector: XT60 Plug. Note: This battery features an XT60 connector. Please confirm your device’s compatibility before purchase.
  • 【5200mAh Battery Dimensions】- Zeee 11.1V 50C 5200mAh rc lipo battery dimension is: 132*43*25mm/5.2*1.69*0.98 inch(L*W*H); Approx Weight(±15g): 343g /12.1oz.
  • 【3S RC Lipo Application】- Zeee 3S 5200mah lipo battery compatible with RC helicopter, airplane, multirotor, Boat, Car, Truck, RC models 1/10 scale vehicles, Slash VXL, Slash 4x4 VXL, E-Maxx Brushless, racing models(Only if the voltage, dimension and the plug match, then it will fit)
  • 【Safety Warning】- 1. Users must read safety manual before use of the battery; 2. You must use Lithium Polymer(LiPo) specific balance charger only; 3. The suggested charge rate is 0.5 - 1C; 4. Never charge the battery unattended; 5. The ambient temperature for lithium battery charging should be maintained between 41°F and 95°F.
  • 【How to Choose a Charger】- 1. The charger must have a balance charging function; 2. The charger must support 3S battery charging(11.1V nominal, 12.6V fully charged); 3. The recommended charging current for this battery is 2.6A to 5.2A, so the charger must support this range.
  • 【What You Get】- 1 Pack of Zeee 11.1V 50C 5200mAh lipo battery with XT60 plug. Any product problems, please Contact US: 1. Enter into “Your Orders” to click “Contact Seller” option; 2. Click “Ask a question” on our storefront. We will get back to you within 24 hours.

Converter:

About this item

  • 【Input Voltage】DC 8V-32V (DC 12V/24V)
  • Output USB C Interface: Output voltage: DC 5V; Output current: 5A (max); Output power: 25W (max)
  • Multi-protection Safety Features: With overload protection, overcurrent protection, input low voltage protection, overheat protection
  • 【Silicone sealed design】 IP68 Waterproof, Shockproof, Moistureproof, Dustproof, more durable.
  • Wide device compatibility: 12V/24V to 5V USB-C buck converter, suitable for Raspberry Pi 4, dash cams, mobile phones, and other electronic devices that require 5V power supply

The new specifications confirm that this battery must not be connected directly to the Encoder Motor Module V1.4. Your battery listing states 12.6 V fully charged, while the official Motor Driver Module Introduction specifies DC 3–12 V for the module, with the supply voltage also matched to the motors.

  1. Motor branch: The fully charged battery exceeds the module’s 12 V limit. Your chassis description also specifies 8 V motors, so the original battery → motor-module connection is unsuitable. The converter on the Pi branch does not reduce voltage on the motor branch.

  2. Pi branch: The converter’s stated 8–32 V input range includes both the battery’s 11.1 V nominal and 12.6 V fully charged voltages. This resolves the earlier uncertainty about its input range. However, its 5 V, 5 A maximum output rating and advertised Raspberry Pi 4 compatibility do not establish compatibility with Pi 5. The module documentation does not verify this converter’s USB-C power delivery for Pi 5.

  3. Recommended next step: For initial testing, power the Pi with a supply confirmed compatible with Pi 5, and power the motor module separately with a supply matched to your stated 8 V motors. Independent controller and motor-module supplies are explicitly supported by the module guide. Keep the communication GND connection between the Pi and module.

If you want to retain this battery for both branches, the motor branch also needs suitable voltage regulation before the module; its required current capacity cannot be selected from the battery voltage alone. We would need the motors’ current specifications to recommend that part safely.

Keep the battery disconnected from the motor module until the motor-power arrangement is corrected.


If this reply was helpful, you can mark it as the solution using the button below.

Im confused. So I cant use my current battery setup for powering the pi and the motors? If so what do I need to get in order to do it?

You can keep your battery, but the motor branch needs a voltage converter before it reaches the motor module. My earlier replies should have made that distinction clearer.

Your battery reaches 12.6 V fully charged, according to the specification you posted. The Encoder Motor Module V1.4 accepts DC 3–12 V, and its supply must also match the motors. Your chassis listing specifies 8 V motors.

To retain one battery for everything, the arrangement would be:

  • Motor branch: Battery → DC–DC step-down converter supplying 8 V → motor module’s power input → motors.
  • Pi branch: Battery → USB-C power converter confirmed suitable for Raspberry Pi 5 → Pi.

What you need to get or confirm:

  1. An additional DC–DC step-down converter for the motor branch. Its input range must cover the battery’s voltage, including 12.6 V fully charged, and its output must match the stated 8 V motors. Its current capacity must be sufficient for all four motors, including startup/stall demand. We still need the motors’ current specifications before recommending an amperage or a particular converter—please share the motor specification section or a readable motor-label photo before buying one.
  2. A confirmed Pi 5 power solution. Your existing converter’s advertised 8–32 V input covers the battery’s nominal and fully charged voltages. However, its 5 V / 5 A label alone does not confirm that its USB-C output is suitable for Pi 5. Ask its manufacturer to confirm Pi 5 compatibility; if they cannot, choose a battery-powered converter explicitly confirmed for Pi 5.

For initial testing, you can instead use a confirmed Pi 5 power supply and a separate motor supply matched to the stated 8 V motors.

Keep the battery disconnected from the motor module until the motor branch is corrected. The official Motor Driver Module Introduction supports separate supplies or a shared battery with DC–DC conversion; the direct 12.6 V battery → motor module connection is the part that must change.


If this reply was helpful, you can mark it as the solution using the button below.

Ok so I have to get an additional converter to step down the battery for my motors and I have to check if my current pi supply is compatible with the pi 5

Or do you suggest getting 2 different power supplies for the pi and motors separately that way I dont need to worry about converters?

Yes—you’ve understood correctly. For initial testing, I recommend two separate, correctly rated power supplies. The official Motor Driver Module Introduction explicitly supports independent power for the controller and motor module.

Option 1: Separate supplies—simplest for initial testing

  • Pi: Use a USB-C power supply confirmed compatible with Raspberry Pi 5.
  • Motor module: Use a separate supply matched to your motors. Your chassis listing states 8 V motors, so choose a suitable 8 V supply, with enough current for all four motors. We still need the motors’ current specifications before recommending a supply’s amperage.

With correctly matched supplies, you would not need additional external step-down converters. Keep the Pi and motor module connected through SDA, SCL and GND for communication, but leave the module’s I²C 5V pin unconnected.

Option 2: Keep one battery—for a mobile setup

Your understanding is correct:

  • Motor branch: Add a suitable step-down converter to provide the motor supply voltage.
  • Pi branch: Confirm that your existing USB-C converter supports Pi 5; replace it only if it is unsuitable.

Do not connect your current battery directly to the motor module: Your battery specification gives 12.6 V fully charged, above the module’s 12 V maximum, and the module guide also requires its supply voltage to match the motors.

My recommendation: Get the system working with separate supplies first. If you want it fully battery-powered afterward, revisit the shared-battery arrangement once the motor current requirements and Pi converter compatibility are confirmed.


If this reply was helpful, you can mark it as the solution using the button below.

I think ill be going with option one and i know how to get a correct supply for pi but for the motors what did you mean by needing the motors specifications? is it not 8V?

Yes—8 V is the motor voltage stated in the product description you shared. Sorry for the confusion: I was asking about the motors’ current requirements, not another voltage.

A suitable motor power supply needs both:

  • The correct voltage (V): Matched to the motors—your listing says 8 V. The official Motor Driver Module Introduction requires the supply voltage to match the connected motors.
  • Enough current capacity (A): Enough for all four motors operating together, including their higher demand when starting or stalled. An 8 V label alone does not tell us whether a supply can provide enough current.

The missing information is each motor’s rated current and startup/stall current, or a recommended power-supply current rating for the complete chassis. I haven’t verified those figures for your exact motors, so I shouldn’t guess an amperage for you to buy.

Please share the motor-specification section from your chassis listing, or a clear photo of any model number printed on a motor. You do not need to measure stall current yourself or deliberately stop a powered motor.


If this reply was helpful, you can mark it as the solution using the button below.

I’m bringing in official support staff to help check the motor specifications and suitable power supply. If you still need my help, you can @ me in this topic. @Hiwonder_Scarlett