요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
CS35L36 Speaker Amplifier
Required properties:
- compatible : "cirrus,cs35l36"
- reg : the I2C address of the device for I2C
- VA-supply, VP-supply : power supplies for the device,
as covered in
Documentation/devicetree/bindings/regulator/regulator.txt.
- cirrus,boost-ctl-millivolt : Boost Voltage Value. Configures the boost
converter's output voltage in mV. The range is from 2550mV to 12000mV with
increments of 50mV.
(Default) VP
- cirrus,boost-peak-milliamp : Boost-converter peak current limit in mA.
Configures the peak current by monitoring the current through the boost FET.
Range starts at 1600mA and goes to a maximum of 4500mA with increments of
50mA.
(Default) 4.50 Amps
- cirrus,boost-ind-nanohenry : Inductor estimation LBST reference value.
Seeds the digital boost converter's inductor estimation block with the initial
inductance value to reference.
1000 = 1uH (Default)
1200 = 1.2uH
Optional properties:
- cirrus,multi-amp-mode : Boolean to determine if there are more than
one amplifier in the system. If more than one it is best to Hi-Z the ASP
port to prevent bus contention on the output signal
- cirrus,boost-ctl-select : Boost converter control source selection.
Selects the source of the BST_CTL target VBST voltage for the boost
converter to generate.
0x00 - Control Port Value
0x01 - Class H Tracking (Default)
0x10 - MultiDevice Sync Value
- cirrus,amp-pcm-inv : Boolean to determine Amplifier will invert incoming
PCM data
- cirrus,imon-pol-inv : Boolean to determine Amplifier will invert the
polarity of outbound IMON feedback data
- cirrus,vmon-pol-inv : Boolean to determine Amplifier will invert the
polarity of outbound VMON feedback data
- cirrus,dcm-mode-enable : Boost converter automatic DCM Mode enable.
This enables the digital boost converter to operate in a low power
(Discontinuous Conduction) mode during low loading conditions.
- cirrus,weak-fet-disable : Boolean : The strength of the output drivers is
reduced when operating in a Weak-FET Drive Mode and must not be used to drive
a large load.
- cirrus,classh-wk-fet-delay : Weak-FET entry delay. Controls the delay
(in ms) before the Class H algorithm switches to the weak-FET voltage
(after the audio falls and remains below the value specified in WKFET_AMP_THLD).
0 = 0ms
1 = 5ms
2 = 10ms
3 = 50ms
4 = 100ms (Default)
5 = 200ms
6 = 500ms
7 = 1000ms
- cirrus,classh-weak-fet-thld-millivolt : Weak-FET amplifier drive threshold.
Configures the signal threshold at which the PWM output stage enters
weak-FET operation. The range is 50mV to 700mV in 50mV increments.
- cirrus,temp-warn-threshold : Amplifier overtemperature warning threshold.
Configures the threshold at which the overtemperature warning condition occurs.
When the threshold is met, the overtemperature warning attenuation is applied
and the TEMP_WARN_EINT interrupt status bit is set.
If TEMP_WARN_MASK = 0, INTb is asserted.
0 = 105C
1 = 115C
2 = 125C (Default)
3 = 135C
- cirrus,irq-drive-select : Selects the driver type of the selected interrupt
output.
0 = Open-drain
1 = Push-pull (Default)
- cirrus,irq-gpio-select : Selects the pin to serve as the programmable
interrupt output.
0 = PDM_DATA / SWIRE_SD / INT (Default)
1 = GPIO
Optional properties for the "cirrus,vpbr-config" Sub-node
- cirrus,vpbr-en : VBST brownout prevention enable. Configures whether the
VBST brownout prevention algorithm is enabled or disabled.
0 = VBST brownout prevention disabled (default)
1 = VBST brownout prevention enabled
See Section 7.31.1 VPBR Config for configuration options & further details
- cirrus,vpbr-thld : Initial VPBR threshold. Configures the VP brownout
threshold voltage
- cirrus,cirrus,vpbr-atk-rate : Attenuation attack step rate. Configures the
amount delay between consecutive volume attenuation steps when a brownout
condition is present and the VP brownout condition is in an attacking state.
- cirrus,vpbr-atk-vol : VP brownout prevention step size. Configures the VP
brownout prevention attacking attenuation step size when operating in either
digital volume or analog gain modes.
- cirrus,vpbr-max-attn : Maximum attenuation that the VP brownout prevention
can apply to the audio signal.
- cirrus,vpbr-wait : Configures the delay time between a brownout condition
no longer being present and the VP brownout prevention entering an attenuation
release state.
- cirrus,vpbr-rel-rate : Attenuation release step rate. Configures the delay
between consecutive volume attenuation release steps when a brownout condition
is not longer present and the VP brownout is in an attenuation release state.
- cirrus,vpbr-mute-en : During the attack state, if the vpbr-max-attn value
is reached, the error condition still remains, and this bit is set, the audio
is muted.
Example:
cs35l36: cs35l36@40 {
compatible = "cirrus,cs35l36";
reg = <0x40>;
VA-supply = <&dummy_vreg>;
VP-supply = <&dummy_vreg>;
reset-gpios = <&gpio0 54 0>;
interrupt-parent = <&gpio8>;
interrupts = <3 IRQ_TYPE_LEVEL_LOW>;
cirrus,boost-ind-nanohenry = <1000>;
cirrus,boost-ctl-millivolt = <10000>;
cirrus,boost-peak-milliamp = <4500>;
cirrus,boost-ctl-select = <0x00>;
cirrus,weak-fet-delay = <0x04>;
cirrus,weak-fet-thld = <0x01>;
cirrus,temp-warn-threshold = <0x01>;
cirrus,multi-amp-mode;
cirrus,irq-drive-select = <0x01>;
cirrus,irq-gpio-select = <0x01>;
cirrus,vpbr-config {
cirrus,vpbr-en = <0x00>;
cirrus,vpbr-thld = <0x05>;
cirrus,vpbr-atk-rate = <0x02>;
cirrus,vpbr-atk-vol = <0x01>;
cirrus,vpbr-max-attn = <0x09>;
cirrus,vpbr-wait = <0x01>;
cirrus,vpbr-rel-rate = <0x05>;
cirrus,vpbr-mute-en = <0x00>;
};
};
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
CS35L36 필수 속성과 boost
1-30CS35L36 speaker amplifier의 `compatible` 값은 `cirrus,cs35l36`이고 `reg`에는 I2C 장치 주소를 지정합니다. `VA-supply`와 `VP-supply`는 `Documentation/devicetree/bindings/regulator/regulator.txt`에 정의된 전원 공급 장치를 가리킵니다.
`cirrus,boost-ctl-millivolt`는 boost converter output voltage를 2550mV부터 12000mV까지 50mV 단위로 설정하며 기본값은 VP입니다.
`cirrus,boost-peak-milliamp`는 boost FET 전류를 감시해 peak current limit를 설정합니다. 1600mA부터 최대 4500mA까지 50mA 단위로 증가하며 기본값은 4.50A입니다.
`cirrus,boost-ind-nanohenry`는 digital boost converter의 inductor estimation block에 초기 inductance reference를 제공합니다. 값 1000은 기본 1uH, 값 1200은 1.2uH입니다.
Multi-amp와 boost control source
31-55Boolean `cirrus,multi-amp-mode`는 시스템에 amplifier가 둘 이상 있음을 나타냅니다. 여러 장치가 있으면 output signal의 bus contention을 막기 위해 ASP port를 Hi-Z로 두는 것이 좋습니다.
`cirrus,boost-ctl-select`는 boost converter가 생성할 target VBST voltage의 제어 source를 선택합니다. 값 `0x00`은 Control Port Value, 기본값 `0x01`은 Class H Tracking, `0x10`은 MultiDevice Sync Value입니다.
Boolean `cirrus,amp-pcm-inv`는 들어오는 PCM data를 반전하고, `cirrus,imon-pol-inv`와 `cirrus,vmon-pol-inv`는 각각 외부로 보내는 IMON·VMON feedback data의 polarity를 반전합니다.
`cirrus,dcm-mode-enable`은 부하가 낮을 때 digital boost converter가 저전력 DCM(Discontinuous Conduction Mode)으로 자동 동작하도록 합니다.
Weak-FET 동작
56-76Boolean `cirrus,weak-fet-disable`은 Weak-FET Drive Mode와 관련됩니다. 이 mode에서는 output driver strength가 줄어들므로 큰 부하를 구동하는 데 사용하면 안 됩니다.
`cirrus,classh-wk-fet-delay`는 audio가 `WKFET_AMP_THLD` 아래로 내려가 유지된 뒤 Class H algorithm이 weak-FET voltage로 전환하기 전의 지연입니다. 값 0~7은 각각 0ms, 5ms, 10ms, 50ms, 기본 100ms, 200ms, 500ms, 1000ms입니다.
`cirrus,classh-weak-fet-thld-millivolt`는 PWM output stage가 weak-FET operation에 들어가는 signal threshold이며 50mV부터 700mV까지 50mV 단위입니다.
온도 경고와 interrupt 출력
77-99`cirrus,temp-warn-threshold`는 amplifier overtemperature warning threshold입니다. 임계값에 도달하면 attenuation이 적용되고 `TEMP_WARN_EINT` status bit가 설정되며, `TEMP_WARN_MASK = 0`이면 `INTb`가 assert됩니다. 값 0, 1, 2, 3은 각각 105C, 115C, 기본 125C, 135C입니다.
`cirrus,irq-drive-select`는 interrupt output driver type을 선택합니다. 값 0은 open-drain, 기본값 1은 push-pull입니다.
`cirrus,irq-gpio-select`는 programmable interrupt output으로 사용할 pin을 선택합니다. 기본값 0은 `PDM_DATA / SWIRE_SD / INT`, 값 1은 GPIO입니다.
VPBR brownout 방지
100-109`cirrus,vpbr-config` 하위 노드의 `cirrus,vpbr-en`은 VBST brownout prevention algorithm을 켜거나 끕니다. 값 0은 비활성화이며 기본값이고, 값 1은 활성화입니다.
구성 선택지와 자세한 동작은 Datasheet 7.31.1절 VPBR Config를 참조합니다.
VPBR attack과 release 제어
110-135`cirrus,vpbr-thld`는 초기 VPBR threshold, 즉 VP brownout threshold voltage를 설정합니다.
원문에 `cirrus,cirrus,vpbr-atk-rate`로 적힌 속성은 brownout condition이 있고 VPBR가 attack state일 때 연속 volume attenuation step 사이의 지연을 설정합니다.
`cirrus,vpbr-atk-vol`은 digital volume 또는 analog gain mode에서 attack attenuation step size를 정하고, `cirrus,vpbr-max-attn`은 VPBR가 audio signal에 적용할 수 있는 최대 attenuation을 정합니다.
`cirrus,vpbr-wait`는 brownout condition이 사라진 뒤 attenuation release state로 들어가기 전의 지연입니다. `cirrus,vpbr-rel-rate`는 brownout이 더 이상 없고 release state일 때 연속 volume attenuation release step 사이의 지연을 설정합니다.
`cirrus,vpbr-mute-en`이 설정된 상태에서 attack 중 `vpbr-max-attn`에 도달한 뒤에도 error condition이 남아 있으면 audio를 mute합니다.
`cirrus,cirrus,vpbr-atk-rate`의 중복 `cirrus,` 접두사는 원문 표기를 그대로 보존한 것입니다. 아래 예제에서는 `cirrus,vpbr-atk-rate`로 사용됩니다.
CS35L36 기본 예제
136-157예제는 I2C 주소 `0x40`, VA·VP supply, reset GPIO와 level-low interrupt를 지정합니다. 1uH inductor, 10000mV boost, 4500mA peak current, Control Port boost source와 multi-amp mode를 구성하고 온도 경고와 interrupt pin 동작을 선택합니다.
예제의 `cirrus,weak-fet-delay`와 `cirrus,weak-fet-thld`는 위 설명의 `cirrus,classh-wk-fet-delay` 및 `cirrus,classh-weak-fet-thld-millivolt`와 이름이 다릅니다. 예제 코드는 원문 그대로 유지했습니다.
cs35l36: cs35l36@40 {
compatible = "cirrus,cs35l36";
reg = <0x40>;
VA-supply = <&dummy_vreg>;
VP-supply = <&dummy_vreg>;
reset-gpios = <&gpio0 54 0>;
interrupt-parent = <&gpio8>;
interrupts = <3 IRQ_TYPE_LEVEL_LOW>;
cirrus,boost-ind-nanohenry = <1000>;
cirrus,boost-ctl-millivolt = <10000>;
cirrus,boost-peak-milliamp = <4500>;
cirrus,boost-ctl-select = <0x00>;
cirrus,weak-fet-delay = <0x04>;
cirrus,weak-fet-thld = <0x01>;
cirrus,temp-warn-threshold = <0x01>;
cirrus,multi-amp-mode;
cirrus,irq-drive-select = <0x01>;
cirrus,irq-gpio-select = <0x01>;
VPBR 하위 노드 예제
158-168`cirrus,vpbr-config` 예제는 brownout prevention enable, threshold, attack rate와 step, 최대 attenuation, wait, release rate, mute enable 값을 지정합니다.
cirrus,vpbr-config {
cirrus,vpbr-en = <0x00>;
cirrus,vpbr-thld = <0x05>;
cirrus,vpbr-atk-rate = <0x02>;
cirrus,vpbr-atk-vol = <0x01>;
cirrus,vpbr-max-attn = <0x09>;
cirrus,vpbr-wait = <0x01>;
cirrus,vpbr-rel-rate = <0x05>;
cirrus,vpbr-mute-en = <0x00>;
};
};
요약과 해설
cs35l36.txt:1-168Boost 전기 설정, multi-device bus 운용, Weak-FET와 온도 보호, interrupt pin, VP brownout prevention을 순서대로 해설합니다. 접을 수 있는 영어 원문 전체와 원문 줄 좌표를 보존한 한국어 전문 번역을 제공합니다.