xref: /freebsd/sys/contrib/device-tree/Bindings/sound/rt5645.txt (revision f81cdf24ba5436367377f7c8e8f51f6df2a75ca7)
1RT5650/RT5645 audio CODEC
2
3This device supports I2C only.
4
5Required properties:
6
7- compatible : One of "realtek,rt5645" or "realtek,rt5650".
8
9- reg : The I2C address of the device.
10
11- interrupts : The CODEC's interrupt output.
12
13- avdd-supply: Power supply for AVDD, providing 1.8V.
14
15- cpvdd-supply: Power supply for CPVDD, providing 3.5V.
16
17Optional properties:
18
19- hp-detect-gpios:
20  a GPIO spec for the external headphone detect pin. If jd-mode = 0,
21  we will get the JD status by getting the value of hp-detect-gpios.
22
23- realtek,in2-differential
24  Boolean. Indicate MIC2 input are differential, rather than single-ended.
25
26- realtek,dmic1-data-pin
27  0: dmic1 is not used
28  1: using IN2P pin as dmic1 data pin
29  2: using GPIO6 pin as dmic1 data pin
30  3: using GPIO10 pin as dmic1 data pin
31  4: using GPIO12 pin as dmic1 data pin
32
33- realtek,dmic2-data-pin
34  0: dmic2 is not used
35  1: using IN2N pin as dmic2 data pin
36  2: using GPIO5 pin as dmic2 data pin
37  3: using GPIO11 pin as dmic2 data pin
38
39-- realtek,jd-mode : The JD mode of rt5645/rt5650
40   0 : rt5645/rt5650 JD function is not used
41   1 : Mode-0 (VDD=3.3V), two port jack detection
42   2 : Mode-1 (VDD=3.3V), one port jack detection
43   3 : Mode-2 (VDD=1.8V), one port jack detection
44
45Pins on the device (for linking into audio routes) for RT5645/RT5650:
46
47  * DMIC L1
48  * DMIC R1
49  * DMIC L2
50  * DMIC R2
51  * IN1P
52  * IN1N
53  * IN2P
54  * IN2N
55  * Haptic Generator
56  * HPOL
57  * HPOR
58  * LOUTL
59  * LOUTR
60  * PDM1L
61  * PDM1R
62  * SPOL
63  * SPOR
64
65Example:
66
67codec: rt5650@1a {
68	compatible = "realtek,rt5650";
69	reg = <0x1a>;
70	hp-detect-gpios = <&gpio 19 0>;
71	interrupt-parent = <&gpio>;
72	interrupts = <7 IRQ_TYPE_EDGE_FALLING>;
73	realtek,dmic-en = "true";
74	realtek,en-jd-func = "true";
75	realtek,jd-mode = <3>;
76};
77