# SimpleFOCMini Over Heating - Arduino - BLDC

**URL:** https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545
**Category:** hardware support
**Tags:** arduino\_uno
**Created:** [July 4, 2023, 8:27pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545 "2023-07-04T20:27:57Z")
**Posts on this page:** 16
**Page:** 1

<div class="post-metadata">

### Author: ![LaraTheWitch](https://community.simplefoc.com/user_avatar/community.simplefoc.com/larathewitch/32/5121_2.png) [@LaraTheWitch](https://community.simplefoc.com/u/LaraTheWitch)
#### Post date: [July 4, 2023, 8:27pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/1 "2023-07-04T20:27:57Z")

</div>

Hi I am using Arduino Uno and SimpleFOCMini and have used the example code for open loop velocity control to test my motor and SimpleFOCMini board, but the motor will turn fine but after a few seconds the SimpleFOCMini chip will get really hot so I turn off the power. I’m using around 8V with the motor [Sunnysky X2204 KV1800] in the following URL:

> **[1PC Original Sunnysky X2204 KV1480/KV1800 Brushless Motor designed for RC...](https://vi.aliexpress.com/item/4000604405617.html?spm=a2g0o.order_list.order_list_main.5.63f91802l18V0T&gatewayAdapt=glo2vnm)**
>
> Smarter Shopping, Better Living! Aliexpress.com

Please could you help so I can then start the process of getting the closed loop design working. Also I can provide the code I am using and the pictures of hardware and wiring configuration.

Thank you.

---

<div class="post-metadata">

### Author: ![LaraTheWitch](https://community.simplefoc.com/user_avatar/community.simplefoc.com/larathewitch/32/5121_2.png) [@LaraTheWitch](https://community.simplefoc.com/u/LaraTheWitch)
#### Post date: [July 4, 2023, 8:38pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/2 "2023-07-04T20:38:29Z")

</div>

> [@LaraTheWitch](#):
>
> the example code for open loop velocity control to test my motor and SimpleFOCMini board, but the motor will turn fine but afte

// Open loop motor control example  
#include \<SimpleFOC.h\>

// BLDC motor & driver instance  
// BLDCMotor motor = BLDCMotor(pole pair number);  
BLDCMotor motor = BLDCMotor(7);  
// BLDCDriver3PWM driver = BLDCDriver3PWM(pwmA, pwmB, pwmC, Enable(optional));  
BLDCDriver3PWM driver = BLDCDriver3PWM(11, 10, 9, 8);

// Stepper motor & driver instance  
//StepperMotor motor = StepperMotor(50);  
//StepperDriver4PWM driver = StepperDriver4PWM(9, 5, 10, 6, 8);

//target variable  
float target\_velocity = 5;

// instantiate the commander  
Commander command = Commander(Serial);  
void doTarget(char\* cmd) { command.scalar(&target\_velocity, cmd); }  
void doLimit(char\* cmd) { command.scalar(&motor.voltage\_limit, cmd); }

void setup() {

// driver config  
// power supply voltage [V]  
driver.voltage\_power\_supply = 8;  
// limit the maximal dc voltage the driver can set  
// as a protection measure for the low-resistance motors  
// this value is fixed on startup  
driver.voltage\_limit = 8;  
driver.init();  
// link the motor and the driver  
motor.linkDriver(&driver);

// limiting motor movements  
// limit the voltage to be set to the motor  
// start very low for high resistance motors  
// current = voltage / resistance, so try to be well under 1Amp  
motor.voltage\_limit = 8; // [V]

// open loop control config  
motor.controller = MotionControlType::velocity\_openloop;

// init motor hardware  
motor.init();

// add target command T  
command.add(‘T’, doTarget, “target velocity”);  
command.add(‘L’, doLimit, “voltage limit”);

Serial.begin(115200);  
Serial.println(“Motor ready!”);  
Serial.println(“Set target velocity [rad/s]”);  
\_delay(1000);  
}

void loop() {

// open loop velocity movement  
// using motor.voltage\_limit and motor.velocity\_limit  
motor.move(target\_velocity);

// user communication  
command.run();  
}

---

<div class="post-metadata">

### Author: ![Valentine](https://community.simplefoc.com/user_avatar/community.simplefoc.com/valentine/32/1024_2.png) [@Valentine](https://community.simplefoc.com/u/Valentine)
#### Post date: [July 4, 2023, 9:26pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/3 "2023-07-04T21:26:29Z")

</div>

> [@LaraTheWitch](#):
>
> the motor will turn fine but after a few seconds the SimpleFOCMini chip will get really hot so

The Mini max current is about 2A.

The motor you use required about five times that much (over 10A).

You need a much more powerful board to drive that motor (about twice the max motor current, 20A).

You may try lowering the voltage

driver.voltage\_limit = 1;  
motor.voltage\_limit = 1;

however this will also limit the torque. But the board probably won’t get that hot.

Cheers,  
Valentine

---

<div class="post-metadata">

### Author: ![LaraTheWitch](https://community.simplefoc.com/user_avatar/community.simplefoc.com/larathewitch/32/5121_2.png) [@LaraTheWitch](https://community.simplefoc.com/u/LaraTheWitch)
#### Post date: [July 4, 2023, 9:49pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/5 "2023-07-04T21:49:07Z")

</div>

Hi, thank you soo much for your reply. Do you know which simple foc board will work with this motor? Also alternatively do you know any relatively cheap (small) bldc motor?

Thanks again 😀

---

<div class="post-metadata">

### Author: ![Valentine](https://community.simplefoc.com/user_avatar/community.simplefoc.com/valentine/32/1024_2.png) [@Valentine](https://community.simplefoc.com/u/Valentine)
#### Post date: [July 4, 2023, 11:00pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/6 "2023-07-04T23:00:01Z")

</div>

> [@LaraTheWitch](#):
>
> which simple foc board will work with this motor

> **[BLDC drivers](https://docs.simplefoc.com/bldc_drivers)**
>
> Arduino Simple Field Oriented Control (FOC) library .

Check out the High performance boards.

Cheers,  
Valentine

---

<div class="post-metadata">

### Author: ![Anthony\_Douglas](https://community.simplefoc.com/user_avatar/community.simplefoc.com/anthony_douglas/32/2300_2.png) [@Anthony\_Douglas](https://community.simplefoc.com/u/Anthony_Douglas)
#### Post date: [July 4, 2023, 11:23pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/7 "2023-07-04T23:23:04Z")

</div>

the B-G431B-ESC1 is pretty good value, easy to get and a lot of the details are already working. If you go with one of the other boards you might get some surprises.

For good cheap motors just search aliexpress for gimbal motors, they are always different but they are a fraction the price of new ones.

---

<div class="post-metadata">

### Author: ![LaraTheWitch](https://community.simplefoc.com/user_avatar/community.simplefoc.com/larathewitch/32/5121_2.png) [@LaraTheWitch](https://community.simplefoc.com/u/LaraTheWitch)
#### Post date: [July 4, 2023, 11:28pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/8 "2023-07-04T23:28:59Z")

</div>

> [@Anthony\_Douglas](#):
>
> motors just search aliexpress for gimbal mo

im thinking of buying the motor driver you mentioned

but how would i wire it though, and would it work with arduino? if so what would the code look like.

also would either of these two different motors work?

> **[IFlight IPower Motor GBM2804H 100T Brushless gimbal motor with hollow shaft...](https://vi.aliexpress.com/item/1005005494735327.html?spm=a2g0o.productlist.main.5.4e745f92hrtFP5&algo_pvid=3072bfe8-3c9b-4f78-b1a7-2de54d762c9f&algo_exp_id=3072bfe8-3c9b-4f78-b1a7-2de54d762c9f-2&pdp_npi=3%40dis%21GBP%2110.63%219.56%21%21%21%21%21%40211bf3f816885122007235477d0797%2112000033302995648%21sea%21GB%214464738407&curPageLogUid=XWUQyUzBh0ws)**
>
> Smarter Shopping, Better Living! Aliexpress.com

> **[1PC Original Sunnysky X2204 KV1480/KV1800 Brushless Motor designed for RC...](https://vi.aliexpress.com/item/4000604405617.html?spm=a2g0o.order_list.order_list_main.5.63f91802l18V0T&gatewayAdapt=glo2vnm)**
>
> Smarter Shopping, Better Living! Aliexpress.com

---

<div class="post-metadata">

### Author: ![Grizzly](https://community.simplefoc.com/letter_avatar_proxy/v4/letter/g/a9adbd/32.png) [@Grizzly](https://community.simplefoc.com/u/Grizzly)
#### Post date: [July 5, 2023, 6:04am UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/9 "2023-07-05T06:04:38Z")

</div>

I fully agrre with @Anthony_Douglas statement regarding the B-G431B-ESC1 board, but would like to add a warning: You definitely need good soldering skills. Everything on that board is tiny and densely packed.

---

<div class="post-metadata">

### Author: ![Owen\_Williams](https://community.simplefoc.com/user_avatar/community.simplefoc.com/owen_williams/32/105_2.png) [@Owen\_Williams](https://community.simplefoc.com/u/Owen_Williams)
#### Post date: [July 5, 2023, 8:39am UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/10 "2023-07-05T08:39:01Z")

</div>

What did you want to do with your motor? The motor you’ve bought is fast with very low resistance, do you need that speed?

Depending on your application, it may be worth considering a smaller (slow) gimbal motor that would work with the mini

---

<div class="post-metadata">

### Author: ![LaraTheWitch](https://community.simplefoc.com/user_avatar/community.simplefoc.com/larathewitch/32/5121_2.png) [@LaraTheWitch](https://community.simplefoc.com/u/LaraTheWitch)
#### Post date: [July 5, 2023, 10:16am UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/12 "2023-07-05T10:16:43Z")

</div>

I’m trying to build a quadruped robot dog, so I need torque.

---

<div class="post-metadata">

### Author: ![Owen\_Williams](https://community.simplefoc.com/user_avatar/community.simplefoc.com/owen_williams/32/105_2.png) [@Owen\_Williams](https://community.simplefoc.com/u/Owen_Williams)
#### Post date: [July 5, 2023, 11:55am UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/13 "2023-07-05T11:55:38Z")

</div>

Your motor is on the high side for kv. E.g at 10v it would be doing 15k rpm. Lower kv motors typically have higher torque. If you are wanting to do a powerful mit cheetah style dog then you may want a lower kv motors and some gearing  
For example I think dagor uses 300kv motors with 9to 1 gearing:  
[https://youtube.com/playlist?list=PLP1lkRM0UD9occAaueumWdNhqz5UpWdfu](https://youtube.com/playlist?list=PLP1lkRM0UD9occAaueumWdNhqz5UpWdfu)

If you’re dog is smaller you might be able to get away with gimbal motors (100kv)

---

<div class="post-metadata">

### Author: ![LaraTheWitch](https://community.simplefoc.com/user_avatar/community.simplefoc.com/larathewitch/32/5121_2.png) [@LaraTheWitch](https://community.simplefoc.com/u/LaraTheWitch)
#### Post date: [July 5, 2023, 1:40pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/15 "2023-07-05T13:40:02Z")

</div>

do you think this motor will be good?

[aliexpress.com/item/1005002046611157.html?spm=a2g0o.productlist.main.87.4f497941aMo9m1&algo\_pvid=58a75601-813a-4acd-b758-aa1a6dcfc952&algo\_exp\_id=58a75601-813a-4acd-b758-aa1a6dcfc952-43&pdp\_npi=3%40dis!GBP!14.16!8.78!!!17.47!!%402102191b16885589384698069d0782!12000018542618261!sea!GB!4464738407&curPageLogUid=3sJh4LRkUoxq](http://aliexpress.com/item/1005002046611157.html?spm=a2g0o.productlist.main.87.4f497941aMo9m1&algo_pvid=58a75601-813a-4acd-b758-aa1a6dcfc952&algo_exp_id=58a75601-813a-4acd-b758-aa1a6dcfc952-43&pdp_npi=3%40dis%21GBP%2114.16%218.78%21%21%2117.47%21%21%402102191b16885589384698069d0782%2112000018542618261%21sea%21GB%214464738407&curPageLogUid=3sJh4LRkUoxq)

---

<div class="post-metadata">

### Author: ![LaraTheWitch](https://community.simplefoc.com/user_avatar/community.simplefoc.com/larathewitch/32/5121_2.png) [@LaraTheWitch](https://community.simplefoc.com/u/LaraTheWitch)
#### Post date: [July 5, 2023, 1:41pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/16 "2023-07-05T13:41:06Z")

</div>

I’ve been trying to make a quadruped robot for over 2 years now, but I keep facing problems.

---

<div class="post-metadata">

### Author: ![Valentine](https://community.simplefoc.com/user_avatar/community.simplefoc.com/valentine/32/1024_2.png) [@Valentine](https://community.simplefoc.com/u/Valentine)
#### Post date: [July 5, 2023, 5:47pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/17 "2023-07-05T17:47:02Z")

</div>

> [@LaraTheWitch](#):
>
> make a quadruped robot

You need geared motors for that, something like the MIT mini-cheetah. These bare BLDC motors you want to use don’t have the torque for the job you need.

Check this link below.

[https://www.aliexpress.us/item/2255800382938470.html](https://www.aliexpress.us/item/2255800382938470.html)

You need the option with the MIT driver.

Problem is they are expensive.

Valentine

---

<div class="post-metadata">

### Author: ![Anthony\_Douglas](https://community.simplefoc.com/user_avatar/community.simplefoc.com/anthony_douglas/32/2300_2.png) [@Anthony\_Douglas](https://community.simplefoc.com/u/Anthony_Douglas)
#### Post date: [July 5, 2023, 10:45pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/18 "2023-07-05T22:45:21Z")

</div>

hobby servos are incredibly cheap, I got metal geared ones for 5 bucks each on aliexpress. something 995 I think. M995 or something, very common model.

There is a ton of these ones kicking around too, as Valentine notes they won’t have the torque on their own, but the pulley is a 2 mm pulley so you can do something with that. [DC 12-24V Nidec Mini 24H Brushless Servo Motor Built-in Drive 100-wire Encoder Micro Brushless Motor Encoder Pwm 9T Metal Gear - AliExpress](https://vi.aliexpress.com/item/1005005246045403.html?spm=a2g0o.productlist.main.11.5c476cfc2HwALj&algo_pvid=a6562aeb-04bd-498b-8162-e6afbe14ec38&algo_exp_id=a6562aeb-04bd-498b-8162-e6afbe14ec38-5&pdp_npi=3%40dis%21CAD%215.62%215.17%21%21%214.15%21%21%40212279a216885972360317851d0763%2112000032346448560%21sea%21CA%212412066855&curPageLogUid=YdhWpEqgSNW4)

---

<div class="post-metadata">

### Author: ![runger](https://community.simplefoc.com/user_avatar/community.simplefoc.com/runger/32/395_2.png) [@runger](https://community.simplefoc.com/u/runger)
#### Post date: [July 9, 2023, 12:47pm UTC](https://community.simplefoc.com/t/simplefocmini-over-heating-arduino-bldc/3545/19 "2023-07-09T12:47:02Z")

</div>

If I may chime in on this thread:

The SimpleFOC mini is actually quite ok for the motor you picked, you can’t run this little motor at 10A anyways.  
But as Valentine and others have pointed out, this motor likes to turn fast, and keeping the currents low enough using the SimpleFOC mini will require you to limit the voltage, and therefore torque.

You’ll go further with a lower KV motor, although as Valentine has mentioned, I have also never seen a direct drive leg. They’re always done with gear-down, often built into the motor itself (often called quasi direct drive, like the MIT cheetah) or via belts or capstan drives.  
So I’d advise working in that direction, although of course if you want to try direct drive, you can give it a go… but I suspect you won’t hit the torque to mass ratios you’ll need.

Servos are not designed to be compliant, handle back-driving or sudden high currents. All the servo based legs I’ve seen (forgive me!) are just rubbish. If it’s to work at all then you need to use expensive robotics servos like Dynamixels, otherwise you’re likely to just burn out your servos all the time.

There’s some designs online you can look at:

MIT cheetah  
Stanford pupper  
James Bruton’s OpenDog

And a whole lot more that use Servos.

Even following or adapting an existing design will be super interesting and challenging project 🙂

> [@LaraTheWitch](#):
>
> do you think this motor will be good?

This same model is also available in 360KV. I’d go for that one. Here’s 6 for $100, so $200 for all 12 motors needed (assuming you use all the same), that seems quite a good price to me. 🙂

> **[5010 360KV / 750KV High Torque Brushless Motors For ZD550 ZD850 MultiCopter...](https://www.aliexpress.com/item/4000510841212.html)**
>
> Smarter Shopping, Better Living! Aliexpress.com

I believe David has experimented with these ones… might be worth asking him about them…  
In fact David might just generally be a good person to buy a beer and chat about this topic 😉
