{"id":13802165,"url":"https://github.com/brainelectronics/micropython-nextion","last_synced_at":"2025-05-07T14:47:18.407Z","repository":{"id":47799654,"uuid":"516286213","full_name":"brainelectronics/micropython-nextion","owner":"brainelectronics","description":"Control Nextion displays using MicroPython","archived":false,"fork":false,"pushed_at":"2023-06-12T20:08:13.000Z","size":308,"stargazers_count":13,"open_issues_count":5,"forks_count":5,"subscribers_count":3,"default_branch":"develop","last_synced_at":"2025-04-20T21:03:55.791Z","etag":null,"topics":["display","hmi","hmi-tft","library","micropython","micropython-lib","nextion","nextion-communication","nextion-display","serial","uart"],"latest_commit_sha":null,"homepage":"","language":"Python","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/brainelectronics.png","metadata":{"files":{"readme":"README.md","changelog":"changelog.md","contributing":"docs/CONTRIBUTING.md","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}},"created_at":"2022-07-21T08:23:44.000Z","updated_at":"2024-10-05T19:47:38.000Z","dependencies_parsed_at":"2024-01-29T19:40:39.562Z","dependency_job_id":null,"html_url":"https://github.com/brainelectronics/micropython-nextion","commit_stats":{"total_commits":184,"total_committers":2,"mean_commits":92.0,"dds":0.005434782608695676,"last_synced_commit":"f46aa184efec1350028c17d7ca70b5c8712c7877"},"previous_names":[],"tags_count":30,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brainelectronics%2Fmicropython-nextion","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brainelectronics%2Fmicropython-nextion/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brainelectronics%2Fmicropython-nextion/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brainelectronics%2Fmicropython-nextion/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/brainelectronics","download_url":"https://codeload.github.com/brainelectronics/micropython-nextion/tar.gz/refs/heads/develop","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252898803,"owners_count":21821690,"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":["display","hmi","hmi-tft","library","micropython","micropython-lib","nextion","nextion-communication","nextion-display","serial","uart"],"created_at":"2024-08-04T00:01:37.909Z","updated_at":"2025-05-07T14:47:18.365Z","avatar_url":"https://github.com/brainelectronics.png","language":"Python","readme":"# MicroPython Nextion library\n\n[![Downloads](https://pepy.tech/badge/micropython-nextion)](https://pepy.tech/project/micropython-nextion)\n![Release](https://img.shields.io/github/v/release/brainelectronics/micropython-nextion?include_prereleases\u0026color=success)\n![MicroPython](https://img.shields.io/badge/micropython-Ok-green.svg)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n\nMicroPython Nextion library\n\n---------------\n\n## General\n\nPorted library to interact with [Nextion serial displays][ref-nextion-wiki],\nbased on the [ITEAD Arduino Nextion][ref-itead-nextion-github] library.\n\n## Installation\n\n### Install required tools\n\nPython3 must be installed on your system. Check the current Python version\nwith the following command\n\n```bash\npython --version\npython3 --version\n```\n\nDepending on which command `Python 3.x.y` (with x.y as some numbers) is\nreturned, use that command to proceed.\n\n```bash\npython3 -m venv .venv\nsource .venv/bin/activate\n\npip install -r requirements.txt\n```\n\n## Setup\n\n### Install package\n\nConnect the MicroPython device to a network (if possible)\n\n```python\nimport network\nstation = network.WLAN(network.STA_IF)\nstation.active(True)\nstation.connect('SSID', 'PASSWORD')\nstation.isconnected()\n```\n\n#### General\n\nInstall the latest package version of this lib on the MicroPython device\n\n```python\nimport mip\nmip.install(\"github:brainelectronics/micropython-nextion\")\n```\n\nFor MicroPython versions below 1.19.1 use the `upip` package instead of `mip`\n\n```python\nimport upip\nupip.install('micropython-nextion')\n```\n\n#### Specific version\n\nInstall a specific, fixed package version of this lib on the MicroPython device\n\n```python\nimport mip\n# install a verions of a specific branch\nmip.install(\"github:brainelectronics/micropython-nextion\", version=\"feature/add-mip-package-file\")\n# install a tag version\nmip.install(\"github:brainelectronics/micropython-nextion\", version=\"0.15.0\")\n```\n\nFor MicroPython versions below 1.19.1 use the `upip` package instead of `mip`\n\n```python\nimport upip\nupip.install('micropython-nextion')\n```\n\n#### Test version\n\nInstall a specific release candidate version uploaded to\n[Test Python Package Index](https://test.pypi.org/) on every PR on the\nMicroPython device. If no specific version is set, the latest stable version\nwill be used.\n\n```python\nimport mip\nmip.install(\"github:brainelectronics/micropython-nextion\", version=\"0.15.0-rc1.dev29\")\n```\n\nFor MicroPython versions below 1.19.1 use the `upip` package instead of `mip`\n\n```python\nimport upip\n# overwrite index_urls to only take artifacts from test.pypi.org\nupip.index_urls = ['https://test.pypi.org/pypi']\nupip.install('micropython-nextion')\n```\n\nSee also [brainelectronics Test PyPi Server in Docker][ref-brainelectronics-test-pypiserver]\nfor a test PyPi server running on Docker.\n\n### Manually\n\n#### Upload files to board\n\nCopy the module to the MicroPython board and import them as shown below\nusing [Remote MicroPython shell][ref-remote-upy-shell]\n\nOpen the remote shell with the following command. Additionally use `-b 115200`\nin case no CP210x is used but a CH34x.\n\n```bash\nrshell --port /dev/tty.SLAB_USBtoUART --editor nano\n```\n\nPerform the following command inside the `rshell` to copy all files and\nfolders to the device\n\n```bash\nmkdir /pyboard/lib\nmkdir /pyboard/lib/nextion\n\ncp nextion/* /pyboard/lib/nextion\n\ncp examples/basic/main.py /pyboard\ncp examples/boot.py /pyboard\n```\n\n## Usage\n\nUse one of the [examples](examples/) to get started. Read also the\n[examples README](examples/README.md) to find all supported elements\n\n## Credits\n\nBig thank you to [ITEAD Studio][ref-itead-github] for the implementation\nof the Arduino library.\n\n\u003c!-- Links --\u003e\n[ref-nextion-wiki]: https://wiki.iteadstudio.com/Nextion_HMI_Solution\n[ref-itead-nextion-github]: https://github.com/itead/ITEADLIB_Arduino_Nextion\n[ref-remote-upy-shell]: https://github.com/dhylands/rshell\n[ref-brainelectronics-test-pypiserver]: https://github.com/brainelectronics/test-pypiserver\n[ref-github-be-mircopython-modules]: https://github.com/brainelectronics/micropython-modules\n[ref-itead-github]: https://github.com/itead\n","funding_links":[],"categories":["Libraries"],"sub_categories":["Display"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrainelectronics%2Fmicropython-nextion","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbrainelectronics%2Fmicropython-nextion","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrainelectronics%2Fmicropython-nextion/lists"}