Open nsmith1024 opened 4 months ago
Hello, hope this message finds you well. Congrats to your first Issue! We will review it as soon as possiable. Feel free to have a look at https://www.amebaiot.com/en/ameba-arduino-summary/ for more information
There is no example for PWM itself, It shows a tone generator example, and servo example, but those doesnt allow direct control of the PWM.
The proper PWM functions ledcAttach(PWM_PIN, FREQ, RESOLUTION); and ledcWrite(PWM_PIN,pwm_value); are undefined in arduino.
Im trying to control a DC motor (not a servo, and not a stepper) just a regular DC motor using the PWM, where i need to change both the frequency and duty cycle.
This issue is stale because it has been open for 14 days with no activity.
Boards
AMB82-Mini
External Hardware
NONE
Hardware Configuration
Using PWM
Version
latest dev (checkout manually)
IDE Name
Arduino IDE 2.3.2
Operating System
Windows
Auto Flash Mode
Disable
Erase All Flash Memory (16MB)
Disable
Standard Lib
Arduino_STD_PRINTF
Upload Speed
2000000
Description
How do i change the PWM frequency?
I tried using standard the Arduino functions
ledcAttach(PWM_PIN, FREQ, RESOLUTION); ledcWrite(PWM_PIN,pwm_value);
Both are undefined.
Please tell me how to set the PWM frequency, resolution, and duty cycle.
Thanks
Sketch
Error/Debug Message
Reproduce remarks
No response
I have checked online documentation, FAQ, GitHub Wiki and existing/closed issues.