{"id":20668607,"url":"https://github.com/casavinteum/cafe21","last_synced_at":"2026-03-01T05:02:46.143Z","repository":{"id":259260089,"uuid":"871631807","full_name":"CasaVinteUm/Cafe21","owner":"CasaVinteUm","description":"This project transforms a Philips Walita Coffee Machine (EP1220) into a smart coffee dispenser that accepts Bitcoin Lightning Network payments. ","archived":false,"fork":false,"pushed_at":"2025-02-10T11:51:13.000Z","size":8373,"stargazers_count":7,"open_issues_count":5,"forks_count":2,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-04-19T19:51:27.438Z","etag":null,"topics":["bitcoin","coffee","ep1220","hacking","lightning-network","lnbits","philips","smart-home","walita"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CasaVinteUm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-10-12T13:59:17.000Z","updated_at":"2025-03-10T21:13:29.000Z","dependencies_parsed_at":"2024-10-23T23:53:42.064Z","dependency_job_id":"0722aba2-1563-4a97-9cce-03296bea7f0e","html_url":"https://github.com/CasaVinteUm/Cafe21","commit_stats":null,"previous_names":["casavinteum/cafe21"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/CasaVinteUm/Cafe21","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CasaVinteUm%2FCafe21","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CasaVinteUm%2FCafe21/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CasaVinteUm%2FCafe21/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CasaVinteUm%2FCafe21/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CasaVinteUm","download_url":"https://codeload.github.com/CasaVinteUm/Cafe21/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CasaVinteUm%2FCafe21/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261262545,"owners_count":23132467,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bitcoin","coffee","ep1220","hacking","lightning-network","lnbits","philips","smart-home","walita"],"created_at":"2024-11-16T20:09:59.129Z","updated_at":"2026-03-01T05:02:41.061Z","avatar_url":"https://github.com/CasaVinteUm.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Cafe Vinteum\n\nThis project transforms a **Philips Walita Coffee Machine (EP1220)** into a smart coffee dispenser that accepts **Bitcoin Lightning Network** payments. By replacing the original control panel with an ESP32 development board featuring a display and touch interface, users can purchase coffee seamlessly using Lightning payments.\n\n## Table of Contents\n\n- [Introduction](#introduction)\n- [Disclaimer](#disclaimer)\n- [Features](#features)\n- [Hardware Requirements](#hardware-requirements)\n  - [Supported Dev Boards](#supported-dev-boards)\n  - [Additional Hardware](#additional-hardware)\n- [Software Dependencies](#software-dependencies)\n- [Installation](#installation)\n  - [Hardware Setup](#hardware-setup)\n  - [Firmware Installation](#firmware-installation)\n- [Usage](#usage)\n- [LNBits Integration](#lnbits-integration)\n- [Help Wanted](#help-wanted)\n- [Contributing](#contributing)\n- [Acknowledgments](#acknowledgments)\n- [License](#license)\n- [Contact](#contact)\n\n## Introduction\n\n**Cafe Vinteum** aims to modernize the coffee experience by integrating cryptocurrency payments directly into a popular coffee machine model. This project is ideal for tech enthusiasts, coffee lovers, and anyone interested in the practical applications of the Lightning Network.\n\n## Disclaimer\n\nYou might void your machine's warranty by attempting to use this software and following these instructions.\n\nBe advised that **CasaVinteUm** will not be held responsible for any damage to people or property resulting from improper use or misunderstanding of this project.\n\n## Features\n\n- **Lightning Payments**: Accepts payments via the Bitcoin Lightning Network.\n- **Touchscreen Interface**: User-friendly navigation and coffee selection.\n- **Wi-Fi Connectivity**: Easy network setup using WiFiManager.\n- **Customizable UI**: Built with LVGL and SquareLine Studio for flexibility.\n- **Open Source**: Built with open-source tools and libraries.\n\n## Hardware Requirements\n\n### Supported Dev Boards\n\nThis project works out of the box with three different development board displays known as **Cheap Yellow Display (CYD)**:\n\n- **esp32-3248S035C**: The less capable brother.\n- **esp32-4827S043C**: The middle brother.\n- **esp32-8048S043C**: The good-looking, intelligent brother.\n\nThese displays typically include:\n\n- An **ESP32** microcontroller.\n- An integrated **LCD display**.\n- **Touchscreen** capability.\n\n### Additional Hardware\n\n- **Philips Walita Coffee Machine (EP1220)**\n- **Level Shifters**: To adjust voltage levels between the coffee machine (5V) and ESP32 (3.3V).\n- **Perforated Board**: For assembling the custom circuit.\n- **Header Pins and Connectors**: For secure connections.\n- **Power Supply**: Ensure adequate power for both the ESP32 and the coffee machine.\n\n## Software Dependencies\n\nWe utilize several open-source libraries and tools:\n\n- [PlatformIO](https://platformio.org): Integrated development environment for IoT.\n- [LVGL](https://lvgl.io): Powerful graphics library for embedded systems.\n- [SquareLine Studio](https://squareline.io): Design tool for creating UI interfaces (free for personal use).\n- [WiFiManager](https://github.com/tzapu/WiFiManager): Simplifies Wi-Fi configuration on the ESP32.\n- [WebSockets](https://github.com/links2004/WebSockets): Enables real-time communication via WebSockets.\n- [ESP32 Smart Display](https://github.com/rzeldent/esp32_smartdisplay): Facilitates smart display functionalities.\n- [ESP32 Partition Tool](https://esp32.jgarrettcorbin.com): Creates custom partition tables for more storage.\n- [SquareLine Studio Boards](https://github.com/nGoline/squarelinestudio-boards): Board definitions for SquareLine Studio.\n\n## Installation\n\n### Hardware Setup\n\n1. **Disassemble the Coffee Machine**:\n   - Carefully remove the original control panel from the Philips EP1220.\n   - Preserve all connectors and cables for reuse.\n\n2. **Prepare the ESP32 Board**:\n   - Choose one of the supported CYD boards.\n   - Install any necessary firmware (see Firmware Installation below).\n\n3. **Assemble the Circuit**:\n   - Use a perforated board to mount the level shifters and header pins.\n   - Connect the coffee machine's data lines to the level shifters.\n   - Connect the level shifters to the ESP32 board.\n   - Ensure all connections match the voltage requirements (5V ↔ 3.3V).\n\n4. **Integration**:\n   - Mount the ESP32 display where the original control panel was located.\n   - Secure all components to prevent movement or disconnection.\n\n   *Note: Detailed schematics and wiring diagrams are available in the `/hardware` directory.*\n\n### Firmware Installation\n\n1. **Set Up Development Environment**:\n   - Install [PlatformIO](https://platformio.org/install) in your preferred IDE (VSCode recommended).\n\n2. **Clone the Repository**:\n   ```bash\n   git clone https://github.com/yourusername/cafe-vinteum.git\n   ```\n\n3. **Install Libraries**:\n   - Open the project in PlatformIO.\n   - PlatformIO should automatically install the required libraries specified in `platformio.ini`.\n\n4. **Configure Wi-Fi (Optional)**:\n   - By default, WiFiManager handles Wi-Fi setup.\n   - If you prefer to hardcode your Wi-Fi credentials, modify the relevant sections in the code.\n\n5. **Compile and Upload Firmware**:\n   - Connect the ESP32 board to your computer via USB.\n   - In PlatformIO, build and upload the firmware:\n     ```\n     pio run --target upload\n     ```\n\n6. **UI Design with SquareLine Studio**:\n   - Follow the instructions [here](https://github.com/nGoline/squarelinestudio-boards) to install the boards on SquareLine Studio.\n   - Open the provided UI project in SquareLine Studio.\n   - Export the UI assets.\n   - Ensure the exported assets are placed in the `/assets` directory of your PlatformIO project.\n\n7. **Adjust Partition Scheme** for non-s3 boards:\n   - Use the [ESP32 Partition Tool](https://esp32.jgarrettcorbin.com) to create a custom partition if needed.\n   - Update the `partitions.csv` file in your project accordingly.\n\n## Usage\n\n1. **Power On the Machine**:\n   - Plug in the modified coffee machine.\n   - The coffee machine will turn on automatically.\n\n2. **Wi-Fi Configuration**:\n   - On first boot, the ESP32 will create an access point (e.g., `CafeVinteum_AP`).\n   - Connect to this AP using a smartphone or laptop.\n   - Follow the captive portal to input your Wi-Fi credentials.\n\n3. **Connect to LNBits**:\n   - Configure the LNBits integration (see [LNBits Integration](#lnbits-integration)).\n\n4. **Using the Touch Interface**:\n   - Select your preferred coffee type on the touchscreen.\n   - A QR code will appear for payment.\n\n5. **Make a Payment**:\n   - Use a Lightning-compatible wallet to scan the QR code.\n   - Upon successful payment, the machine will brew your coffee.\n\n## LNBits Integration\n\nWe use [LNBits](https://lnbits.com) and its **LNURLDevice** extension to handle Lightning payments.\n\n### Setup Instructions\n\n1. **Install LNBits**:\n   - You can self-host LNBits or use a hosted instance.\n   - Follow the official [LNBits installation guide](https://docs.lnbits.com/guide/installation.html).\n\n2. **Enable LNURLDevice Extension**:\n   - In LNBits, navigate to the Extensions page.\n   - Enable and set up the LNURLDevice extension.\n\n3. **Create a new device**:\n   - Choose the option Switch;\n   - Click the plus(+) button twice to add two configurations;\n   - Set the price for Espresso and Coffee, respectivelly;\n   - Set the duration and GPIO pin for the **Espresso** as `1` and `1`.\n   - Set the duration and GPIO pin for the **Coffee** as `2` and `2`.\n\n4. **Update Firmware Configuration**:\n   - In your ESP32 code, update the LNBits API endpoint and LNURLs for each beverage.\n   - You can also set this up on the captive portal during first boot.\n\n5. **Test the Connection**:\n   - Trigger a test payment to ensure the system works end-to-end.\n\n## Help Wanted\n\nWe need assistance with:\n\n- **Translations**: Adding multiple language support to the SquareLine project and touchscreen messages.\n- **Testing**: Running the project on different hardware setups and reporting issues.\n- **Documentation**: Improving installation guides, especially for the hardware setup.\n\nIf you're interested in contributing, please check out the [Contributing](#contributing) section.\n\n## Contributing\n\nWe welcome contributions from the community!\n\n- **Fork the Repository**: Create your own fork and work on it.\n- **Create a Branch**: Use descriptive branch names for your features or fixes.\n- **Pull Requests**: Submit a pull request to the `main` branch with a clear description of your changes.\n- **Report Issues**: Use the GitHub Issues page to report bugs or suggest enhancements.\n\nPlease adhere to the coding standards and follow the existing code style.\n\n## Acknowledgments\n\n- **[TillFleisch](https://github.com/TillFleisch/ESPHome-Philips-Smart-Coffee)**: For the initial inspiration and groundwork in understanding the communication protocol between the machine and the control panel.\n- **Open-Source Community**: For providing the tools and libraries that make this project possible.\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.\n\n## Contact\n\nFor questions or support, please open an issue on GitHub.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcasavinteum%2Fcafe21","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcasavinteum%2Fcafe21","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcasavinteum%2Fcafe21/lists"}