00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #define TIMER0_PRESCALER_DIV_0 0
00029 #define TIMER0_PRESCALER_DIV_1 1
00030 #define TIMER0_PRESCALER_DIV_8 2
00031 #define TIMER0_PRESCALER_DIV_64 3
00032 #define TIMER0_PRESCALER_DIV_256 4
00033 #define TIMER0_PRESCALER_DIV_1024 5
00034 #define TIMER0_PRESCALER_DIV_FALL 6
00035 #define TIMER0_PRESCALER_DIV_RISE 7
00036
00037 #define TIMER0_PRESCALER_REG_0 0
00038 #define TIMER0_PRESCALER_REG_1 1
00039 #define TIMER0_PRESCALER_REG_2 8
00040 #define TIMER0_PRESCALER_REG_3 64
00041 #define TIMER0_PRESCALER_REG_4 256
00042 #define TIMER0_PRESCALER_REG_5 1024
00043 #define TIMER0_PRESCALER_REG_6 -1
00044 #define TIMER0_PRESCALER_REG_7 -2
00045
00046
00047 #define TIMER1_PRESCALER_DIV_0 0
00048 #define TIMER1_PRESCALER_DIV_1 1
00049 #define TIMER1_PRESCALER_DIV_2 2
00050 #define TIMER1_PRESCALER_DIV_4 3
00051 #define TIMER1_PRESCALER_DIV_8 4
00052 #define TIMER1_PRESCALER_DIV_16 5
00053 #define TIMER1_PRESCALER_DIV_32 6
00054 #define TIMER1_PRESCALER_DIV_64 7
00055 #define TIMER1_PRESCALER_DIV_128 8
00056 #define TIMER1_PRESCALER_DIV_256 9
00057 #define TIMER1_PRESCALER_DIV_512 10
00058 #define TIMER1_PRESCALER_DIV_1024 11
00059 #define TIMER1_PRESCALER_DIV_2048 12
00060 #define TIMER1_PRESCALER_DIV_4096 13
00061 #define TIMER1_PRESCALER_DIV_8192 14
00062 #define TIMER1_PRESCALER_DIV_16384 15
00063
00064 #define TIMER1_PRESCALER_REG_0 0
00065 #define TIMER1_PRESCALER_REG_1 1
00066 #define TIMER1_PRESCALER_REG_2 2
00067 #define TIMER1_PRESCALER_REG_3 4
00068 #define TIMER1_PRESCALER_REG_4 8
00069 #define TIMER1_PRESCALER_REG_5 16
00070 #define TIMER1_PRESCALER_REG_6 32
00071 #define TIMER1_PRESCALER_REG_7 64
00072 #define TIMER1_PRESCALER_REG_8 128
00073 #define TIMER1_PRESCALER_REG_9 256
00074 #define TIMER1_PRESCALER_REG_10 512
00075 #define TIMER1_PRESCALER_REG_11 1024
00076 #define TIMER1_PRESCALER_REG_12 2048
00077 #define TIMER1_PRESCALER_REG_13 4096
00078 #define TIMER1_PRESCALER_REG_14 8192
00079 #define TIMER1_PRESCALER_REG_15 16384
00080
00081
00082
00083 #define TIMER0_AVAILABLE
00084 #define TIMER0A_AVAILABLE
00085 #define TIMER0B_AVAILABLE
00086 #define TIMER1_AVAILABLE
00087 #define TIMER1A_AVAILABLE
00088 #define TIMER1B_AVAILABLE
00089
00090
00091 #define SIG_OVERFLOW0_NUM 0
00092 #define SIG_OVERFLOW1_NUM 1
00093 #define SIG_OVERFLOW_TOTAL_NUM 2
00094
00095
00096 #define SIG_OUTPUT_COMPARE0A_NUM 0
00097 #define SIG_OUTPUT_COMPARE0B_NUM 1
00098 #define SIG_OUTPUT_COMPARE1A_NUM 2
00099 #define SIG_OUTPUT_COMPARE1B_NUM 3
00100 #define SIG_OUTPUT_COMPARE_TOTAL_NUM 4
00101
00102
00103 #define PWM0A_NUM 0
00104 #define PWM0B_NUM 1
00105 #define PWM1A_NUM 2
00106 #define PWM1B_NUM 3
00107 #define PWM_TOTAL_NUM 4
00108
00109
00110 #define SIG_INPUT_CAPTURE_TOTAL_NUM 0
00111
00112
00113
00114 #define CLKPS0_REG CLKPR
00115 #define CLKPS1_REG CLKPR
00116 #define CLKPS2_REG CLKPR
00117 #define CLKPS3_REG CLKPR
00118 #define CLKPCE_REG CLKPR
00119
00120
00121 #define WDP0_REG WDTCR
00122 #define WDP1_REG WDTCR
00123 #define WDP2_REG WDTCR
00124 #define WDE_REG WDTCR
00125 #define WDCE_REG WDTCR
00126 #define WDP3_REG WDTCR
00127 #define WDIE_REG WDTCR
00128 #define WDIF_REG WDTCR
00129
00130
00131 #define PCIE_REG GIMSK
00132 #define INT0_REG GIMSK
00133
00134
00135 #define AIN0D_REG DIDR0
00136 #define AIN1D_REG DIDR0
00137 #define ADC1D_REG DIDR0
00138 #define ADC3D_REG DIDR0
00139 #define ADC2D_REG DIDR0
00140 #define ADC0D_REG DIDR0
00141
00142
00143 #define MUX0_REG ADMUX
00144 #define MUX1_REG ADMUX
00145 #define MUX2_REG ADMUX
00146 #define MUX3_REG ADMUX
00147 #define REFS2_REG ADMUX
00148 #define ADLAR_REG ADMUX
00149 #define REFS0_REG ADMUX
00150 #define REFS1_REG ADMUX
00151
00152
00153 #define CS10_REG TCCR1
00154 #define CS11_REG TCCR1
00155 #define CS12_REG TCCR1
00156 #define CS13_REG TCCR1
00157 #define COM1A0_REG TCCR1
00158 #define COM1A1_REG TCCR1
00159 #define PWM1A_REG TCCR1
00160 #define CTC1_REG TCCR1
00161
00162
00163 #define C_REG SREG
00164 #define Z_REG SREG
00165 #define N_REG SREG
00166 #define V_REG SREG
00167 #define S_REG SREG
00168 #define H_REG SREG
00169 #define T_REG SREG
00170 #define I_REG SREG
00171
00172
00173 #define DDB0_REG DDRB
00174 #define DDB1_REG DDRB
00175 #define DDB2_REG DDRB
00176 #define DDB3_REG DDRB
00177 #define DDB4_REG DDRB
00178 #define DDB5_REG DDRB
00179
00180
00181 #define EEDR0_REG EEDR
00182 #define EEDR1_REG EEDR
00183 #define EEDR2_REG EEDR
00184 #define EEDR3_REG EEDR
00185 #define EEDR4_REG EEDR
00186 #define EEDR5_REG EEDR
00187 #define EEDR6_REG EEDR
00188 #define EEDR7_REG EEDR
00189
00190
00191 #define ISC00_REG MCUCR
00192 #define ISC01_REG MCUCR
00193 #define SM0_REG MCUCR
00194 #define SM1_REG MCUCR
00195 #define SE_REG MCUCR
00196 #define PUD_REG MCUCR
00197
00198
00199 #define PSR0_REG GTCCR
00200 #define TSM_REG GTCCR
00201 #define PSR1_REG GTCCR
00202 #define FOC1A_REG GTCCR
00203 #define FOC1B_REG GTCCR
00204 #define COM1B0_REG GTCCR
00205 #define COM1B1_REG GTCCR
00206 #define PWM1B_REG GTCCR
00207
00208
00209 #define DTPS0_REG DTPS
00210 #define DTPS1_REG DTPS
00211
00212
00213 #define PCIF_REG GIFR
00214 #define INTF0_REG GIFR
00215
00216
00217 #define TOIE0_REG TIMSK
00218 #define OCIE0B_REG TIMSK
00219 #define OCIE0A_REG TIMSK
00220 #define TOIE1_REG TIMSK
00221 #define OCIE1B_REG TIMSK
00222 #define OCIE1A_REG TIMSK
00223
00224
00225 #define ADPS0_REG ADCSRA
00226 #define ADPS1_REG ADCSRA
00227 #define ADPS2_REG ADCSRA
00228 #define ADIE_REG ADCSRA
00229 #define ADIF_REG ADCSRA
00230 #define ADATE_REG ADCSRA
00231 #define ADSC_REG ADCSRA
00232 #define ADEN_REG ADCSRA
00233
00234
00235
00236
00237
00238
00239
00240
00241
00242
00243
00244
00245
00246
00247
00248
00249
00250
00251
00252
00253
00254
00255
00256
00257
00258
00259
00260
00261
00262
00263
00264
00265 #define SP8_REG SPH
00266 #define SP9_REG SPH
00267
00268
00269 #define SP0_REG SPL
00270 #define SP1_REG SPL
00271 #define SP2_REG SPL
00272 #define SP3_REG SPL
00273 #define SP4_REG SPL
00274 #define SP5_REG SPL
00275 #define SP6_REG SPL
00276 #define SP7_REG SPL
00277
00278
00279 #define PRADC_REG PRR
00280 #define PRUSI_REG PRR
00281 #define PRTIM0_REG PRR
00282 #define PRTIM1_REG PRR
00283
00284
00285 #define GPIOR10_REG GPIOR1
00286 #define GPIOR11_REG GPIOR1
00287 #define GPIOR12_REG GPIOR1
00288 #define GPIOR13_REG GPIOR1
00289 #define GPIOR14_REG GPIOR1
00290 #define GPIOR15_REG GPIOR1
00291 #define GPIOR16_REG GPIOR1
00292 #define GPIOR17_REG GPIOR1
00293
00294
00295 #define GPIOR00_REG GPIOR0
00296 #define GPIOR01_REG GPIOR0
00297 #define GPIOR02_REG GPIOR0
00298 #define GPIOR03_REG GPIOR0
00299 #define GPIOR04_REG GPIOR0
00300 #define GPIOR05_REG GPIOR0
00301 #define GPIOR06_REG GPIOR0
00302 #define GPIOR07_REG GPIOR0
00303
00304
00305 #define GPIOR20_REG GPIOR2
00306 #define GPIOR21_REG GPIOR2
00307 #define GPIOR22_REG GPIOR2
00308 #define GPIOR23_REG GPIOR2
00309 #define GPIOR24_REG GPIOR2
00310 #define GPIOR25_REG GPIOR2
00311 #define GPIOR26_REG GPIOR2
00312 #define GPIOR27_REG GPIOR2
00313
00314
00315 #define PORF_REG MCUSR
00316 #define EXTRF_REG MCUSR
00317 #define BORF_REG MCUSR
00318 #define WDRF_REG MCUSR
00319
00320
00321 #define EERE_REG EECR
00322 #define EEPE_REG EECR
00323 #define EEMPE_REG EECR
00324 #define EERIE_REG EECR
00325 #define EEPM0_REG EECR
00326 #define EEPM1_REG EECR
00327
00328
00329 #define PCINT0_REG PCMSK
00330 #define PCINT1_REG PCMSK
00331 #define PCINT2_REG PCMSK
00332 #define PCINT3_REG PCMSK
00333 #define PCINT4_REG PCMSK
00334 #define PCINT5_REG PCMSK
00335
00336
00337 #define SPMEN_REG SPMCSR
00338 #define PGERS_REG SPMCSR
00339 #define PGWRT_REG SPMCSR
00340 #define RFLB_REG SPMCSR
00341 #define CTPB_REG SPMCSR
00342
00343
00344 #define CAL0_REG OSCCAL
00345 #define CAL1_REG OSCCAL
00346 #define CAL2_REG OSCCAL
00347 #define CAL3_REG OSCCAL
00348 #define CAL4_REG OSCCAL
00349 #define CAL5_REG OSCCAL
00350 #define CAL6_REG OSCCAL
00351 #define CAL7_REG OSCCAL
00352
00353
00354 #define ADCL0_REG ADCL
00355 #define ADCL1_REG ADCL
00356 #define ADCL2_REG ADCL
00357 #define ADCL3_REG ADCL
00358 #define ADCL4_REG ADCL
00359 #define ADCL5_REG ADCL
00360 #define ADCL6_REG ADCL
00361 #define ADCL7_REG ADCL
00362
00363
00364 #define USICNT0_REG USISR
00365 #define USICNT1_REG USISR
00366 #define USICNT2_REG USISR
00367 #define USICNT3_REG USISR
00368 #define USIDC_REG USISR
00369 #define USIPF_REG USISR
00370 #define USIOIF_REG USISR
00371 #define USISIF_REG USISR
00372
00373
00374 #define PORTB0_REG PORTB
00375 #define PORTB1_REG PORTB
00376 #define PORTB2_REG PORTB
00377 #define PORTB3_REG PORTB
00378 #define PORTB4_REG PORTB
00379 #define PORTB5_REG PORTB
00380
00381
00382 #define ADCH0_REG ADCH
00383 #define ADCH1_REG ADCH
00384 #define ADCH2_REG ADCH
00385 #define ADCH3_REG ADCH
00386 #define ADCH4_REG ADCH
00387 #define ADCH5_REG ADCH
00388 #define ADCH6_REG ADCH
00389 #define ADCH7_REG ADCH
00390
00391
00392 #define TCNT0_0_REG TCNT0
00393 #define TCNT0_1_REG TCNT0
00394 #define TCNT0_2_REG TCNT0
00395 #define TCNT0_3_REG TCNT0
00396 #define TCNT0_4_REG TCNT0
00397 #define TCNT0_5_REG TCNT0
00398 #define TCNT0_6_REG TCNT0
00399 #define TCNT0_7_REG TCNT0
00400
00401
00402 #define TCNT1_0_REG TCNT1
00403 #define TCNT1_1_REG TCNT1
00404 #define TCNT1_2_REG TCNT1
00405 #define TCNT1_3_REG TCNT1
00406 #define TCNT1_4_REG TCNT1
00407 #define TCNT1_5_REG TCNT1
00408 #define TCNT1_6_REG TCNT1
00409 #define TCNT1_7_REG TCNT1
00410
00411
00412 #define CS00_REG TCCR0B
00413 #define CS01_REG TCCR0B
00414 #define CS02_REG TCCR0B
00415 #define WGM02_REG TCCR0B
00416 #define FOC0B_REG TCCR0B
00417 #define FOC0A_REG TCCR0B
00418
00419
00420 #define TOV0_REG TIFR
00421 #define OCF0B_REG TIFR
00422 #define OCF0A_REG TIFR
00423 #define TOV1_REG TIFR
00424 #define OCF1B_REG TIFR
00425 #define OCF1A_REG TIFR
00426
00427
00428 #define WGM00_REG TCCR0A
00429 #define WGM01_REG TCCR0A
00430 #define COM0B0_REG TCCR0A
00431 #define COM0B1_REG TCCR0A
00432 #define COM0A0_REG TCCR0A
00433 #define COM0A1_REG TCCR0A
00434
00435
00436 #define EEAR8_REG EEARH
00437
00438
00439 #define PLOCK_REG PLLCSR
00440 #define PLLE_REG PLLCSR
00441 #define PCKE_REG PLLCSR
00442 #define LSM_REG PLLCSR
00443
00444
00445 #define USITC_REG USICR
00446 #define USICLK_REG USICR
00447 #define USICS0_REG USICR
00448 #define USICS1_REG USICR
00449 #define USIWM0_REG USICR
00450 #define USIWM1_REG USICR
00451 #define USIOIE_REG USICR
00452 #define USISIE_REG USICR
00453
00454
00455 #define EEAR0_REG EEARL
00456 #define EEAR1_REG EEARL
00457 #define EEAR2_REG EEARL
00458 #define EEAR3_REG EEARL
00459 #define EEAR4_REG EEARL
00460 #define EEAR5_REG EEARL
00461 #define EEAR6_REG EEARL
00462 #define EEAR7_REG EEARL
00463
00464
00465 #define DWDR0_REG DWDR
00466 #define DWDR1_REG DWDR
00467 #define DWDR2_REG DWDR
00468 #define DWDR3_REG DWDR
00469 #define DWDR4_REG DWDR
00470 #define DWDR5_REG DWDR
00471 #define DWDR6_REG DWDR
00472 #define DWDR7_REG DWDR
00473
00474
00475 #define ACME_REG ADCSRB
00476 #define ADTS0_REG ADCSRB
00477 #define ADTS1_REG ADCSRB
00478 #define ADTS2_REG ADCSRB
00479 #define IPR_REG ADCSRB
00480 #define BIN_REG ADCSRB
00481
00482
00483 #define OCR1B0_REG OCR1B
00484 #define OCR1B1_REG OCR1B
00485 #define OCR1B2_REG OCR1B
00486 #define OCR1B3_REG OCR1B
00487 #define OCR1B4_REG OCR1B
00488 #define OCR1B5_REG OCR1B
00489 #define OCR1B6_REG OCR1B
00490 #define OCR1B7_REG OCR1B
00491
00492
00493 #define OCR1C0_REG OCR1C
00494 #define OCR1C1_REG OCR1C
00495 #define OCR1C2_REG OCR1C
00496 #define OCR1C3_REG OCR1C
00497 #define OCR1C4_REG OCR1C
00498 #define OCR1C5_REG OCR1C
00499 #define OCR1C6_REG OCR1C
00500 #define OCR1C7_REG OCR1C
00501
00502
00503
00504
00505
00506
00507
00508
00509
00510
00511
00512
00513 #define OCR1A0_REG OCR1A
00514 #define OCR1A1_REG OCR1A
00515 #define OCR1A2_REG OCR1A
00516 #define OCR1A3_REG OCR1A
00517 #define OCR1A4_REG OCR1A
00518 #define OCR1A5_REG OCR1A
00519 #define OCR1A6_REG OCR1A
00520 #define OCR1A7_REG OCR1A
00521
00522
00523 #define ACIS0_REG ACSR
00524 #define ACIS1_REG ACSR
00525 #define ACIE_REG ACSR
00526 #define ACI_REG ACSR
00527 #define ACO_REG ACSR
00528 #define ACBG_REG ACSR
00529 #define ACD_REG ACSR
00530
00531
00532 #define PINB0_REG PINB
00533 #define PINB1_REG PINB
00534 #define PINB2_REG PINB
00535 #define PINB3_REG PINB
00536 #define PINB4_REG PINB
00537 #define PINB5_REG PINB
00538
00539
00540 #define USIBR0_REG USIBR
00541 #define USIBR1_REG USIBR
00542 #define USIBR2_REG USIBR
00543 #define USIBR3_REG USIBR
00544 #define USIBR4_REG USIBR
00545 #define USIBR5_REG USIBR
00546 #define USIBR6_REG USIBR
00547 #define USIBR7_REG USIBR
00548
00549
00550 #define USIDR0_REG USIDR
00551 #define USIDR1_REG USIDR
00552 #define USIDR2_REG USIDR
00553 #define USIDR3_REG USIDR
00554 #define USIDR4_REG USIDR
00555 #define USIDR5_REG USIDR
00556 #define USIDR6_REG USIDR
00557 #define USIDR7_REG USIDR
00558
00559
00560 #define MOSI_PORT PORTB
00561 #define MOSI_BIT 0
00562 #define DI_PORT PORTB
00563 #define DI_BIT 0
00564 #define SDA_PORT PORTB
00565 #define SDA_BIT 0
00566 #define AIN0_PORT PORTB
00567 #define AIN0_BIT 0
00568 #define OC0A_PORT PORTB
00569 #define OC0A_BIT 0
00570 #define OC1A_PORT PORTB
00571 #define OC1A_BIT 0
00572 #define AREF_PORT PORTB
00573 #define AREF_BIT 0
00574 #define PCINT0_PORT PORTB
00575 #define PCINT0_BIT 0
00576
00577 #define MISO_PORT PORTB
00578 #define MISO_BIT 1
00579 #define DO_PORT PORTB
00580 #define DO_BIT 1
00581 #define AIN1_PORT PORTB
00582 #define AIN1_BIT 1
00583 #define OC0B_PORT PORTB
00584 #define OC0B_BIT 1
00585 #define OC1A_PORT PORTB
00586 #define OC1A_BIT 1
00587 #define PCINT1_PORT PORTB
00588 #define PCINT1_BIT 1
00589
00590 #define SCK_PORT PORTB
00591 #define SCK_BIT 2
00592 #define USCK_PORT PORTB
00593 #define USCK_BIT 2
00594 #define SCL_PORT PORTB
00595 #define SCL_BIT 2
00596 #define ADC1_PORT PORTB
00597 #define ADC1_BIT 2
00598 #define T0_PORT PORTB
00599 #define T0_BIT 2
00600 #define INT0_PORT PORTB
00601 #define INT0_BIT 2
00602 #define PCINT2_PORT PORTB
00603 #define PCINT2_BIT 2
00604
00605 #define ADC3_PORT PORTB
00606 #define ADC3_BIT 3
00607 #define OC1B_PORT PORTB
00608 #define OC1B_BIT 3
00609 #define XTAL1_PORT PORTB
00610 #define XTAL1_BIT 3
00611 #define PCINT4_PORT PORTB
00612 #define PCINT4_BIT 3
00613
00614 #define ADC2_PORT PORTB
00615 #define ADC2_BIT 4
00616 #define OC1B_PORT PORTB
00617 #define OC1B_BIT 4
00618 #define XTAL2_PORT PORTB
00619 #define XTAL2_BIT 4
00620 #define PCINT3_PORT PORTB
00621 #define PCINT3_BIT 4
00622
00623 #define RESET_PORT PORTB
00624 #define RESET_BIT 5
00625 #define ADC0_PORT PORTB
00626 #define ADC0_BIT 5
00627 #define PCINT5_PORT PORTB
00628 #define PCINT5_BIT 5
00629 #define dW_PORT PORTB
00630 #define dW_BIT 5
00631
00632