{"id":29296945,"url":"https://github.com/peff74/esp32-c3_oled","last_synced_at":"2025-10-20T07:19:28.445Z","repository":{"id":301613041,"uuid":"928935142","full_name":"peff74/ESP32-C3_OLED","owner":"peff74","description":"litte Arduino code for ESP32-C3 SuperMini Board with 0.42 Inch OLED Display","archived":false,"fork":false,"pushed_at":"2025-10-14T23:13:04.000Z","size":2485,"stargazers_count":25,"open_issues_count":1,"forks_count":5,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-10-15T03:44:04.805Z","etag":null,"topics":["arduino","arduino-sketch","esp32","esp32-c3","esp32-c3-super-mini","oled","ssd1306"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/peff74.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-02-07T14:06:53.000Z","updated_at":"2025-10-12T06:41:17.000Z","dependencies_parsed_at":null,"dependency_job_id":"873e09c4-ba49-4b57-8412-2eac0a58fe33","html_url":"https://github.com/peff74/ESP32-C3_OLED","commit_stats":null,"previous_names":["peff74/esp32-c3_oled"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/peff74/ESP32-C3_OLED","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/peff74%2FESP32-C3_OLED","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/peff74%2FESP32-C3_OLED/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/peff74%2FESP32-C3_OLED/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/peff74%2FESP32-C3_OLED/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/peff74","download_url":"https://codeload.github.com/peff74/ESP32-C3_OLED/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/peff74%2FESP32-C3_OLED/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":280039909,"owners_count":26262113,"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","status":"online","status_checked_at":"2025-10-20T02:00:06.978Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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","arduino-sketch","esp32","esp32-c3","esp32-c3-super-mini","oled","ssd1306"],"created_at":"2025-07-06T16:07:56.687Z","updated_at":"2025-10-20T07:19:28.431Z","avatar_url":"https://github.com/peff74.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ESP32-C3_OLED\n![AHT20_BMP280 logo](https://github.com/peff74/ESP32-C3_OLED/blob/main/ESP32-C3_oled.jpg)\n\n\n- The ESP32-C3 OLED is a very practical and cheap ESP32-C3 Supermini with 0.42 Inch OLED Display.\n- It is sold on all known platforms.\n- Most dealers provide no technical data, which sometimes makes it difficult to get it up and running...\n- The OLED display requires a workaround to function correctly because there is no dedicated 72x40 constructor in the U8g2 library.\n\n\n\n## Technical specs\n- SDA is D6\n- SCL is D5\n- Resolution is 72x40\n\n## Code using U8g2\n\n```\n#include \u003cU8g2lib.h\u003e\n#define OLED_RESET U8X8_PIN_NONE  // Reset pin\n#define OLED_SDA 5\n#define OLED_SCL 6\n\n\nU8G2_SSD1306_128X64_NONAME_F_HW_I2C u8g2(U8G2_R0, OLED_RESET, OLED_SCL, OLED_SDA);\nint width = 72;\nint height = 40;\nint xOffset = 30;  // = (132-w)/2\nint yOffset = 12;  // = (64-h)/2\n\n\nint c = 0;\n\nvoid handle_oled(int c) {\n  u8g2.clearBuffer();\n  u8g2.setFont(u8g2_font_4x6_tr);\n  u8g2.drawStr(xOffset + 0, yOffset + 10, \"Display is working!\");\n  u8g2.drawStr(xOffset + 0, yOffset + 20, \"Have fun with it\");\n  char buffer[20];\n  snprintf(buffer, sizeof(buffer), \"Uptime: %ds\", c);\n  u8g2.drawStr(xOffset + 0, yOffset + 30, buffer);\n  u8g2.sendBuffer();\n}\n\n\nvoid setup(void) {\n  u8g2.begin();\n  u8g2.setContrast(255);     // set contrast to maximum\n  u8g2.setBusClock(400000);  //400kHz I2C\n}\n\nvoid loop(void) {\n  handle_oled(c);\n  c++;\n  delay(1000);\n}\n```\n![Badge](https://hitscounter.dev/api/hit?url=https%3A%2F%2Fgithub.com%2Fpeff74%2FESP32-C3_OLED\u0026label=Hits\u0026icon=github\u0026color=%23198754\u0026message=\u0026style=flat\u0026tz=UTC)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpeff74%2Fesp32-c3_oled","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpeff74%2Fesp32-c3_oled","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpeff74%2Fesp32-c3_oled/lists"}