
1. 项目概述:构建你的专属低功耗信息中心
几年前,我第一次接触到电子墨水屏,就被它那种“类纸”的表明成效深深吸引。它不发光,只反射环境光,看久了眼睛也不会累,而且一旦画面刷新完成,即使断电,内容也能一直保留。这种特性让它天生就合适做一个“常显”的信息看板——例如挂在墙上的日历、摆在桌面的天气预报,或者玄关处的家庭日程提醒。但当时的彩色电子墨水屏要么售价高昂,要么驱动复杂,让很多爱好者望而却步。
直到最近,随着 Waveshare 这类厂商推出了更多亲民的机型,以及像 InkyPi 这样出色的开源软件浮现,自己动手构建一个能力多元、颜值在线的彩色电子墨水屏仪表盘,终于变成了一件触手可及的事情。这个项目的核心,就是利用树莓派 Zero 2 W 这块小巧但表现足够的“大脑”,驱动一块 7.3 英寸的彩色电子墨水屏,借助 InkyPi 软件框架,灵活地轮播展示天气、日历、照片、新闻等各类信息。它不像普通显示屏那样刺眼、耗电,更像是一幅会自动更新的“数字画作”,安静地融入你的家居或办公环境。
无论你是想学习树莓派和 Python 的软硬件结合,还是单纯想具备一个独一无二的个性化信息终端,这个项目都能带给你从硬件组装、平台规格到软件定制的完整感受。整个过程不需要高深的编程知识,跟着步骤走,你就能收获一个既实用又有成就感的作品。
2. 硬件选型与组装:从零搭建的物理基础
2.1 核心硬件解析与选购要点
这个项目的硬件清单格外精简,但每一件都至关关键。理解它们的作用,能协助你在采购和组装时少走弯路。
树莓派 Zero 2 W:项目的“心脏”我挑选树莓派 Zero 2 W 而非其他型号,主要基于几个考量。首先,功耗与表现的平衡:Zero 2 W 使用了与树莓派 3B+ 同代的四核 Cortex-A53 处理器,表现足以流畅运行轻量级的 Linux 平台和 InkyPi 这样的 Python 应用,同时其 idle 状态功耗仅约 0.5W,格外合适需要 7x24 小时运行的常显设备。其次,尺寸与接口:其超小的体积(65mm x 30mm)使得它能从容隐藏在相框背后;自带的 WiFi 和蓝牙模块,免去了额外配件的麻烦,是达成网络数据获取(如天气、新闻)的关键。最后是成本:在保证基础表现的前提下,它是当下性价比最高的树莓派型号之一。
注意:务必确认你购买的是“Zero 2 W”而非早期的“Zero W”。两者的外观几乎一样,但 Zero 2 W 的 CPU 表现有数倍提高,对于需要定时渲染复杂界面(尤其是彩色图片)的应用来说,感受差异巨大。
Waveshare 7.3英寸彩色电子墨水屏及驱动HAT:项目的“面孔”这是整个项目的视觉核心。我挑选 7.3 英寸、800x480 分辨率的型号,是因为这个尺寸在信息密度和观看距离上取得了很好的平衡——足够表明日历、多日天气预报等复杂信息,又不会显得笨重。彩色电子墨水屏(E-Ink)的原理是利用带颜色的带电粒子在电场作用下移动,形成静态图像。其最大长处就是超低功耗:只在刷新画面时耗电,静态表明时为零。这意味着你可以用一个普通的手机充电宝让它工作好几天。
驱动 HAT(Hardware Attached on Top)是连接显示屏和树莓派的桥梁。它集成了专门的驱动芯片和电平转换电路,负责将树莓派 GPIO 发出的数字信号,转换成能精确控制显示屏上数百万个微胶囊电压的复杂波形。购买时,显示屏和配套的 HAT 通常作为套装出售,务必确认型号完全匹配。
其他配件:细节决定成败
- USB 数据线与电源:建议使用一条短而结实的 Micro USB 数据线(如 0.5米)。过长的线缆会增加电压损耗,可能导致树莓派在显示屏刷新峰值电流时供电不稳而重启。电源适配器建议 5V/2.5A 以上,确保稳定。
- 紧固件:M3x6mm 螺丝用于固定显示屏背板和框架,M2.5x16mm 螺丝用于将树莓派固定在 HAT 的立柱上。使用尺寸精确的螺丝可以避免滑丝或损坏脆弱的 PCB 板。
- 外壳框架:这是赋予项目个性的部分。你可以挑选宜家 13x18cm 的相框(型号 RODALM),追求原木质感;也可以使用作者给出的 3D 模型文件开展打印,构建卡通电视、复古鼠标等创意造型。3D 打印建议使用 PLA 材料,层高 0.2mm,填充率 20-25% 即可保证强度。
2.2 分步组装实操指南
组装过程就像拼装一个精密的模型,顺序很关键。我的经验是:先处理显示屏模块,再安装树莓派,最后开展总装。
第一步:准备显示屏模块与框架
- 显示屏保护膜:新显示屏正面有一层透明的保护膜,用于运输防刮。在安装前,务必将其轻轻撕下,这是影响最终表明清晰度的关键一步。
- 安装显示屏到框架:如果你使用宜家相框,需要先打印并准备好“Ikea Frame Front.stl”这个前挡板。将显示屏正面朝下,小心地放入框架或 3D 打印的前壳中。此时要特别留意显示屏排线(一根扁平的灰色带状电缆)的走向,确保它能从框架底部预留的缺口顺畅穿出,避免弯折过度(建议弯曲半径大于 5mm)。
- 固定显示屏背板:将打印好的“Display Back.stl”背板盖在显示屏背面,使用 4 颗 M3x6mm 螺丝,从背板外侧的四个角孔位拧入,将显示屏牢牢夹在框架和前挡板之间。拧螺丝时使用“对角线顺序”,逐步上紧,确保受力均匀,显示屏不会翘曲。
第二步:连接排线与驱动板
- 安装排线插座板:将那个带有黑色锁扣的小板(排线插座板)放在背板中央的凸起位置上,用另外 4 颗 M3x6mm 螺丝固定。这个板子是用来连接显示屏排线和 HAT 的转接板。
- 连接显示屏排线:这是最需要耐心的一步。用指甲或塑料撬棒,轻轻向上抬起排线插座上的黑色锁扣(不是拔出,是让它从水平变成竖直状态)。然后将显示屏排线金色触点朝上,对准插座,平稳地插入到底。你会感觉到一个轻微的“咔哒”感。最后,将黑色锁扣用力按回水平位置,听到清脆的锁定声。这个操作如果没做好,会导致显示屏无表明或表明异常。
- 安装树莓派与 HAT:将驱动 HAT 对准树莓派 Zero 2 W 的 40Pin GPIO 排针,垂直向下均匀用力按压,确保所有针脚都对齐并插到底。然后,在 HAT 和树莓派之间安装 4 个 3D 打印的立柱(“Waveshare HAT Stand Offs.stl”),最后用 4 颗 M2.5x16mm 的螺丝从树莓派背面拧入立柱,将两者固定在一起。立柱的作用是防止 HAT 因受力不均而弯曲,损坏 GPIO 针脚。
第三步:最终连线与理线
- 连接 HAT 排线:将 HAT 上引出的另一根排线,以同样方式(金色触点朝上)插入到刚才固定在背板上的排线插座板。这样,信号通路就完整了:树莓派 -> HAT -> 排线 -> 显示屏。
- 连接电源与理线:将 Micro USB 线连接到树莓派 Zero 2 W 上靠外侧的那个 USB 口(这是电源口,靠内侧的是 OTG 数据口)。使用打印好的线缆固定夹(“Cable Harness‘s.stl”),将显示屏排线和 USB 电源线在框架内整理并固定好,避免它们松动后拉扯接口。
- 总装与测试前检查:如果使用宜家相框,此时可以将整个组装好的模块塞入相框,移除或保留原有的亚克力板(移除后反光更少,更像纸张)。最后,给整个平台通电前,做一次快速检查:所有排线是否插紧锁好?螺丝有无过长顶到电路?USB 线连接是否牢固?
3. 软件平台部署:让硬件“活”起来
硬件组装完毕,它只是一具精致的躯壳。接下来,笔者要为它注入灵魂——操作平台和应用软件。
3.1 为树莓派安装与规格操作平台
树莓派没有内置存储,所有平台都运行在 Micro SD 卡上。因而,笔者的第一步是制作一张平台启动卡。
使用 Raspberry Pi Imager 刷写平台这是官方建议的也是最省心的工具。从树莓派官网下载并安装后,操作流程如下:
- 挑选设备:在“Choose Device”中,明确挑选“Raspberry Pi Zero 2 W”。虽然也可以刷写通用平台,但针对性挑选能让 Imager 应用一些针对该型号的优化设置。
- 挑选操作平台:点击“Choose OS”,挑选“Raspberry Pi OS (other)”,然后挑选“Raspberry Pi OS Lite (64-bit)”。我强烈建议Lite(无桌面环境)版本,因为它更轻量,启动更快,占用资源更少,对于这种专一用途的设备再合适不过。版本号当下可能是“Trixie”。
- 关键:自定义高级设置:在点击“Write”之前,务必按下
Ctrl+Shift+X打开“高级选项”菜单。这里需要规格几个关键项:- 设置主机名:例如
inkypi。这将是你的设备在网络中的名字,方便后续查找。 - 启用 SSH:勾选“Enable SSH”,并挑选“Use password authentication”。这是笔者后续无头(无表明器)操作树莓派的唯一通道。
- 规格 WiFi:填写你的家庭 WiFi 名称(SSID)和密码。确保国家/地区设置正确。
- 设置使用者名和密码:设置一个非默认的使用者(如
pi)和强密码。安全无小事。 - 规格区域设置:设置正确的时区(如
Asia/Shanghai),这对后续表明准确时间至关关键。
- 设置主机名:例如
- 写入与验证:插入 SD 卡,挑选它,点击“Write”。完成后,工具会开展验证。一定要等待验证完成,这能确保平台镜像完整无误地写入,避免首次启动失败。
首次启动与网络连接将刷写好的 SD 卡插入树莓派,接通 USB 电源。树莓派上的红色电源灯常亮,绿色活动灯不规则闪烁,表明平台正在启动。首次启动会开展文件平台扩展等初始化操作,需要1-3分钟。
如何知道它启动好了?笔者需要找到它的 IP 地址。有以下几种方法:
- 路由器后台查看:登录你家路由器的管理页面(通常是 192.168.1.1),在“已连接设备”或“DHCP 客户端列表”中,查找你设置的主机名(如
inkypi)。 - 使用网络扫描工具:在电脑上使用
Advanced IP Scanner、Angry IP Scanner或命令行工具arp -a(在同一个局域网内)来扫描。 - (备用)mDNS 访问:如果你的网络兼容 mDNS,可以直接在浏览器或 SSH 客户端里用
inkypi.local来访问(Windows 可能需要安装 Bonjour 服务)。
记下获取到的 IP 地址,例如192.168.1.100。
3.2 借助 SSH 远程连接与基础规格
找到 IP 后,笔者就可以远程登录了。Windows 使用者建议使用Termius或PuTTY,macOS 和 Linux 使用者可以直接使用终端。
以 Termius 为例:
- 新建一个主机(Host),地址栏填入树莓派的 IP 地址。
- 端口保持 22(SSH 默认端口)。
- 使用者名和密码填写你在 Imager 中设置的那些。
- 点击连接。首次连接会有一个安全警告,确认即可。
连接成功后,你会看到一个命令行提示符,例如pi@inkypi:~ $。恭喜,你现在已经站在了树莓派的“内部”。
连接后建议立即做的几件事:
- 更新平台:虽然不必须,但建议先更新软件包列表并升级现有软件,确保平台稳定。
(这个过程可能需要几分钟,取决于网络速度。)sudo apt update sudo apt upgrade -y - 检查网络与时间:输入
date命令,查看时间是否正确。如果不正确,可以运行sudo raspi-config,进入“Localisation Options”重新设置时区。
3.3 安装与规格 InkyPi 核心软件
InkyPi 是一个专为树莓派驱动 Waveshare 电子墨水屏而外观的开源仪表盘软件,用 Python 编写,给出了 Web 界面开展规格,格外友好。
克隆与安装
- 克隆代码库:在 SSH 终端中,执行以下命令,将 InkyPi 的代码从 GitHub 下载到树莓派上。
git clone https://github.com/fatihak/InkyPi.git - 进入目录并运行安装脚本:
这里的cd InkyPi sudo bash install/install.sh -W epd7in3eepd7in3e参数至关关键,它指定了显示屏型号(7.3英寸彩色)。如果你用的是其他尺寸的 Waveshare 显示屏,需要依据 InkyPi 官方文档修改此参数。
安装脚本会自动完成一系列繁重的工作:安装 Python 依赖库、规格平台服务、设置开机自启等。整个过程大约需要 5-10 分钟,期间显示屏可能会闪烁几次,这是正常的驱动测试。安装成功的标志是:显示屏最终刷新,表明出一个包含 InkyPi 的 Web 界面访问地址(IP 和端口)的界面。
实操心得:安装过程如果卡住或报错,最常见的原因是网络难题(下载 Python 包失败)。可以尝试按
Ctrl+C中断,然后重新运行安装命令。也可以先运行sudo apt install python3-pip确保 pip 工具正常。安装脚本运行完毕后,建议重启一次树莓派,让所有服务就绪:sudo reboot。
4. InkyPi 仪表盘深度定制与使用
安装完成并重启后,你的电子墨水屏应该已经表明出了 InkyPi 的默认界面,上面有 IP 地址。现在,笔者可以在同一局域网内的任何电脑或手机的浏览器中,输入这个 IP 地址(如http://192.168.1.100)来访问仪表盘的控制后台。
4.1 Web 控制台详解与核心设置
InkyPi 的 Web 界面格外直观。顶部中央是显示屏的实时预览缩略图。左侧是插件列表,右侧是选中插件的规格区域。
首要规格:平台设置点击右上角的齿轮图标(设置),进入核心规格页面。这里有几个关键设置:
- 时区(Time Zone):确保这里挑选的是
Asia/Shanghai(或你所在时区),这关系到时钟、日历等所有与时间相关插件的准确性。 - 刷新间隔(Update Interval):这是全局刷新频率。电子墨水屏有刷新寿命(通常几十万次),且全屏刷新会有短暂黑闪。不建议设置得过短。对于天气、新闻这类信息,设置 30 分钟到 1 小时刷新一次完全足够。时钟可以单独设置更快的刷新频率(如每分钟)。我通常设置为 1800 秒(30分钟)。
- 表明增强:
- 饱和度(Saturation):适当调高(如 1.2)可以让彩色更鲜艳,但过高会失真。
- 锐度(Sharpness):轻微调高(如 1.1)可以让文字和图标边缘更清晰。
- 亮度(Brightness):依据环境光调整,通常微调即可。
- 显示屏旋转(Rotation):如果你的显示屏是竖着放的,可以在这里设置 90 或 270 度旋转。
插件工作机制解析InkyPi 的核心能力借助插件(Plugin)达成。每个插件都是一个独立的 Python 脚本,负责从特定数据源(网络 API、本地文件、平台命令)获取数据,并渲染成一幅合适墨水屏表明的图像。Web 界面借助调用这些插件,并将生成的图像发送给显示屏驱动来更新表明。你可以规格一个插件列表,InkyPi 会按顺序轮播它们。
4.2 核心插件规格实战
让笔者深入规格几个最常用的插件,理解其背后的数据流和规格逻辑。
1. 时钟插件(Clock)这是最简单的插件,但却是仪表盘的灵魂。规格项涵盖:
- 样式(Style):挑选模拟钟、数字钟或简约文字。模拟钟更有装饰性,数字钟信息更直接。
- 颜色(Color):挑选指针和数字的颜色。电子墨水屏的彩色是有限的(通常是红、黄、蓝、白、黑),挑选比较度高的组合。
- 表明日期:勾选后会在时钟下方表明日期和星期。
- 更新频率:可以设置为每分钟(
*/1 * * * *)或每 5 分钟更新一次时间。由于只是重绘时间,局部刷新很快,对显示屏损耗极小。
2. 天气插件(Weather)这是最实用的插件之一,它通常从 OpenWeatherMap 等免费 API 获取数据。
- 获取 API Key:你需要去 OpenWeatherMap 官网注册一个免费账户,生成一个 API Key。免费套餐的调用频率对于个人使用绰绰有余。
- 位置设置:可以输入城市名(如
Beijing)或经纬度。使用城市名更简单,但确保拼写准确。 - 单位制:挑选摄氏度(°C)和华氏度(°F)。
- 表明内容:规格表明当前温度、体感温度、最高/最低温、湿度、风速、将来几小时或几天的预报图标等。建议不要堆砌太多信息,保持界面清爽。
- 工作原理:插件会定时(如每30分钟)向天气 API 发送一次 HTTP 请求,解析返回的 JSON 数据,然后依据模板生成包含图标和文字的天气信息图。
3. 图片上传插件(Image Upload)这个插件允许你上传本地图片并表明在显示屏上,格外合适展示家庭照片或艺术作品。
- 上传与处理:在插件界面点击上传,挑选图片。InkyPi 会上传图片到树莓派,并利用Floyd-Steinberg 抖动算法开展处理。
- 算法解析:为什么用这个1976年的老算法?因为电子墨水屏每个像素只能表明有限的几种颜色(如7色),无法展现真彩色的渐变。抖动算法借助将相邻像素的颜色误差扩散,用有限的颜色模拟出更多色彩层次,从而让彩色图片在墨水屏上看起来不那么“色块化”,更接近原图成效。你可以调整抖动强度来平衡细节和色彩成效。
- 表明模式:可以设置为单次表明,或加入轮播序列。
4. 日历插件(Calendar)通常兼容 iCal 格式的日历订阅,例如 Google Calendar。
- 获取日历地址:在 Google 日历的设置中,找到对应日历的“秘密地址”(iCal 格式)。这是一个以
.ics结尾的链接。 - 规格 URL:将链接填入插件规格。插件会定期抓取这个
.ics文件,解析其中的事件(标题、时间、地点)。 - 表明设置:可以设置表明将来多少天内的事件(如 7 天),以及每屏表明的事件条数。事件会以列表形式清晰展示。
5. 新闻插件(RSS)借助订阅 RSS 源来表明新闻摘要。
- 寻找 RSS 源:许多新闻网站、博客都给出 RSS 地址。例如,某个科技媒体的 RSS 链接。
- 规格与表明:将 RSS 源地址填入插件,设置更新频率(如每小时)、表明标题数量、是否表明摘要等。它会抓取最新的条目滚动表明。
4.3 创建与管理表明轮播序列
单一插件表明久了会单调。InkyPi 允许你创建一个播放列表(Playlist)。
- 在 Web 界面,你可以将规格好的插件拖拽到一个序列中。
- 为序列中的每个插件设置表明时长,例如:时钟表明 1 分钟,然后切换到天气表明 30 秒,再切换到日历表明 1 分钟,最后表明家庭照片 2 分钟,如此循环。
- 你甚至可以创建多个序列,并设置在不同时间段激活。例如,在规格文件中可以设置:
- 早晨 7-9 点:优先表明日历(今日日程)和天气(出行准备)。
- 晚上 7-10 点:表明新闻摘要和家庭照片。
- 其他时间:表明时钟和简洁的天气信息。
这种基于时间的动态规格,让这块显示屏真正成为一个智能的信息中枢,在不同的时刻给出你最需要的信息。
5. 进阶优化、难题排查与创意扩展
当基础能力运行稳定后,笔者可以探索一些进阶玩法,并了解如何应对可能遇到的难题。
5.1 表现优化与稳定性提高
树莓派 Zero 2 W 表现有限,长期运行需注意优化。
- 禁用不必要的服务:例如蓝牙(
sudo systemctl disable bluetooth)、音频(sudo systemctl disable alsa-state)等,可以释放一些内存和 CPU 资源。 - 优化日志:防止日志文件撑满 SD 卡。可以安装
logrotate开展管理,或定期清理/var/log目录下的大文件。 - 使用高质量的 SD 卡:挑选 A1 或 A2 级别的 Micro SD 卡,其随机读写表现更好,能提高平台响应速度和寿命。
- 电源管理:确保电源稳定。可以在 SSH 中输入
vcgencmd get_throttled命令检查树莓派是否因供电不足而浮现过降频(throttling)。如果返回值不是throttled=0x0,就需要更换电流更大的电源适配器。
5.2 常见难题与排查技巧实录
即使按照步骤操作,也可能会遇到一些小难题。这里记录了我踩过的坑和应对方法。
| 难题现象 | 可能原因 | 排查步骤与应对思路 |
|---|---|---|
| 显示屏一片空白,无任何表明 | 1. 供电不足。 2. 排线未插好或损坏。 3. 显示屏型号参数错误。 | 1. 检查 USB 电源是否为 5V/2.5A 以上,尝试更换电源和线缆。 2.重点检查:重新拔插显示屏和 HAT 两端的排线,确保锁扣扣紧。 3. 确认安装命令 sudo bash install/install.sh -W epd7in3e中的epd7in3e与你的显示屏型号完全一致(Waveshare 机型页面有标注)。 |
| 显示屏有表明,但内容错乱、残影严重 | 1. 显示屏驱动未正确安装或冲突。 2. 刷新模式或波形文件不对。 | 1. 尝试重启树莓派:sudo reboot。2. 进入 InkyPi 目录,重新运行安装脚本(它会覆盖规格)。 3. 在 InkyPi 的 Web 设置中,尝试切换不同的“刷新模式”(如果有此选项),或降低刷新频率。 |
| 无法借助 Web 界面访问 | 1. IP 地址变更。 2. InkyPi 服务未启动。 3. 防火墙阻止。 | 1. 重新在路由器中查找树莓派 IP,或尝试inkypi.local。2. SSH 登录后,检查服务状态: sudo systemctl status inky。如果未运行,尝试启动:sudo systemctl start inky并设置开机自启:sudo systemctl enable inky。3. 树莓派 OS Lite 默认无防火墙,此难题概率低。 |
| 天气/新闻插件不更新数据 | 1. 网络连接失败。 2. API Key 无效或过期。 3. 数据源 URL 错误。 | 1. 在 SSH 中 ping 一个外网地址(如ping 8.8.8.8),检查网络。2. 检查插件规格中的 API Key 或 RSS 地址是否正确,免费 API 是否有调用次数限制。 3. 查看 InkyPi 的日志获取错误信息: sudo journalctl -u inky -f(按 Ctrl+C 退出)。 |
| 显示屏刷新时浮现全屏黑白闪烁 | 这是电子墨水屏的正常全局刷新(Full Refresh)过程,用于清除残影。 | 这是正常现象,无法避免。可以借助在插件规格中减少使用复杂图片、增加局部刷新(Partial Refresh)的次数来延缓全局刷新的频率。InkyPi 的驱动通常会智能地在多次局部刷新后插入一次全局刷新。 |
5.3 创意扩展思路
基础项目完成后,这个平台还有巨大的可玩性。
- 开发自定义插件:InkyPi 的插件架构是开放的。如果你懂一点 Python,可以参考现有插件,编写自己的插件。例如,表明智能家居设备状态、股票指数、待办事项列表(从 Todoist 或滴答清单同步)、甚至是地铁到站信息。
- 集成 Home Assistant:如果你使用 Home Assistant 管理智能家居,可以编写一个插件,借助 HA 的 REST API 获取实体状态(如室内温湿度、灯光开关状态)并表明在显示屏上。
- 多显示屏同步:如果你有多个树莓派和墨水屏,可以规格它们从同一个中央服务器(例如运行 Home Assistant 或 Node-RED 的设备)获取数据,达成多个房间的信息同步表明。
- 优化外观:除了 3D 打印外壳,你还可以尝试用实木雕刻外壳、将显示屏嵌入油画框中伪装成数字画作,或者为其添加一个光传感器,达成依据环境光自动调整表明亮度和刷新频率。
这个项目最吸引我的地方,在于它完美地结合了硬件动手的乐趣、软件定制的自由以及最终成果的实用性。它静静地立在桌角或墙上,不打扰,却总能给出你需要的信息。从一堆散件到它第一次成功表明出天气图标的那一刻,那种成就感是纯粹的。希望这份详细的指南,能协助你顺利绕过我踩过的那些坑,更快地享受到创造和使用的乐趣。如果在制作过程中遇到任何新的难题,不妨回到 InkyPi 的 GitHub 页面看看 issue 讨论,或者与社区里的其他爱好者交流,那里总会有意想不到的灵感和应对思路。
本文来源:http://www.mfbz.cn/news/380519
若有版权问题,请来信告知:13951431913#139.com 或在右方提交评论。
1. Project overview: building your own low-power information hub
A few years ago I first came across e-ink and was deeply captivated by its paper-like display. It doesn't emit light, only reflecting ambient light, so your eyes don't tire even over long viewing; and once a frame has been refreshed, the content persists even if power is cut. Those traits make it naturally suited to an 'always-on' information board — a calendar hung on the wall, a weather forecast on a desk, or a family schedule reminder by the front door. But back then
Until recently, as vendors like Waveshare released more affordable models and excellent open-source software like InkyPi emerged, building a capable, good-looking colour e-ink dashboard yourself finally became something within reach. The core of this project is to use the small but sufficiently capable 'brain' of a Raspberry Pi Zero 2 W to drive a
Whether you want to learn hardware-software integration with Raspberry Pi and Python, or simply want a unique personal information terminal of your own, this project gives you the full experience from hardware assembly and platform setup to software customisation. The whole process requires no advanced programming knowledge — follow the steps and you will end up with something both practical and satisfying.
2. Hardware selection and assembly: the physical foundation built from scratch
2.1 Core hardware analysis and buying tips
This project's hardware list is unusually short, but every item is critical. Understanding what each one does will help you avoid detours when buying and assembling.
Raspberry Pi Zero 2 W: the 'heart' of the project — I chose the Zero 2 W over other models based on several considerations. First, the balance of power consumption and performance: the Zero 2 W uses a quad-core Cortex-A53 processor from the same generation as the Raspberry Pi 3B+, delivering enough performance to smoothly run a lightweight Linux system and Python applications like InkyPi
Note: be sure to confirm you are buying the 'Zero 2 W' rather than the earlier 'Zero W'. The two look almost identical, but the Zero 2 W's CPU performance is several times higher, which makes a huge difference for apps that need scheduled rendering of complex interfaces (especially colour images).
Waveshare 7.3-inch colour e-ink display and driver HAT: the project's 'face' — this is the visual core of the whole project. I chose the 7.3-inch, 800x480 model because this size strikes a good balance between information density and viewing distance — enough to show a calendar, multi-day weather forecast and other complex information, without looking bulky. The colour e-ink (E-Ink)
The driver HAT (Hardware Attached on Top) is the bridge between the display and the Raspberry Pi. It integrates dedicated driver chips and level-shifting circuits, responsible for converting the Raspberry Pi's digital GPIO signals into the complex waveforms that precisely control the millions of microcapsules on the display. When buying, the display and matching HAT are usually sold as a kit — make sure the model matches exactly
Other accessories: where the details decide success
USB cable and power supply: a short, sturdy Micro USB cable is recommended (such as 0.5m). An overly long cable increases voltage loss, which may cause the Raspberry Pi's power to become unstable and reboot during the display's peak refresh current. A power adapter of 5V/2.5A or higher is recommended for stability.
Fasteners: M3x6mm screws fix the display backplate and frame, while M2.5x16mm screws secure the Raspberry Pi to the HAT's standoffs. Using precisely sized screws avoids stripping threads or damaging the fragile PCB.
Enclosure frame: this is the part that gives the project its personality. You can pick an IKEA 13x18cm picture frame (model RODALM) for a natural wood feel; or use the author's 3D model files to print a cartoon TV, retro mouse or other creative shape. For 3D printing, PLA material at 0.2mm layer height and 20-25% infill is enough to guarantee strength.
2.2 Step-by-step assembly guide
The assembly process is like putting together a precision model, where order matters. My experience: handle the display module first, then install the Raspberry Pi, and finally do the full assembly.
Step 1: prepare the display module and frame
Display protective film: a new display has a transparent protective film on the front for scratch protection during transport. Before installation, be sure to gently peel it off — this is a key step affecting final display clarity.
Install the display into the frame: if you use an IKEA frame, you need to print and prepare the 'Ikea Frame Front.stl' front retainer first. Place the display face down and carefully set it into the frame or 3D-printed front shell. Pay particular attention to the display flex cable (a flat grey ribbon cable) routing, ensuring it passes smoothly through the notch reserved at the bottom of the frame, avoiding over-bending (bending is recommended to
Secure the display backplate: place the printed 'Display Back.stl' backplate on the back of the display, use 4 M3x6mm screws through the four corner holes from the outside, and clamp the display firmly between the frame and the front retainer. Tighten the screws in a 'diagonal sequence', gradually, ensuring even force so the display does not warp.
Step 2: connect the flex cable and driver board
Install the flex socket board: place the small board with the black latch (the flex socket board) on the raised position in the centre of the backplate and fix it with another 4 M3x6mm screws. This board is the adapter connecting the display flex cable and the HAT.
Connect the display flex cable: this is the step that needs the most patience. Using a fingernail or a plastic spudger, gently lift the black latch on the flex socket upward (not pull it out — let it go from horizontal to vertical). Then insert the display flex cable with the gold contacts facing up, aligned with the socket, and push it steadily all the way in. You should feel a slight 'click'. Finally, press the black latch firmly back to horizontal with a crisp locking sound. This operation
Install the Raspberry Pi and HAT: align the driver HAT with the Raspberry Pi Zero 2 W's 40-pin GPIO header, press straight down evenly, ensuring all pins are aligned and fully inserted. Then install 4 3D-printed standoffs ('Waveshare HAT Stand Offs.stl') between the HAT and the Raspberry Pi, and finally use the
Step 3: final wiring and cable management
Connect the HAT flex cable: insert the other flex cable coming out of the HAT into the flex socket board just fixed to the backplate, in the same way (gold contacts facing up). This completes the signal path: Raspberry Pi -> HAT -> flex cable -> display.
Connect power and manage cables: connect the Micro USB cable to the outer USB port on the Raspberry Pi Zero 2 W (this is the power port; the inner one is the OTG data port). Use the printed cable harness clips ('Cable Harness's.stl') to organise and secure the display flex cable and USB power cable inside the frame, preventing them from tugging when they come loose
Final assembly and pre-power checks: if using an IKEA frame, you can now slide the fully assembled module into the frame, and remove or keep the original acrylic panel (removing it reduces reflection, looking more like paper). Finally, before powering the whole platform, do a quick check: are all flex cables firmly latched? Are any screws too long and poking into the circuit? Is the USB cable secure?
3. Software platform deployment: bringing the hardware 'to life'
With the hardware assembled, it is only a beautiful shell. Next, I will inject the soul into it — the operating system and application software.
3.1 Installing and configuring the OS on the Raspberry Pi
The Raspberry Pi has no built-in storage, so all systems run from a microSD card. Therefore my first step is making an OS boot card.
Flashing the OS with Raspberry Pi Imager — this is the officially recommended and most hassle-free tool. After downloading and installing from the Raspberry Pi website, the flow is as follows:
Choose device: in 'Choose Device', be sure to select 'Raspberry Pi Zero 2 W'. You can also flash a generic image, but choosing specifically lets the Imager apply optimisations tuned to that model.
Choose operating system: click 'Choose OS' and pick 'Raspberry Pi OS (other)', then 'Raspberry Pi OS Lite (64-bit)'. I strongly recommend the Lite (no desktop environment) version because it is lighter, boots faster and uses fewer resources — perfect for a single-purpose device like this. Version
Set the hostname: for example, inkypi. This will be your device's name on the network, making it easier to find later.
Enable SSH: tick 'Enable SSH' and choose 'Use password authentication'. This is my only channel for headless (display-less) operation of the Raspberry Pi.
Configure WiFi: enter your home WiFi name (SSID) and password. Make sure the country/region is set correctly.
Set username and password: set a non-default username (such as pi) and a strong password. Security is no small matter.
Configure locale: set the correct time zone (such as Asia/Shanghai), which is critical for accurate time display later.
Write and verify: insert the SD card, select it, and click 'Write'. When finished, the tool runs a verification. Be sure to wait for verification to complete — this ensures the image is written intact, avoiding first-boot failures.
First boot and network connection — insert the flashed SD card into the Raspberry Pi and connect USB power. The red power LED stays solid and the green activity LED blinks irregularly, indicating the system is booting. First boot runs initialisation such as filesystem expansion, which takes 1-3 minutes.
How do you know it has booted? I need to find its IP address. There are several ways:
Router admin page: log into your router's management page (usually 192.168.1.1), and look under 'connected devices' or 'DHCP client list' for the hostname you set (such as inkypi).
Network scanning tool: on your computer use Advanced IP Scanner, Angry IP Scanner, or the command line tool arp -a (on the same LAN) to scan.
(Fallback) mDNS access: if your network supports mDNS, you can access it directly via inkypi.local in a browser or SSH client (Windows may need the Bonjour service installed).
Write down the IP address you obtained, for example 192.168.1.100.
3.2 Remote connection and basic configuration over SSH
With the IP found, I can log in remotely. Windows users are advised to use Termius or PuTTY; macOS and Linux users can use the terminal directly.
Taking Termius as an example:
Create a new host, and put the Raspberry Pi's IP address in the address field.
Leave the port at 22 (the SSH default).
Enter the username and password you set in the Imager.
Click connect. The first connection will show a security warning — just confirm it.
Once connected you will see a command-line prompt such as pi@inkypi:~$ . Congratulations — you are now inside the Raspberry Pi.
A few things recommended right after connecting:
Update the system: while not strictly required, update the package list and upgrade existing software first to keep the system stable. sudo apt update && sudo apt upgrade -y (this may take a few minutes depending on network speed.)
Check network and time: run the date command to see whether the time is correct. If not, run sudo raspi-config and go to 'Localisation Options' to reset the time zone.
3.3 Installing and configuring InkyPi core software
InkyPi is an open-source dashboard application written in Python, purpose-built to drive Waveshare e-ink displays on the Raspberry Pi, offering a web interface for configuration — particularly friendly.
Cloning and installing
Clone the repository: in the SSH terminal, run the following command to download InkyPi's code from GitHub onto the Raspberry Pi. git clone https://github.com/fatihak/InkyPi.git
Enter the directory and run the install script: cd InkyPi && sudo bash install/install.sh -W epd7in3e — the epd7in3e parameter here is absolutely critical: it specifies the display model (7.3-inch colour). If you use a different size of Waveshare display, you need to follow InkyPi's official
The install script automatically handles a series of heavy lifting: installing Python dependencies, configuring system services, setting up auto-start and so on. The whole process takes about 5-10 minutes, during which the display may flicker a few times — that is a normal driver test. The sign of success is: the display finally refreshes to show a screen containing the InkyPi web interface access address (IP and port).
Practical notes: if installation hangs or errors, the most common cause is network trouble (failure downloading Python packages). You can try interrupting with Ctrl+C and re-running the install command. You can also run sudo apt install python3-pip first to ensure pip works. After the install script finishes, it is recommended to reboot the Raspberry Pi once so all services
4. Deep customisation and use of the InkyPi dashboard
After installation completes and the reboot, your e-ink display should be showing InkyPi's default interface with the IP address on it. Now I can open a browser on any computer or phone on the same LAN and enter this IP address (such as http://192.168.1.100 ) to reach the dashboard's control backend.
4.1 Web console walkthrough and core settings
InkyPi's web interface is particularly intuitive. At the top centre is a live preview thumbnail of the display. The left side is the plugin list, the right side is the configuration area for the selected plugin.
Primary configuration: system settings — click the gear icon (Settings) in the top right to enter the core configuration page. There are several key settings here:
Time zone: make sure Asia/Shanghai (or your own zone) is selected here — it affects the accuracy of all time-related plugins such as clock and calendar.
Update interval: this is the global refresh frequency. E-ink has a refresh lifespan (typically several hundred thousand refreshes), and a full refresh causes a brief black flash. Do not set it too short. For weather and news, refreshing every 30 minutes to 1 hour is plenty. The clock can be set to a faster refresh rate (such as every minute) on its own. I usually set 1800 seconds (
Saturation: raising it appropriately (such as 1.2) makes colours more vivid, but too high causes distortion.
Sharpness: a slight increase (such as 1.1) makes text and icon edges crisper.
Brightness: adjust based on ambient light — a small tweak is usually enough.
Display rotation: if your display is mounted vertically, set 90 or 270 degree rotation here.
How plugins work — InkyPi's core capabilities are delivered through plugins. Each plugin is an independent Python script responsible for fetching data from a specific source (network API, local file, system command) and rendering it into an image suited for e-ink display. The web interface invokes these plugins and sends the generated images to the display driver to update the screen. You
4.2 Hands-on configuration of the core plugins
Let me go deep into configuring the most commonly used plugins, understanding the data flow and configuration logic behind them.
1. Clock plugin — this is the simplest plugin, yet the soul of the dashboard. Configuration items include:
Style: choose analog, digital or a simple text style. Analog is more decorative; digital conveys information more directly.
Colour: choose the colour of the hands and digits. E-ink colour is limited (usually red, yellow, blue, white, black), so pick a high-contrast combination.
Show date: ticking this shows the date and weekday below the clock.
Update frequency: can be set to every minute (*/1 * * * * ) or every 5 minutes. Since it only redraws the time, partial refresh is fast and wears the display minimally.
2. Weather plugin — one of the most practical plugins, usually fetching data from a free API such as OpenWeatherMap.
Get an API key: you need to register a free account on the OpenWeatherMap website and generate an API key. The free plan's call frequency is more than enough for personal use.
Location: you can enter a city name (such as Beijing) or coordinates. City name is simpler, but make sure the spelling is correct.
Units: choose Celsius (°C) or Fahrenheit (°F).
Display content: configure to show current temperature, feels-like temperature, high/low, humidity, wind speed, and forecast icons for the coming hours or days. Avoid cramming in too much information — keep the interface clean.
How it works: the plugin periodically (such as every 30 minutes) sends an HTTP request to the weather API, parses the returned JSON, then generates a weather image with icons and text based on a template.
3. Image upload plugin — this plugin lets you upload local images and display them, ideal for showing family photos or artwork.
Upload and processing: click upload in the plugin interface and choose an image. InkyPi uploads it to the Raspberry Pi and processes it using the Floyd-Steinberg dithering algorithm.
Why that algorithm: why use a 1976 classic? Because each e-ink pixel can only display a limited number of colours (such as 7), and cannot show true-colour gradients. Dithering diffuses the colour error of adjacent pixels, simulating more colour levels with limited colours, so colour images look less 'blocky' on e-ink and closer to the original. You can adjust dithering intensity to balance detail against colour.
Display mode: can be set to display once, or added to a carousel sequence.
4. Calendar plugin — usually supports iCal-format calendar subscriptions such as Google Calendar.
Get the calendar address: in Google Calendar's settings, find the 'secret address' (iCal format) for the corresponding calendar. This is a link ending in .ics.
Configure the URL: paste the link into the plugin configuration. The plugin periodically fetches this .ics file and parses the events within (title, time, location).
Display settings: configure how many days ahead of events to show (such as 7 days), and how many events per screen. Events are displayed clearly in list form.
5. News plugin (RSS) — shows news summaries by subscribing to RSS feeds.
Finding RSS feeds: many news sites and blogs provide RSS addresses — for example, a certain tech media outlet's RSS link.
Configure and display: enter the RSS feed URL into the plugin, set the update frequency (such as hourly), the number of headlines to show, and whether to show summaries. It fetches the latest entries and scrolls them on screen.
4.3 Creating and managing display carousel sequences
A single plugin shown for a long time gets monotonous. InkyPi lets you create a playlist.
In the web interface, you can drag configured plugins into a sequence.
Set a display duration for each plugin in the sequence, for example: clock for 1 minute, then switch to weather for 30 seconds, then calendar for 1 minute, then family photos for 2 minutes, and repeat.
Morning 7-9am: prioritise calendar (today's schedule) and weather (travel preparation).
Evening 7-10pm: show news summaries and family photos.
Other times: show the clock and brief weather information.
This time-based dynamic configuration turns the display into a genuine smart information hub, giving you the information you need most at different moments.
5. Advanced optimisation, troubleshooting and creative extensions
Once the basics run stably, I can explore some advanced options and learn how to handle problems that may arise.
5.1 Performance optimisation and stability improvements
The Raspberry Pi Zero 2 W has limited performance, so long-term running requires optimisation.
Disable unnecessary services: for example Bluetooth (sudo systemctl disable bluetooth ) and audio (sudo systemctl disable alsa-state ) can free up some memory and CPU resources.
Optimise logs: prevent log files from filling the SD card. You can install logrotate for management, or periodically clean large files under /var/log.
Use a high-quality SD card: choose an A1 or A2 rated microSD card, which has better random read/write performance and can improve system responsiveness and longevity.
Power management: ensure stable power. You can run vcgencmd get_throttled over SSH to check whether the Raspberry Pi has experienced throttling due to insufficient power. If the return value is not throttled=0x0 , you need a higher-current power adapter.
5.2 Common problems and troubleshooting notes
Even following the steps, you may hit some small problems. Here are the pitfalls I encountered and how I handled them.
5.3 Creative extension ideas
Once the basic project is done, this platform still has enormous play value.
Develop custom plugins: InkyPi's plugin architecture is open. If you know a little Python, you can reference existing plugins and write your own — for example displaying smart home device status, stock indices, to-do lists (synced from Todoist or TickTick), or even subway arrival information.
Integrate Home Assistant: if you use Home Assistant to manage your smart home, you can write a plugin that uses HA's REST API to fetch entity state (such as indoor temperature and humidity, light switch state) and display it.
Multi-display sync: if you have multiple Raspberry Pis and e-ink displays, you can configure them to fetch data from the same central server (for example a device running Home Assistant or Node-RED), achieving synchronised information display across multiple rooms.
Optimise the look: beyond 3D-printed enclosures, you can try a solid wood carved shell, embed the display in an oil painting frame disguised as a digital artwork, or add a light sensor to automatically adjust display brightness and refresh frequency based on ambient light.
What attracts me most to this project is how it perfectly combines the joy of hands-on hardware work, the freedom of software customisation and the practicality of the end result. It stands quietly on a desk corner or against a wall, never in the way, yet always there with the information you need. From a pile of loose parts to the moment it first successfully renders a weather icon — that sense of accomplishment is pure. I hope this detailed guide helps you smoothly avoid the pitfalls I hit and enjoy creating and using it faster.
Programming Learning Study Diary Hands-on Experience
