xref: /linux/Documentation/devicetree/bindings/sound/axentia,tse850-pcm5142.txt (revision ab520be8cd5d56867fc95cfbc34b90880faf1f9d)
1Devicetree bindings for the Axentia TSE-850 audio complex
2
3Required properties:
4  - compatible: "axentia,tse850-pcm5142"
5  - axentia,ssc-controller: The phandle of the atmel SSC controller used as
6    cpu dai.
7  - axentia,audio-codec: The phandle of the PCM5142 codec.
8  - axentia,add-gpios: gpio specifier that controls the mixer.
9  - axentia,loop1-gpios: gpio specifier that controls loop relays on channel 1.
10  - axentia,loop2-gpios: gpio specifier that controls loop relays on channel 2.
11  - axentia,ana-supply: Regulator that supplies the output amplifier. Must
12    support voltages in the 2V - 20V range, in 1V steps.
13
14The schematics explaining the gpios are as follows:
15
16               loop1 relays
17   IN1 +---o  +------------+  o---+ OUT1
18            \                /
19             +              +
20             |   /          |
21             +--o  +--.     |
22             |  add   |     |
23             |        V     |
24             |      .---.   |
25   DAC +----------->|Sum|---+
26             |      '---'   |
27             |              |
28             +              +
29
30   IN2 +---o--+------------+--o---+ OUT2
31               loop2 relays
32
33The 'loop1' gpio pin controlls two relays, which are either in loop position,
34meaning that input and output are directly connected, or they are in mixer
35position, meaning that the signal is passed through the 'Sum' mixer. Similarly
36for 'loop2'.
37
38In the above, the 'loop1' relays are inactive, thus feeding IN1 to the mixer
39(if 'add' is active) and feeding the mixer output to OUT1. The 'loop2' relays
40are active, short-cutting the TSE-850 from channel 2. IN1, IN2, OUT1 and OUT2
41are TSE-850 connectors and DAC is the PCB name of the (filtered) output from
42the PCM5142 codec.
43
44Example:
45
46	&i2c {
47		codec: pcm5142@4c {
48			compatible = "ti,pcm5142";
49
50			reg = <0x4c>;
51
52			AVDD-supply = <&reg_3v3>;
53			DVDD-supply = <&reg_3v3>;
54			CPVDD-supply = <&reg_3v3>;
55
56			clocks = <&sck>;
57
58			pll-in = <3>;
59			pll-out = <6>;
60		};
61	};
62
63	ana: ana-reg {
64		compatible = "pwm-regulator";
65
66		regulator-name = "ANA";
67
68		pwms = <&pwm0 2 1000 PWM_POLARITY_INVERTED>;
69		pwm-dutycycle-unit = <1000>;
70		pwm-dutycycle-range = <100 1000>;
71
72		regulator-min-microvolt = <2000000>;
73		regulator-max-microvolt = <20000000>;
74		regulator-ramp-delay = <1000>;
75	};
76
77	sound {
78		compatible = "axentia,tse850-pcm5142";
79
80		axentia,ssc-controller = <&ssc0>;
81		axentia,audio-codec = <&codec>;
82
83		axentia,add-gpios = <&pioA 8 GPIO_ACTIVE_LOW>;
84		axentia,loop1-gpios = <&pioA 10 GPIO_ACTIVE_LOW>;
85		axentia,loop2-gpios = <&pioA 11 GPIO_ACTIVE_LOW>;
86
87		axentia,ana-supply = <&ana>;
88	};
89