#include typedef struct { uint32_t comp1_en : 1; // 0 Comparator 1 enable bit uint32_t reserve0 : 3; // 1 Reserve uint32_t comp1_inmsel: 4; // 4 Comparator 1 Input Minus connection configuration bit uint32_t comp1_inpsel: 2; // 8 Comparator1 input plus selection bit uint32_t reserve1 : 1; // 10 Reserve uint32_t comp1_winmode: 1; // 11 COMP1_WINMODE uint32_t reserve2 : 2; // 12 Reserve uint32_t comp1_winout: 1; // 14 COMP1_WINOUT uint32_t comp1_polarity: 1; // 15 Comparator 1 polarity selection bit uint32_t comp1_hyst: 2; // 16 Comparator 1 hysteresis selection bits uint32_t comp1_pwrmode: 2; // 18 COMP1_PWRMODE uint32_t comp1_blanksel: 5; // 20 COMP1_BLANKSEL uint32_t reserve3 : 5; // 25 Reserve uint32_t comp1_value: 1; // 30 Comparator 1 output status bit uint32_t comp1_lock: 1; // 31 COMP1_CSR register lock bit } reg_comp__csr_t; typedef struct { uint32_t com2_en : 1; // 0 Comparator 2 enable bit uint32_t reserve0 : 3; // 1 Reserve uint32_t com2_inmsel: 4; // 4 Comparator 2 Input Minus connection configuration bit uint32_t com2_inpsel: 2; // 8 Comparator 2 input plus selection bit uint32_t reserve1 : 1; // 10 Reserve uint32_t com2_winmode: 1; // 11 COM2_WINMODE uint32_t reserve2 : 2; // 12 Reserve uint32_t com2_winout: 1; // 14 COM2_WINOUT uint32_t com2_polarity: 1; // 15 Comparator 2 polarity selection bit uint32_t com2_hyst : 2; // 16 Comparator 2 hysteresis selection bits uint32_t com2_pwrmode: 2; // 18 COM2_PWRMODE uint32_t com2_blanksel: 5; // 20 COM2_BLANKSEL uint32_t reserve3 : 5; // 25 Reserve uint32_t com2_value: 1; // 30 Comparator 2 output status bit uint32_t com2_lock : 1; // 31 COMP2_CSR register lock bit } reg_comp__csr_t; typedef struct { volatile reg_comp__csr_t _csr; volatile reg_comp__csr_t _csr; } reg_comp_t;