Skip to content

pantaluna/esp32_ledc_pwm_basics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Apr 11, 2019
db04dd0 · Apr 11, 2019

History

3 Commits
Apr 11, 2019
Nov 16, 2018
Mar 24, 2019
Nov 16, 2018
Nov 16, 2018
Apr 11, 2019
Apr 11, 2019
Nov 16, 2018

Repository files navigation

Project Description

This example shows how to control the intensity of LEDs using the standard ESP-IDF LEDC driver (a LED Controller using PWM):

  • Frequency
  • Duty resolution
  • Duty cycle

Espressif Reference Documentation: https://esp-idf.readthedocs.io/en/latest/api-reference/peripherals/ledc.html

What are the HW SW requirements of the ESP32 MJD Starter Kit?

Hardware

  • A decent ESP development board. I suggest to buy a popular development board with good technical documentation and a significant user base. Examples: Adafruit HUZZAH32, Espressif ESP32-DevKitC, Pycom WiPy, Wemos D32.
  • The peripherals that are used in the project. @tip The README of each component contains a section "Shop Products". @example A Bosch BME280 meteo sensor breakout board.

Software: ESP-IDF v3.2

mkdir ~/esp
cd    ~/esp
git clone -b v3.3 --recursive https://github.com/espressif/esp-idf.git esp-idf-v3.2

FAQ

Hardware Setup

  • This setup uses a yellow LED with a Forward voltage of 2.0-2.2V. The resistor value of 100 Ohm is specific for the LED's forward voltage. If you use a LED with a higher Forward Voltage then you might have to lower the resistor value else the LED will not turn on.
  • Wire ESP32's GPIO_NUM_14 -> (+) 5mm yellow LED (-) -> Resistor 100 Ohm -> GND

Running the example

  • Run make flash monitor to build and upload the example to your board and connect to its serial terminal.

Reference: the ESP32 MJD Starter Kit SDK

Do you also want to create innovative IoT projects that use the ESP32 chip, or ESP32-based modules, of the popular company Espressif? Well, I did and still do. And I hope you do too.

The objective of this well documented Starter Kit is to accelerate the development of your IoT projects for ESP32 hardware using the ESP-IDF framework from Espressif and get inspired what kind of apps you can build for ESP32 using various hardware modules.

Go to https://github.com/pantaluna/esp32-mjd-starter-kit