6
$\begingroup$

I have four brushless motors that I want to control using an Arduino Nano. I was looking at getting a 4-in-1 ESC controller similar to this one on amazon.

At this point in my project, I'm more interested in toying around with components and understanding how to control them using an Arduino rather than having a fully functional drone. I was wondering if anyone had a good resource on how to communicate with and control ESCs using an Arduino. Is this something that can easily be done?

enter image description here

It seems pretty straightforward how to solder the actual brushless motors to the ESC, however I was mainly wondering how this 8-wire connector can be used to control them from an Arduino. If I directly connect the M1/M2/M3/M4 wires to pins on my Arduino, are there libraries which can be used to control the motors?

$\endgroup$
5
  • $\begingroup$ Well, which one you get matters a lot here. :) There are several different protocols that may or may not be supported by any given part. $\endgroup$
    – ifconfig
    Jan 7, 2021 at 21:28
  • 1
    $\begingroup$ Some useful resources for the DSHOT protocol might be arduino.stackexchange.com/questions/43851/… and github.com/gueei/DShot-Arduino $\endgroup$
    – ifconfig
    Jan 7, 2021 at 21:34
  • $\begingroup$ Thanks again for your responses! I'm planning on getting the one linked on Amazon, which I believe supports the "DShot150/300/600/MultiShot/OneShot" protocols. Do you know how I could find out if my Arduino can also use these protocols? EDIT: Your second comment answers these questions, thank you! $\endgroup$ Jan 7, 2021 at 21:35
  • 1
    $\begingroup$ Yeah, not natively. :P But as the arduino.SE post says, there are hacky ways to do it with AVR arduino and some more established methods if you venture into STM32 arduino. (like the Betaflight/Cleanflight/etc. FCs) $\endgroup$
    – ifconfig
    Jan 7, 2021 at 21:46
  • $\begingroup$ Did you ever found a solution to this problem? I'm currently doing a project for school and would greatly benefit from this. I'm also looking to interface a 4 in 1 ESC with an Arduino for an autonomous drone. $\endgroup$ Nov 29, 2022 at 16:20

1 Answer 1

6
$\begingroup$

If you must use dshot then try this library https://github.com/gueei/DShot-Arduino However, for just playing around, it would be much easier to use PWM protocol and the servo library for Arduino. Most ESC's are backwards compatible so I recommend trying using PWM first and if you must, use DSHOT.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.