[EN] ESP-IDF Ep.9 : LEDC (PWM) Output

This article discusses the use of the ESP32’s GPIO to output digital signals such as PWM or Pulse Width Modulation or LEDC (LED Control), which enables frequency generation or adjusts the proportion of 1 and 0 states in 1 waveform. Thus, in the absence of the DAC, we can still adjust the average voltage at that pin as needed and it can be applied to control servo motors as well. Therefore, in this article, we will learn how to use PWM and apply it to frequency transmission instead of DAC (from the previous article) and LED dimming using the experimental board as shown in Figure 1.

LEDC / PWM Labs.
(Figure. 1 Our LEDC)
Read More

[EN] ESP-IDF Ep.8 : DAC Output Part 2

This article discusses the use of the ESP32’s GPIO as an analog signal output through the 8-bit DAC module of the ESP32 microcontroller. In this article, we use Cosine wave generation to output the analog signal of the microcontroller through the speaker and show the waveform obtained from the oscilloscope display. The experimental board is still used as shown in Figure 1.

(Figure. 1 Connection and use of DAC examples)
Read More

[EN] ESP-IDF Ep.6 : ADC Input

This article discusses the use of the ESP32’s GPIO as an analog input. By using the voltage input circuit from adjusting values with an adjustable resistor as shown in Figure 1. So, in this article, we will learn how to use the ADC instruction of the ESP32 microcontroller and how to configure the value of ADC in menuconfig.

(Figure. 1 The implementation is illustrated with the example in this article)
Read More

[EN] ulab v3.0

From the previous ulab article, it was found that Micropython can implement the same dataset processing instructions as used in Numpy through the previous ulab library v.0.54.0 which is the older version of ulab (currently v.3.0.1) brought up this article. This article describes how to create a Micropython that integrates the ulab library and uses it with SPIRAM versions of esp32.

(Figure. 1 Module list of ulab)

ulab3

From Figure 1, it can be seen that the structure of the ulab library has changed from the original. This causes the programming from the previous example to have to be modified. Under ulab there are libraries of numpy and scipy. The details of numpy that are supported are as follows.

Read More

[TH] ESP-IDF Ep.10 : Control the Servo Motor with LEDC.

บทความนี้กล่าวถึงการใช้งานโมดูลเซอร์โวมอเตอร์ด้วยการใช้ GPIO ของ ESP32 ที่นำออกสัญญาณดิจิทัลแบบ PWM หรือ Pulse Width Modulation หรือ LEDC (LED Control) ซึ่งทำให้สามารถสร้างคลื่นความถี่ หรือปรับสัดส่วนของสถานะ 1 และ 0 ใน 1 ลูกคลื่น ที่มีความถี่ 50Hz โดยใช้บอร์ดทดลองดังภาพที่ 1

ภาพที่ 1 การต่อใช้งานประกอบตัวอย่างการใช้งาน LEDC
Read More

[TH] ESP-IDF Ep.9 : LEDC (PWM) Output

บทความนี้กล่าวถึงการใช้งาน GPIO ของ ESP32 เพื่อทำหน้าที่นำออกสัญญาณดิจิทัลแบบ PWM หรือ Pulse Width Modulation หรือ LEDC (LED Control) ซึ่งทำให้สามารถสร้างคลื่นความถี่ หรือปรับสัดส่วนของสถานะ 1 และ 0 ใน 1 ลูกคลื่น ด้วยเหตุนี้ในกรณีที่ไม่มีภาค DAC ผู้เขียนยังคงสามารถปรับค่าเฉลี่ยของแรงดันที่ขานั้นได้ตามที่ต้องการ และสามารถประยุกต์ใช้ในการควบคุมมอเตอร์แบบเซอโวได้อีกด้วย ดังนั้น ในบทความนี้จึงเป็นการเรียนรู้การใช้งาน PWM และประยุกต์เข้ากับการส่งคลื่นความถี่แทน DAC  (จากบทความที่แล้ว) และการหรี่หลอดแอลอีดี โดยใช้บอร์ดทดลองดังภาพที่ 1

LEDC / PWM Labs.
ภาพที่ 1 การต่อใช้งานประกอบตัวอย่างการใช้งาน LEDC
Read More