Weekly Progress Report: Upstream Greybus Module for Zephyr

Hi all,

I’m Sahil Jaiswal, working on the project Upstream Greybus Module for Zephyr as part of GSoC 2025, under the mentorship of @ayush1325 , @vaishnav , and @moto-timo .

This thread will serve as a weekly log of my progress throughout the summer. Each post will outline the following:

  • :white_check_mark: Accomplishments
  • :hammer_and_wrench: Resolutions to blockers
  • :warning: Ongoing blockers
  • :date: Plans for the current week

Feel free to share any suggestions or feedback. Looking forward to an exciting and productive journey with you all!

2 Likes

Week 0:

Accomplishments:

  • Migrated deployment to GitHub and began reviving existing workflow CI pipeline test file.
  • Received all hardware required for the project.
  • Completed fresh setup of Greybus and Zephyr to start GSoC coding period.

Resolutions to Blockers:

  • Resolved initial setup challenges by performing a clean installation of Greybus and Zephyr environments and used west.yml to setup Greybus in Zephyr workspace.

Ongoing Blockers:

  • N/A

Plans for Next Week:

  • Study BeagleConnect Technology, Greybus, and Zephyr documentation in depth.
  • Begin working on a PPT for an introductory project video.
  • Setup and Explore BeaglePlay and BeagleConnect Freedom.
  • Reviving existing workflow CI pipeline test file.

Week 1:

Accomplishments:

  • Studied BeagleConnect Technology, Greybus, and Zephyr documentation.
  • Created and uploaded an introductory project video to YouTube with a PPT based on my study.
  • Flashed Debian Image on BeaglePlay.
  • Flashed CC1352P7 on BeaglePlay with greybus-host firmware using gb_beagleplay sysfs API.
  • Flashed BeagleConnect Freedom with greybus-node firmware.
  • Identified failing CRC during BeaglePlay CC1352P7 flashing and discussed with mentor.

Resolutions to Blockers:

  • N/A

Ongoing Blockers:

  • N/A

Plans for Next Week:

  • Resume reviving the workflow CI pipeline test file on GitHub.
  • Study Zephyr Twister and testing infrastructure in detail.
  • Analyze Greybus node firmware code, focusing on MikroBUS manifest bits, and perform cleanups.
  • Explore Greybus more on BeaglePlay + BeagleConnect Freedom.
  • Debug BeaglePlay CC1352P7 CRC failing issue with mentor.

Week 2:

Accomplishments:

  • Made MikroBUS support optional in Greybus via a new Kconfig option.
  • Added conditional compilation to MikroBUS-specific code in manifest handling.
  • Reviewed logs on BeagleConnect Freedom to identify failures following the enabling or disabling of MikroBUS support.
  • Verified binary size reduction (~70KB) when MikroBUS support is disabled.
  • Studied Greybus manifest generation and handling for BeagleConnect Freedom.

Resolutions to Blockers:

  • Fixed build errors when configuring MikroBUS support by properly defining Kconfig symbols.

Ongoing Blockers:

  • N/A

Plans for Next Week:

  • Resume work on CI pipeline for testing on GitHub.
  • Implement Zephyr Twister tests for Greybus.
  • Do cleanups on MikroBUS manifest where it is possible.
  • Analyze host-side handling of Greybus on BeaglePlay.
  • Debug BeaglePlay CC1352P7 CRC failing.
  • Test upstream dns_sd support in cc1352-firmware once merged into Zephyr.
1 Like

Week 3:

Accomplishments:

  • Successfully flashed micropython beagleplay_cc1352p7.bin onto the CC1352P7 using cc1352-flasher. Verified REPL functionality on /dev/ttyS1 .
  • Flashed zephyr.bin using cc1352-flasher. Confirmed successful boot via “Hello World!” console output.
  • Verified that the gb-beagleplay driver was disabled via the k3-am625-beagleplay-bcfserial-no-firmware.dtbo overlay. Ensured /dev/ttyS1 was available for direct use.
  • Investigated CRC errors. Identified a temporary resolution and observed recurrence of issues.
  • Began analysis of host-side Greybus behavior on BeaglePlay.

Resolutions to Blockers:

  • N/A

Ongoing Blockers:

  • Recurring CRC failures in gb-beagleplay communication.

Plans for Next Week:

  • Debug recurring Greybus CRC failure.
  • Validate optional MikroBUS manifest against mainline.
  • Continue Fixing CI pipeline for GitHub.
  • Test dns_sd support in CC1352P7 firmware.

Week 4:

Accomplishments:

  • Resolved west command errors and container PATH issues in GitHub Actions workflow.
  • Successfully configured zephyrprojectrtos/ci:latest container with proper environment variables.

Resolutions to Blockers:

  • West Not Found Error: Fixed by setting correct PATH to /opt/python/venv/bin in container.

Ongoing Blockers:

  • Github CI build Failing: No space left on device
  • CRC Failures: Persistent gb-beagleplay communication errors.

Plans for Next Week:

  • Fix GitHub CI build Failing.
  • Validate optional MikroBUS manifest against mainline
  • Debug remaining CRC Failing issues.

Week 5:

Accomplishments:

  • Fixed GitHub CI Build Failures and Resolved “No space left on device” error.
  • Modernized CI Workflow and Successfully updated GitHub Actions workflow from legacy zephyrprojectrtos/ci:v0.11.10 to modern zephyrprojectrtos/ci:latest container.
  • Did a Cleanup and Properly configured CMAKE_PREFIX_PATH for modern Zephyr builds.

Resolutions to Blockers:

  • Github CI build Failing: Fixed by updating to modern container image and properly configuring environment variable.
  • CMake Configuration: Fixed “Could not find ZephyrConfig.cmake” errors by properly extending CMAKE_PREFIX_PATH at runtime.

Ongoing Blockers:

  • CRC Failures: Persistent gb-beagleplay communication errors.

Plans for Next Week:

  • Complete Mid Project Evaluation.
  • Validate optional MikroBUS manifest against mainline Zephyr.
  • Implement detailed logging and debugging for gb-beagleplay communication failures.

Week 6:

Accomplishments:

  • Succesfully Passed Mid Project Evaluation.
  • Migrated cc1352 host firmware repository from GitLab to GitHub.
  • Implemented GitHub Actions CI pipeline for automated firmware builds and artifact upload in cc1352 host firmware.
  • Resolved K_MEM_SLAB_DEFINE_STATIC compilation errors by using __alignof__(struct gb_interface) for automatic alignment detection.

Resolutions to Blockers:

  • N/A

Ongoing Blockers:

  • CRC Failures: Persistent gb-beagleplay communication errors.

Plans for Next Week:

  • Debug and Fix CRC Failures.
  • Implement Twister Based Testing in Greybus Module.

Week 7 Report

Accomplishments:

  • Updated Greybus’s GitHub CI workflow (module.yml and west.yml) for improved efficiency and maintainability.
  • Switched to action-zephyr-setup, resulting in a cleaner and more consistent Zephyr environment setup across CI jobs.
  • Added name-allowlist to prevent unnecessary module imports.
  • Achieved a significant build time reduction from 7–8 minutes down to 3–4 minutes. CI Run Reference (GitHub Actions)

Resolutions to Blockers:

  • N/A

Ongoing Blockers:

  • CRC Failures: Persistent gb-beagleplay communication errors.

Plans for Next Week:

  • Continue debugging and resolving CRC failure issues in Greybus communication.
  • Begin implementing Twister-based testing in the Greybus module.
1 Like

Week 8 Report

Accomplishments:

  • Continued debugging Greybus communication for on CRC related failures.
  • Added more logging in the modified Greybus driver to capture more detailed traces for troubleshooting communication issues.
  • Investigated manifest parsing failures in the Mikrobus optional manifest logic.

Resolutions to Blockers:

  • N/A

Ongoing Blockers:

  • CRC Failures: Persistent gb-beagleplay communication errors remain unresolved.
  • Manifest Parsing Failing.

Plans for Next Week:

  • Continue debugging and resolving CRC failure issues in Greybus communication.
  • Fix manifest parsing logic for optional Mikrobus manifest.
  • Start implementing Twister-based testing in the Greybus module.
1 Like

Since Your Mentors Cannot Help You with Direct Answers,

I was thinking you could show off your communication errors that are outstanding.

If this is not okay, I understand. I figured I could do some background research and look up ideas on the naming scheme of the errors and if there are any related coding blocks in association.

Seth

P.S. I know in GSoC, people and especially your mentors, cannot give a 100%, definitive answer to you because you need to handle your own use case in GSoC. So, I can understand if you do not want to share as of now. In any light, good luck and keep it up. You are making good headway.

Week 9 Report

Accomplishments:

  • Located Greybus Twister suites and attempted discovery/builds (focus on I2C on native_sim).
  • Reviewed test YAML/CMake and DT overlays/bindings for Twister compatibility.
  • Started Debugging Twister build errors.
  • Decided to proceed with known-good host firmware that avoids CRC issues as node firmware is more important right now.

Resolutions to Blockers:

  • N/A

Ongoing Blockers:

  • Inconsistent Twister test discovery .
  • Devicetree overlay errors during Twister builds.

Plans for Next Week:

  • Investigate Greybus manifest parsing failures on upstream Linux Kernel.
  • Prune unused strings from the manifest to reduce footprint.

Week 10 Report

Accomplishments:

  • Identified root cause of Greybus manifest parsing failures, presence of non-spec descriptors (DEVICE 0x07, PROPERTY, and MIKROBUS) in the Zephyr node’s manifest.
  • Confirmed that these extra entries caused the BeaglePlay Greybus host to reject the manifest, preventing Greybus I2C auto-instantiation and leaving iio_info empty.
  • Refactored default manifest to include only Greybus-spec-compliant descriptors (INTERFACE, BUNDLE, CPORT) and gated MikroBUS-specific descriptors behind a Kconfig option.
  • Pruned unused strings from manifest to reduce footprint.

Resolutions to Blockers:

  • Greybus host rejection of manifest: resolved by adhering strictly to spec in default configuration and moving MikroBUS-specific parts behind Kconfig.

Ongoing Blockers:

  • N/A

Plans for Next Week:

  • Functional validation of refactored manifest by manually instantiating I2C clients.
  • Verify stability of Greybus link and ensure sensor detection.

Week 11 Report

Accomplishments:

  • On the host side, successfully instantiated I2C clients manually via /sys/bus/i2c/.../new_device for OPT3001@0x44 and HDC2010@0x41.
  • Restored iio_info detection and maintained Greybus link stability.
  • Verified the fix through functional testing ( Testing Video: YouTube Link ).

Resolutions to Blockers:

  • Manifest compliance issues are now fully resolved, host rejection no longer occurs.

Plans for Next Week:

  • If possible add Twister-based automated testing to the Greybus module before project ends.
  • Finalize and submit PR with cleaned-up code changes of node.

Week 12 Report

Accomplishments:

  • Raised PR for Greybus updates (PR: GitHub Link).
  • Focused Twister effort on Greybus I2C (native_sim), enumerated tests and attempted discovery/build.
  • Debugged Twister logs and tried mapped failures across YAML parsing, Kconfig, DTS, and DT to manifest stages.

Resolutions to Blockers:

  • N/A

Ongoing Blockers (Twister):

  • Inconsistent test discovery (testcase.yaml structure/filters suspected).
  • Platform selection gaps (native_sim filtering/overlays).
  • Devicetree overlay issues (unknown/mismatched compatibles and vendor prefixes).
  • Kconfig configuration aborts (undefined/renamed symbols).
  • DT manifest conversion error from gbutil/manifesto: “invalid id for [None] (cannot be 0)” on string/interface IDs.
  • Intermittent build error: “device.h: No such file or directory.”

Plans for Next Week:

  • Upload Final Video.
  • Final Summary Post.
  • Submit Final Report.

:star2: Google Summer of Code 2025 – Final Evaluation Report

Project: Upstream Greybus Module for Zephyr

Organization: BeagleBoard.org
Student: Sahil Jaiswal
Mentors: @ayush1325, @vaishnav, @moto-timo
Project Size: 350 hours


:open_book: Introduction

Greybus is a modular communication protocol originally developed for Project Ara and later extended to connect peripherals in embedded systems. Currently, the Greybus module for Zephyr exists as an out-of-tree module, which makes it:

  • Hard to maintain
  • Difficult for contributors
  • Non-standard (depends on MikroBUS manifest, which is not part of the official Greybus specification).

The objective of my GSoC 2025 project was to upstream the Greybus module into mainline Zephyr. This project builds upon the Replace GBridge (2023) effort and aims to establish a long-term, testable, and community-friendly Greybus integration.


:dart: Project Goals

  1. Revive testing infrastructure for Greybus module.
  2. Make MikroBUS manifest optional, since it is not part of Greybus spec.
  3. Ustream the module as an official Zephyr module.
  4. Use Greybus abstractions inside greybus-host firmware for BeagleConnect.

:white_check_mark: Major Accomplishments

:small_blue_diamond: 1. MikroBUS Manifest Optionalization

  • Added new Kconfig option to enable/disable MikroBUS support.
  • Introduced conditional compilation for MikroBUS-specific code.
  • Verified binary size reduction (approx 70KB) when MikroBUS support is disabled.
  • Ensured the module remains spec-compliant when MikroBUS is disabled.

:small_blue_diamond: 2. Greybus Manifest Compliance

  • Identified root cause of manifest rejection on BeaglePlay host: presence of non-spec descriptors (DEVICE 0x07, PROPERTY, MIKROBUS).
  • Refactored default manifest to strictly follow Greybus spec (INTERFACE, BUNDLE, CPORT).
  • Moved MikroBUS-specific descriptors behind Kconfig option.
  • Successfully restored Greybus I2C instantiation on BeaglePlay.
  • Verified functionality by instantiating OPT3001@0x44 and HDC2010@0x41 sensors and checking via iio_info.

:small_blue_diamond: 3. CI/CD Infrastructure Modernization

  • Revived existing GitHub Actions workflows and migrated to zephyrprojectrtos/ci:latest.
  • Resolved west PATH errors and CMake misconfigurations.
  • Fixed “No space left on device” CI failure by restructuring builds.
  • Introduced action-zephyr-setup for cleaner environments.
  • Achieved 50% CI build time reduction (7–8 minutes to 3–4 minutes).
  • Migrated CC1352 host firmware from GitLab to GitHub with automated builds & artifact uploads.

:small_blue_diamond: 4. Debugging CRC Failures in Greybus Communication

  • Persistent CRC failures in host firmware on latest Zephyr.
  • Added enhanced logging in Greybus driver for deeper analysis.
  • Tested with micropython firmware and Zephyr builds on CC1352P7.
  • Identified partial workarounds but left as an open for future work.

:small_blue_diamond: 5. Twister Testing Integration (open for future work)

  • Located Greybus Twister test suites and integrated initial builds (focus: Greybus I2C on native_sim).
  • Debugged failures:
    • Inconsistent test discovery.
    • Devicetree overlay mismatches (unknown compatibles).
    • Kconfig aborts (undefined/renamed symbols).
    • Manifest conversion errors from gbutil/manifesto (invalid id for [None]).

:construction: Blockers & Resolutions

Blocker Resolution
CRC failures in gb-beagleplay communication Added detailed logging, tested alternate firmwares, partial resolution but still open.
Manifest rejection on host Refactored manifests to spec compliance, gated MikroBUS via Kconfig.
CI workflow failures (“no space left on device”) Updated containers, fixed PATH & CMake, migrated to modern setup.
Twister integration issues Debugged overlays, Kconfig, YAML parsing. Open for future work.

:bar_chart: Weekly Highlights

  • Week 0–2: Setup environment, revived CI, began MikroBUS optionalization.
  • Week 3–5: Debugged CRC failures, fixed CI build pipeline, reduced CI runtime.
  • Week 6–8: Migrated CC1352 host repo, strict manifest compliance fixes, began Twister integration.
  • Week 9–11: Resolved manifest rejection, verified I2C sensors via Greybus, restored iio_info detection.
  • Week 12: Raised PR for Greybus updates, attempted automated testing integration, prepared final documentation & video.

:link: Contributions


:rocket:Possible Future Work

  • Complete Twister-based automated test integration for Greybus.
  • Fully resolve CRC communication failures on BeaglePlay host.
  • Submit finalized module for Upstreaming into mainline Zephyr.
  • Extend testing to cover more Greybus subsystems.

:books: Learnings & Skills Gained

Over the summer, I gained hands-on experience in:

  • Zephyr RTOS internals (device-tree, Kconfig, Twister testing).
  • Embedded Firmware Flashing & Debugging (BeaglePlay, CC1352P7, BeagleConnect Freedom).
  • Greybus Protocol (manifest parsing, spec compliance, I2C auto-instantiation).
  • Linux System Debugging (/sysfs, iio_info, overlays).
  • CI/CD for Embedded Systems (GitLab CI, GitHub Actions).
  • Collaborative open-source development (PR workflow, discussions with mentors, community contributions).

:pray: Acknowledgments

I am deeply grateful to my mentors @ayush1325, @vaishnav, and @moto-timo for their constant support, reviews, and encouragement throughout the project. Thanks also to the BeagleBoard.org and Zephyr communities for their invaluable documentation, feedback, and infrastructure support.


:sparkles: Conclusion

This GSoC project is a advancement in maintainability, portability, and spec compliance of the Greybus module for Zephyr, while also strengthening the BeagleConnect ecosystem.

I’m excited to continue contributing beyond GSoC — especially in automated testing and upstreaming efforts — and to support future contributors who will build upon this work.


:hotsprings: Miscellaneous

1 Like