Skip to content

Commit 96ca3b9

Browse files
committed
update README
1 parent d31803f commit 96ca3b9

File tree

4 files changed

+78
-78
lines changed

4 files changed

+78
-78
lines changed

README.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,34 @@
11
# EPD-nRF5
22

3-
墨水屏日历固件,支持农历、节气、节假日调休显示,也可以通过蓝牙传输图像到墨水屏作为相框使用。日历界面已适配常见的 4.2 寸和 7.5 寸墨水屏分辨率,且同一个固件可驱动不同尺寸屏幕(可通过上位机在线切换屏幕尺寸和驱动)。
3+
E-paper display calendar firmware with support for Chinese lunar calendar, solar terms, and holiday schedules. It can also transmit images via Bluetooth to the e-paper display for use as a digital photo frame. The calendar interface is adapted for common 4.2-inch and 7.5-inch e-paper resolutions, and the same firmware can drive different screen sizes (screen size and driver can be switched online through the web interface).
44

5-
支持的主控芯片有: `nrf51822` / `nrf51802` / `nrf52811` / `nrf52810`,墨水屏方面支持常见的 `UC81xx` / `SSD16xx` 系列驱动(黑白/三色/四色),同时还支持自定义墨水屏到 MCU 的引脚映射,支持睡眠唤醒(NFC / 无线充电器),支持蓝牙 OTA 固件升级。
5+
Supported MCUs: `nrf51822` / `nrf51802` / `nrf52811` / `nrf52810`. For e-paper displays, it supports common `UC81xx` / `SSD16xx` series drivers (black & white / 3-color / 4-color). It also supports custom pin mapping from the e-paper display to the MCU, sleep/wake functionality (NFC / wireless charger), and Bluetooth OTA firmware updates.
66

77
![](docs/images/3.jpg)
88

9-
## 上位机
9+
## Web Interface
1010

11-
本项目自带一个基于浏览器蓝牙接口实现的网页版上位机,可使用手机或电脑打开下面地址使用,或者在本地直接双击打开 `html/index.html` 来使用。
11+
This project includes a web-based interface implemented using Web Bluetooth API. You can use it on your phone or computer by visiting the URL below, or by directly double-clicking `html/index.html` locally.
1212

13-
- 地址:https://tsl0922.github.io/EPD-nRF5
14-
- 演示:https://www.bilibili.com/video/BV1KWAVe1EKs
15-
- 交流群: [1033086563](https://qm.qq.com/q/SckzhfDxuu) (点击链接加入群聊)
13+
- URL: https://tsl0922.github.io/EPD-nRF5
14+
- Demo Video: https://www.bilibili.com/video/BV1KWAVe1EKs
15+
- Discussion Group: [1033086563](https://qm.qq.com/q/SckzhfDxuu) (Click the link to join the chat group)
1616

1717
![](docs/images/0.jpg)
1818

19-
上位机支持多种图片抖动算法,且可以对图片进行涂鸦、添加文字。除了显示图片作为电子相框外,还可以切换到日历模式,显示月历、农历节气、节假日、放假调休等信息。
19+
The web interface supports multiple image dithering algorithms and allows you to doodle on images and add text. In addition to displaying images as a digital photo frame, it can also switch to calendar mode to display monthly calendars, Chinese lunar calendar solar terms, holidays, and work schedule adjustments.
2020

21-
## 支持设备
21+
## Supported Devices
2222

23-
[查看文档](docs/devices.md)
23+
[View Documentation](docs/devices.md).
2424

25-
## 开发编译
25+
## Development
2626

27-
[查看文档](docs/develop.md)
27+
[View Documentation](docs/develop.md).
2828

29-
## 致谢
29+
## Acknowledgments
3030

31-
本项目使用或参考了以下项目的代码:
31+
This project uses or references code from the following projects:
3232

3333
- [ZinggJM/GxEPD2](https://github.com/ZinggJM/GxEPD2)
3434
- [waveshareteam/e-Paper](https://github.com/waveshareteam/e-Paper)

docs/README.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
UC8176 的数据手册中不包含 LUT 相关指令的说明,但是 UC8151 的手册里有,且格式是一样的,故把 UC8151 的手册也放了上来。
1+
The UC8176 datasheet does not include descriptions of LUT-related instructions, but the UC8151 manual does, and the format is the same, so the UC8151 manual has also been included.
22

3-
OTP 目录为从屏幕中读取出的 OTP 数据:
3+
The OTP directory contains OTP data read from the screens:
44

5-
- `bw.txt`: 黑白屏
6-
- `3c.txt`: 黑白红三色屏
5+
- `bw.txt`: Black & white screen
6+
- `3c.txt`: Black, white, and red 3-color screen
77

8-
可从 OTP 数据中提取屏幕内置的 LUT 波形作为参考,以方便自定义 LUT 波形。
8+
You can extract the built-in LUT waveforms from the OTP data as a reference to facilitate custom LUT waveforms.
99

10-
以下是从 OTP 中提取出的 LUT 波形例子(均已测试和本项目支持的 2 个屏幕不加载外部 LUT 时在 20 度左右室温下显示效果一致):
10+
The following are examples of LUT waveforms extracted from OTP (all tested to match the display effect at room temperature around 20°C when the 2 screens supported by this project do not load external LUTs):
1111

12-
**黑白屏:**
12+
**Black & White Screen:**
1313

1414
```c
1515
// OTP location: 0x300
@@ -65,7 +65,7 @@ static const unsigned char LUTBB[] = {
6565
};
6666
```
6767

68-
**三色屏:**
68+
**3-Color Screen:**
6969

7070
```c
7171
// OTP location: 0x400
@@ -121,9 +121,9 @@ static const unsigned char LUTB[] = {
121121
};
122122
```
123123

124-
使用以下 LUT 且把驱动设置为 BW 模式可把三色屏当作黑白屏使用,刷新时间能从 15s 降到 2-3s 左右:
125-
> - 有待继续优化,显示效果比默认三色的 LUT 淡一些
126-
> - 刷新时间应该还有优化的空间,理论上来说应该还可以做一个支持局刷的 LUT
124+
Using the following LUT and setting the driver to BW mode allows the 3-color screen to be used as a black & white screen, reducing refresh time from 15s to around 2-3s:
125+
> - Further optimization is needed; the display effect is slightly lighter than the default 3-color LUT
126+
> - There should be room for optimization of refresh time; theoretically, a LUT supporting partial refresh could also be created
127127
128128
```c
129129
// OTP location: 0x200, from bw.txt

docs/develop.md

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,32 @@
1-
## 开发
1+
## Development
22

3-
> **注意:**
4-
> - 推荐使用 [Keil 5.36](https://img.anfulai.cn/bbs/96992/MDK536.EXE) 或以下版本(如遇到 pack 无法下载,可到群文件下载)
5-
> - `sdk10` 分支为旧版 SDK 代码,蓝牙协议栈占用的空间小一些,用于支持 128K Flash 芯片(不再更新)
3+
> **Note:**
4+
> - Recommended to use [Keil 5.36](https://img.anfulai.cn/bbs/96992/MDK536.EXE) or lower versions (if pack downloads fail, you can download from the group files)
5+
> - The `sdk10` branch contains the legacy SDK code with a smaller Bluetooth protocol stack footprint, used to support 128K Flash chips (no longer updated)
66
7-
这里以 nRF51 版本项目为例 (`Keil/EPD-nRF51.uvprojx`),项目配置有几个 `Target`
7+
Using the nRF51 version project as an example (`Keil/EPD-nRF51.uvprojx`), the project configuration has several `Targets`:
88

9-
- `nRF51822_xxAA`: 用于编译 256K Flash 固件
10-
- `flash_softdevice`: 刷蓝牙协议栈用(只需刷一次)
9+
- `nRF51822_xxAA`: Used to compile 256K Flash firmware
10+
- `flash_softdevice`: Used to flash the Bluetooth protocol stack (only needs to be flashed once)
1111

12-
烧录器可以使用 J-Link 或者 DAPLink(可使用 [RTTView](https://github.com/XIVN1987/RTTView) 查看 RTT 日志)。
12+
For programmers, you can use J-Link or DAPLink (you can use [RTTView](https://github.com/XIVN1987/RTTView) to view RTT logs).
1313

14-
**刷机流程:**
14+
**Flashing Process:**
1515

16-
> **注意:** 这是自己编译代码的刷机流程。如不改代码,强烈建议到 [Releases](https://github.com/tsl0922/EPD-nRF5/releases) 下载编译好的固件,**不需要单独下载蓝牙协议栈**,且有 [刷机教程](https://b23.tv/AaphIZp) (没有 Keil 开发经验的,请不要给自己找麻烦去编译)
16+
> **Note:** This is the flashing process for self-compiled code. If you're not modifying the code, it's strongly recommended to download pre-compiled firmware from [Releases](https://github.com/tsl0922/EPD-nRF5/releases), which **does not require separately downloading the Bluetooth protocol stack**, and there's a [flashing tutorial](https://b23.tv/AaphIZp) available (if you don't have Keil development experience, don't create trouble for yourself by compiling)
1717
18-
1. 全部擦除 (Keil 擦除后刷不了的话,使用烧录器的上位机软件擦除试试)
19-
2. 切换到 `flash_softdevice`,下载蓝牙协议栈,**不要编译直接下载**(只需刷一次)
20-
3. 切换到 `nRF51822_xxAA`,先编译再下载
18+
1. Erase all (if you can't flash after erasing in Keil, try using the programmer's host software to erase)
19+
2. Switch to `flash_softdevice`, download the Bluetooth protocol stack, **download directly without compiling** (only needs to be flashed once)
20+
3. Switch to `nRF51822_xxAA`, compile first then download
2121

22-
### 晶振配置
22+
### Crystal Oscillator Configuration
2323

24-
本项目默认都没有使用外部低速晶振 (频率: `32.768kHz`),因为不是所有的板子都有这个晶振,没有低速晶振的板子刷了开启低速晶振的固件是运行不起来的。
25-
如果你的板子有外部低速晶振,建议修改为使用外部晶振,这样时钟走时会更准确一些。以下是修改方法:
24+
By default, this project does not use an external low-speed crystal oscillator (frequency: `32.768kHz`), because not all boards have this oscillator. Boards without a low-speed oscillator cannot run firmware that enables the low-speed oscillator.
25+
If your board has an external low-speed crystal oscillator, it's recommended to modify it to use the external oscillator, as this will make the clock timing more accurate. Here's how to modify it:
2626

2727
**nRF51**
2828

29-
修改 `main.c`:
29+
Modify `main.c`:
3030

3131
```c
3232
#define NRF_CLOCK_LFCLKSRC {.source = NRF_CLOCK_LF_SRC_XTAL, \
@@ -36,7 +36,7 @@
3636
```
3737
**nRF52**
3838

39-
修改 `sdk_config.h`:
39+
Modify `sdk_config.h`:
4040

4141
```c
4242
#define NRF_SDH_CLOCK_LF_SRC 1
@@ -45,28 +45,28 @@
4545
#define NRF_SDH_CLOCK_LF_ACCURACY 7
4646
```
4747
48-
### 模拟器
48+
### Emulator
4949
50-
本项目提供了一个可在 Windows 下运行界面代码的模拟器,修改了界面代码后无需下载到单片机即可查看效果。
50+
This project provides an emulator that can run GUI code on Windows, allowing you to view the effects after modifying the GUI code without downloading to the microcontroller.
5151
52-
仿真效果图:
52+
Emulation screenshot:
5353
5454
![](images/4.jpg)
5555
5656
57-
**编译方法:**
57+
**Compiling:**
5858
59-
下载并安装 [MSYS2](https://www.msys2.org) 后,打开 `MSYS2 MINGW64` 命令窗口执行以下命令安装依赖:
59+
After downloading and installing [MSYS2](https://www.msys2.org), open the `MSYS2 MINGW64` command window and execute the following commands to install dependencies:
6060
6161
```bash
6262
pacman -Syu
6363
pacman -S make mingw-w64-x86_64-gcc
6464
```
6565

66-
然后 cd 到项目目录,执行 `make -f Makefile.win32` 即可编译出模拟器的可执行文件。
66+
Then `cd` to the project directory and execute `make -f Makefile.win32` to compile the emulator executable.
6767

68-
**修改界面:**
68+
**Modifying the GUI:**
6969

70-
修改 GUI 目录下的代码后,重新执行上面的 make 命令编译即可。
70+
After modifying the code in the GUI directory, simply re-execute the make command above to compile.
7171

72-
> **注意:** GUI 目录下的代码不可依赖平台相关的东西,比如单片机特有的 API 接口,否则在 Windows 下编译会失败。正确的做法是:在调用 `DrawGUI` 函数前就把数据算好并放到 `gui_data_t` 里,然后通过 `data` 参数传进去。
72+
> **Note:** Code in the GUI directory must not depend on platform-specific things, such as microcontroller-specific API interfaces, otherwise compilation on Windows will fail. The correct approach is: calculate the data and put it in `gui_data_t` before calling the `DrawGUI` function, then pass it in through the `data` parameter.

docs/devices.md

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,45 @@
1-
## 支持设备
1+
## Supported Devices
22

3-
只要是基于 `nrf51822` / `nrf51802` / `nrf52811` / `nrf52810` 的价签,理论上都支持。
3+
Theoretically, all electronic shelf labels (ESL) based on `nrf51822` / `nrf51802` / `nrf52811` / `nrf52810` are supported.
44

5-
下面列举几个适配了的价签驱动板。
5+
Below are several adapted ESL driver boards.
66

7-
### 老五 4.2 寸价签,黑白双色版本
7+
### Laowu 4.2-inch ESL, Black & White Version
88

9-
- MCUnrf51822
10-
- RAM16K
11-
- ROM128K
12-
- 驱动:UC8176
13-
- 屏幕引脚:0508090A0B0C0D
14-
- 线圈引脚:07
9+
- MCU: nrf51822
10+
- RAM: 16K
11+
- ROM: 128K
12+
- Driver: UC8176
13+
- Pin Config: `0508090A0B0C0D`
14+
- Wakeup Pin: `07`
1515

1616
![](images/1.jpg)
1717

18-
### 老五 4.2 寸价签,黑白红三色版本
18+
### Laowu 4.2-inch ESL, Black White Red 3-Color Version
1919

20-
- MCUnrf51802
21-
- RAM16K
22-
- ROM256K
23-
- 驱动:UC8176
24-
- 屏幕引脚:0A0B0C0D0E0F10
25-
- 线圈引脚:09
26-
- LED引脚:03/04/05 (有三个 LED,任选一个使用)
20+
- MCU: nrf51802
21+
- RAM: 16K
22+
- ROM: 256K
23+
- Driver: UC8176
24+
- Pin Config: `0A0B0C0D0E0F10`
25+
- Wakeup Pin: `09`
26+
- LED Pins: `03/04/05` (Three LEDs available, choose one to use)
2727

2828
![](images/2.jpg)
2929

30-
### 思飞 52810
30+
### Sifei 52810
3131

32-
- MCUnrf52810
33-
- RAM24K
34-
- ROM192K
32+
- MCU: nrf52810
33+
- RAM: 24K
34+
- ROM: 192K
3535

3636
![](images/5.jpg)
3737

3838

39-
### 盒马/阿里 52811
39+
### Hema/Alibaba 52811
4040

41-
- MCUnrf52811
42-
- RAM24K
43-
- ROM192K
41+
- MCU: nrf52811
42+
- RAM: 24K
43+
- ROM: 192K
4444

4545
![](images/6.jpg)

0 commit comments

Comments
 (0)