Skip to content

Commit

Permalink
dtoverlays: adds support for Hifiberry ADC8x to the DAC8x
Browse files Browse the repository at this point in the history
Allows the usage of ADC8x stacked on top of the DAC8x.
Activates all I2S pins and uses now the dummy-dai instead
of the formerly used pcm5102 to allow the use of a
capture device, too. The simple card driver will
probe for the ADC8x and may activate the 8 channel
capture. Uses GPIO5 for detection.

Signed-off-by: j-schambacher <[email protected]>
  • Loading branch information
j-schambacher authored and pelwell committed Feb 11, 2025
1 parent 0f292fb commit 2cdd833
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
3 changes: 3 additions & 0 deletions arch/arm/boot/dts/overlays/README
Original file line number Diff line number Diff line change
Expand Up @@ -1879,6 +1879,9 @@ Params: <None>

Name: hifiberry-dac8x
Info: Configures the HifiBerry DAC8X audio cards (only on Pi5)
This driver also detects a stacked ADC8x and activates the
capture capabilities.
Note: for standalone use of the ADC8x activate the ADC8x module.
Load: dtoverlay=hifiberry-dac8x
Params: <None>

Expand Down
14 changes: 10 additions & 4 deletions arch/arm/boot/dts/overlays/hifiberry-dac8x-overlay.dts
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
// SPDX-License-Identifier: GPL-2.0
// Definitions for HiFiBerry DAC8x
/dts-v1/;
/plugin/;

#include <dt-bindings/gpio/gpio.h>

/ {
compatible = "brcm,bcm2712";

Expand All @@ -10,8 +13,10 @@
__overlay__ {
rp1_i2s0_dac8x: rp1_i2s0_dac8x {
function = "i2s0";
pins = "gpio18", "gpio19", "gpio21",
"gpio23", "gpio25", "gpio27";
pins = "gpio18", "gpio19", "gpio20",
"gpio21", "gpio22", "gpio23",
"gpio24", "gpio25", "gpio26",
"gpio27";
bias-disable;
status = "okay";
};
Expand All @@ -30,9 +35,9 @@
fragment@2 {
target-path = "/";
__overlay__ {
pcm5102a-codec {
dummy-codec {
#sound-dai-cells = <0>;
compatible = "ti,pcm5102a";
compatible = "snd-soc-dummy";
status = "okay";
};
};
Expand All @@ -43,6 +48,7 @@
__overlay__ {
compatible = "hifiberry,hifiberry-dac8x";
i2s-controller = <&i2s_clk_producer>;
hasadc-gpio = <&gpio 5 GPIO_ACTIVE_LOW>;
status = "okay";
};
};
Expand Down

0 comments on commit 2cdd833

Please sign in to comment.