Skip to content

feature: new API and prepare for espFoC 2.0.0#26

Open
uLipe wants to merge 9 commits intomainfrom
feature/newAPI
Open

feature: new API and prepare for espFoC 2.0.0#26
uLipe wants to merge 9 commits intomainfrom
feature/newAPI

Conversation

@uLipe
Copy link
Owner

@uLipe uLipe commented Feb 4, 2026

This will be a major update where the new API of espFoC is introduced:

  • motor controller is now standalone and defer a periodic callback to plug with user code, not more esp_foc_set_target_xxx
  • The nested servo controller was removed from the motor controller, and now is independent from the motor controller subsystems, allowing to be managed individually / allowing user to implement their own servo control;
  • Fixes in the PLL observer and open loop startup for sensorless mode.
  • Updates on the adc_oneshot driver that can now borrow one channel for analog encoder sensor;
  • Increase the PWM rate to 50KHz (experimental).
  • rust support is removed since its API has been broken, so I will update here first and reintroduce it in the 2.1.0

uLipe added 7 commits February 2, 2026 16:14
Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
That was causing drift of the phase estimed.

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
Now it is possible to see the SVPWM output and Vq/d command.

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
At initialization for quick checking if its working in the log.

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
To be used for reading an analog encoder, also provide a rotor
sensor driver on top of it.

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
Making more smooth after the transition

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
As a replacement of the old nested control decoupling the
servo capabillities from the motor controller.

No implementation yet.

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
@uLipe uLipe self-assigned this Feb 4, 2026
@uLipe uLipe changed the title feature: newAPI and prepare for espFoC 2.0.0 feature: new API and prepare for espFoC 2.0.0 Feb 4, 2026
uLipe added 2 commits February 4, 2026 14:02
By changing the gpio number signal for the enable, passing
the desired gpio in negative value makes the enable logic to invert

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
Based on a 1st order current regulator with
ouput clamp.

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
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.

1 participant