This control board is intended for use with fighting robots, or other applications where high current brushed motors need to be driven wirelessly with a high reliability.
Features:
- Uses Bluepad32 to allow connection to a wide varienty of wireless game controllers (PS4, PS5, XBOX, Wii, Switch, etc..).
- Integrates two high current H bridges to control two brushed motors.
- Has a programmable current limit to prevent burning out motors or the control board.
- Current surge protection
- Voltage input of 8V to 26V (2S to 6S lipo)
- Has been extensively tested using stalled motors at 10A continuous - with some small mods it can do 20A continuous.
- Has ports to plug in and control ESCs or servos.
- Has ports to allow a standard RC controller receiver to be connected.
- Integrated 5V 2A regulator.
Safety warning
- Ensure you are familiar with lipo safety if you are using lithium batteries
- Do not connect the battery or power supply in reverse, you will destroy your board
- Do not exceed 26V input voltage
- If you wish to plug in your laptop while powering the control board from a battery or PSU, I recommend de-soldering D9 to ensure that your laptop has additional isolation from the board
You will likely have recieved a PCB with no fuses or connectors soldered. Here are the steps to get the board fully constructed and ready to be programmed.
I recommend using 25A fuses, as the maximum recommended current limit is 20A. Here I have used 30A but this is all I had available at the time. You can fit regular AT0 fuses and mini fuses. If you try to power and run the board without fuses populated, the motor controller IC will report errors.
You can solder XT30 connectors for each motor. It is not essential to solder motor connectors, you can instead solder the motor wires directly to the board if you want.
The input power connector size is a standard XT60
The PCB traces use a 1oz copper thickness, which means that it can handle 10A continuously. However, if you require more current than this, i would massively recommend adding a bunch of solder over all exposed power traces to thicken them up. Set the soldering iron to about 400 degrees and spread a layer of solder over the traces, try to be relatively quick to prevent overheating components on the board.
solder.traces.mp4
An arduino library and example code has been provided in this repository. There are a few initial steps to getting the Arduino IDE to support the control board.
Head over to https://www.arduino.cc/en/software to download the Arduino IDE 2.0
Then install it on your machine.
The chip used on this board is an ESP32, therefore we need to add support for this chip via the arduino board manager. Head to file->preferences.
Copy and paste the following two lines to the Additional Boards Manager URLs field. https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json https://raw.githubusercontent.com/ricardoquesada/esp32-arduino-lib-builder/master/bluepad32_files/package_esp32_bluepad32_index.json
Search for ESP32 and press the install button for esp32 and esp32_bluepad32.
Clone this github repository or download the repo as a zip.
Copy the RobotMotors folder to C:\USERNAME\Documents\Arduino\libraries. This will add the Control Board library to the Arduino IDE
Extract the RobotControlBoard.ino file to C:\USERNAME\Documents\Arduino (or anywhere you like) and then open it in the Arduino IDE
This is the code that is used to control the Control Board.
Select the correct target board by going to tools->board->esp32_bluepad32->DOIT ESP32 DEVKIT V1 (you may have to scroll down a bit).
Plug in your board via the micro USB port. If your PC does not detect it then you will have to download the drivers from the following page: https://docs.espressif.com/projects/esp-idf/en/stable/esp32/get-started/establish-serial-connection.html
If it is still not detected then try different USB cables.
Select the COM port that corresponds to the port of your control board
Hit the upload button. The IDE will then compile the code and start uploading it to the board.
You may find that you get an error while connecting to the board. If this is the case then you will have to hold the Boot button on the top right corner of the control board during the connecting process. Release the button when you see it uploading the code.
You have now uploaded the code to the control board! Connect a controller and start driving some motors. For information on supported controllers and how to pair controllers, visit https://github.com/ricardoquesada/bluepad32/blob/main/docs/supported_gamepads.md