Porting StepMotor module example ?
-
Hi everyone,
I am currently trying to use a StepMotor Module (13.2, version 1.0), with a Core2.
The example StepmotorPulse_M039.ino includes some libraries:
#include "M5Stack.h"
#include "Module_Stepmotor.h"
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"And all seem up to date.
However, compilation fails:Compilation error: 'ledcSetup' was not declared in this scope
I read in many discussions that M5Stack.h should be replacer by M5Unified.h and FastLED.h
Is the example broken by new libraries ? Shall I downgrade the libraries ? Or change the example ?
Thanks in advance for any advice, link or reading.
-
@ChSimon
esp32 by Espressif ver 3 brought changes and headaches.
you can still compile with ver 2.0.17.
Ver 3 changes are outlined here:
https://randomnerdtutorials.com/esp32-migrating-version-2-to-3-arduino/
The third party vendors, such as, but not limited to, M5Stack had to scramble, back peddle if you will.
I use ver 3.1.0 which is stable for all my projects.
'ledcSetup' was "deprecated". -
@teastain Huge thanks !
Randomnerdtutorial link is the best Christmas Gift I've received this year !
Why does not M5Stack update the examples accordingly ? Not enough human resources ?
This is deeply misleading, is not it ? -
@ChSimon My pleasure!
M5Stack releases a new gadget or two every week!
They need to support us Arduino IDE guys and the UIFlow with new drivers (libraries) and examples.
The esp32S3 variant has been a nightmare for then, apparently.
The 'esp32 by Espressif' board def, shift to ver3 was seismic.
This Community website is a resource for them because we find the problems and complain. then their engineers hunt it down and correct it.
The new Unified library helps a lot.
We have a DIY hobby!
Cheers, Terry. -
Hi everyone,
In case somebody would be interested, here is the modified version of the example code StepmotorPulse_M039 working with M5Unified.h and Espressif API updates.
Tested with an old M5Basic.
In retrospect, it's relatively obvious.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login