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

Add currentsense.enable/disable #365

Merged
merged 3 commits into from
Jan 9, 2024
Merged

Conversation

runger1101001
Copy link
Member

Add a enable() and disable() function to currentsense, and reset the PIDs on a motor.enable().

See discussion here:
https://community.simplefoc.com/t/read-a-potentiometer-continuously-on-stm32-and-analogread/4214/90

@runger1101001
Copy link
Member Author

I think this can be merged, to allow us to fix the "current kick" after enable on STM32...

@runger1101001 runger1101001 merged commit 1bad770 into simplefoc:dev Jan 9, 2024
16 checks passed
@Candas1
Copy link
Collaborator

Candas1 commented Jan 13, 2024

Hi Richard,

I wanted to start implementing current sense enable/disable on STM32, but after I created a branch on my fork based on the project's dev, I end up with a arduino-FOC and a Simple FOC folder in the dependencies:
image

It looks like:

Do you have the same issue ?
I updated platformio just before that, so it could be a bug there.

@runger1101001
Copy link
Member Author

Is maybe one of them the original project dependency?

SimpleFOC is the project and library name, but Arduino-FOC is the actual folder/repository name. At a guess I'd say one of them comes from a git pull, and the other via library dependency or symlink?

I can't say I have the same issue, and when I check the dev branch online I can't see any trace of SimpleFOC within the drivers?

@Candas1
Copy link
Collaborator

Candas1 commented Jan 13, 2024

ok I won't waste too much time for now.
the arduino-foc folder has your last changes and points to my fork, so it should be good enough.

So just to understand, how should I declare the enable and disable function ?
Should I override it in lowsidecurrentsense class, and call new _enable() and _disable() functions in the current sense driver ?

@runger1101001 runger1101001 added this to the 2.3.3_Release milestone Jan 21, 2024
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

Successfully merging this pull request may close these issues.

2 participants