Skip to content

drivers: dac: silabs_vdac implementation #93677

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

Conversation

silabs-BastienB
Copy link
Contributor

@silabs-BastienB silabs-BastienB commented Jul 24, 2025

The goal of this PR is to enable the use of the DAC driver for series 2 devices.
This PR does the following:

  • Fix the clock branch bindings.
  • Import sl_hal_vdac in hal_silabs/simplicity_sdk.
  • Enables the hal_silabs VDAC module to be compiled for series 2.
  • Defines a compatible binding which can be used for series 2 parts that have a VDAC peripheral.
  • Instantiates the xg2x parts with a VDAC peripheral with a VDAC node in their respective part dtsi.
  • Implements the DAC driver compatible with silabs,vdac.
  • Adds support for the DAC driver in the relevant series 2 development kits and radio boards.
  • Extends the dac_api and dac_loopback tests for xg23 and xg24 boards.

@silabs-BastienB silabs-BastienB force-pushed the drivers/dac/silabs_vdac-implementation branch from bc44d3c to b740944 Compare July 24, 2025 19:15
Copy link
Contributor

@asmellby asmellby left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this! I've got a few comments, nothing major.

@asmellby asmellby changed the title Drivers: comparator: silabs_vdac implementation drivers: dac: silabs_vdac implementation Jul 25, 2025
@silabs-BastienB silabs-BastienB force-pushed the drivers/dac/silabs_vdac-implementation branch 3 times, most recently from ce40dd9 to 076477a Compare July 28, 2025 13:24
Copy link
Contributor

@Martinhoff-maker Martinhoff-maker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only minor comments, otherwise LGTM.
Don't forget to add a commit where you modify west.yml to point the corresponding hal_silabs pull request.
edit: also don't forget to take a look at sonarqube issue.

@silabs-BastienB silabs-BastienB force-pushed the drivers/dac/silabs_vdac-implementation branch from 076477a to 188c5a1 Compare July 28, 2025 16:21
Copy link

github-actions bot commented Jul 28, 2025

The following west manifest projects have changed revision in this Pull Request:

Name Old Revision New Revision Diff

All manifest checks OK

Note: This message is automatically posted and updated by the Manifest GitHub Action.

@github-actions github-actions bot added manifest manifest-hal_silabs DNM (manifest) This PR should not be merged (controlled by action-manifest) labels Jul 28, 2025
@silabs-BastienB silabs-BastienB force-pushed the drivers/dac/silabs_vdac-implementation branch from 188c5a1 to 93370f3 Compare July 28, 2025 16:47
@github-actions github-actions bot removed manifest manifest-hal_silabs DNM (manifest) This PR should not be merged (controlled by action-manifest) labels Jul 28, 2025
@silabs-BastienB silabs-BastienB force-pushed the drivers/dac/silabs_vdac-implementation branch from 93370f3 to 9219013 Compare July 29, 2025 04:38
@github-actions github-actions bot added manifest manifest-hal_silabs DNM (manifest) This PR should not be merged (controlled by action-manifest) labels Jul 29, 2025
@silabs-BastienB silabs-BastienB force-pushed the drivers/dac/silabs_vdac-implementation branch from 9219013 to fdd8f3d Compare July 29, 2025 05:43
@silabs-BastienB silabs-BastienB marked this pull request as ready for review July 29, 2025 06:22
@zephyrbot zephyrbot added area: DAC Digital-to-Analog Converter area: Clock Control platform: Silabs Silicon Labs labels Jul 29, 2025
@github-actions github-actions bot removed the DNM (manifest) This PR should not be merged (controlled by action-manifest) label Aug 6, 2025
jerome-pouiller
jerome-pouiller previously approved these changes Aug 6, 2025
asmellby
asmellby previously approved these changes Aug 6, 2025
jhedberg
jhedberg previously approved these changes Aug 6, 2025
@jhedberg
Copy link
Member

jhedberg commented Aug 6, 2025

The west.yml change will need to be coordinated with #92808, since that one bumps hal_silabs to latest main whereas this bumps it to main~2

Updated CLOCK_BRANCH bindings to stay in sync with the enum
sl_clock_branch_t in the Silicon Labs HAL.

Signed-off-by: Bastien Beauchamp <[email protected]>
This enables Silabs Series 2 HAL source files for the Silabs
VDAC module to be compiled when the SOC_SILABS_ACMP
configuration is selected.

Signed-off-by: Bastien Beauchamp <[email protected]>
Generates bindings that define VDAC auxiliary output.
These bindings can be used in devicetree sources to configure
the aux-output property.

Signed-off-by: Bastien Beauchamp <[email protected]>
Defines bindings that are compatible with Silabs VDAC.
Reference your part's design book when configuring
values for the properties.

Signed-off-by: Bastien Beauchamp <[email protected]>
This implements the DAC driver for silabs VDAC peripherals
using the silabs,vdac compatible binding.

Signed-off-by: Bastien Beauchamp <[email protected]>
Defines a VDAC node for xg23 and xg24 parts, which are all
compatible with the silabs,vdac binding.

Signed-off-by: Bastien Beauchamp <[email protected]>
Set status to okay for VDAC nodes for xg23 and xg24 boards.

Signed-off-by: Bastien Beauchamp <[email protected]>
The xg24_dk2601b, xg24_ek2703a, xg23_rb4210a and
xg24_rb4187c board yaml files were updated
to support the DAC driver.

Signed-off-by: Bastien Beauchamp <[email protected]>
Add board overlays and defines to the test sources files to execute
the dac_api and dac_loopback tests on xg23_rb4210a, xg24_dk2601b,
xg24_ek2703a and xg24_rb4187c.

Signed-off-by: Bastien Beauchamp <[email protected]>
Copy link

sonarqubecloud bot commented Aug 7, 2025

@jhedberg
Copy link
Member

jhedberg commented Aug 7, 2025

@martinjaeger could you please have another look?

@cfriedt cfriedt merged commit 16298e9 into zephyrproject-rtos:main Aug 8, 2025
29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Clock Control area: DAC Digital-to-Analog Converter platform: Silabs Silicon Labs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants