{"id":15973365,"url":"https://github.com/sglvladi/ticker_esp32","last_synced_at":"2026-05-12T07:43:08.237Z","repository":{"id":92100715,"uuid":"103447986","full_name":"sglvladi/Ticker_ESP32","owner":"sglvladi","description":"esp32 library that calls functions periodically (similar to \"Ticker.h\" for esp8266)","archived":false,"fork":false,"pushed_at":"2017-09-14T05:46:46.000Z","size":15,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-02-10T01:44:49.766Z","etag":null,"topics":["arduino","esp32","ticker"],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sglvladi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-09-13T20:38:11.000Z","updated_at":"2020-11-09T07:40:32.000Z","dependencies_parsed_at":null,"dependency_job_id":"ea23ab0b-d6c0-4bc1-88ff-d438a721f29c","html_url":"https://github.com/sglvladi/Ticker_ESP32","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sglvladi%2FTicker_ESP32","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sglvladi%2FTicker_ESP32/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sglvladi%2FTicker_ESP32/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sglvladi%2FTicker_ESP32/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sglvladi","download_url":"https://codeload.github.com/sglvladi/Ticker_ESP32/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247208371,"owners_count":20901570,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["arduino","esp32","ticker"],"created_at":"2024-10-07T21:04:32.541Z","updated_at":"2026-05-12T07:43:03.198Z","avatar_url":"https://github.com/sglvladi.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Ticker_ESP32\nA primitive library which makes use of the hardware timers in ESP32, to provide similar funtionality and interface akin to the \"Ticker.h\" library for ESP8266.\n\n# Differences to \"Ticker.h\" for ESP8266\n* Each Ticker instance must be provided with the id of the respective hw timer which should be employed. Valid ids can be in the range 0-3. (e.g. ```Ticker LED_Ticker_1(2);```)\n* ESP32 has 4 hw timers, which means up to 4 Ticker instances can be instantiated, one for each timer.\n* Unlike \"Ticker.h\", callback functions with arguments are not supported (yet).\n\n# Usage\n* Define a Ticker instance (e.g. on 4th hw timer):\n\n```c++\nTicker myTicker(3);\n```\n\n* Define a callback function to be called when timer fires:\n\n```c++\nvoid myCallback(){\n  // Do something interesting...\n}\n```\n\n* Initiate the timer and attach our callback to be run at a certain interval (e.g. 1 sec):\n\n```c++\nmyTicker.attach(1, myCallback); \n\nor\n\nmyTicker.attach_us(1000000, myCallback); // 1 second = 1000000 microseconds\n\n```\n\n* When desired, stop the timer and detach the callback:\n```\nmyTicker.detach();\n```\n\nSee the blinkLEDs sketch, for a full example.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsglvladi%2Fticker_esp32","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsglvladi%2Fticker_esp32","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsglvladi%2Fticker_esp32/lists"}