🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Interrupt or other solution to run code when time seconds changes

    Scheduled Pinned Locked Moved Arduino
    1 Posts 1 Posters 1.0k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • TomKattT Offline
      TomKatt
      last edited by TomKatt

      Working on a Dial project in Arduino IDE... Looking at the schematics, I note that the RTC INT signal is hardwired to the power rail so the RTC can wake the device when an alarm triggers. I believe most other M5Stack controllers with RTC share the same design.

      But without access to RTC interrupt, what is the best way to trigger code to run when time seconds change? I guess I could create a loop with a small delay and keep checking for Seconds variable to change, but that seems a bit wasteful. Is there some way to know exactly when the time seconds updates? The issue is not the timing of one second, my requirements need to know when UTC time seconds change in order to perform a task as close to exact time as possible.

      EDIT - similar question would be how to know when RTC alarm is triggered?

      Thanks

      1 Reply Last reply Reply Quote 0

      Hello! It looks like you're interested in this conversation, but you don't have an account yet.

      Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

      With your input, this post could be even better 💗

      Register Login
      • First post
        Last post