Skip to content

Commit

Permalink
overlays: Add overlay for Hifiberry ADC
Browse files Browse the repository at this point in the history
Adds the DT overlay for the HiFiBerry ADC.

Signed-off-by: j-schambacher <[email protected]>
  • Loading branch information
j-schambacher authored and pelwell committed Aug 27, 2024
1 parent 255788c commit 2dd8d93
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 0 deletions.
1 change: 1 addition & 0 deletions arch/arm/boot/dts/overlays/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
hd44780-i2c-lcd.dtbo \
hd44780-lcd.dtbo \
hdmi-backlight-hwhack-gpio.dtbo \
hifiberry-adc.dtbo \
hifiberry-amp.dtbo \
hifiberry-amp100.dtbo \
hifiberry-amp3.dtbo \
Expand Down
7 changes: 7 additions & 0 deletions arch/arm/boot/dts/overlays/README
Original file line number Diff line number Diff line change
Expand Up @@ -1786,6 +1786,13 @@ Params: gpio_pin GPIO pin used (default 17)
expects a high to switch it on.


Name: hifiberry-adc
Info: Configures the HifiBerry ADC audio card
Load: dtoverlay=hifiberry-adc,<param>=<val>
Params: leds_off If set to 'true' the onboard indicator LED
is switched off at all times.


Name: hifiberry-amp
Info: Configures the HifiBerry Amp and Amp+ audio cards
Load: dtoverlay=hifiberry-amp
Expand Down
45 changes: 45 additions & 0 deletions arch/arm/boot/dts/overlays/hifiberry-adc-overlay.dts
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
// SPDX-License-Identifier: GPL-2.0
// Definitions for HiFiBerry ADC, no onboard clocks
/dts-v1/;
/plugin/;

/ {
compatible = "brcm,bcm2835";

fragment@0 {
target = <&i2s_clk_producer>;
__overlay__ {
status = "okay";
};
};

fragment@1 {
target = <&i2c1>;
__overlay__ {
#address-cells = <1>;
#size-cells = <0>;
status = "okay";

hb_adc: pcm186x@4a {
#sound-dai-cells = <0>;
compatible = "ti,pcm1863";
reg = <0x4a>;
status = "okay";
};
};
};

fragment@2 {
target = <&sound>;
hifiberry_adc: __overlay__ {
compatible = "hifiberry,hifiberry-adc";
audio-codec = <&hb_adc>;
i2s-controller = <&i2s_clk_producer>;
status = "okay";
};
};

__overrides__ {
leds_off = <&hifiberry_adc>,"hifiberry-adc,leds_off?";
};
};
1 change: 1 addition & 0 deletions sound/soc/bcm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ config SND_BCM2708_SOC_HIFIBERRY_ADC
select SND_RPI_HIFIBERRY_ADC
help
Say Y or M if you want to add support for HifiBerry ADC.
Use this module for HiFiBerry's ADC-only sound cards

config SND_BCM2708_SOC_HIFIBERRY_DAC
tristate "Support for HifiBerry DAC and DAC8X"
Expand Down

0 comments on commit 2dd8d93

Please sign in to comment.