Skip to content

Commit 2f656dc

Browse files
j-schambacherpelwell
authored andcommitted
overlays: Add overlay for Hifiberry ADC
Adds the DT overlay for the HiFiBerry ADC. Signed-off-by: j-schambacher <[email protected]>
1 parent 784ef64 commit 2f656dc

File tree

4 files changed

+54
-0
lines changed

4 files changed

+54
-0
lines changed

arch/arm/boot/dts/overlays/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
8585
hd44780-i2c-lcd.dtbo \
8686
hd44780-lcd.dtbo \
8787
hdmi-backlight-hwhack-gpio.dtbo \
88+
hifiberry-adc.dtbo \
8889
hifiberry-amp.dtbo \
8990
hifiberry-amp100.dtbo \
9091
hifiberry-amp3.dtbo \

arch/arm/boot/dts/overlays/README

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1771,6 +1771,13 @@ Params: gpio_pin GPIO pin used (default 17)
17711771
expects a high to switch it on.
17721772

17731773

1774+
Name: hifiberry-adc
1775+
Info: Configures the HifiBerry ADC audio card
1776+
Load: dtoverlay=hifiberry-adc,<param>=<val>
1777+
Params: leds_off If set to 'true' the onboard indicator LED
1778+
is switched off at all times.
1779+
1780+
17741781
Name: hifiberry-amp
17751782
Info: Configures the HifiBerry Amp and Amp+ audio cards
17761783
Load: dtoverlay=hifiberry-amp
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
// SPDX-License-Identifier: GPL-2.0
2+
// Definitions for HiFiBerry ADC, no onboard clocks
3+
/dts-v1/;
4+
/plugin/;
5+
6+
/ {
7+
compatible = "brcm,bcm2835";
8+
9+
fragment@0 {
10+
target = <&i2s_clk_producer>;
11+
__overlay__ {
12+
status = "okay";
13+
};
14+
};
15+
16+
fragment@1 {
17+
target = <&i2c1>;
18+
__overlay__ {
19+
#address-cells = <1>;
20+
#size-cells = <0>;
21+
status = "okay";
22+
23+
hb_adc: pcm186x@4a {
24+
#sound-dai-cells = <0>;
25+
compatible = "ti,pcm1863";
26+
reg = <0x4a>;
27+
status = "okay";
28+
};
29+
};
30+
};
31+
32+
fragment@2 {
33+
target = <&sound>;
34+
hifiberry_adc: __overlay__ {
35+
compatible = "hifiberry,hifiberry-adc";
36+
audio-codec = <&hb_adc>;
37+
i2s-controller = <&i2s_clk_producer>;
38+
status = "okay";
39+
};
40+
};
41+
42+
__overrides__ {
43+
leds_off = <&hifiberry_adc>,"hifiberry-adc,leds_off?";
44+
};
45+
};

sound/soc/bcm/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ config SND_BCM2708_SOC_HIFIBERRY_ADC
4545
select SND_RPI_HIFIBERRY_ADC
4646
help
4747
Say Y or M if you want to add support for HifiBerry ADC.
48+
Use this module for HiFiBerry's ADC-only sound cards
4849

4950
config SND_BCM2708_SOC_HIFIBERRY_DAC
5051
tristate "Support for HifiBerry DAC and DAC8X"

0 commit comments

Comments
 (0)