PX4 / sapog

Sapog - advanced multiplatform ESC firmware
https://kb.zubax.com/x/cYAh
BSD 3-Clause "New" or "Revised" License
204 stars 142 forks source link

Power stage self test fails with high FET dead time setting #3

Closed pavel-kirienko closed 10 years ago

pavel-kirienko commented 10 years ago

Together with a PWM_DEAD_TIME_NANOSEC=750, the FETs run at about 45°C @ 80% power for a minute. Unfortunately the DEAD_TIME seems to be quite on the edge, sometimes the boot of the ESC fails with the following error messages (LED red, low freq beep):

UAVCAN: CAN bitrate 1000000 bps
UAVCAN: Node started, ID 10
Motor: Power stage test...
Motor: Selftest phase 0: low 6, high 2603
Motor: Selftest phase 1: low 6, high 1171
Motor: Selftest phase 2: low 6, high 2597
Motor: Selftest FAILURE at phase 1: sample 1171 is far from median 2597
Motor: Power stage test...
Motor: Selftest phase 0: low 7, high 2604
Motor: Selftest phase 1: low 6, high 2595
Motor: Selftest phase 2: low 6, high 2597
Motor: Cross phase test...
Motor: Phase 0 cross conductivity: 2603 2630 2642
Motor: Phase 1 cross conductivity: 1177 1170 1173
Motor: Phase 2 cross conductivity: 1086 1080 1083
Motor: All phases are shorted, assuming the motor is connected
Motor: Sensors test...
Motor: Raw input voltage 2373, raw input current 487
Hardware OK
Motor OK

The issue is most likely caused by poorly chosen duty cycle that prevents the high side FET driver cap from recharging: https://github.com/pavel-kirienko/px4esc/blob/master/firmware/src/motor/realtime/motor_pwm.c#L365.

pavel-kirienko commented 10 years ago

@hsteinhaus Would you mind to fix it and also commit your refined dead time settings (750ns)?