ModalAI Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Diagnosing ESC fire on m0138

    ESCs
    2
    4
    86
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Martin LukacM
      Martin Lukac
      last edited by

      Hello!

      We have a m0138 we received a couple weeks ago. The setup we are working to test out:

      • 6S battery (more details below)
      • 2812, 1100kv motor
      • 8046 3-blade props

      During a calibration it caught fire. We are looking for help to diagnose whether this is a bad combo, a soldering/short issue, or a bad parameter, or something else we can't think of. My detailed questions are at the end and we would appreciate anyone with experience taking a look!

      Note - all tests run on #2 esc/motor.

      We first tested the calibration with a 6S 2200mAhr 50C battery. I did a firmware update. Then I started with this file and modified the KV (and the tones), and loaded the file onto the ESC.

      I did the spin test on, and then ran the calibration and it was fine. I have plotly installed but it complained (maybe something wrong with my env) so it didn't generate the calibration html file. I did capture the console output and included for calculating the min and max rpm. See the file labeled goodtest-notes here. Everything looked fine, temps were good, motor was just little warm, current went close to 40.

      I put the result of the calibration and min/max rpm into the xml file here and loaded it onto the ESC.

      A few hours later a bigger battery was charged. I connected to the same setup except and did not change any parameters except I replaced the battery with a 6S 2P 9Ahr battery (also known as a P45B). The battery is 10C max continuous.

      I had the same plotly issue, so see the notes_fire.txt here. You can see that it got to POW: 73, then it stalled/desynced, tried to ramp up the power again, then dropped the power, and the temp kept going up and it aborted. I was behind a door and it sounded like it finished so I looked at it was on fire. See image below.

      How should we debug this? We have another couple m0138's but we are hesitant to try.

      • Can you review the outputs? Does our motor, prop, battery combo make sense here (we are going for long duration).
      • Could this have been a short? something about our wiring?
      • Anything weird in our parameters? Did we start with a good file?
      • I saw some threads about a capacitor, would adding one help here?
      • What can we do to ensure there are no future issues?

      Thank you!

      Here is a picture of the result -- it was mounted in a frame properly isolated but we removed it:

      f3d99342-880b-4d52-859b-0304632ef8ba-image.png

      1 Reply Last reply Reply Quote 0
      • Alex KushleyevA
        Alex Kushleyev ModalAI Team
        last edited by

        Hi @Martin-Lukac ,

        I am really sorry this happened to you! the damage to the ESC is quite spectacular.

        I will need to think about this a bit more, but my initial guess of what happened is as follows:

        • as you mentioned, during the failed calibration attempt, there was a de-sync event, which may suggest the demagnetization time of the motor coils is higher than usual (this is one possibility). A fresh (and larger capacity) battery could have resulted in higher voltage + lower output impedance, causing higher current spikes in the motor (longer demag time). Usually this does not happen with motors of this kV (but much lower like 700 or lower), however it depends on the particular motor.
        • after the de-sync (which it looks like the ESC detected and attempted to restart), the start-up potentially failed because the motor was spinning very fast and it could have gotten into a weird state, applying 80% power to a motor that was not spinning properly. However, in this case i would expect the motor to burn up first before the ESC. Did the motor burn out as well?
          • to resolve the de-sync problem, we typically increase the esc commutation and sense advance (I can go into detail later), but this is documented here: https://gitlab.com/voxl-public/voxl-sdk/utilities/voxl-esc/-/blob/master/voxl-esc-tools/doc/low_kv_motor_tuning.md
        • the unfortunate part is that during the motor calibration, the motor is controlled with % power, not RPM commands, and there are fewer safety checks. If this happened in RPM mode, the ESC would have most likely prevented applying such a high power while motor was spinning very slowly.

        Considering the outcome of your testing, my recommendation would be for us to test your motor / prop configuration and see if there is a repeatable issue. Are you able to share the exact motor and propeller part number and where to purchase it, if possible?

        Thank you

        Alex

        Martin LukacM 1 Reply Last reply Reply Quote 0
        • Martin LukacM
          Martin Lukac @Alex Kushleyev
          last edited by

          @Alex-Kushleyev Hello! thank you for the response and suggestions. We got it working but I have a number of followup questions based on our experiences. They are at the end of this post.

          1. The motor did not burn out as well. It was fine. I think we forgot to check if it was hot with all the other stuff going on.

          2. Thank you for the link, the information is helping us understand better. Is there

          3. Good news is we tried testing again with the same setup and there were no issues. We tried an alternate motor and prop as well (parts listed below). So maybe we had a short, bad soldering, or something? It was fine during the 10% power spin test which we rand for about 15-20 seconds before doing the calibration command

          We used both:

          • this motor with this prop
          • and this motor with a 10 inch 2 blade APC prop (I can't find the link for it right now).

          I put both the calibration output html files in the same folder as the previous files.

          With the 10inch prop the current went over 40amps at 100% power.

          We put the quads together to fly and found that with the first setup 1100kv motor and 8046 was warbling even on arming at the lowest rpm. We did a couple short 5-10 second flights. The px4 logs from the FCv2 showed showed the rpm's were really oscillating and the temperature was ramping up to 90C in about 5-10 seconds.

          We put the ki and kp values to 0 and the warbling and temp issue went way.

          My followup questions are:

          • Can you take a peak at the calibraiton html files I put in the folder? Anything wrong stand out to you in those -- I'm just starting to understand how to look at these and it seems fine, except for maybe the amp spikes with each step. Also should we be looking for a bigger ESC if we are getting to 40 amps or over 40 amps? we dont expect to be flying full out all the time.

          • In the low_kc_motor_tuning document you shared there is section on ki/kp. It says: "leave kp and ki at zero or set to mild gains of kp=50 and ki=10 to avoid oscillations". 1. is there any more documentation on these parameters? 2. By setting them to zero are we loosing the gains of having this closed loop esc? 3. Is there an automated way to find an optimal ki/kp or is it just a manual process of setting, testing, looking at data?

          • I will look at the px4 code but maybe you have a quick answer. In QGroundControl, does setting the max rpm and min rpm override the parameters programed into the ESC? For example if I have two quads with slightly different configurations an I saw the FCv2 that was set for one with a max of 18k rpm to the ESC set with 14k rpm max, what will happen.

          Thank you! We really appreciate the followup!

          Martin.

          Alex KushleyevA 1 Reply Last reply Reply Quote 0
          • Alex KushleyevA
            Alex Kushleyev ModalAI Team @Martin Lukac
            last edited by

            Hi @Martin-Lukac ,

            Thank you for the update. I am glad to see that your new tests went fine. As I mentioned before, i was quite surprised to see the ESC fail in such a way, which may suggest some kind of anomaly.

            I will provide a longer answer soon, but for now some quick notes:

            • non-zero kp / ki parameters will speed up the ESC's RPM response. I will provide some examples
            • you can test whether the ESC closed-loop controller is stable using voxl-esc tools, using step inputs, etc. if unstable, lower Kp. Then lower Ki to avoid slow overshoots. Ki will definitely not contribute to high frequency oscillations.
            • assuming the ESC closed loop response is stable, if the Flight Controller is commanding noisy RPMs, the ESC with aggressive tuning (high kp) will try to track the noisy rpm commands, resulting in motor and ESC heating up.
            • there are generally two main sources of oscillations: unstable attitude controller or vibrations / noisy gyro
              • unstable attitude controller : characterized by lower frequency oscillations (in the range of 10-30Hz, depending on your frame, motors, etc)
              • vibrations can result from drone frame twisting at the frequency of motor RPM, or loose flight controller board / IMU, if flight board is shock mounted, the connected wires can potentially carry vibrations or cause the board to flex due to the wires vibrating / moving (very quickly). These vibrations will be at the frequency of motor RPM. aggressive (high) values of ESC kp will amplify these vibrations, so you can end up in a situation when the ESC's closed loop RPM controller is feeding back and contributing to higher oscillations.
              • by analyzing the gyro logs (will need to enable high rate logging), using FFT you can determine if your frame is mechanically unstable / noisy or the attitude controller is unstable.
            • if you set kp and ki to 0, you still have the advantage of calibrated (and voltage-compensated) RPM control. However, the control will only have feed-forward term. So behavior will be close to response of a traditional ESC with added calibrated feed-forward rpm control with voltage compensation.
            • regarding whether you need a bigger ESC.. it depends on the maximum total current that you plan to pull. The M0138 ESC has been tested with similar motor / prop combo (3110 motor, 900kV with a 10x4.5 tri-blade) . During bench testing, each motor could pull close to 40A at 6S, however in practice you are never going to have all 4 motors spinning at absolute maximum rpm (then you will not have any control margin for attitude). We have tested full punch-out flights for 100+ Amps for over a minute and the ESC was perfectly fine (airflow required for cooling). The mosfets on M0138 are rated for 100A+ continuous (each), so 40A continuous an issue. It will come down to the total current draw and cooling. For high power applications like this, you should definitely start at lighter loads and try to push the ESC to the limit. You will also need to worry about power connector(s) if you are drawing 100A+ continuously (battery connector may melt).
            • px4 params: the min and max rpm params in px4 should match the min and max in your esc params. the px4 params do not override the limits in the esc params - the ESC will cap the incoming rpm commands if they are outside of the ESC params limits. Also, if you have incorrect px4 rpm limits, the thrust calculation in px4 will be incorrectly scaled from 0 to 100%, so you definitely want to get those rpm limits to be in sync between the ESC and px4.

            Also, you can use our custom version of flight-review to display additional data specific to our ESC (rpm commands, actual rpms, esc temps, etc) : https://github.com/modalai/px4-flight-review (you can run it locally in docker).

            Alex

            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            Powered by NodeBB | Contributors