Microchip AVR8 用のライブラリを自作する。(TCA)

TCAはシングルモードのみの対応。引数を省略したbegin()呼び出し(標準動作モード)時のみ起動時からの経過時間取得(read)と任意時間による割込み(interrupt)に対応している。

HW割込みを使うには、
[avr8_config.h] #define CONFIG_TCA_ISR 1
の設定が必要となる。

【サンプルコード (Microchip Studio)】

【ライブラリ】

【関連投稿】
Microchip AVR8 用のライブラリを自作する。(GPIO)
Microchip AVR8 用のライブラリを自作する。(FUSE)
Microchip AVR8 用のライブラリを自作する。(CLOCK)
Microchip AVR8 用のライブラリを自作する。(RESET)
Microchip AVR8 用のライブラリを自作する。(PORTMUX)
Microchip AVR8 用のライブラリを自作する。(USART)
Microchip AVR8 用のライブラリを自作する。(RTC)
Microchip AVR8 用のライブラリを自作する。(TCA)
Microchip AVR8 用のライブラリを自作する。(TCB)
Microchip AVR8 用のライブラリを自作する。(VREF)
Microchip AVR8 用のライブラリを自作する。(DAC)
Microchip AVR8 用のライブラリを自作する。(AC)
Microchip AVR8 用のライブラリを自作する。(ADC)
Microchip AVR8 用のライブラリを自作する。(ZCD)
Microchip AVR8 用のライブラリを自作する。(SPI)
Microchip AVR8 用のライブラリを自作する。(TWI)
Microchip AVR8 用のライブラリを自作する。(YIELD)
Microchip AVR8 用のライブラリを自作する。(CONFIG)