-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error MOTOR_BLOCKED #96
Comments
I don't know why the error doesn't get cleared, but your guess with hal sensor issue seem reasonable. You could check connections for the rust.
You mean the
FYI, 360degrees represents electrical AC waveform rotation. Motor rotation will be 1/8 of that (based on number of motor poles pairs). I would update to newer Casaihno's first. It will have more commonalities with this software. |
Thanks, @dzid26 for your answer!
God, what a beginner mistake :-) have totally not considered the pole pair number in my post. Thanks for pointing that out, it was a while since I dealt with pmsm control. Alright, then I will test 1.1.2 with some manual adaptions. A last question out of interest: is the software fully reliant on the hall sensors or will it eventually shift over to back-emf angle estimation towards higher speeds? |
Battery voltage limits the max speed (at least if we speak about 48V motor type), not hal reading frequency - as far as know. However, this software does also support field weakening. But of course at speeds above base speed, the torque becomes small naturally. |
Hello everybody! Great community work, super impressed by the firmware so far! 🥇
I'm opening this issue due to lack of support in previous forks that casainho maintained. Assuming this is the only active community for the TSDZ2 OSF.
I'm currently on an ancient version of the OSF (0.6.4) on my cargo bike in combination with the 850C display. So far, I did not see the need of an upgrade as everything worked just fine. Never change a running system :-)
Recently, the error MOTOR_BLOCKED shows up regularly in random situations (with and without torque on the pedals, different speeds etc.). So I really don't see a pattern to trace down the root cause.
I investigated the source code and found the following section where the error is set/cleared:
https://github.com/OpenSourceEBike/TSDZ2-Smart-EBike/blob/264e04089b7dbeeb487038d40920737d3243a62e/src/ebike_app.c#L1442
One thing I find really strange is that the error never gets cleared when I see the problem ( --> there might be an additional bug in the sw, maybe as
ui8_motor_blocked_reset_counter
does not get initialised to 0 in the declaration line.).Questions/thoughts:
if ((ui16_g_adc_motor_current_filtered > MOTOR_BLOCKED_MOTOR_CURRENT_THRESHOLD_X5) && (ui16_motor_get_motor_speed_erps() < MOTOR_BLOCKED_ERPS_THRESHOLD))
, my assumption is thatui16_motor_get_motor_speed_erps()
returns 0 due to some other error which causes the error to be set after a while when there is a certain amount of current in the system.motor_controller_void()
function (TSDZ2-Smart-EBike-1/src/controller/motor.c
Line 361 in cb8b032
@emmebrusa : Do you remember why you did this change and do you see a chance that updating to the latest SW solves my problem? If so, I would have to consider buying an 860C or using the vlcd5 stock display as my 850C won't support the latest versions any longer. Actually I would have hoped to tackle the problem by updating to casainhos 1.1.2, however the suspicious lines are still the same there.
Another question:
The two forks ran apart pretty early a few years ago. Did you try to catch changes that casainho implemented since then? Hard to judge without experimenting which repo actually offers the better performance...
Looking forward to answers helping to find a solution to my problem!
The text was updated successfully, but these errors were encountered: