Recent Releases of SimpleFOC
SimpleFOC - v2.3.5
SimpleFOClibrary v2.3.5
Main features
- ESP32 bugfix
- after the low-level API changes in the Arduino-ESP32 core #447
- Pin is not configured #458
- C6 MCPWM bugfix #440
- New fuctionality
- HybridStepperMotor added to the main library #457 - see in docs
- Motor characterisation (phase resistance and inductance) #436 - see in docs
- SAMD21 support for low-side current sensing #479
- RP2350 support #435 #468
- STM32
- New driver code #442
- Low-side current sensing support for H7 family #/460
- Docs
- Hybrid stepper motor example see in docs
- Sensorless FOC example see in docs
- A short guide to synchronous loop - see in docs
See the complete list of bugfixes and new features of v2.3.5 fixes and PRs
What's Changed
- Add RP2350 support by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/435
- Fix for MagneticSensorI2C uses incorrect bit mask calculation #402 by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/412
- Add motor characterisation by @mcells in https://github.com/simplefoc/Arduino-FOC/pull/436
- ESP32 C6 fix & STM32 new HAL only driver by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/442
- STM32 HAL-only PWM driver by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/430
- Current calculation typo in comments by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/449
- Update esp32ledcmcu.cpp to ensure ledctimer is initialised to a known state (ledctimer = false) by @rob-deutsch in #447
- Merge master changes back to dev branch by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/452
- Feat hybrid stepper to main + implement current sensing for it by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/457
- Feat current sense check if TRGO set for STM32 by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/456
- Fix
Pin is not configured as analog channelerror by @jeremiahrose in https://github.com/simplefoc/Arduino-FOC/pull/458 - Add support for timer 8 by @jeroenzwan in https://github.com/simplefoc/Arduino-FOC/pull/468
- use default dir only if sensor not connected by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/459
- Feat h7 current sensing by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/460
- Disable allow power down when creating MCPWM timer by @adamgerhant in https://github.com/simplefoc/Arduino-FOC/pull/474
- Fix lowside sync lost by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/478
- Feat lowside samd21 by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/479
- esp32 ledc skips first channel index #471 by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/480
- Dev to master v2.3.5 by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/481
New Contributors
- @jeremiahrose made their first contribution in https://github.com/simplefoc/Arduino-FOC/pull/458
- @jeroenzwan made their first contribution in https://github.com/simplefoc/Arduino-FOC/pull/468
- @adamgerhant made their first contribution in https://github.com/simplefoc/Arduino-FOC/pull/474
Full Changelog: https://github.com/simplefoc/Arduino-FOC/compare/v2.3.4...v2.3.5
Scientific Software - Peer-reviewed
- C++
Published by askuric 10 months ago
SimpleFOC - v2.3.4
SimpleFOClibrary v2.3.4
Some of the most important features
- ESP32 MCUs extended support #414
- Transition to the arduino-esp32 version v3.x (ESP-IDF v5.x) #387
- New support for MCPWM driver
- New support for LEDC drivers - center-aligned PWM and 6PWM available
- Rewritten and simplified the fast ADC driver code (
adcRead) - for low-side and inline current sensing.
- Stepper motors current sensing support #421
- Support for current sensing (low-side and inline) - see in docs
- Support for true FOC control -
foc_currenttorque control - see in docs
- New current sense alignment procedure #422 - see in docs
- Support for steppers
- Much more robust and reliable
- More verbose and informative
- Support for HallSensors without interrupts #424 - see in docs
- Docs
- A short guide to the units in the library - see in docs
- See the complete list of bugfixes and new features of v2.3.4 fixes and PRs
What's Changed
- fix RP2040 compile problems with earlehillpower by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/397
- Merge teensy updates from master branch by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/399
- move setting target to start of move() #404 by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/405
- add MT6701 I2C sensor configuration by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/406
- Added gain documentation to BG431BESC1.ino by @rob-deutsch in https://github.com/simplefoc/Arduino-FOC/pull/407
- 408 feature support for arduino esp32 v301 current sensing by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/414
- 390 support for the new esp32 ledc library api by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/410
- 408 feature support for arduino esp32 v301 by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/411
- Fix for #415 sin/cos integer overflow on 16-bit CPUs by @dekutree64 in https://github.com/simplefoc/Arduino-FOC/pull/416
- Hall sensor without interrupt by @Candas1 in https://github.com/simplefoc/Arduino-FOC/pull/424
- Feat new cs align by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/422
- Feat stepper current sensing by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/421
- Dev to master for the release v2.3.4 by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/425
New Contributors
- @rob-deutsch made their first contribution in https://github.com/simplefoc/Arduino-FOC/pull/407
Full Changelog: https://github.com/simplefoc/Arduino-FOC/compare/v2.3.3...v2.3.4
Scientific Software - Peer-reviewed
- C++
Published by askuric almost 2 years ago
SimpleFOC - v2.3.3
SimpleFOClibrary v2.3.3
Some of the most important features: - STM32 MCUs - support for center aligned pwm (even across multiple timers and motors/drivers) #374, #388 - support for DMA based low-side current sensing: #383,#378 - support for F7 architecture #388,#394 - Teensy4 MCUs - support for low-side current sensing #392 - support for center aligned 6pwm and 3pwm (optional) #392 - KV rating calculation fix #347 - Much more performant Park/Clarke calculation #340 - And much more - see the complete list of bugfixes and new features of v2.3.3 fixes and PRs
What's Changed
- Stm32 adc no interrupt by @Candas1 in https://github.com/simplefoc/Arduino-FOC/pull/341
- Foc refactoring by @Candas1 in https://github.com/simplefoc/Arduino-FOC/pull/340
- Kv rating fix by @nmscode in https://github.com/simplefoc/Arduino-FOC/pull/347
- Make timeout configurable in MagneticSensorPWM #348 by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/354
- Fix some constants, update library files for next release by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/358
- Prevent double constants by @Candas1 in https://github.com/simplefoc/Arduino-FOC/pull/359
- Add library.json to set libArchive #357 by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/360
- Add currentsense.enable/disable by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/365
- expose result of PP check by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/368
- RP2040: respect pin nrs on boards which remap them by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/369
- Fix bug in ATMega sine computation by @runger1101001 in https://github.com/simplefoc/Arduino-FOC/pull/373
- initFOC: remove unnecessary delay by @Schnilz in https://github.com/simplefoc/Arduino-FOC/pull/370
- [BUGFIX] Injected channel by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/371
- Feat stm32 synctimers by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/374
- Update stm32_mcu.cpp by @Candas1 in https://github.com/simplefoc/Arduino-FOC/pull/378
- Use interrupt if no repetition counter by @Candas1 in https://github.com/simplefoc/Arduino-FOC/pull/383
- Analogread by @Candas1 in https://github.com/simplefoc/Arduino-FOC/pull/385
- Add missing implementation for MagneticSensorI2C::AS5600 by @ystradmann in https://github.com/simplefoc/Arduino-FOC/pull/389
- Set STM32 timer prescaler based on timer clock frequency by @Copper280z in https://github.com/simplefoc/Arduino-FOC/pull/388
- Feat teensy4 lowside by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/392
- Move Ualpha and Ubeta to FOCMotor by @Candas1 in https://github.com/simplefoc/Arduino-FOC/pull/326
- Add lowside current sensing for STM32F7 microcontrollers by @Copper280z in https://github.com/simplefoc/Arduino-FOC/pull/394
- new CI by @askuric in https://github.com/simplefoc/Arduino-FOC/pull/396
New Contributors
- @nmscode made their first contribution in https://github.com/simplefoc/Arduino-FOC/pull/347
- @Schnilz made their first contribution in https://github.com/simplefoc/Arduino-FOC/pull/370
- @ystradmann made their first contribution in https://github.com/simplefoc/Arduino-FOC/pull/389
Full Changelog: https://github.com/simplefoc/Arduino-FOC/compare/v2.3.2...v2.3.3
Scientific Software - Peer-reviewed
- C++
Published by askuric about 2 years ago
SimpleFOC - v2.3.2
SimpleFOClibrary v2.3.2
- Improved space vector modulation code thanks to @Candas1
- Bugfix for stepper motor initialization
- Bugfix for current sensing when only 2 phase currents available - please re-check your current sense PID tuning
- Bugfix for teensy3.2 - #321
- Added teensy3/4 compile to the github CI using platformio
- Fix compile issues with recent versions of ESP32 framework
- Add ADC calibration on STM32 MCUs thanks to @Candas1
- Bugfix for crash when using ADC2 on ESP32s - thanks to @mcells
- Bugfix for renesas PWM on UNO R4 WiFi - thanks to @facchinm
- And more bugfixes - see the complete list of 2.3.2 fixes and PRs
Scientific Software - Peer-reviewed
- C++
Published by runger1101001 over 2 years ago
SimpleFOC - v2.3.1
# SimpleFOClibrary v2.3.1
- Support for Arduino UNO R4 Minima (Renesas R7FA4M1 MCU - note UNO R4 WiFi is not yet supported)
- Support setting PWM polarity on ESP32 (thanks to @mcells)
- Expose I2C errors in MagneticSensorI2C (thanks to @padok)
- Improved default trig functions (sine, cosine) - faster, smaller
- Overridable trig functions - plug in your own optimized versions
- Bugfix: microseconds overflow in velocity mode #287
- Bugfix: KV initialization (5fc3128)
- And more bugfixes - see the complete list of 2.3.1 fixes here
- Change: simplify initFOC() API (d57d32d. 5231e5e, 10c5b87)
- Change: check for linked driver in currentsense and exit gracefully (5ef4d9d)
- Compatibility with newest versions of Arduino framework for STM32, Renesas, ESP32, Atmel SAM, Atmel AVR, nRF52 and RP2040
Scientific Software - Peer-reviewed
- C++
Published by runger1101001 over 2 years ago
SimpleFOC - v2.3.0
# SimpleFOClibrary v2.3.0
- Arduino Mega 6pwm more timers supported
- Arduino boards - frequency change support either 32kHz or 4kHz
- Arduino Uno - synched timers in 3pwm and 6pwm mode #71
- Teensy 3.x initial support for 6pwm
- Teensy 4.x initial support for 6pwm
- Example for v3.1 SimpleFOCShield
- RP2040 compatibility for earlehillpower core #234 #236
- More flexible monitoring API
- start, end and separator characters
- decimal places (settable through commander)
- Added machine readable verbose mode in
Commander#233 - SimpleFOCWebController - Web based user interface for SimpleFOC by @geekuillaume - webcontroller.simplefoc.com
- bugfix -
MagneticSensorPWMmultiple occasions - #258 - bugfix - current sense align - added offset exchange when exchanging pins
- bugfix - trapezoid 150 fixed
- bugfix - 4pwm on ESP8266 #224
- Additional
InlineCurrentSenseandLowsideCurrentSenseconstructor using milliVolts per Amp #253 - STM32L4xx current sense support by @Triple6 (discord) #257
- phase disable in 6pwm mode
- stm32 - software and hardware 6pwm
- atmega328
- atmega2560
- Lag compensation using motor inductance #246
- current control through voltage torque mode enhancement
- extended
BLDCMotorandStepperMotorconstructors to receive the inductance paramerer - can also be set using
motor.phase_inductanceor throughCommander
Scientific Software - Peer-reviewed
- C++
Published by askuric about 3 years ago
SimpleFOC - v2.2.3
SimpleFOClibrary v2.2.3
- stm32 low-side current sensing
- bugfixing
- leonardo
- mega2560 #190
- inline current sense without driver #188
- bg431b support current sense fix #210
StepperDriver4PWMwrong init #182- open loop back-emf voltage issue #219
- SAMD51 compile issue #217
- ESP32-S3 compile issue #198
- ESP32 compile issue #208, #207
- magnetic sensor direction finding more robust #173, #164
StepDirListenerimproved timing #169, #209HallSensorvelocity calculation fix #192
- API changes
setPhaseVoltageis now public functiongetVelocitycan now be called as many times as necessary - see in docs- it recalculates the velocity if the time between calls is longer then
min_elapsed_time- default 0.1ms
- it recalculates the velocity if the time between calls is longer then
HallSensorvelocity calculation outlier removal using max expected velocityvelocity_max- see in docs- BG431 board can be used only with
LowsideCurrentSenseclass! - see in docs initFOCfails if current sense not initialised - see in docs- driver and current sense have to be well initialised for
initFOCto start - see in docs cs.init()anddriver.init()return1if well initialised and0if failed
- driver and current sense have to be well initialised for
Scientific Software - Peer-reviewed
- C++
Published by askuric over 3 years ago
SimpleFOC - v2.2.2
SimpleFOClibrary v2.2.2
- GenericCurrentSense bugfix and testing
- bugfix leonardo #170
- bugfix - no index search after specifying natural direction
- Low level API restructuring #153
- Driver API
- Current sense API
- New debugging interface - see in docs #158
- Static class SimpleFOCDebug
- CurrentSense API change - added method
linkDriver()- see in docs - Low-side current sensing - see in docs
- ESP32 generic support for multiple motors
- Added low-side current sensing support for stm32 - only one motor #6
- f1 family
- f4 family
- g4 family
- New appraoch for current estimation for torque control using voltage - see in docs
- Support for motor KV rating - back emf estimation
- Using motor phase resistance
- KV rating and phase resistance used for open-loop current limiting as well - see in docs
Scientific Software - Peer-reviewed
- C++
Published by askuric about 4 years ago
SimpleFOC - v2.2.1
SimpleFOClibrary v2.2.1
- Sensor class init bugfix #121
- Voltage/current limit handling bugs #118
- Added the new motion control interface to the commander see docs
- New target setting - possible to set the position, velocity and torque target at once
- Separated the motion control interface from full motor callback - only motion control and torque control type, enable disable and target setting
- New MCU support see docs
- Generic sensor class - to implement a new sensor only implement one function see docs
- Motor class initialisation status tracking by @runger1101001
Scientific Software - Peer-reviewed
- C++
Published by askuric over 4 years ago
SimpleFOC - v2.2
SimpleFOClibrary v2.2
- Sensor floating point error bugfix (initial solution) #83, #37
- Sensor class restructuring - slight API change - docs
- Restructured the generic code and simplified adding new mcus: IMPORTANT: an additional compiler flag needed for PlatformIO see issue and PlatformIO docs
- Removed initial jump #110, #111
- Double to float transformation of the code - performance increase by @sDessens (#100), @KaSroka (#100)
- Docs webiste translated to Chinese! π: Awesome work π by @MINQING1101, @Deng-ge-open-source and @mingggggggg
- New MCU support
- Low side current sensing initial support - docs
Scientific Software - Peer-reviewed
- C++
Published by askuric over 4 years ago
SimpleFOC - v2.1.1
SimpleFOClibrary v2.1.1
- bugfixes commander monitoring get values
- bugfix
voltage_limitwhen providedphase_resistance@byDagor - bugfix
hall_sensorexamples @owennewo - full support of the SimpleFOCStudio @JorgeMaker
- added examples for the PowerShield
- added initial support for
MagneticSensorPWM- interrupts - nonblocking
- blocking mode
pulseln
- SAMD51 support by @runger1101001
- initial support for Raspberry pi Pico π @runger1101001
- added examples to find the raw max and min of the analog and pwm sensor
- extension of the
Commanderinterface- added pwm centering option
WC - added pwm modulation cmd
WT - issue #46: commander end of line character - by @maxlem
- added pwm centering option
- improved esp32 implementation to avoid the need for mcpwm.h changes by @tschundler
- issue #62: motor.shaft_angle setting in the motor.initFOC()
- issue #76: esp32 division by zero
- community fix AS5600 register value
- renamed
Pullup::EXTERNandPullup::INTERNtoPullup::USE_EXTERNandPullup::USE_INTERN
Scientific Software - Peer-reviewed
- C++
Published by askuric about 5 years ago
SimpleFOC - v2.1
SimpleFOClibrary v2.1
- Initial current sensing supportπ
- Inline current sensors
- adaptive zero finding and shunt direction
- Implemented real torque control
- using voltage
- using current magnitude (one current)
- using FOC currents ( d-q currents ) - real foc control
- SVPWM full implementation d+q axis
- Simplified sensor implementationπ’
- For new sensor implementation only one function necessary
getAngle()
- For new sensor implementation only one function necessary
- Upgrade of the HallSensor implementation by @owennewo
- Support for Arduino DUE - everything except the 6PWM mode
- Support for ATMega328pb
- bugfix for the Teensy boards ( setting 3pwm )
- extended support for 2PWM stepper drivers - by @zjor
- pull request #52
- included F macro for shrinking string memory usage - moved to programming memory
- disable phase support for 3pwm driver
- not yet for 6pwm
- rewritten
initFOC()- can be skipped and outputs much more info
- align sensor: direction + zero offset + pole pair check
- align current sense
- sensor offset supported (
motor.sensor_offset) - refactored motor commands interface
- much more flexible and easy to extend
- very easy to add new commands and function callbacks
- implemented motor+pid+lpf commands of-the-shelf
- Added step/dir interface
- integrated as an optional communication channel
- Added support for samd21 boards by @runger1101001
- pull request #56
BEWARE π’ slight API changes included
- ControlType renamed into MotionControlType
- ControlType::voltage does not exist any more now - MotionControlType::torque
Scientific Software - Peer-reviewed
- C++
Published by askuric about 5 years ago
SimpleFOC - v2.0
SimpleFOClibrary v2.0
- 6PWM support
- Arduino UNO (atmega328)
- stm32 boards
- esp32 boards
- BLDC driver code separated See in docs!
- BLDC: 6pwm and 3pwm
- Stepper: 4pwm
- Hardware specific code in separate files
- PWM config
- I2C and SPI sensors multiple busses support by @owennewo See in docs!
- Hall sensor refactoring @owennewo
- A lot of refactoring
Experimental features - Initial implementation of Block commutation by @owennewo - FOCModulationType::Trapezoid120 - FOCModulationType::Trapezoid150 - Added support for separate setting of Ud and Uq setting. - Preparations for current control - Working only for SinePWM modulation at the moment
Scientific Software - Peer-reviewed
- C++
Published by askuric over 5 years ago
SimpleFOC - v1.6.0
SimpleFOClibrary version 1.6.0
- Stepper motor FOC support π¨π π
- Very easy to use and results are great, I love it!
- backdrivable,
- no losing steps
- short demo youtube video
- Pull requests by @cousinitt
- refactoring and c++11 improvements
- pid + low pass filter refactoring
- Extended configurability of the sensor classes @owennewo
- clock frequency
- pinout configuration
- quick config constructors
- configurable pwm frequency by JΓΌrgen Frisch
- stm32,teensy,eps32 - not for Arduino
- stm32 added 12bit pwm resolution
- Teensy support by Christopher Parrott
- Huge refactoring done in the library π
Scientific Software - Peer-reviewed
- C++
Published by askuric over 5 years ago
SimpleFOC - v1.5.0
SimpleFOClibrary version 1.5.0
Features: - Open-loop motor control - Support Hall sensors - Support for Analog interface Magnetic sensor - New alignment procedure - automatic sensor direction detection - possibility to avoid alignment completely - PI controller updated to PID controller - Alignment and cogging test - Refactored voltage and velocity limits - Introduced absolute voltage limit
BUGFIXES:
- Space vector calculation
- time measurement - two times _micros() call
Big thanks to @owennewo for awesome suggestions and pull-requests!
Scientific Software - Peer-reviewed
- C++
Published by askuric over 5 years ago
SimpleFOC - v1.4.1
SimpleFOClibrary version v1.4.1
- implemented ESP32 support
- possible to run 4 motors
- documentation provided
- examples added
- moved hardware writing of PWM to
FOCutilssuch asanalogWrite() - shrunk monitoring and motor commands prints due to the memory issues
Scientific Software - Peer-reviewed
- C++
Published by askuric almost 6 years ago
SimpleFOC - v1.3.1
SimpleFOC library version 1.3.1
- Added support for DRV8302 baord Aliexpress link YouTube link
- Added an example of the configuration and usage
Scientific Software - Peer-reviewed
- C++
Published by askuric almost 6 years ago
SimpleFOC - v1.3.0
SimpleFOC library v1.3.0
- Support for STM32 devices
- tested Nucleo-64 and Bluepill
- Full documentation updated
- refactoring debugging to monitoring
- added motor commands
- added align voltage
- removed index search PI parameters
- added
defauts.h - refactored examples
Scientific Software - Peer-reviewed
- C++
Published by askuric almost 6 years ago
SimpleFOC - v1.2.0
Simple FOC Arduino library v1.2.0
- PI controller restructuring
- Added velocity filter
- Added PI tuning examples
- Implemented AS5047/48 sensor SPI intrface
- A lot of testing:
- 14 and 11 pole pair motors
- encoder 2048 and 8192 ppr
- Arudino UNO + HMGBC
- Restructuring the readme
- Ready for release of SimpleFOC shield
Scientific Software - Peer-reviewed
- C++
Published by askuric about 6 years ago
SimpleFOC - v1.1.2
Simple FOC stable release v1.1.2
- Sine wave approximation using an array
- Index pin interrupt handling
- major bugfix
- Enabled all Arduino UNO pwm pins to run with the library
- Restructured the doucmentation (README) and added more content
- Added voltage ramping feature
- Refactoring for easier use
- thouroughly tested all the examples and library features
Scientific Software - Peer-reviewed
- C++
Published by askuric about 6 years ago
SimpleFOC - v1.1.0
Simple FOC release v1.1.0
- Implemented encoder index support - constant velocity
- removed unipolar/bipolar support (not necessary)
- BLDCMotor class serial debug added
- Encoder quadrature mode enable/disable feature
- PI/P controller refactoring
- Default values refactoring
Scientific Software - Peer-reviewed
- C++
Published by askuric about 6 years ago
