Skip to content

HAL Module Request: HAL for AFBR-S50 ToF sensors #87704

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ubieda opened this issue Mar 26, 2025 · 5 comments
Closed

HAL Module Request: HAL for AFBR-S50 ToF sensors #87704

ubieda opened this issue Mar 26, 2025 · 5 comments
Assignees
Labels
area: Blobs Binary blobs area: Sensors Sensors TSC Topics that need TSC discussion

Comments

@ubieda
Copy link
Member

ubieda commented Mar 26, 2025

Origin

Broadcom's AFBR-S50 API: https://github.com/broadcom/AFBR-S50-API/

External Module

Zephyr HAL for submission: https://github.com/cognipilot/hal_afbr

Purpose

This SDK supports the familiy of AFBR-S50 3D Time of Flight sensors for Broadcom, useful for Robotics applications (among other areas).

Mode of integration

The suggested integration mode is as an external module. The reason being: the library includes precompiled libraries, which can't be included in-tree.

Specifically, the integration is split between code residing in the External module and the Zephyr repository. The following diagram depics how this is done:

Image

  • Zephyr code:
    • Zephyr Application using Zephyr Sensor API (e.g: Sensor Shell)
    • AFBR-S50 Sensor Driver: Implements Zephyr Sensor APIs (e.g: Read/Decode or Streaming, using sensor channels/triggers).
    • HAL (Zephyr-specific): Provides the glue to allow AFBR-S50 library to utilize IRQ, Timer(s), Counter, SPI and GPIOs to communicate with the sensor.
  • AFBR-S50 code:

Suggested name: hal_afbr.

Maintainership

Maintainers:

Collaborators:

Pull Request

#87699

Description

AFBR-S50-API contains the neccesary software to support the AFBR-S50 sensor modules. This includes APIs. data-types and pre-compiled binaries and sample-code.

The AFBR HAL is a simplified version of this repository, following Zephyr suggested practices to integrate external moduels (including not hosting binary blobs in the repo).

Security

No security components included.

Dependencies

No other dependencies.

Revision

https://github.com/CogniPilot/hal_afbr/tree/676cafb93a8b01b1a5ac80dbe7cfac839b1bd8a5

License

BSD 3-Clause License

Copyright (c) 2021, Broadcom Inc
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this
   list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice,
   this list of conditions and the following disclaimer in the documentation
   and/or other materials provided with the distribution.

3. Neither the name of the copyright holder nor the names of its
   contributors may be used to endorse or promote products derived from
   this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
@ubieda ubieda added the TSC Topics that need TSC discussion label Mar 26, 2025
@ubieda
Copy link
Member Author

ubieda commented Apr 16, 2025

Apologies for having the External module private. It is now made a public repo: https://github.com/cognipilot/hal_afbr.

@nashif @carlescufi Please LMK if you have any questions!

@nashif nashif moved this from Todo to Done in TSC Attention Needed Apr 24, 2025
@ubieda
Copy link
Member Author

ubieda commented May 19, 2025

@nashif @stephanosio since the TSC voted to approve this on April 23th, can you help creating the module repo under @zephyrproject-rtos, please?

@nashif
Copy link
Member

nashif commented May 19, 2025

will do. sorry I missed that.

@ubieda
Copy link
Member Author

ubieda commented May 19, 2025

no worries!

@ubieda
Copy link
Member Author

ubieda commented May 29, 2025

This has been completed since the PR was merged. Thanks!

@ubieda ubieda closed this as completed May 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Blobs Binary blobs area: Sensors Sensors TSC Topics that need TSC discussion
Projects
Status: Done
Development

No branches or pull requests

6 participants