{"id":16133108,"url":"https://github.com/aschuma/esp32_nextion_js_binary_clock","last_synced_at":"2025-06-10T21:11:24.888Z","repository":{"id":92576771,"uuid":"164224889","full_name":"aschuma/esp32_nextion_js_binary_clock","owner":"aschuma","description":"A binary clock driven by an ESP32 microcontroller and a Nextion display, utilizing Mongoose OS and JavaScript technology","archived":false,"fork":false,"pushed_at":"2022-01-08T16:03:32.000Z","size":12509,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-06T15:16:50.914Z","etag":null,"topics":["binary-clock","clock","esp32","esp8266","iot","iot-device","javascript","mjs","mongoose-os","nextion","nextion-display","uart","uart-protocol"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aschuma.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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":"2019-01-05T15:02:40.000Z","updated_at":"2023-02-05T20:27:04.000Z","dependencies_parsed_at":null,"dependency_job_id":"828b7de5-2fa6-422d-a775-9a9e68c45b53","html_url":"https://github.com/aschuma/esp32_nextion_js_binary_clock","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/aschuma%2Fesp32_nextion_js_binary_clock","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aschuma%2Fesp32_nextion_js_binary_clock/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aschuma%2Fesp32_nextion_js_binary_clock/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aschuma%2Fesp32_nextion_js_binary_clock/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aschuma","download_url":"https://codeload.github.com/aschuma/esp32_nextion_js_binary_clock/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aschuma%2Fesp32_nextion_js_binary_clock/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259152636,"owners_count":22813219,"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":["binary-clock","clock","esp32","esp8266","iot","iot-device","javascript","mjs","mongoose-os","nextion","nextion-display","uart","uart-protocol"],"created_at":"2024-10-09T22:37:04.838Z","updated_at":"2025-06-10T21:11:23.272Z","avatar_url":"https://github.com/aschuma.png","language":"JavaScript","readme":"# ESP32 and Nextion powered Binary Clock \n\nThis is a Javascript demo Mongoose OS app. The aim of this project is to demonstrate how to drive a Nextion HMI display from an ESP32 device.\n\nHere is what you get when you deploy the application on your ESP32 board and your Nextion display:\n\n[![Demo](https://github.com/aschuma/esp32_nextion_js_binary_clock/raw/master/BinaryClockGithub_V_0_2.gif)](https://www.youtube.com/watch?v=-_jJSQp22Mc)\n\n# Onboarding\n\n## Required hardware\n* [ESP32 Device](https://www.aliexpress.com/wholesale?catId=0\u0026initiative_id=AS_20190129143241\u0026SearchText=esp32+development+board)\n* [Nextion 2.8\" TFT 320x240 HMI](https://itead.cc/product/nx3224t028-nextion-2-8-basic-series-hmi-touch-display/)\n* Breadboard, wires, USB data cable ...\n\n## Get the software\n* For the mos tool, please follow the Mongoose OS [instructions](https://mongoose-os.com/docs/mongoose-os/quickstart/setup.md).\n* For the nextion editor (optional), check this [hint](https://nextion.tech/editor_guide/) (Windows only). \n\n## Clone the repository\n```git clone https://github.com/aschuma/esp32_nextion_js_binary_clock.git```\n\n## Prepare the Nextion display\nThis is an optional step. It might work without any preparation of the Nextion display. \nIf not, change to ```src/nextion``` directory and follow the instructions in the ```README.md``` file.\n\n## Wire the hardware\n```\nESP32 5V      \u003c-\u003e Nextion 5V  (do NOT use 3V, this might kill the Nextion display) \nESP32 GND     \u003c-\u003e Nextion GND\nESP32 GPIO16  \u003c-\u003e Nextion TX  (optional, might be required in case of further development)\nESP32 GPIO17  \u003c-\u003e Nextion RX \n```\n\n## Prepare the firmware\n```cd src/mos```\n\n### Prepare helper script for development\n* ```cp deploy.sh.template deploy.sh```\n* Open ```deploy.sh``` and alter the WiFi settings. \n\n### Check mos.yml\n* Alter WiFi settings (ESP32 only support 2.4Ghz networks)\n* Adjust the timezone ```sys.tz_spec```. Please consult Google to find the value for your local time zone.\n\n### Build\nThis could take some time. Be patient.\n```mos build --platform esp32 --local```\n\n## Flash the firmware\n* Power up the ESP32 device.\n* ```mos flash```\n* In case of problems, try to hold down the 'boot' button during the flashing process and/or explicitly set a port value, e.g. \n```mos flash esp32 --port /dev/tty.SLAB_USBtoUART```\n\n## Play with the sources :-)\n* ```init.js``` is the starting point.\n* Redeploy the altered sources by executing the ```deploy.sh``` script.\n* In case of problems, start the mos ui by calling ```mos ui``` and observe the log.\n\n# Finally\n\nBe aware that my primary coding language is not javascript and I'm not an ESP32 or Mongoose OS expert at all.  I'm still learning ESP32 development.\n\nPlease feel free to issue a bug report or submit a PR. Any helping hand is welcome.\n\n\n# Useful links:\n- [Espressif ESP32](https://www.espressif.com/en/products/hardware/esp32/overview)\n- [Nextion 2.8\" TFT 320x240 HMI](https://itead.cc/product/nx3224t028-nextion-2-8-basic-series-hmi-touch-display/)\n- [Mongoose OS](https://mongoose-os.com/mos.html)\n- [Mongoose OS quick start guide](https://mongoose-os.com/docs/mongoose-os/quickstart/setup.md)\n- [mJS - Embedded JavaScript engine for C/C++](https://github.com/cesanta/mjs)\n- https://wiki.iteadstudio.com/index.php?title=Nextion_Instruction_Set\u0026oldid\n- https://nextion.tech/editor_guide/\n- [pynextion - A Python library for Nextion smart display management. A little bit out of scope but helpful to see how to control Nextion via UART](https://github.com/aschuma/pynextion)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faschuma%2Fesp32_nextion_js_binary_clock","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faschuma%2Fesp32_nextion_js_binary_clock","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faschuma%2Fesp32_nextion_js_binary_clock/lists"}