mirror of
https://github.com/espressif/esp-idf.git
synced 2025-09-30 19:19:21 +00:00
systimer: refactor hal to accomodate more xtal choices
This commit is contained in:
@@ -151,6 +151,10 @@ config SOC_SDM_SUPPORTED
|
||||
bool
|
||||
default y
|
||||
|
||||
config SOC_SYSTIMER_SUPPORTED
|
||||
bool
|
||||
default y
|
||||
|
||||
config SOC_SUPPORT_COEXISTENCE
|
||||
bool
|
||||
default y
|
||||
@@ -683,10 +687,6 @@ config SOC_SPIRAM_SUPPORTED
|
||||
bool
|
||||
default y
|
||||
|
||||
config SOC_SYSTIMER_SUPPORTED
|
||||
bool
|
||||
default y
|
||||
|
||||
config SOC_SYSTIMER_COUNTER_NUM
|
||||
int
|
||||
default 2
|
||||
@@ -703,7 +703,7 @@ config SOC_SYSTIMER_BIT_WIDTH_HI
|
||||
int
|
||||
default 20
|
||||
|
||||
config SOC_SYSTIMER_HAS_FIXED_TICKS_PER_US
|
||||
config SOC_SYSTIMER_FIXED_DIVIDER
|
||||
bool
|
||||
default y
|
||||
|
||||
|
@@ -52,6 +52,7 @@
|
||||
#define SOC_I2S_SUPPORTED 1
|
||||
#define SOC_RMT_SUPPORTED 1
|
||||
#define SOC_SDM_SUPPORTED 1
|
||||
#define SOC_SYSTIMER_SUPPORTED 1
|
||||
#define SOC_SUPPORT_COEXISTENCE 1
|
||||
#define SOC_TEMP_SENSOR_SUPPORTED 1
|
||||
#define SOC_AES_SUPPORTED 1
|
||||
@@ -282,14 +283,13 @@
|
||||
#define SOC_SPIRAM_SUPPORTED 1
|
||||
|
||||
/*-------------------------- SYS TIMER CAPS ----------------------------------*/
|
||||
#define SOC_SYSTIMER_SUPPORTED 1
|
||||
#define SOC_SYSTIMER_COUNTER_NUM (2) // Number of counter units
|
||||
#define SOC_SYSTIMER_ALARM_NUM (3) // Number of alarm units
|
||||
#define SOC_SYSTIMER_BIT_WIDTH_LO (32) // Bit width of systimer low part
|
||||
#define SOC_SYSTIMER_BIT_WIDTH_HI (20) // Bit width of systimer high part
|
||||
#define SOC_SYSTIMER_HAS_FIXED_TICKS_PER_US (1) // Number of ticks per microsecond is fixed (16 ticks/us)
|
||||
#define SOC_SYSTIMER_INT_LEVEL (1) // Systimer peripheral uses level
|
||||
#define SOC_SYSTIMER_ALARM_MISS_COMPENSATE (1) // Systimer peripheral can generate interrupt immediately if t(target) > t(current)
|
||||
#define SOC_SYSTIMER_COUNTER_NUM 2 // Number of counter units
|
||||
#define SOC_SYSTIMER_ALARM_NUM 3 // Number of alarm units
|
||||
#define SOC_SYSTIMER_BIT_WIDTH_LO 32 // Bit width of systimer low part
|
||||
#define SOC_SYSTIMER_BIT_WIDTH_HI 20 // Bit width of systimer high part
|
||||
#define SOC_SYSTIMER_FIXED_DIVIDER 1 // Clock source divider is fixed: 2.5
|
||||
#define SOC_SYSTIMER_INT_LEVEL 1 // Systimer peripheral uses level
|
||||
#define SOC_SYSTIMER_ALARM_MISS_COMPENSATE 1 // Systimer peripheral can generate interrupt immediately if t(target) > t(current)
|
||||
|
||||
/*-------------------------- TIMER GROUP CAPS --------------------------------*/
|
||||
#define SOC_TIMER_GROUPS (2)
|
||||
|
@@ -357,7 +357,7 @@ typedef union {
|
||||
} systimer_date_reg_t;
|
||||
|
||||
|
||||
typedef struct {
|
||||
typedef struct systimer_dev_t {
|
||||
volatile systimer_conf_reg_t conf;
|
||||
volatile systimer_unit_op_reg_t unit_op[2];
|
||||
volatile systimer_unit_load_val_reg_t unit_load_val[2];
|
||||
|
Reference in New Issue
Block a user