Skip to content
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

Current controller counter issue in motor.c #151

Open
4var1 opened this issue Apr 12, 2021 · 4 comments
Open

Current controller counter issue in motor.c #151

4var1 opened this issue Apr 12, 2021 · 4 comments

Comments

@4var1
Copy link
Contributor

4var1 commented Apr 12, 2021

ui16_motor_speed_controller_counter never gets reset after firing so will fire lots more than expected... means it fires most of the time - only not firing for 2000 pwm cycles just after ui16_motor_speed_controller_counter wraps back to 0...

Not tested - just noticed as part of porting mspider65's changes across

else if ((ui16_motor_speed_controller_counter > 2000) && // test about every 100ms
    (ui16_motor_speed_erps > ui16_max_motor_speed_erps))

The equivalent current counter gets reset ok - so would work as expected...

if (ui8_current_controller_counter > 14)
  ui8_current_controller_counter = 0;
@casainho
Copy link
Contributor

Good catch!

@4var1
Copy link
Contributor Author

4var1 commented Apr 12, 2021 via email

@casainho
Copy link
Contributor

casainho commented Apr 13, 2021

no probs - any idea why I can't open issues for the Android App too?

Was disabled. You can now.

@4var1
Copy link
Contributor Author

4var1 commented Apr 13, 2021 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants