Bare metal GPIO driver for ESP32 | Toggling an LED

  Рет қаралды 6,317

The EV Engineer

The EV Engineer

Жыл бұрын

In this video, I write my own GPIO driver for the ESP32 microcontroller, instead of using the provided ESP-IDF headers. All memory addresses are pulled directly from the Technical Reference Manual.
[Technical Reference Manual]
www.espressif.com/sites/defau...
[Source Code]
github.com/JoshMarangoni/bare...

Пікірлер: 15
@turboimport95
@turboimport95 5 ай бұрын
Man this was dope, explanation was great. Most people just blow right over stuff like this like its nothing.
@zaca211
@zaca211 2 ай бұрын
Holy crap that was simple. I just switched over the Espressif framework from Arduino and I've been messing around with their GPIO driver for a couple of hours now. Considering all I needed to do was toggle the internal LED, this saves so much hassle.
@alexclarosfernandez8467
@alexclarosfernandez8467 5 ай бұрын
Your videos are great!!! Thanx a lot for your time and effort!!!
@tjwatts100
@tjwatts100 6 ай бұрын
Very useful: thanks. Great for ULP programming where there's no other option.
@aslambasha539
@aslambasha539 6 ай бұрын
Can anyone give insight on how to read GPIO pin such as button and control LED foe ESP32.
@jakewasowski1353
@jakewasowski1353 Ай бұрын
Thanks bro
@fadieid5638
@fadieid5638 8 ай бұрын
Great stuff, arw you willing to continue the series? I am looking for a bate metal approach to the ESP32 instead of the typical arduino core use. What topics are you looking to cover?
@Mankindux
@Mankindux 5 ай бұрын
this is not bare metal as the dev uses esp-idf which incorporates bootloader, start linker script and so on. a bare metal approach would be to write a main, assembly file and use clang directly.
@matsvandamme1
@matsvandamme1 8 ай бұрын
Nice video. Please note that GPIO_OUT_W1TS_REG and GPIO_OUT_W1TC_REG are exposed in soc/gpio_reg.h so a simple #include is sufficient, no need to define these registers inside your code. Please also note that GPIO pin numbers are exposed in hal/gpio_types.h. Same comment, no need to define GPIO5 macro again.
@PatrioticGestalt
@PatrioticGestalt 11 ай бұрын
I tried reading the same document to see how you came about your awesome simplicity. What made you decide to avoid setting the GPIO_FUNCx_OUT_SEL register?
@EV_engineer
@EV_engineer 11 ай бұрын
For simply toggling an LED, GPIO_OUT_W1TS_REG and GPIO_OUT_W1TC_REG are generally easier to set up and offer greater flexibility. But if you have a specific hardware event that you want to use to trigger the LED, and you want to minimize CPU overhead, then GPIO_FUNCx_OUT_SEL might be more appropriate.
@jeanfernandeseng
@jeanfernandeseng 7 күн бұрын
When this code is executed on ESP32, Is there some FreeRTOS tasks at under kernel ? I am trying to check a gpio from external source and send to serial, and the FreeRTOS under IDF sometimes run task like IPC and move the context of execution. I watched the video and I dont understand why you move to linux. Does it possible under windows create a Real Bare Bone code ? Thanks in Advance.
@skanderbelhaj2278
@skanderbelhaj2278 4 ай бұрын
man writing code like its native language
@easyelectronics4364
@easyelectronics4364 3 ай бұрын
😂😂😂
@grenadier4702
@grenadier4702 Ай бұрын
The next step is write your own linker script
UART Echo Task on ESP32 using ESP-IDF
20:47
The EV Engineer
Рет қаралды 3 М.
Playing hide and seek with my dog 🐶
00:25
Zach King
Рет қаралды 32 МЛН
Каха и суп
00:39
К-Media
Рет қаралды 6 МЛН
Does size matter? BEACH EDITION
00:32
Mini Katana
Рет қаралды 20 МЛН
Red❤️+Green💚=
00:38
ISSEI / いっせい
Рет қаралды 79 МЛН
How to Run Linux on an ESP32
18:53
element14 presents
Рет қаралды 151 М.
Bare-Metal MCU #1 - Intro to registers
13:10
Mitch Davis
Рет қаралды 69 М.
Rust on ESP32 - Getting started
14:09
Floodplain: Streaming, Rust and Embedded
Рет қаралды 20 М.
Minimalist Microcontroller: Building a Bare-Bones Dev Board
9:15
Revolutionize Your ESP32 Projects with Live GPIO Pin Monitoring!
8:08
The Last Outpost Workshop
Рет қаралды 158 М.
Как бесплатно замутить iphone 15 pro max
0:59
ЖЕЛЕЗНЫЙ КОРОЛЬ
Рет қаралды 4 МЛН
Самые крутые школьные гаджеты
0:49
Новые iPhone 16 и 16 Pro Max
0:42
Romancev768
Рет қаралды 684 М.
Здесь упор в процессор
18:02
Рома, Просто Рома
Рет қаралды 399 М.
EXEED VX 2024: Не өзгерді?
9:06
Oljas Oqas
Рет қаралды 49 М.