{"id":22279865,"url":"https://github.com/jupfu/beck-view-connector","last_synced_at":"2026-05-09T04:34:00.885Z","repository":{"id":266152919,"uuid":"896492774","full_name":"JuPfu/beck-view-connector","owner":"JuPfu","description":null,"archived":false,"fork":false,"pushed_at":"2025-11-27T21:27:37.000Z","size":66923,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-11-30T12:11:39.874Z","etag":null,"topics":["c","multicore","pico","pio","pthreads","raspberry"],"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/JuPfu.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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-11-30T14:06:35.000Z","updated_at":"2025-11-27T21:27:40.000Z","dependencies_parsed_at":"2025-02-24T22:27:21.310Z","dependency_job_id":"dccb412b-e790-4c3f-a3c8-8f5344bd036c","html_url":"https://github.com/JuPfu/beck-view-connector","commit_stats":null,"previous_names":["jupfu/beck-view-connector"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/JuPfu/beck-view-connector","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuPfu%2Fbeck-view-connector","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuPfu%2Fbeck-view-connector/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuPfu%2Fbeck-view-connector/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuPfu%2Fbeck-view-connector/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JuPfu","download_url":"https://codeload.github.com/JuPfu/beck-view-connector/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JuPfu%2Fbeck-view-connector/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32807265,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-08T08:22:46.396Z","status":"online","status_checked_at":"2026-05-09T02:00:06.633Z","response_time":123,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["c","multicore","pico","pio","pthreads","raspberry"],"created_at":"2024-12-03T15:24:13.116Z","updated_at":"2026-05-09T04:34:00.867Z","avatar_url":"https://github.com/JuPfu.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Beck View Connector\n\n**Beck View Connector** is a sub-project of the [Beck View Digitize](https://github.com/JuPfu/beck-view-digitize) project. This component serves as an intermediary between the photoelectric sensors attached to the film projector and the computer running Beck View Digitize. It enables the detection, synchronization, and handling of frame advancements and end-of-film events, with real-time data displayed on a connected TFT screen.\n\n![Prototype](./assets/img/beck-view-connector.jpg)\n*Image: Prototype of the Beck View Connector, positioned between the film projector and [Beck View Digitize](https://github.com/JuPfu/beck-view-digitize) \n\n---\n\n## Overview\n\n[beck-view-connector](https://github.com/JuPfu/beck-view-connector) interfaces with the photoelectric sensors that generate frame advance and end-of-film signals. These signals are then transmitted to the computer running [beck-view-digitize](https://github.com/JuPfu/beck-view-digitize). The compiled [beck-view-connector](https://github.com/JuPfu/beck-view-connector) firmware must be flashed to a Raspberry Pi Pico, which processes these signals and forwards them appropriately.\n\n![beck-view](./assets/img/beck-view-overview.jpg)\n\n## Features\n\n**Frame Advancement Detection:**\nA photoelectric sensor detects when the film's [rotating shutter](https://github.com/user-attachments/assets/5ff01cb6-593f-48e8-9ff4-b41a6fde65f2) no longer blocks the sensor, indicating a stable frame position in front of the projector lens. The frame advance signals are passed to [Beck View Digitize](https://github.com/JuPfu/beck-view-digitize), ensuring synchronization with the camera capturing the film frames.\n\nA photoelectric sensor triggers when a [rotating shutter](https://github.com/user-attachments/assets/5ff01cb6-593f-48e8-9ff4-b41a6fde65f2) does not block the sensor any more, which coincides with the current frame at rest in front of the film projector lens.\nThe frame advance signals from the photoelectric sensor are passed on to [Beck View Digitize](https://github.com/JuPfu/beck-view-digitize). Each frame advance signal is held for 8ms. Based on the frame advance signals [Beck View Digitize](https://github.com/JuPfu/beck-view-digitize) triggers the camera mounted in front of the film projector lens.\n\n**Process Details**\n\nThe projector shutter has a single blade covering approximately 70 degrees of a full 360-degree rotation.\n\n* At a maximum speed of 24 frames per second (FPS), the total duration per frame is 41.67 ms.\n\n* The shutter blade covers the lens for 8.10 ms (calculated as 41.67 ms * 70 / 360).\n\n* When the blade starts blocking the lens, a rising edge signal is emitted.\n\n* The system enforces a rising edge debounce delay of 2000 µs to filter out false triggers.\n\n* When the lens is uncovered, a falling edge signal is emitted, and the frame advance signal is sent to the FT232H chip.\n\n* The signal remains high for 8000 µs.\n\n* The falling edge debounce delay ensures no additional interrupts occur while the frame advance signal is active.\n\n**End-of-Film Detection:**  \nA second photoelectric sensor is used to detect the end of film. The end of film signal is passed on to [Beck View Digitize](https://github.com/JuPfu/beck-view-digitize). The end of film signal is held for 1 second. On receiving the end of film signal [Beck View Digitize](https://github.com/JuPfu/beck-view-digitize) terminates.\n\n**Real-Time Display:**  \nIntegrates with an ILI9341 TFT screen to provide frame timing, frames-per-second (FPS), and other statistics. The frame count displayed on the TFT screen after end of film is reached can be compared with the number of frames stored on disc.\n\n**Debounced GPIO Handling:**  \nEnsures stable signal processing with debouncing for all GPIO pin events.\n\n**Dual-Core Utilization:**  \nLeverages both cores of the Raspberry Pi Pico, dedicating one core for display updates.\n\n**Customizable Timing Configurations:**  \nConfigurable delays for frame and end-of-film signal processing.\n\n**Modular and Extensible:**  \nDesigned with a modular structure to allow easy integration and future enhancements.\n\n---\n\n## Requirements\n\n**Hardware:**\n\n- Raspberry Pi Pico\n- ILI9341 TFT Display (or compatible display)\n- A photoelectric sensor to trigger frame advance signals and a photoelectric sensor to emit an end-of-film signal\n- GPIO wiring\n\n**Software:**\n\n- Recommended IDE for this sub-project is Visual Studio Code \n- The plugin \u003cem\u003eRaspberry Pi Pico\u003c/em\u003e which also cares for the installation of a compatible toolchain for Raspberry Pi Pico (e.g., `arm-none-eabi-gcc`)\n\n---\n\n## Setup and Installation\n\n### 1. Clone the Repository\n\n  ```bash\n  git clone https://github.com/JuPfu/beck-view-connector.git\n  cd beck-view-connector\n  ```\n\n### 2. Build the Project\n\nEnsure the **Pico SDK** is set up and its environment variables are configured. Then:\n\n  ```bash\n  mkdir build\n  cd build\n  cmake ..\n  make\n  ```\n\n### 3. Flash to the Raspberry Pi Pico\n\nAfter building, flash the `beck-view-connector.uf2` file to your Pico:\n\n1. Hold the **BOOTSEL** button on the Pico while plugging it into your computer.\n2. Copy the `.uf2` file onto the Pico's storage device.\n\n  ---\n\n## GPIO Configuration\n\n  | GPIO Pin | Function                                              |\n  |----------|-------------------------------------------------------|\n  | 0        | Set permantly high on EOF to stop the projector motor |\n  | 1        | Reset pin set high on button press                    |\n  | 2        | Pass on Frame Advance Signal to FT232H controller     |\n  | 3        | Pass on End-of-Film Signal to FT232H controller       |\n  | 4        | Frame Advance Signal Input                            |\n  | 5        | End-of-Film Signal Input                              |\n  | 26       | LED lit on Frame Advance Signal                       |\n  | 27       | LED lit on End-of-Film Signal                         |\n\n  ---\n\n## Usage\n\n**Observe Display:** The TFT screen will display real-time frame information and indicate when the film ends.\n\n---\n\n## Key Components\n\n### Core Functionalities:\n\n- **`advance_frame_signal_isr`**: Handles frame advance signal processing.\n- **`end_of_film_signal_isr`**: Manages end-of-film detection.\n- **`update_display`**: Protothread for refreshing the display with timing and status updates.\n\n### Protothread System:\n\nLeverages a lightweight threading system for efficient multitasking.\n\n### Timing Configurations:\n\n- `FRAME_ADVANCE_DELAY_US`: Delay to maintain the frame advance signal.\n- `END_OF_FILM_DELAY_US`: Delay to maintain the end-of-film signal.\n- `DEBOUNCE_DELAY_US`: Debounce timing for signal edges.\n\n---\n\n## Project Structure\n\n```plaintext\nbeck-view-connector/\n├── .vscode/                 # Configuration files for Visual Studio Code\n├── examples/                # Example applications or usage scenarios\n├── extra/                   # Additional resources or utilities\n├── include/\n│   └── st7789/              # Header files for the ST7789 display driver\n├── st7789/                  # Source files for the ST7789 display driver\n├── .gitignore               # Specifies files to ignore in version control\n├── CMakeLists.txt           # Build configuration file for CMake\n├── README.md                # Project documentation\n├── beck_view_connector.cpp  # Main implementation file\n├── display.cpp              # Display handling logic\n├── display.h                # Header for display handling\n├── frame_signal.pio         # PIO program for frame signal processing\n├── frame_timing.c           # Frame timing calculations\n├── frame_timing.h           # Header for frame timing calculations\n├── pico_sdk_import.cmake    # CMake script to import the Pico SDK\n├── pt_v1_3.h                # Protothreading system header\n└── types.h                  # Type definitions used across the project\n```\n\n---\n\n## Contribution\n\nContributions are welcome! Please fork the repository, create a feature branch, and submit a pull request.\n\n---\n\n## License\n\nThis project is licensed under the **MIT License**. See the [LICENSE](LICENSE) file for details.\n\n---\n\n## Acknowledgments\n\n- The **Raspberry Pi Foundation** for the hardware and SDK.\n- The open-source community for providing valuable tools and libraries.\n\nFor more details on the parent project, visit the [Beck View Digitize repository](https://github.com/JuPfu/beck-view-digitize).\n\n  ---\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjupfu%2Fbeck-view-connector","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjupfu%2Fbeck-view-connector","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjupfu%2Fbeck-view-connector/lists"}