esp32_cam软件开发6-PWM

/*
* About this example
*
* 1. Start with initializing LEDC module:
* a. Set the timer of LEDC first, this determines the frequency
* and resolution of PWM.
* b. Then set the LEDC channel you want to use,
* and bind with one of the timers.
*
* 2. You need first to install a default fade function,
* then you can use fade APIs.
*
* 3. You can also set a target duty directly without fading.
*
* 4. This example uses GPIO18/19/4/5 as LEDC output,
* and it will change the duty repeatedly.
*
* 5. GPIO18/19 are from high speed channel group.
* GPIO4/5 are from low speed channel group.
*
*/

猜你喜欢

转载自www.cnblogs.com/llw2017/p/9267688.html