EasyManua.ls Logo

Espressif ESP32-S2 - Page 258

Espressif ESP32-S2
1695 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Chapter 2. API Reference
Header File
components/hal/include/hal/timer_types.h
Structures
struct timer_config_t
Data structure with timers configuration settings.
Public Members
timer_alarm_t alarm_en
Timer alarm enable
timer_start_t counter_en
Counter enable
timer_intr_mode_t intr_type
Interrupt mode
timer_count_dir_t counter_dir
Counter direction
timer_autoreload_t auto_reload
Timer auto-reload
uint32_t divider
Counter clock divider. The dividers range is from from 2 to 65536.
timer_src_clk_t clk_src
Use XTAL as source clock.
Enumerations
enum timer_group_t
Selects a Timer-Group out of 2 available groups.
Values:
TIMER_GROUP_0 = 0
Hw timer group 0
TIMER_GROUP_1 = 1
Hw timer group 1
TIMER_GROUP_MAX
enum timer_idx_t
Select a hardware timer from timer groups.
Values:
TIMER_0 = 0
Select timer0 of GROUPx
TIMER_1 = 1
Select timer1 of GROUPx
TIMER_MAX
enum timer_count_dir_t
Decides the direction of counter.
Values:
TIMER_COUNT_DOWN = 0
Descending Count from cnt.high|cnt.low
Espressif Systems 247
Submit Document Feedback
Release v4.4

Table of Contents