T-Clock Desktop Clock
Preparation
- NodeMCU: Based on ESP8266
- OLED: 128x64 resolution, I2C interface (for SPI, please refer to the reference link)
Wiring
OLED | NodeMCU |
---|---|
GND | GND |
VCC | 3.3V |
SCL | D1 |
SDA | D2 |
Example
API Configuration
- Register an account on Seniverse
- Add a new product in the console (choose the free version)
- Copy the API key
Library Files
Final Example
Note: You need to change the WiFi name and password, city, and API key to your own.
If you encounter an error during compilation and the error message points to #error("Height incorrect, please fix Adafruit_SSD1306.h!");
, you need to open the library file Adafruit_SSD1306.h
and change #define SSD1306_128_32
to #define SSD1306_128_64
.
Note: Custom hardware projects are on the way~
References and Acknowledgements
- T-Clock Desktop Clock (Old)
- Seniverse
- ESP8266 Access to Seniverse API [Program + Detailed Explanation]
- ESP8266 + OLED = Network Clock and 3-day Weather Forecast
- My_ESP8266/Seniverse
- OLED Graphic Display Interfacing with NodeMCU
- adafruit/Adafruit_SSD1306
Original: https://wiki-power.com/
This post is protected by CC BY-NC-SA 4.0 agreement, should be reproduced with attribution.This post is translated using ChatGPT, please feedback if any omissions.