
如果家里已部署Home Assistant,早上想看室温和湿度得摸手机解锁打开App等待加载。智能家居的终极目标是让信息主动无感融入生活,于是常显、低功耗、信息集中的物理仪表盘成为自然需求。电子墨水屏几乎是这个需求的完美答案:只在刷新时耗电,显示静态内容时几乎零功耗,可放床头、贴冰箱或挂玄关7x24小时显示关键信息,且本身不发光、光线越强越清晰。项目目标是用十分钟、最低成本搭建Home Assistant墨水屏仪表盘,用Seeed Studio的reTerminal或reComputer作主控,配合ePaper屏,通过ESPHome桥接数据。
主控选reTerminal/reComputer的理由:它本身是带5英寸触摸屏的完整设备,提供40针GPIO可连接ePaper,核心是树莓派CM4模块,有完整Linux和强大算力;通过Type-C供电通信,GPIO电压3.3V与大多数ePaper兼容无需电平转换;作为树莓派生态一员有庞大社区支持,ESPHome在Linux上部署成熟。没有reTerminal用reComputer或树莓派4B/3B搭配40Pin扩展板也完全可行。
ePaper核心是电泳技术,屏幕由微胶囊构成,胶囊内带负电黑色粒子和带正电白色粒子悬浮透明液体,施加电场时粒子被吸引到顶部形成黑白显示。两个关键特性:双稳态,粒子移动后撤掉电场仍保持原位,所以静态显示不耗电;刷新慢,粒子物理移动需几百毫秒到几秒,不适合视频动画但适合几分钟更新一次的仪表盘。常用7.5英寸800x480或4.2英寸400x300,通过SPI与主控通信。
软件桥梁ESPHome的角色:它并不直接运行在reTerminal上,而是运行在家庭网络另一台设备(通常是Home Assistant服务器或常开电脑)上,充当虚拟设备或桥接器。在ESPHome定义虚拟显示屏设备,通过Home Assistant API订阅关心的实体状态;状态变化时HA主动通知ESPHome设备;ESPHome把数据通过自定义文本协议输出到串口;reTerminal用USB转TTL或GPIO UART读取串口数据,用轻量Python脚本解析并调用ePaper驱动库更新屏幕。好处是解耦,reTerminal只需读串口和画屏幕,复杂交互由ESPHome后台完成。
搭建步骤:硬件连接把7.5寸屏SPI引脚接reTerminal GPIO,VCC务必接3.3V接5V会烧屏;在reTerminal启用SPI并安装Waveshare的e-Paper Python库和pyserial;在HA服务器新建epaper_bridge配置,用homeassistant传感器和uart组件绑定温度湿度灯光实体并设置on_value触发uart.write输出TEMP,22.5这类格式;用socat创建虚拟串口或USB转TTL建立通信链路;编写epaper_dashboard.py用waveshare_epd驱动画图并监听串口。优化方向包括用PIL设计背景图布局更多数据、增加CRC8校验和心跳重连、创建systemd服务自启动、定期全刷防残影。排查方向:全白全黑先查3.3V供电和SPI启用,收不到数据查串口和实体状态,残影用全局刷新,乱码安装DejaVu字体。
本文来源:https://www.sheratonhq.com/news/68860
若有版权问题,请来信告知:13951431913#139.com 或在右方提交评论。
If Home Assistant is already deployed at home, checking the indoor temperature and humidity in the morning means reaching for the phone, unlocking it, opening the app and waiting for it to load. The ultimate goal of smart home is to let information blend into life proactively and unobtrusively, so an always-on, low-power, information-dense physical dashboard becomes a natural need. E-paper is almost the perfect answer to this need: it consumes power only when refreshing, uses almost zero power when displaying static content, can sit on a bedside table, stick to the fridge or hang in the entryway showing key information 7x24 hours a day, and since it emits no light of its own, it becomes clearer the stronger the ambient light. The project goal is to build a Home Assistant e-ink dashboard in ten minutes at minimal cost, using Seeed Studio's reTerminal or reComputer as the main controller together with an ePaper screen, with data bridged through ESPHome.
Reasons for choosing the reTerminal/reComputer as the main controller: it is itself a complete device with a 5-inch touchscreen, providing 40-pin GPIO to connect the ePaper; at its core is a Raspberry Pi CM4 module with full Linux and strong computing power; power and communication go over Type-C, and the 3.3V GPIO level is compatible with most ePaper screens without level shifting; as part of the Raspberry Pi ecosystem it has a large community, and ESPHome deployment on Linux is mature. Without a reTerminal, using a reComputer or a Raspberry Pi 4B/3B with a 40-pin expansion board works just as well.
The core of ePaper is electrophoretic technology: the screen is made of microcapsules containing negatively charged black particles and positively charged white particles suspended in a transparent fluid; when an electric field is applied, the particles are attracted to the top to form a black-and-white image. Two key characteristics: bistability — after the particles move and the field is removed they stay in place, so static display consumes no power; and slow refresh — the physical movement of particles takes hundreds of milliseconds to several seconds, making it unsuitable for video or animation but well suited to a dashboard updated every few minutes. Common choices are 7.5-inch 800x480 or 4.2-inch 400x300, communicating with the main controller over SPI.
The role of the software bridge ESPHome: it does not run directly on the reTerminal, but on another device on the home network (usually the Home Assistant server or an always-on PC), acting as a virtual device or bridge. You define a virtual display device in ESPHome and subscribe to the entity states you care about via the Home Assistant API; when a state changes, HA actively notifies the ESPHome device; ESPHome outputs the data to the serial port using a custom text protocol; the reTerminal reads the serial data via a USB-to-TTL adapter or GPIO UART, and a lightweight Python script parses it and calls the ePaper driver library to update the screen. The benefit is decoupling — the reTerminal only needs to read the serial port and draw the screen, while complex interaction is handled by ESPHome in the background.
Build steps: for hardware, connect the 7.5-inch screen's SPI pins to the reTerminal GPIO, and be sure to connect VCC to 3.3V — connecting 5V will burn the screen; enable SPI on the reTerminal and install Waveshare's e-Paper Python library and pyserial; on the HA server create an epaper_bridge configuration, use the homeassistant sensor and uart components to bind the temperature, humidity and light entities, and set on_value to trigger uart.write to output formats like TEMP,22.5; use socat to create a virtual serial port or a USB-to-TTL adapter to establish the communication link; write epaper_dashboard.py to draw with the waveshare_epd driver and listen on the serial port. Optimisation directions include using PIL to design a background image that lays out more data, adding CRC8 checksums and heartbeat reconnection, creating a systemd service for auto-start, and periodic full refreshes to prevent ghosting. Troubleshooting: for an all-white or all-black screen first check the 3.3V supply and SPI enablement; if no data arrives check the serial port and entity states; use a global refresh for ghosting; and install the DejaVu font for garbled characters.
本文来源:https://www.sheratonhq.com/news/68860
若有版权问题,请来信告知:13951431913#139.com 或在右方提交评论。