Article

Flashing Bluejay on BLHeli_S ESCs: PWM frequency, startup power and the settings that protect your motors

Bluejay is free, open-source ESC firmware for the 8-bit ESCs that ship with BLHeli S. It is based on BLHeli S revision 16.7 and adds what stock BLHeli S lacks: bidirectional DShot for RPM filtering, Extended DShot Telemetry (EDT), a choice of 24, 48 or 96 kHz PWM, and editable startup tunes. Flashing it takes a few minutes in a browser. Choosing the PWM frequency and setting startup power deserve more thought than the flash itself, because they decide how the motors behave in a crash.

The facts below come from the Bluejay GitHub wiki and release notes, the ESC Configurator site and Oscar Liang's Bluejay guide. Where they disagree, both views are given.

Does your ESC take Bluejay?

Bluejay runs on ESCs built around the SiLabs EFM8 Busy Bee microcontroller, which is the hardware BLHeli_S runs on. It does not run on 32-bit ESCs that use BLHeli_32 or AM32. For those, Betaflight recommends AM32, which the article on RPM filtering on this site covers.

The quickest check is ESC Configurator itself: connect, read the ESCs and see which firmware and layout it reports. Layout names look like A_H_15. The first letter is the board design, the second the chip (L for BB1, H for BB2, X for BB51) and the number is the dead time. Release files add the PWM frequency and version, for example A_H_15_48_v0.21.0.hex. ESC Configurator downloads the right file for you, so you only need this naming when something goes wrong.

Two limits are worth knowing before you flash. Bluejay supports DShot only, with no Oneshot, Multishot or other analog protocols. According to the Bluejay FAQ, BB1 (L) chips handle DShot150 and DShot300, while BB2 and BB51 handle DShot300 and DShot600.

Which version

The latest stable release is v0.21.0, published in July 2024. A v0.21.1 release candidate followed in August 2024 and is marked as a pre-release. The Bluejay team recommends always running the latest version and says it supports only the latest version.

If any of your quads are still on 0.20.0, update them. ESC Configurator shows a warning about issues with stall detection and motor protection in 0.20.0 that "might result in broken ESCs and/or motors." The 0.21.0 release notes explain what happened: fixing 3D mode in 0.20 accidentally disabled startup motor protection, and a separate bug made the ESC ignore the maximum startup power. According to the notes, that second bug existed in BLHeli_S and in every Bluejay version up to 0.20.0.

The same notes list a known issue in 0.21.0: 3D mode has performance problems after the startup protection fixes, and the team says it cannot advise using it.

Flashing with ESC Configurator

You can flash with the standalone Bluejay Configurator, but Oscar Liang recommends the web app at esc-configurator.com, which only works in Chrome-based browsers.

  1. Take the props off.
  2. Close Betaflight Configurator so it does not hold the serial port.
  3. Connect the flight controller to the computer over USB, then plug in a LiPo. The ESCs need battery power to be read and flashed.
  4. Click Select Serial Port, pick the flight controller's port and click Connect. Then click Read Setup to read the ESCs.
  5. Click Flash All and set:
    • Firmware: Bluejay.
    • ESC: leave the detected layout as it is.
    • Version: the latest official release.
    • PWM Frequency: see the next section.
  6. Click Flash and wait until every ESC is done.

If one ESC shows as "Unknown" while the others are recognized, Oscar suggests ticking Ignore MCU Layout and flashing it with the same layout as the others. If all of them show as Unknown and you do not know the correct layout, do not use this option, because the wrong file can stop the ESC from working. An ESC whose bootloader is damaged can only be recovered through its C2 interface. The Bluejay wiki has an unbricking guide for that.

After flashing, enable bidirectional DShot and set the motor pole count in Betaflight. The article on RPM filtering on this site covers those steps and how to check that the RPM telemetry is clean.

PWM frequency: 24, 48 or 96 kHz

PWM frequency is how fast the ESC switches power to the motor windings. In Bluejay it is built into the firmware file, so changing it means flashing the ESCs again with a different build.

The advice differs depending on who you ask.

Oscar Liang's guideline is 96 kHz for tiny whoops, 24 kHz for 5-inch quads and 48 kHz for sizes in between. In the settings section of the same guide he suggests 48 kHz for long range and freestyle and 24 kHz for racing. He also notes that lower PWM frequency reduces motor braking power, which slows deceleration but has little effect on acceleration.

The Bluejay developers are more sceptical of 96 kHz. Their FAQ says 48 kHz is usually the best choice on whoops because it gives the longest flight times, and that the improvement from 48 to 96 kHz is usually "miniscule and not worth it." In the 0.21.0 release notes they go further and write that 96 kHz mode is "pretty much useless" and might be removed. The reason is resolution. The wiki lists 1000 throttle steps at 24 kHz, 500 at 48 kHz and 250 at 96 kHz. The dead time is deducted from the duty cycle on top of that, which cuts the usable resolution further.

Dead time is the second thing to look at. According to the FAQ, the higher the dead time, the lower the PWM frequency should be. With a dead time of 30 or more, drop to a lower frequency if you see any of these:

  • motors that do not spin up consistently on arm, even with startup power at maximum;
  • frequent desyncs;
  • stuttering motors.

A reasonable starting point is 48 kHz on whoops, as the developers suggest, and 24 or 48 kHz on a 5-inch quad. Oscar's own tip for 5-inch freestyle is to try 48 kHz if the motors sound rough on 24 kHz.

One older recommendation no longer applies. The wiki's settings page still advises leaving PWM dithering on above 24 kHz, but the 0.21.0 release notes say dithering was removed because it did not do what it promised.

Startup power and motor idle

BLHeli_S ESCs have no phase current feedback. The Bluejay wiki says plainly that the ESC cannot tell when it is pushing too much current into a stalled motor. Startup power is the only safeguard. Bluejay first tries to start the motor at the minimum startup power and raises it with each attempt up to the maximum. If the motor still does not turn at the maximum, the ESC treats it as stalled. In a crash, with a prop jammed in the grass, these limits are what stop the ESC from burning out the motor, or itself.

The wiki's goal is the lowest values that still start the motors reliably. Its starting points, tested by the Bluejay team with static idle:

Battery Min/max startup power Motor Idle (Betaflight)
4S and above 1010/1020 5.5
3S 1020/1040 5.5

For 1S and 2S quads the wiki has a separate table by motor and dead time, with values from 1020/1040 to 1090/1150 for ESCs with a dead time under 30, and a warning that a dead time of around 50 or more can need much higher values. Do not borrow the high-dead-time values for another quad. The wiki warns that using them on a low-dead-time ESC, or on anything above 2S, leaves you with no motor protection at all.

Then arm the quad without props and watch how the motors behave:

  • They spin and stop again and again: raise motor idle in Betaflight by 3% and check that dynamic idle is off.
  • They do not spin, or spin weakly and stop: raise both min and max startup power by 10 and repeat until they start.
  • They start reliably every time: try lowering min and max startup power by 10 until they stop starting reliably, then go back up a step.
  • They fail to start when the battery is low: raise motor idle or the maximum startup power by 10.

Motor idle matters as much as startup power. As soon as the ESC sees the motor spinning, it hands throttle control to the flight controller. If Betaflight's idle value is too low, the motor stalls right after it spins up.

If your values end up more than 10 away from a similar quad in the wiki's tables, the wiki tells you to inspect the hardware first: solder joints, wires, motor screws and bearings. On ESCs with a dead time below 25, a bigger change most likely means you have reduced the startup protection. The wiki adds that crashed quads normally do not need higher startup limits.

Dynamic idle is a separate risk. Because the ESC cannot sense current, dynamic idle keeps raising motor speed when a prop is blocked, which can hold the motor at full load for a long time. The wiki says to avoid dynamic idle on 1S and 2S with Betaflight versions before 4.5. With older versions, pilots found the motors hard to start and raised startup power until the protection stopped working. Betaflight 4.5 added a parameter to deal with this.

EDT and temperature protection

Extended DShot Telemetry sends extra data from the ESC to the flight controller, such as ESC temperature. Since 0.21.0, Bluejay also uses EDT for a safety feature: the ESC arms only after a valid EDT handshake, if the flight controller firmware supports it. In Betaflight, turn EDT on in the CLI:

set dshot_edt=on
save

With the props off, the wiki's test is:

dshotprog 255 13
motor 255 1060
dshot_telemetry_info

The motor command spins all the motors. The output shows eRPM and RPM as long as bidirectional DShot is on, and a TEMP column with the reading from the ESC chip's internal sensor.

Temperature protection is off by default since 0.21.0. The release notes say it had "effectively not been working for a long time (probably ever)," and when it was fixed, some quads started losing power in flight. To use it:

  1. Add the ESC temperature element to the Betaflight OSD and enable EDT.
  2. In ESC Configurator, set Power rating: 1S only on boards rated for 1S only, and 2S+ on everything else, including boards rated for 1-2S.
  3. Check the temperature readings. The wiki considers ambient temperature plus 10-20 degrees a sane range. Readings of 0 or 255 mean something is wrong. Try the other power rating and check again.
  4. Only then turn temperature protection on.

If a quad gradually loses power until it lands, the FAQ points first to temperature protection with the wrong power rating.

The remaining settings

After flashing, click Read Setup again. Oscar Liang says the defaults suit most pilots. A few settings are worth understanding before you change them:

  • RPM Power Protection (Rampup) limits power according to how fast the motor is turning. Lower values avoid power spikes but can reduce acceleration and top speed.
  • Motor Timing: higher timing is less prone to desyncs and gives more power, at the cost of efficiency. Oscar suggests leaving the default unless you know why you are changing it, and says whoop pilots can try a lower value such as 15 degrees.
  • Beep Strength and Beacon Strength: the wiki warns that a high value can make the motors or ESCs hot.
  • Brake On Stop keeps braking while throttle is at zero and the quad is disarmed.
  • Startup melody: the melody editor lets you pick a ready-made tune or write your own in RTTTL notation, then save it with Write Melodies.

Click Write Setup before you disconnect. Then put the props back on and test hover and a few throttle punches in a safe spot before you fly the quad hard.