1# Copyright (c) 2022 Espressif Systems (Shanghai) Co., Ltd.
2# SPDX-License-Identifier: Apache-2.0
3
4description: |
5        Espressif's general-purpose Timers.
6        Each Timer is part of a Timer Group and the number of available Timers
7        is SoC-dependent.
8
9        As as example, ESP32 has 4 Timers available, which are split in two
10        different groups (TIM0_G0, TIM1_G0, TIM0_G1 and TIM1_G1).
11
12        In order to use one of the available timers on your application add
13        a <board>.overlay file with contents as below
14
15          &timer0 {
16                  status = "okay";
17                  prescaler = <10>;
18          };
19
20        From the above, setting 'status' is required while the prescaler is
21        optional. Check below for more information on the prescaler.
22
23include: base.yaml
24
25properties:
26  group:
27    description: |
28      The Timer Group index to which a timer belongs.
29    type: int
30    required: true
31    enum:
32    - 0
33    - 1
34
35  index:
36    description: |
37      The index that identifies a timer within a Timer Group.
38    type: int
39    required: true
40    enum:
41    - 0
42    - 1
43
44  prescaler:
45    description: |
46      The prescaler value defines the factor by which the APB clock will be
47      divided. The outcome of which serves as clock reference to the Timer
48      itself.
49
50      The allowed values for this property are in the range [2..65535].
51      Values above that range will be 16-bit-masked. Values 0 and 1 will be
52      forced to 2.
53    type: int
54    default: 2
55
56compatible: "espressif,esp32-timer"
57