• Skip to main content
  • Skip to primary sidebar

RNTLab.com

The Ultimate Shortcut to Learn Electronics and Programming with Open Source Hardware and Software

  • Courses
  • Forum
    • Forum
    • Ask Question
  • Shop
  • Account
  • Blog
  • Login

How to set timer/interrupt to blink a LED each half-second on nodeMCU esp8266 and esp32?

Q&A Forum › Category: ESP8266 › How to set timer/interrupt to blink a LED each half-second on nodeMCU esp8266 and esp32?
0 Vote Up Vote Down
Etienne Gomide asked 4 years ago

Hello,
I have searched and found how to setup the 8-bit and 16-bit timers on Atmega328 and Atmega2560 to blink a LED, for example, but I could not find how to do that on nodeMCU esp8266 and esp32 using the Arduino IDE.
Can you show me some code on how to do that? (set timer/interrupt to blink a LED each half-second on nodeMCU esp8266 and esp32)
 
Thanks,
Etienne

Question Tags: Arduino IDE, ESP32, ESP8266, nodemcu, timers
3 Answers
0 Vote Up Vote Down
Sara Santos Staff answered 4 years ago

Hi.
At the moment we don’t have any tutorials about that.
But, I found this example code for the ESP32:

  • https://gist.github.com/sarasantos/0afb8c65d8386fa09aba5a7d844ad434

In the following link you can find examples for both boards:

  • https://www.visualmicro.com/page/Timer-Interrupts-Explained.aspx

I hope this helps.
Regards,
Sara

0 Vote Up Vote Down
Etienne Gomide answered 4 years ago

Hi Sara,
Thank you very much!
Exactly what I was looking for.
 
Regards,
Etienne

0 Vote Up Vote Down
Sara Santos Staff answered 4 years ago

Great!
I’ll mark this issue as resolved. If you need further help, you just need to open a new question in our forum.
Regards,
Sara

Primary Sidebar

Login to Ask or Answer Questions

This Forum is private and it’s only available for members enrolled in our Courses.

Login »

Latest Course Updates

  • [New Edition] Build ESP32-CAM Projects eBook – 2nd Edition April 16, 2025
  • [eBook Updated] Learn ESP32 with Arduino IDE eBook – Version 3.2 April 16, 2025

You must be logged in to view this content.

Contact Support - Refunds - Privacy - Terms - MakerAdvisor.com - Member Login

Copyright © 2013-2025 · RandomNerdTutorials.com · All Rights Reserved

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.