Home
Softono
a

allegra42

Professional software vendor delivering innovative solutions on the Softono platform. Specialized in both open-source and proprietary software development.

Total Products
2

Software by allegra42

ZEReader
Open Source

ZEReader

<!-- SPDX-FileCopyrightText: 2025 Anna-Lena Marx <[email protected]> SPDX-License-Identifier: MPL-2.0 --> # ZEReader [![Build Zephyr ZEReader Application](https://github.com/Allegra42/ZEReader/actions/workflows/build-zephyr.yaml/badge.svg)](https://github.com/Allegra42/ZEReader/actions/workflows/build-zephyr.yaml) [![Build ZEReader documentation](https://github.com/Allegra42/ZEReader/actions/workflows/build-docs.yaml/badge.svg)](https://github.com/Allegra42/ZEReader/actions/workflows/build-docs.yaml) <a href="https://allegra42.github.io/ZEReader/"> <img alt="Documentation" src="https://img.shields.io/badge/documentation-3D578C?logo=sphinx&logoColor=white"> </a> <a href="https://allegra42.github.io/ZEReader/doxygen"> <img alt="API Documentation" src="https://img.shields.io/badge/API-documentation-3D578C?logo=c&logoColor=white"> </a> <!-- <img alt="ZEReader in Action" src='/doc/pics/ZEReader.webp' width="500" /> --> ![ZEReader in Action](/doc/pics/ZEReader-vid.webp) ZEReader is a Zephyr based firmware for an open hardware eBook reader approach. See https://github.com/Allegra42/ZEReader-KiCad for more information about the hardware design. The firmware is currently in a really early PoC stage. Nevertheless, due to Zephyr, it is easily portable and adaptable to different hardware platforms which provide the essential components and a proper device tree (overlay) configuration. ## ZEReader Hardware The ZEReader firmware is, based on Zephyr, highly flexible and can be adopted to a wide range of different hardware with a proper device tree (overlay). In general, the development and testing is based on the following components: - Raspberry Pi Pico 1/2 - Waveshare ePaper Display 7,5" (Gooddisplay GDEW075T7, GDEY075T7) with UC8179 controller - SD Card Reader (SPI) - 4 Buttons for navigation The ZEReader PCB itself is developed in a seperated git repository available [here](https://github.com/Allegra42/ZEReader-KiCad). ## Setup for local development ``` west init -m [email protected]:Allegra42/ZEReader.git zereader-workspace cd zereader-workspace python3 -m venv .venv source .venv/bin/activate west update pip install -r zephyr-rtos/scripts/requirements.txt cd zephyr-rtos west sdk install ``` ## Build Always source the venv environment first! ``` cd zereader-workspace source .venv/bin/activate cd ZEReader ``` ### Build for Raspberry Pi Pico 1 using a Device Tree Overlay ``` west build -b rpi_pico app -p always ``` ### Build for Raspberry Pi Pico 2 using a Device Tree Overlay ``` west build -b rpi_pico2/rp2350a/m33 app -p always ``` ### Build for the ZEReader Rev1 Board ``` west build -b zereader_rev1/rp2350a/m33 app -p always ``` ### Build for the ZEReader Rev2 Board ``` west build -b zereader_rev2/rp2350a/m33 app -p always ``` ### Other useful build commands ``` # Update Zephyr and external modules # The west.yml of this project uses potentially unstable main branches from Zephyr and the modules. # This was needed as neighter Pi Pico 2 nor LVGL v9 were included in the 4.0 release, but more or less important for this project. # Be aware this can break! west update # May check if patches in this repo are (still) needed or new ones needed or new issues showed up. # Generate SBoM west spdx ``` ## Flash Pico - disconnect USB - press the 'BOOTSEL' button during reconnect - the device shows up as a mass storage - copy 'build/zephyr/zephyr.uf2' to the device - it flashes itself and restarts running the firmware ## Logs Logs are printed via the Pi Pico default UART pins with 115200 bauds. ## Debugging With Blackmagic Debug Probe using the SWD interface: - connect the Blackmagic Debug Probe to the Pi Pico's SWD header - `west debug --runner blackmagicprobe` -> Connects to a GDB session - set breakpoint with `break <full/source/code/file/path>:<linenumber>` - step through / step in with GDB commands (next/n, step in/si, ..) ## Emulator Note: the Zephyr native simulator only works on Linux. To build the emulator, build the ZEReader app for the `native_sim` board: ``` west build -b native_sim/native/64 app ``` To run the emluator, execute this command: ``` ./build/zephyr/zephyr.exe ``` The native simulator uses emulated flash to provide storage, which replaces the SD card from the actual board. This emulated storage is backed by a 100 MB file named `flash.bin`, located in the directory where the emulator is run. If this file does not exist, the emulator creates it. To put data onto the simulated SD card, mount the file on the host and copy the data into it: ``` sudo mount -o loop flash.bin /mnt sudo cp -r my-book /mnt sudo umount /mnt ``` Alternatively, if the FUSE development headers are installed, FUSE access to the simulated storage can be enabled: ``` west build -b native_sim/native/64 app -- -DCONFIG_FUSE_FS_ACCESS=y ``` When the emulator is running, it mounts the simulated SD card on the directory `flash/SD:`, so the book can be copied there: ``` cp -r my-book flash/SD\:/ ``` In any case, the emulator needs to be restarted after new books are added to the simulated SD card. ## Current state This is still a work-in-process. The firmware shows a proof-of-concept that reading EPUBs as they are is possible with the available resources of a cheap microcontroller unit like the RP2040/RP2350. (Right now, without unzipping the EPUB files directly from Zephyr.) The firmware supports showing the contents of a book in correct order while jumping over pictures and leave (X)HTML formatting untouched. The UI implementation is still very basic. The display orientation is still landscape and refresh configurations need to be tuned for an actually usable reading experience. Config options for EPUB handling are still part of epub.h and should move to an own KConfig definition as the project proceeds in order to keep these configurations in a central location adopt Zephyr idioms. See the GitHub issue page for a closer look on planned tasks.

E-book Management Firmware & RTOS
155 Github Stars
ZEReader-KiCad
Open Source

ZEReader-KiCad

<!-- # ZEReader-PCB ZEReader-PCB is a custom hardware design, intended to be used with the [ZEReader firmware](https://github.com/Allegra42/ZEReader). The project is supported by [AISLER](https://aisler.net/en?utm_source=zereader), which sponsor prototying PCBs. See [Production](#production) for more information. Thanks [AISLER](https://aisler.net/en?utm_source=zereader)! - [ZEReader-PCB](#zereader-pcb) - [PCB Revisions](#pcb-revisions) - [Revision 2](#revision-2) - [Known Issues Rev 2](#known-issues-rev-2) - [Revision 1](#revision-1) - [Known Issues Rev 1](#known-issues-rev-1) - [CI and Automation](#ci-and-automation) - [Production](#production) - [License](#license) ## PCB Revisions ### Revision 2 ![PCB rendering rev2](pictures/ZEReader-Pico%20v2.png) ZEReader revision 2 is a major redesign of the PCB. Major improvements and changes in rev 2: - connected USB-C datalines and added additional ESD and overvoltage protection with USB optimized ESD diodes and a polyfuse - switched to BQ25170 as a charging controller - removed the on-PCB NTC for monitoring the lipo temperature in favor for an integrated one - implemented a new button-based on/off mechanism [based on a self-holding circuit](https://marx.engineer/blog/a-gentle-power-off/) - fixed FFC connector inversion from rev 1 - removed switch in the display's booster circuit, if you want to use an EPD that needs a 3 ohms resistor populate R11 accordingly - connect all SD card connector datalines - reworked and improved general schematic clarity - take advantage of the hierarchical sheets - use new Pi Pico footprint - adopt netclasses in the schematic #### Known Issues Rev 2 - None, the PCB *is not produced yet*! ### Revision 1 Caution: v1 is working, but the FFC connector is inverted. Twisting the cable solves the issue for now. This is to be fixed in the next revision! ![PCB rendering](pictures/ze-ray-front.png) #### Known Issues Rev 1 - FFC connector is inverted, twisting the cable is a quick fix - R11, which defines ISET for the charging controller BQ24092 is too large. 2.7 kohms set a charging current of 200 mA and thus 200 mA for ISET2. In this configuration, the device can not be driven standalone by USB-C. ## CI and Automation This project uses GitHub Actions and KiBot for CI/CD. Outputs can be downloaded in the Actions section. They include: - BoM (interactive for manual assembly and classical HTML) - Drill file (.drl) - Gerber files (.gbr) - KiRi KiCad Revision Inspector files and server To make use of KiRi, move everything besides 'kiri-server' in a subdirectory called 'web' and start the server using 'python kiri-server .' from the KiRi directory - PCB Renderings - PDF Schematic/PCB printout from KiCad - ERC Output (HTML) - DRC Output (HTML) - Fabrication Ready Zip All CI generated output files like schematic and pcb should contain the git revision hash of the commit they were generated from to clearly identify the exact design version. The git revision hash is also added as a silk screen label to the manufacturing files. This intended to help with a more agile approach in hardware development. Besides, KiRi makes it easy to visualize and understand changes in schematic and pcb files tracked by git. ## Production [AISLER](https://aisler.net/en?utm_source=zereader) supports the ZEReader project with prototyping PCBs. Hugh thank you for that! To get the lastest git head manufactured, just follow this link for [Uploading to AISLER](https://aisler.net/p/new?url=https://raw.githubusercontent.com/Allegra42/ZEReader-KiCad/refs/heads/main/ZEReader-Pico.kicad_pcb&ref=github). Alternatively, the GitHub Actions output already contains a prepacked ZIP file with everything needed for production (Gerber files as well as the .kicad_pcb) and correct git revisions filled in. ## License While the project is license as CERN-OHL-S v2, the squirrel logo is a registered design and not allowed to be used in other contexts. --> # ZEReader KiCad The ZEReader PCB is the custom open-hardware board designed for the [ZEReader](https://github.com/Allegra42/ZEReader) project — an open hardware eBook reader approach. The project is supported by [AISLER](https://aisler.net/en?utm_source=zereader), which sponsors prototype boards. See [Production](#production) for more information. Huge thanks to [AISLER](https://aisler.net/en?utm_source=zereader) for their support! --- ## Table of Contents - [ZEReader KiCad](#zereader-kicad) - [Table of Contents](#table-of-contents) - [PCB Revisions](#pcb-revisions) - [Revision 2](#revision-2) - [Known Issues Rev 2](#known-issues-rev-2) - [Revision 1](#revision-1) - [Known Issues Rev 1](#known-issues-rev-1) - [CI and Automation](#ci-and-automation) - [Production](#production) - [Option 1: Tip of the Tree Production](#option-1-tip-of-the-tree-production) - [Option 2: Using Pre-Generated Artifacts](#option-2-using-pre-generated-artifacts) - [Thanks](#thanks) - [License](#license) --- ## PCB Revisions ### Revision 2 **Current Status:** The board is **working**, but USB-C cannot be used for flashing. Use the Micro-USB port on the Raspberry Pi Pico 2 instead! This revision is a major redesign, focused on fixing Rev 1 issues and significantly improving power handling and robustness. ![PCB rendering rev2](pictures/ZEReader-Pico%20v2.png) Major improvements and changes in rev 2: - Connected **USB-C datalines** and added additional **ESD and overvoltage protection** with USB optimized ESD diodes and a polyfuse. - Switched to **BQ25170** as a charging controller. - Removed the on-board NTC for monitoring the LiPo temperature in favor of an integrated one. - Implemented a new **button-based on/off mechanism** [based on a self-holding circuit](https://marx.engineer/blog/a-gentle-power-off/). - Fixed **FFC connector inversion** from rev 1. - Removed switch in the display's booster circuit; populate R11 accordingly for EPDs that require a 3-ohm resistor. - Connected all SD card connector datalines. - Switched to a standard SWD pin header format (2x05, 1.27 pitch) for convenience. - Reworked and improved general schematic clarity (hierarchical sheets, new Pi Pico footprint, netclasses adoption). - Improved BoM. #### Known Issues Rev 2 | Issue | Workaround/Impact | | :--- | :--- | | **USB-C / Power Path** | **USB-C cannot be used for firmware flashing.** The current power path design gates the entire circuit through the on/off button. Because flashing requires constant power, the controller cuts out during the process unless the button is manually held down (which is unreliable). <br>*Status: To be fixed in the next hardware revision. Use the Raspberry Pi Pico's micro-USB for now!* | | **Front-Side Buttons** | Front-side buttons are centered relative to the physical PCB dimensions, rather than the active display area. This results in a visual asymmetry. | ### Revision 1 **Current Status:** The board is **working**, but the FFC connector is inverted. Twisting the cable solves the issue for now. ![PCB rendering](pictures/ze-ray-front.png) #### Known Issues Rev 1 | Issue | Workaround/Impact | | :--- | :--- | | **FFC Connector** | **Inverted!** Requires **twisting the FFC cable** before connection. | | **Charging Circuit**| R11 (ISET for BQ24092) is too large (2.7-kohms). This sets charging current to 200 mA, which is insufficient to drive the device standalone by USB-C. | --- ## CI and Automation This project uses **GitHub Actions** and **KiBot** for continuous integration and delivery. This ensures that all manufacturing files are up-to-date and directly traceable to the source code. Outputs can be downloaded in the Actions section. They include: - **Fabrication Ready Zip** - Gerber files (.gbr) - Drill file (.drl) - Bill of Materials (BoM) (interactive for manual assembly and classical HTML) - Board Renderings and PDF Schematic/Board printouts - Verification Reports: ERC Output (HTML), DRC Output (HTML) - KiRi KiCad Revision Inspector files (for visualizing design changes) > **Version Control:** All CI-generated output files like schematic and board should contain the **git revision hash** of the commit they were generated from to clearly identify the exact design version. The git revision hash is also added as a silkscreen label to the manufacturing files. --- ## Production [AISLER](https://aisler.net/en?utm_source=zereader) supports the ZEReader project with prototyping boards. Huge thank you for that! ### Option 1: Tip of the Tree Production To get the design from the latest commit manufactured, just follow this link for **[Uploading to AISLER](https://aisler.net/p/new?url=https://raw.githubusercontent.com/Allegra42/ZEReader-KiCad/refs/heads/main/ZEReader-Pico.kicad_pcb&ref=github)**. ### Option 2: Using Pre-Generated Artifacts The GitHub Actions output already contains a **prepacked ZIP file** with everything needed for production (Gerber files as well as the `.kicad_pcb`) and correct git revisions filled in. This is the **best way to order a specific, verified commit version**. The generated output is optimized for AISLER. If using a different manufacturing service, please verify that the production files meet their specific requirements. 1. Navigate to the **GitHub Actions** page for the desired commit. 2. Download the **`KiBot_Outputs`** artifact. 3. Upload the Gerber files or the `.kicad_pcb` to [AISLER](https://aisler.net/en?utm_source=zereader). --- ## Thanks - to [casartar](https://github.com/casartar) for reviewing the design and some great tips and ideas! ## License While the project is licensed as **CERN Open Hardware Licence Version 2 - Strongly Reciprocal (CERN-OHL-S v2)**, the squirrel logo is a registered design and not allowed to be used in other contexts.

Utilities & System E-book Management
61 Github Stars