How to flash SimonK and enable comp_pwm

Many of the ESCs on the market have their own firmware and are not optimized for using in multicopters. For best performance you need to flash the ESCs with a special multirotor firmware. Note: Not all of the ESCs can be flashed with these firmwares. Check this list to see which ESCs are supported.

The most popular are SimonK and BLHeli. Which one is better is hardly to say, especially when using different type of motors. Here I will show you, how to flash the SimonK firmware on a HK BlueSeries 12a ESC and how to enable the comp_pwm feature.

What is comp_pwm? It is not exact the same thing as damped light on BLHeli, but it performs a bit like an ESC with damped light enabled. On the KISS ESCs its called active freewheeling. It switches the passive MOSFET on your ESC “ON” during the freewheeling phases and so reducing the power loss. If you want to learn more about PWM and active freewheeling, watch this video.

Damped light or regenerative braking: when you reduce the throttle, your motors don’t stop immediately. If damped light is enabled, the ESC actively stops the motor. This allows faster response of your copter. This video shows it very clear. On SimonK firmware you need to enable the “MOTOR_BRAKE” feature for regenerative braking.

Summary: if you enable comp_pwm and motor_brake on SimonK, you get the same experience as Damped Light on BLHeli.

Tools needed for flashing the firmware:

  • An ISP Programmer – USBasp AVR Programming Device for ATMEL; you can also use Arduino as ISP device, but it is easier with the USBasp.
  • Atmega Socket Flashing Tool. On some ESCs, that have pads on the PCB board you can even do it without this tool. I have done it once on my HK BlueSeries 30A, but it is much easier with the tool.

There are several software applications you use to flash the firmware. I have always used the KKmulticopter Flash Tool. If you want to enable the comp_pwm function you will need the latest beta version.

Connecting: Plug the USBasp into your PCs USB-port. If you are using the Atmega Socket Firmware Flashing Tool connect it to the USBasp device.

If you have decided to do it without the tool, connect the pins of your USBasp device with cables to the pads of your ESC (you need to identify the MISO, MOSI, GND, VCC, SCK and RESET pads on your ESC).

IMAG0295_1

IMAG0297_1

Once everything is connected you need to supply power to the ESC. It is not recommended to use a LiPo battery as an external power supply, so do it on your own risk.

Flashing: Start the KKmulticopter Flash Tool. Choose the USBasp as a programmer. Then choose your ESC type. As said I will be flashing my HK BlueSeries 12a, which has atmega8. Note: most of the ESCs on the market have this one or Silabs processor. Be sure to choose the one “+ enable Bootloader”, so you can later flash new firmware easily trough the servo-cable of the ESC.

It is very important to flash the right firmware on the ESC or you can damage it. The list with the supported ESCs on top of this page tells you, which one is the right for you. Last but not least you can define the firmware version. The latest one SimonK from 2015-04-19 support another useful function called “OneShot125”. It is a modification on how the flight controller and the ESC communicate between each other. It should give you more responsiveness, but there could be issues with some ESCs and motors.

KKmulticopter.Pic1

If you don’t want to enable comp_pwm, you need only to click on the green button and the firmware will be flashed to the ESC. You should get the “Flashing of firmware was successful” message.

If you want to get use of the feature click on the “SimonK Firmware Compiler”-Tab. Select the version, click Download on the right and choose again the right one for your ESC.

KKmulticopter.Pic2

Then on the tgy.asm-Tab scroll down to the line where COMP_PWM is defined. To enable it replace the “0” with “1”. You can also enable the MOTOR_BRAKE feature. Then click “Save” and “Compile”. The newly created file is ready to flash and you can click on the green button to do it.

Leave a Reply

4 Comments

  1. Yao Wei

    Hi,
    I use Afro Race Spec 20A ESCs on SimonK firmware from HobbyKing. I used KKFlashtool_Beta to update firmware to 20-04-19 release and had the COMP_PWM and MOTOR_BRAKE activated per your blog. They all seem to show flash was successful, I did 4 and reconnected them to my flight controller Naze32 Rev6 on Cleanflight 1.13. I plugged my battery into the quad and it started making a jittering and popping noise. Havent seen any white smoke but I think I might have burnt something. Any advise why this is happening? The Afro ESCs I have are https://www.hobbyking.com/hobbyking/store/uh_viewItem.asp?idProduct=86396

    Appreciate some advise.

    • Sergey

      Hey Yao, as far as I remember, jittering and noise are normal, when you have not connected the signal cable right. Maybe reversed signal and ground cables. Please check the connection to your Naze32. Best, Sergey

      • Yao Wei

        Hi Sergey, I definitely connected the cables correctly, for AfroESC orange is the signal and brown is ground and double checked on Naze board. But thanks for the thought anyway.

        • Sergey

          The ESC should be fine, but cant remember any more, what can cause this…