요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
Hardware pattern and repeat
sysfs-class-led-trigger-pattern:25-50Hardware-specific semantics와 software pattern 비활성화, -1 무한 반복 및 invalid repeat 값을 구분합니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
1
What: /sys/class/leds/<led>/pattern
2
Date: September 2018
3
KernelVersion: 4.20
4
Description:
5
Specify a software pattern for the LED, that supports altering
6
the brightness for the specified duration with one software
7
timer. It can do gradual dimming and step change of brightness.
9
The pattern is given by a series of tuples, of brightness and
10
duration (ms).
12
The exact format is described in:
13
Documentation/devicetree/bindings/leds/leds-trigger-pattern.txt
15
What: /sys/class/leds/<led>/hr_pattern
16
Date: April 2024
17
Description:
18
Specify a software pattern for the LED, that supports altering
19
the brightness for the specified duration with one software
20
timer. It can do gradual dimming and step change of brightness.
22
Unlike the /sys/class/leds/<led>/pattern, this attribute runs
23
a pattern on high-resolution timer (hrtimer).
25
What: /sys/class/leds/<led>/hw_pattern
26
Date: September 2018
27
KernelVersion: 4.20
28
Description:
29
Specify a hardware pattern for the LED, for LED hardware that
30
supports autonomously controlling brightness over time, according
31
to some preprogrammed hardware patterns. It deactivates any active
32
software pattern.
34
Since different LED hardware can have different semantics of
35
hardware patterns, each driver is expected to provide its own
36
description for the hardware patterns in their documentation
37
file at Documentation/leds/.
39
What: /sys/class/leds/<led>/repeat
40
Date: September 2018
41
KernelVersion: 4.20
42
Description:
43
Specify a pattern repeat number. -1 means repeat indefinitely,
44
other negative numbers and number 0 are invalid.
46
This file will always return the originally written repeat
47
number.
49
It should be noticed that some leds, like EL15203000 may
50
only support indefinitely patterns, so they always store -1.
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
Software LED pattern
1-13| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/class/leds/<led>/pattern |
| Date | 2018년 9월 |
| KernelVersion | 4.20 |
| Description | 하나의 software timer로 지정한 duration 동안 LED brightness를 바꾸는 software pattern을 지정합니다. Gradual dimming과 brightness step change를 지원합니다. Pattern은 brightness와 duration(ms) tuple의 연속으로 제공합니다. 정확한 형식은 Documentation/devicetree/bindings/leds/leds-trigger-pattern.txt에 설명되어 있습니다. |
High-resolution timer pattern
15-23| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/class/leds/<led>/hr_pattern |
| Date | 2024년 4월 |
| Description | 하나의 software timer로 지정한 duration 동안 LED brightness를 바꾸는 software pattern을 지정하며 gradual dimming과 brightness step change를 지원합니다. /sys/class/leds/<led>/pattern과 달리 이 속성은 high-resolution timer(hrtimer)에서 pattern을 실행합니다. |
Hardware LED pattern
25-37| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/class/leds/<led>/hw_pattern |
| Date | 2018년 9월 |
| KernelVersion | 4.20 |
| Description | 시간에 따라 brightness를 자율적으로 제어하는 LED hardware를 위해 사전 program된 hardware pattern을 지정합니다. 활성 software pattern은 비활성화합니다. LED hardware마다 hardware pattern semantics가 다를 수 있으므로 각 driver는 Documentation/leds/ 아래 자신의 documentation file에 pattern 설명을 제공해야 합니다. |
속성실행 주체Timing특성
patternSoftwareSoftware timerGradual dimming·step change
hr_patternSoftwarehrtimerHigh-resolution timing
hw_patternHardwareDriver-specific활성 software pattern 비활성화
세 pattern 속성의 실행 주체와 timing source를 비교합니다.
Pattern repeat count
39-50| 항목 | 한국어 전문 번역 |
|---|---|
| What | /sys/class/leds/<led>/repeat |
| Date | 2018년 9월 |
| KernelVersion | 4.20 |
| Description | Pattern repeat 횟수를 지정합니다. -1은 무한 반복을 뜻하고 다른 음수와 0은 유효하지 않습니다. 이 file은 항상 원래 쓴 repeat 값을 반환합니다. EL15203000 같은 일부 LED는 무한 pattern만 지원할 수 있으므로 항상 -1을 저장합니다. |
값의미
-1무한 반복
0Invalid
-1 이외의 음수Invalid
양수지정한 repeat 횟수
원문이 정의한 무한 반복과 invalid 값, 일반 repeat 횟수입니다.
Software timer patterns
sysfs-class-led-trigger-pattern:1-23pattern과 hr_pattern은 gradual dimming·step change를 지원하며 후자는 high-resolution timer에서 실행됩니다.