2024-07-06 10:13 AM
When I try to start my motor by programming a torque ramp and starting the motor, if the motor fails to start, the motor state moves to FAULT_NOW with a startup error. The real issue is that I don’t know how to clear the fault. The state never changes to FAULT_OVER so I can never acknowledge the fault. I wish I could try to restart the motor without having to totally power cycle the system to clear the fault. How do I get a startup fault to transition from FAULT_NOW to FAULT_OVER?
2024-07-08 05:06 AM
Hello captat,
If the motor state moves and stays to FAULT_NOW, it means that the issue is still there so in any case you would not be able to restart your motor. However, this behavior seems strange.
Have you connected your board to the MotorPilot to see what kind of issue there is ? You can also check it by having a look at what means the error code in the MCSDK User Manual. (Via WorkBench, you can find it by clicking on About -> Documentations -> Documentation -> in the newly open browser window, click on User Manual)
Also, could you elaborate on your MCSDK version, as well as enabled project features ?
I would gladly appreciate it if you could also share the Hardware setup you are working on.
You can also share your .stwb6 file so I can easily reproduce your behavior and get all the listed information.
2024-07-10 05:20 PM - edited 2024-07-10 05:24 PM
I am using MCSDK 6.3.0 and STM32CubeMX version 6.12.0, just updated everything recently.
The .stwb6 file is attached (with .txt extension). I modified example control and power boards to match a custom motor driver board so reproduction may not be feasible. It is an FOC project with three shunt resistor current feedback in torque control mode. The "on-the-fly" start up parameters are pictured below. My intention was to have the motor only start up if it was already spinning at least 200rpm, maybe I have done that incorrectly.
I have connected to the Motor Pilot desktop software, and I get basically the same result, when I try to start up the motor, Motor Pilot shows a start up error and remains in the FAULT NOW state indefinitely.
I did have this working before, but things seem to have broken when I re-generated the project.
However, I'm suspicious that it may be related to this issue recently explained here: https://community.st.com/t5/stm32-mcus-motor-control/mc-6-3-with-mx6-12-attr-not-supported-dmpu/td-p/694578
Basically, there is an error during the project generation saying "Attr not supported : Dmpu" So the project generates with errors. I'm not sure what this error means, but its probably not a good idea to rely on a project with errors!
I know there are a lot of variables here, especially with the custom hardware that I'm using, and I just dumped a lot of info here, so no expectation for a complete solution. But any pointers would be appreciated!
2024-07-11 02:26 AM
Hello captat,
It seems that there are two issues here. The first one is that you are experiencing a Start up fault, and it should be possible to solve this via tuning.
However the Start up fault should not be permanent, which is the second issue. I find this one more concerning as it implies an error in the state machine. You mentioned earlier being able to run the project before, could you try to recreate such a project, and try comparing the two of them ? Also, could you tell me what you have changed before re-generating ? Of course, if you could send me the working project for me to also compare them, that would be perfect.
Lastly, be aware that the MCSDK does NOT allow re-generation inside the same folder after MCSDK upgrade. For example, generating a project with MCSDK 6.2.1, then upgrading to 6.3, then opening the 6.2.1 file with 6.3 and re-generating the project inside the same folder, without deleting the old generated project leads to FW issues. To prevent this, you need to re-generate inside a different folder.