OneShot125 ESC setting

Firmware/software/electronics/mechanics
Post Reply
t.yoneda
Beginner
Posts: 27
Joined: Mon May 17, 2021 3:03 am

OneShot125 ESC setting

Post by t.yoneda »

Hello!

I want to run Crazyflie Bolt with this ESC
However, the motors are not spinning properly.
Is the setting wrong?

Firmware build setting
uncommented

Code: Select all

# motor.h
#define ENABLE_ONESHOT125
change value

Code: Select all

# motor.h
#define BLMC_PERIOD 0.0025
Video
https://drive.google.com/file/d/1QUA3rc ... sp=sharing

Regards,
tobias
Bitcraze
Posts: 2339
Joined: Mon Jan 28, 2013 7:17 pm
Location: Sweden

Re: OneShot125 ESC setting

Post by tobias »

This is probably related to not having any idle thrust and the ESC has a hard time spinning up the motors. This thread talks a bit about it. If you use START_DISARMED the system.forceArm needs to be set to one to arm it, which I recommend.
t.yoneda
Beginner
Posts: 27
Joined: Mon May 17, 2021 3:03 am

Re: OneShot125 ESC setting

Post by t.yoneda »

Hi tobias.

I have changed config.mk and parameters, but the motor is still stepping-out.

Code: Select all

# config.mk
CFLAGS += -DCF_MASS=0.144f
CFLAGS += -DDEFAULT_IDLE_THRUST=7500
CFLAGS += -DSTART_DISARMED

Code: Select all

// system.c
static bool forceArm = 1;
Also, if I set DDEFAULT_IDLE_THRUST to 10000, motors spin fine without the propeller, but step-out when the propeller is attached.

This is a cfclient plot of the motor output with the propeller removed.
Is there anything I can learn from this?
plot.png
kimberly
Bitcraze
Posts: 1050
Joined: Fri Jul 06, 2018 11:13 am

Re: OneShot125 ESC setting

Post by kimberly »

Hi!

Just a notice, that Tobias is out now on a holiday and won't be back until mid august. We will try to help out but it might be a bit difficult!

I noticed that you didn't add

Code: Select all

CFLAGS += -DENABLE_ONESHOT125
as tobias mentioned in the previous post in the thread he referenced too. Did you try that as well?
t.yoneda
Beginner
Posts: 27
Joined: Mon May 17, 2021 3:03 am

Re: OneShot125 ESC setting

Post by t.yoneda »

thanks kimberly!

I tried the thread that tobias referenced.

I forgot to write that I uncommented "#define ENABLE_ONESHOT125" in motor.h.
if I add "CFLAGS += -DENABLE_ONESHOT125" to config.mk, I get "ENABLE_ONESHOT125 redifined error", so I didn't add it.

also, I changed the ESC to a new one, and at first it was hard to spin, but after waiting a little, it started to spin.
this seems to be a characteristic of small brushless motors.
kimberly
Bitcraze
Posts: 1050
Joined: Fri Jul 06, 2018 11:13 am

Re: OneShot125 ESC setting

Post by kimberly »

alright, good to know.

Unfortunately this is how far I can help, but perhaps you can give an update in a few weeks time and we will notify @tobias to answer again.

Have you seen this blogpost by the way? https://www.bitcraze.io/2020/01/crazyfl ... -autonomy/
Not sure if it helps at all but perhaps give an indication of which modules to use.
Post Reply