~ruther/avr-device

ref: cd7b85ad813a72066d528841738bbb6c923fef61 avr-device/patch/attiny84.yaml -rw-r--r-- 9.2 KiB
cd7b85ad — Andrew Dona-Couch Add PINx patch to ATtiny84 4 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
_include:
  - "common/ac.yaml"
  - "common/port.yaml"
  - "common/wdt.yaml"

  - "timer/attiny84.yaml"

AC:
  _modify:
    DIDR0:
      description: "Digital Input Disable Register 0"
  DIDR0:
    _delete:
      - ADC0D
    _modify:
      ADC1D:
        description: "ADC1 (AIN0) Digital input buffer disable"
    _add:
      ADC2D:
        description: "ADC2 (AIN1) Digital input buffer disable"
        bitOffset: 2
        bitWidth: 1
        access: read-write
ADC:
  ADCSRA:
    ADPS:
      _replace_enum:
        PRESCALER_2: [1, "Prescaler Value 2"]
        PRESCALER_4: [2, "Prescaler Value 4"]
        PRESCALER_8: [3, "Prescaler Value 8"]
        PRESCALER_16: [4, "Prescaler Value 16"]
        PRESCALER_32: [5, "Prescaler Value 32"]
        PRESCALER_64: [6, "Prescaler Value 64"]
        PRESCALER_128: [7, "Prescaler Value 128"]
  ADCSRB:
    ADTS:
      _replace_enum:
        FREE: [0, "Free Running mode"]
        AC: [1, "Analog Comparator"]
        INT0: [2, "External Interrupt Request 0"]
        TC0_CMA: [3, "Timer/Counter0 Compare Match A"]
        TC0_OVF: [4, "Timer/Counter0 Overflow"]
        TC0_CMB: [5, "Timer/Counter0 Compare Match B"]
        PCIR: [6, "Pin Change Interrupt Request"]
  ADMUX:
    _add:
      MUX:
        description: "Analog Channel and Gain Selection Bits"
        bitOffset: 0
        bitWidth: 6
        access: read-write
      REFS:
        description: "Reference Selection Bits"
        bitOffset: 6
        bitWidth: 2
        access: read-write
    MUX:
      _write_constraint: enum
      _replace_enum:
        ADC0: [0, "Single-ended Input ADC0"]
        ADC1: [1, "Single-ended Input ADC1"]
        ADC2: [2, "Single-ended Input ADC2"]
        ADC3: [3, "Single-ended Input ADC3"]
        ADC4: [4, "Single-ended Input ADC4"]
        ADC5: [5, "Single-ended Input ADC5"]
        ADC6: [6, "Single-ended Input ADC6"]
        ADC7: [7, "Single-ended Input ADC7"]

        ADC_GND: [32, "0V (GND)"]
        ADC_VBG: [33, "Internal Reference (VBG)"]
        TEMPSENS: [34, "Temperature sensor"]

        ADC0_ADC0_20X: [35, "Differential Inputs Positive ADC0 Negative ADC0 20x Gain"]
        ADC0_ADC1_1X: [8, "Differential Inputs Positive ADC0 Negative ADC1 1x Gain"]
        ADC0_ADC1_20X: [9, "Differential Inputs Postive ADC0 Negative ADC1 20x Gain"]
        ADC0_ADC3_1X: [10, "Differential Inputs Positive ADC0 Negative ADC3 1x Gain"]
        ADC0_ADC3_20X: [11, "Differential Inputs Positive ADC0 Negative ADC3 20x Gain"]

        ADC1_ADC0_1X: [40, "Differential Inputs Positive ADC1 Negative ADC0 1x Gain"]
        ADC1_ADC0_20X: [41, "Differential Inputs Positive ADC1 Negative ADC0 20x Gain"]
        ADC1_ADC2_1X: [12, "Differential Inputs Positive ADC1 Negative ADC2 1x Gain"]
        ADC1_ADC2_20X: [13, "Differential Inputs Positive ADC1 Negative ADC2 20x Gain"]
        ADC1_ADC3_1X: [14, "Differential Inputs Positive ADC1 Negative ADC3 1x Gain"]
        ADC1_ADC3_20X: [15, "Differential Inputs Positive ADC1 Negative ADC3 20x Gain"]

        ADC2_ADC1_1X: [44, "Differential Inputs Positive ADC2 Negative ADC2 1x Gain"]
        ADC2_ADC1_20X: [45, "Differential Inputs Positive ADC2 Negative ADC2 20x Gain"]
        ADC2_ADC3_1X: [16, "Differential Inputs Positive ADC2 Negative ADC3 1x Gain"]
        ADC2_ADC3_20X: [17, "Differential Inputs Positive ADC2 Negative ADC3 20x Gain"]

        ADC3_ADC0_1X: [42, "Differential Inputs Positive ADC3 Negative ADC0 1x Gain"]
        ADC3_ADC0_20X: [43, "Differential Inputs Positive ADC3 Negative ADC0 20x Gain"]
        ADC3_ADC1_1X: [46, "Differential Inputs Positive ADC3 Negative ADC1 1x Gain"]
        ADC3_ADC1_20X: [47, "Differential Inputs Positive ADC3 Negative ADC1 20x Gain"]
        ADC3_ADC2_1X: [48, "Differential Inputs Positive ADC3 Negative ADC2 1x Gain"]
        ADC3_ADC2_20X: [49, "Differential Inputs Positive ADC3 Negative ADC2 20x Gain"]
        ADC3_ADC3_1X: [36, "Differential Inputs Positive ADC3 Negative ADC3 1x Gain"]
        ADC3_ADC3_20X: [37, "Differential Inputs Positive ADC3 Negative ADC3 20x Gain"]
        ADC3_ADC4_1X: [18, "Differential Inputs Positive ADC4 Negative ADC0 1x Gain"]
        ADC3_ADC4_20X: [19, "Differential Inputs Positive ADC4 Negative ADC0 20x Gain"]
        ADC3_ADC5_1X: [20, "Differential Inputs Positive ADC5 Negative ADC1 1x Gain"]
        ADC3_ADC5_20X: [21, "Differential Inputs Positive ADC5 Negative ADC1 20x Gain"]
        ADC3_ADC6_1X: [22, "Differential Inputs Positive ADC6 Negative ADC2 1x Gain"]
        ADC3_ADC6_20X: [23, "Differential Inputs Positive ADC6 Negative ADC2 20x Gain"]
        ADC3_ADC7_1X: [24, "Differential Inputs Positive ADC7 Negative ADC3 1x Gain"]
        ADC3_ADC7_20X: [25, "Differential Inputs Positive ADC7 Negative ADC3 20x Gain"]

        ADC4_ADC3_1X: [50, "Differential Inputs Positive ADC4 Negative ADC3 1x Gain"]
        ADC4_ADC3_20X: [51, "Differential Inputs Positive ADC4 Negative ADC3 20x Gain"]
        ADC4_ADC5_1X: [26, "Differential Inputs Positive ADC4 Negative ADC5 1x Gain"]
        ADC4_ADC5_20X: [27, "Differential Inputs Positive ADC4 Negative ADC5 20x Gain"]

        ADC5_ADC3_1X: [52, "Differential Inputs Positive ADC5 Negative ADC3 1x Gain"]
        ADC5_ADC3_20X: [53, "Differential Inputs Positive ADC5 Negative ADC3 20x Gain"]
        ADC5_ADC4_1X: [58, "Differential Inputs Positive ADC5 Negative ADC4 1x Gain"]
        ADC5_ADC4_20X: [59, "Differential Inputs Positive ADC5 Negative ADC4 20x Gain"]
        ADC5_ADC6_1X: [28, "Differential Inputs Positive ADC5 Negative ADC6 1x Gain"]
        ADC5_ADC6_20X: [29, "Differential Inputs Positive ADC5 Negative ADC6 20x Gain"]

        ADC6_ADC3_1X: [54, "Differential Inputs Positive ADC6 Negative ADC3 1x Gain"]
        ADC6_ADC3_20X: [55, "Differential Inputs Positive ADC6 Negative ADC3 20x Gain"]
        ADC6_ADC5_1X: [60, "Differential Inputs Positive ADC6 Negative ADC5 1x Gain"]
        ADC6_ADC5_20X: [61, "Differential Inputs Positive ADC6 Negative ADC5 20x Gain"]
        ADC6_ADC7_1X: [30, "Differential Inputs Positive ADC6 Negative ADC7 1x Gain"]
        ADC6_ADC7_20X: [31, "Differential Inputs Positive ADC6 Negative ADC7 20x Gain"]

        ADC7_ADC3_1X: [56, "Differential Inputs Positive ADC7 Negative ADC3 1x Gain"]
        ADC7_ADC3_20X: [57, "Differential Inputs Positive ADC7 Negative ADC3 20x Gain"]
        ADC7_ADC6_1X: [62, "Differential Inputs Positive ADC7 Negative ADC6 1x Gain"]
        ADC7_ADC6_20X: [63, "Differential Inputs Positive ADC7 Negative ADC6 20x Gain"]
        ADC7_ADC7_1X: [38, "Differential Inputs Positive ADC7 Negative ADC7 1x Gain"]
        ADC7_ADC7_20X: [39, "Differential Inputs Positive ADC7 Negative ADC7 20x Gain"]
    REFS:
      _write_constraint: enum
      _replace_enum:
        VCC: [0, "Vcc used as Voltage Reference, disconnected from Aref"]
        AREF: [1, "External Voltage Reference at AREF pin, Internal Voltage Reference turned off"]
        INTERNAL: [2, "Internal 1.1V Voltage Reference"]
CPU:
  _modify:
    OSCCAL:
      access: read-write
  CLKPR:
    CLKPS:
      _replace_enum:
        PRESCALER_1: [0, "Prescaler Value 1"]
        PRESCALER_2: [1, "Prescaler Value 2"]
        PRESCALER_4: [2, "Prescaler Value 4"]
        PRESCALER_8: [3, "Prescaler Value 8"]
        PRESCALER_16: [4, "Prescaler Value 16"]
        PRESCALER_32: [5, "Prescaler Value 32"]
        PRESCALER_64: [6, "Prescaler Value 64"]
        PRESCALER_128: [7, "Prescaler Value 128"]
        PRESCALER_256: [8, "Prescaler Value 256"]
  MCUCR:
    _add:
      BODS:
        description: "BOD Sleep (available on some devices)"
        bitOffset: 7
        bitWidth: 1
        access: read-write
      BODSE:
        description: "BOD Sleep Enable (available on some devices)"
        bitOffset: 2
        bitWidth: 1
        access: read-write
  OSCCAL:
    _modify:
      CAL:
        access: read-write
EEPROM:
  EECR:
    EEPM:
      _replace_enum:
        ATOMIC: [0, "Atomic (erase and write in one operation)"]
        ERASE: [1, "Erase only"]
        WRITE: [2, "Write only"]
EXINT:
  _modify:
    GIFR:
      access: read-write
  MCUCR:
    _delete:
      ISC??:
    _add:
      ISC0:
        description: "Interrupt Sense Control 0 bits"
        bitOffset: 0
        bitWidth: 2
        access: read-write
    ISC0:
      _replace_enum:
        LOW: [0, "The low level of INTx generates an interrupt request"]
        TOGGLE: [1, "Any logical change on INTx generates an interrupt request"]
        FALLING: [2, "The falling edge of INTx generates an interrupt request"]
        RISING: [3, "The rising edge of INTx generates an interrupt request"]
USI:
  _modify:
    USISR:
      access: read-write
  USICR:
    _modify:
      USICLK:
        access: write-only
      USITC:
        access: write-only
    USIWM:
      _replace_enum:
        DISABLED:        [0, "All detectors disabled. Port pins operates as normal."]
        THREE_WIRE:      [1, "Three-wire mode. Uses DO, DI, and USCK pins."]
        TWO_WIRE_SLAVE:  [2, "Two-wire mode (Slave). Uses SDA (DI) and SCL (USCK) pins."]
        TWO_WIRE_MASTER: [3, "Two-wire mode (Master). Uses SDA and SCL pins."]
    USICS:
      NO_CLOCK: [0, "No Clock/Software clock strobe"]
      TC0:      [1, "Timer/Counter0 Compare Match"]
      EXT_POS:  [2, "External, positive edge"]
      EXT_NEG:  [3, "External, negative edge"]
  USISR:
    _modify:
      USIDC:
        access: read-only
Do not follow this link