{"id":15018613,"url":"https://github.com/adafruit/adafruit_circuitpython_st7789","last_synced_at":"2025-04-04T13:10:55.832Z","repository":{"id":40559071,"uuid":"176979181","full_name":"adafruit/Adafruit_CircuitPython_ST7789","owner":"adafruit","description":"CircuitPython DisplayIO Driver for ST7789 Color TFT Controller","archived":false,"fork":false,"pushed_at":"2025-03-03T14:17:27.000Z","size":154,"stargazers_count":62,"open_issues_count":1,"forks_count":20,"subscribers_count":21,"default_branch":"main","last_synced_at":"2025-04-02T23:14:07.890Z","etag":null,"topics":["circuitpython","displayio","hacktoberfest","st7789","st7789-display-driver","tft-display"],"latest_commit_sha":null,"homepage":"https://circuitpython.org","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/adafruit.png","metadata":{"files":{"readme":"README.rst","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-03-21T15:58:42.000Z","updated_at":"2025-03-26T02:08:17.000Z","dependencies_parsed_at":"2023-02-12T12:02:04.092Z","dependency_job_id":"f42bef03-7422-4220-86d1-6a004e54bc3b","html_url":"https://github.com/adafruit/Adafruit_CircuitPython_ST7789","commit_stats":{"total_commits":106,"total_committers":22,"mean_commits":4.818181818181818,"dds":0.8207547169811321,"last_synced_commit":"e23c4871456cdf0ef1bfb59d1c2f6e38b7b640ee"},"previous_names":[],"tags_count":38,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adafruit%2FAdafruit_CircuitPython_ST7789","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adafruit%2FAdafruit_CircuitPython_ST7789/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adafruit%2FAdafruit_CircuitPython_ST7789/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adafruit%2FAdafruit_CircuitPython_ST7789/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/adafruit","download_url":"https://codeload.github.com/adafruit/Adafruit_CircuitPython_ST7789/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247182399,"owners_count":20897381,"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":["circuitpython","displayio","hacktoberfest","st7789","st7789-display-driver","tft-display"],"created_at":"2024-09-24T19:52:11.302Z","updated_at":"2025-04-04T13:10:55.802Z","avatar_url":"https://github.com/adafruit.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"Introduction\n============\n\n.. image:: https://readthedocs.org/projects/adafruit-circuitpython-st7789/badge/?version=latest\n    :target: https://docs.circuitpython.org/projects/st7789/en/latest/\n    :alt: Documentation Status\n\n.. image:: https://raw.githubusercontent.com/adafruit/Adafruit_CircuitPython_Bundle/main/badges/adafruit_discord.svg\n    :target: https://adafru.it/discord\n    :alt: Discord\n\n.. image:: https://github.com/adafruit/Adafruit_CircuitPython_ST7789/workflows/Build%20CI/badge.svg\n    :target: https://github.com/adafruit/Adafruit_CircuitPython_ST7789/actions/\n    :alt: Build Status\n\n.. image:: https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json\n    :target: https://github.com/astral-sh/ruff\n    :alt: Code Style: Ruff\n\ndisplayio driver for ST7789 TFT-LCD displays.\n\nDependencies\n=============\nThis driver depends on:\n\n* `Adafruit CircuitPython 4.0.0-beta.0+ \u003chttps://github.com/adafruit/circuitpython\u003e`_\n\nPlease ensure all dependencies are available on the CircuitPython filesystem.\nThis is easily achieved by downloading\n`the Adafruit library and driver bundle \u003chttps://github.com/adafruit/Adafruit_CircuitPython_Bundle\u003e`_.\n\nUsage Example\n=============\n\n.. code-block:: python\n\n    import board\n    import displayio\n    # Starting in CircuitPython 9.x fourwire will be a seperate internal library\n    # rather than a component of the displayio library\n    try:\n        from fourwire import FourWire\n    except ImportError:\n        from displayio import FourWire\n\n    from adafruit_st7789 import ST7789\n\n    displayio.release_displays()\n\n    spi = board.SPI()\n    while not spi.try_lock():\n        pass\n    spi.configure(baudrate=24000000) # Configure SPI for 24MHz\n    spi.unlock()\n    tft_cs = board.D5\n    tft_dc = board.D6\n\n    display_bus = FourWire(spi, command=tft_dc, chip_select=tft_cs, reset=board.D9)\n\n    display = ST7789(display_bus, width=240, height=240, rowstart=80)\n\n    # Make the display context\n    splash = displayio.Group()\n    display.root_group = splash\n\n    color_bitmap = displayio.Bitmap(240, 240, 1)\n    color_palette = displayio.Palette(1)\n    color_palette[0] = 0xFF0000\n\n    bg_sprite = displayio.TileGrid(color_bitmap,\n                                   pixel_shader=color_palette,\n                                   x=0, y=0)\n    splash.append(bg_sprite)\n\n    while True:\n        pass\n\nDocumentation\n=============\n\nAPI documentation for this library can be found on `Read the Docs \u003chttps://docs.circuitpython.org/projects/st7789/en/latest/\u003e`_.\n\nFor information on building library documentation, please check out `this guide \u003chttps://learn.adafruit.com/creating-and-sharing-a-circuitpython-library/sharing-our-docs-on-readthedocs#sphinx-5-1\u003e`_.\n\nContributing\n============\n\nContributions are welcome! Please read our `Code of Conduct\n\u003chttps://github.com/adafruit/Adafruit_CircuitPython_ST7789/blob/main/CODE_OF_CONDUCT.md\u003e`_\nbefore contributing to help this project stay welcoming.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadafruit%2Fadafruit_circuitpython_st7789","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fadafruit%2Fadafruit_circuitpython_st7789","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadafruit%2Fadafruit_circuitpython_st7789/lists"}