Motor Update

Today, I tried to reflash the built-in ESC of our new motor, EP4108.It runs BLHeli firmware, and we would like to update it in order talk to the ESC via a relatively new protocol, DShot, instead of the age-old PWM control. Short story long, I didn’t manage to do it.

Still, here’s what I tried.

As mentioned in this post, the motor has a 6-pin “flashing port” – except there is no provided connectors and absolutely no instruction on how to reflash the ESC. In fact, we don’t even know what ESC it is. All we know is that it runs some version of the BLHeli open source firmware.

Thankfully, there seems to be an alternate method to reflash an ESC, which uses only the control wire and the ground wire. It’s called “FC Passthrough” and the idea is to allow and ESC to be reflashed directly though the connection to its Flight Controller. 

Our motor, with the flashing port at the front and the black and white ESC wires behind

So the first step of that method would be to flash an Arduino (for instance) with the needed program to make it take the role of the FC in this setup, and then connect it to the ESC and then hop ! a reflashed ESC. Or at least that’s the theory. 

It seems there is a standard tool to achieve this, a Windows app called BLHeliSuite. It allows us to flash the Arduino (in our case an Arduino Mega ADK), and then to connect to the Arduino and ask it to list its ESCs. 

After looking around forums for a while, I managed to get this far. Except no matter how I connected the ESC to the Arduino, I couldn’t manage to make it detect the ESC. 

At this point, Sibille came to help me, and in frustration we even tried to connect the ESC to all the available pins on the Arduino. No dice. We then unscrewed the motor to see inside, but all we learned was that the ESC uses an ATMEGA 8A AU 1508 processor. 

It is in fact possible that the firmware currently on the ESC doesn’t support this flashing method, and that the only way to reflash it is through the “flashing port”. That or the programs (we tried several) we flashed on the Arduino through BLHeliSuite was not adapted to our case.

In any case, according to the motor’s manufacturer’s website the built-in ESC runs BLHeli, so all else having failed we decided to at least start the motor with the firmware as is, using the standard PWM control signal. We found this BLHeli manual and Sibille adapted her previous Arduino test code (written a while ago to test-start the other motor we have)  to configure the ESC and start the motor. So at least that works.

Next we’ll investigate how to use the flashing port and keep trying to reflash the ESC with a new version of BLHeli supporting DShot. Any insight is more than welcome on that. 

Also important, we need to find an easy way to get precise feedback on the motor speed, first so we can see how precise the speed is with just a feedback-less ESC, and then to provide feedback to a microcontroller so it can constantly adjust the signal to the ESC to correct any drift from the target speed. We were thinking we could simply attach a magnet to a rod protruding horizontally from the motor and use a Hall effect sensor, or similarly use an optical sensor interrupted once per rotation by the rod passing through, but it would probably create to much imbalance and either vibrate too much or simply fall apart. Any ideas ? Your experience is also welcome here 🙂

That’s all for now, we’ll keep you posted !

Leave a Reply

Your email address will not be published. Required fields are marked *