30 #ifndef _SAM3U_ADC12B_COMPONENT_ 31 #define _SAM3U_ADC12B_COMPONENT_ 39 #if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) 69 #define ADC12B_CR_SWRST (0x1u << 0) 70 #define ADC12B_CR_START (0x1u << 1) 72 #define ADC12B_MR_TRGEN (0x1u << 0) 73 #define ADC12B_MR_TRGEN_DIS (0x0u << 0) 74 #define ADC12B_MR_TRGEN_EN (0x1u << 0) 75 #define ADC12B_MR_TRGSEL_Pos 1 76 #define ADC12B_MR_TRGSEL_Msk (0x7u << ADC12B_MR_TRGSEL_Pos) 77 #define ADC12B_MR_TRGSEL(value) ((ADC12B_MR_TRGSEL_Msk & ((value) << ADC12B_MR_TRGSEL_Pos))) 78 #define ADC12B_MR_TRGSEL_ADC_TRIG0 (0x0u << 1) 79 #define ADC12B_MR_TRGSEL_ADC_TRIG1 (0x1u << 1) 80 #define ADC12B_MR_TRGSEL_ADC_TRIG2 (0x2u << 1) 81 #define ADC12B_MR_TRGSEL_ADC_TRIG3 (0x3u << 1) 82 #define ADC12B_MR_TRGSEL_ADC_TRIG4 (0x4u << 1) 83 #define ADC12B_MR_TRGSEL_ADC_TRIG5 (0x5u << 1) 84 #define ADC12B_MR_LOWRES (0x1u << 4) 85 #define ADC12B_MR_LOWRES_BITS_12 (0x0u << 4) 86 #define ADC12B_MR_LOWRES_BITS_10 (0x1u << 4) 87 #define ADC12B_MR_SLEEP (0x1u << 5) 88 #define ADC12B_MR_SLEEP_NORMAL (0x0u << 5) 89 #define ADC12B_MR_SLEEP_SLEEP (0x1u << 5) 90 #define ADC12B_MR_PRESCAL_Pos 8 91 #define ADC12B_MR_PRESCAL_Msk (0xffu << ADC12B_MR_PRESCAL_Pos) 92 #define ADC12B_MR_PRESCAL(value) ((ADC12B_MR_PRESCAL_Msk & ((value) << ADC12B_MR_PRESCAL_Pos))) 93 #define ADC12B_MR_STARTUP_Pos 16 94 #define ADC12B_MR_STARTUP_Msk (0xffu << ADC12B_MR_STARTUP_Pos) 95 #define ADC12B_MR_STARTUP(value) ((ADC12B_MR_STARTUP_Msk & ((value) << ADC12B_MR_STARTUP_Pos))) 96 #define ADC12B_MR_SHTIM_Pos 24 97 #define ADC12B_MR_SHTIM_Msk (0xfu << ADC12B_MR_SHTIM_Pos) 98 #define ADC12B_MR_SHTIM(value) ((ADC12B_MR_SHTIM_Msk & ((value) << ADC12B_MR_SHTIM_Pos))) 100 #define ADC12B_CHER_CH0 (0x1u << 0) 101 #define ADC12B_CHER_CH1 (0x1u << 1) 102 #define ADC12B_CHER_CH2 (0x1u << 2) 103 #define ADC12B_CHER_CH3 (0x1u << 3) 104 #define ADC12B_CHER_CH4 (0x1u << 4) 105 #define ADC12B_CHER_CH5 (0x1u << 5) 106 #define ADC12B_CHER_CH6 (0x1u << 6) 107 #define ADC12B_CHER_CH7 (0x1u << 7) 109 #define ADC12B_CHDR_CH0 (0x1u << 0) 110 #define ADC12B_CHDR_CH1 (0x1u << 1) 111 #define ADC12B_CHDR_CH2 (0x1u << 2) 112 #define ADC12B_CHDR_CH3 (0x1u << 3) 113 #define ADC12B_CHDR_CH4 (0x1u << 4) 114 #define ADC12B_CHDR_CH5 (0x1u << 5) 115 #define ADC12B_CHDR_CH6 (0x1u << 6) 116 #define ADC12B_CHDR_CH7 (0x1u << 7) 118 #define ADC12B_CHSR_CH0 (0x1u << 0) 119 #define ADC12B_CHSR_CH1 (0x1u << 1) 120 #define ADC12B_CHSR_CH2 (0x1u << 2) 121 #define ADC12B_CHSR_CH3 (0x1u << 3) 122 #define ADC12B_CHSR_CH4 (0x1u << 4) 123 #define ADC12B_CHSR_CH5 (0x1u << 5) 124 #define ADC12B_CHSR_CH6 (0x1u << 6) 125 #define ADC12B_CHSR_CH7 (0x1u << 7) 127 #define ADC12B_SR_EOC0 (0x1u << 0) 128 #define ADC12B_SR_EOC1 (0x1u << 1) 129 #define ADC12B_SR_EOC2 (0x1u << 2) 130 #define ADC12B_SR_EOC3 (0x1u << 3) 131 #define ADC12B_SR_EOC4 (0x1u << 4) 132 #define ADC12B_SR_EOC5 (0x1u << 5) 133 #define ADC12B_SR_EOC6 (0x1u << 6) 134 #define ADC12B_SR_EOC7 (0x1u << 7) 135 #define ADC12B_SR_OVRE0 (0x1u << 8) 136 #define ADC12B_SR_OVRE1 (0x1u << 9) 137 #define ADC12B_SR_OVRE2 (0x1u << 10) 138 #define ADC12B_SR_OVRE3 (0x1u << 11) 139 #define ADC12B_SR_OVRE4 (0x1u << 12) 140 #define ADC12B_SR_OVRE5 (0x1u << 13) 141 #define ADC12B_SR_OVRE6 (0x1u << 14) 142 #define ADC12B_SR_OVRE7 (0x1u << 15) 143 #define ADC12B_SR_DRDY (0x1u << 16) 144 #define ADC12B_SR_GOVRE (0x1u << 17) 145 #define ADC12B_SR_ENDRX (0x1u << 18) 146 #define ADC12B_SR_RXBUFF (0x1u << 19) 148 #define ADC12B_LCDR_LDATA_Pos 0 149 #define ADC12B_LCDR_LDATA_Msk (0xfffu << ADC12B_LCDR_LDATA_Pos) 151 #define ADC12B_IER_EOC0 (0x1u << 0) 152 #define ADC12B_IER_EOC1 (0x1u << 1) 153 #define ADC12B_IER_EOC2 (0x1u << 2) 154 #define ADC12B_IER_EOC3 (0x1u << 3) 155 #define ADC12B_IER_EOC4 (0x1u << 4) 156 #define ADC12B_IER_EOC5 (0x1u << 5) 157 #define ADC12B_IER_EOC6 (0x1u << 6) 158 #define ADC12B_IER_EOC7 (0x1u << 7) 159 #define ADC12B_IER_OVRE0 (0x1u << 8) 160 #define ADC12B_IER_OVRE1 (0x1u << 9) 161 #define ADC12B_IER_OVRE2 (0x1u << 10) 162 #define ADC12B_IER_OVRE3 (0x1u << 11) 163 #define ADC12B_IER_OVRE4 (0x1u << 12) 164 #define ADC12B_IER_OVRE5 (0x1u << 13) 165 #define ADC12B_IER_OVRE6 (0x1u << 14) 166 #define ADC12B_IER_OVRE7 (0x1u << 15) 167 #define ADC12B_IER_DRDY (0x1u << 16) 168 #define ADC12B_IER_GOVRE (0x1u << 17) 169 #define ADC12B_IER_ENDRX (0x1u << 18) 170 #define ADC12B_IER_RXBUFF (0x1u << 19) 172 #define ADC12B_IDR_EOC0 (0x1u << 0) 173 #define ADC12B_IDR_EOC1 (0x1u << 1) 174 #define ADC12B_IDR_EOC2 (0x1u << 2) 175 #define ADC12B_IDR_EOC3 (0x1u << 3) 176 #define ADC12B_IDR_EOC4 (0x1u << 4) 177 #define ADC12B_IDR_EOC5 (0x1u << 5) 178 #define ADC12B_IDR_EOC6 (0x1u << 6) 179 #define ADC12B_IDR_EOC7 (0x1u << 7) 180 #define ADC12B_IDR_OVRE0 (0x1u << 8) 181 #define ADC12B_IDR_OVRE1 (0x1u << 9) 182 #define ADC12B_IDR_OVRE2 (0x1u << 10) 183 #define ADC12B_IDR_OVRE3 (0x1u << 11) 184 #define ADC12B_IDR_OVRE4 (0x1u << 12) 185 #define ADC12B_IDR_OVRE5 (0x1u << 13) 186 #define ADC12B_IDR_OVRE6 (0x1u << 14) 187 #define ADC12B_IDR_OVRE7 (0x1u << 15) 188 #define ADC12B_IDR_DRDY (0x1u << 16) 189 #define ADC12B_IDR_GOVRE (0x1u << 17) 190 #define ADC12B_IDR_ENDRX (0x1u << 18) 191 #define ADC12B_IDR_RXBUFF (0x1u << 19) 193 #define ADC12B_IMR_EOC0 (0x1u << 0) 194 #define ADC12B_IMR_EOC1 (0x1u << 1) 195 #define ADC12B_IMR_EOC2 (0x1u << 2) 196 #define ADC12B_IMR_EOC3 (0x1u << 3) 197 #define ADC12B_IMR_EOC4 (0x1u << 4) 198 #define ADC12B_IMR_EOC5 (0x1u << 5) 199 #define ADC12B_IMR_EOC6 (0x1u << 6) 200 #define ADC12B_IMR_EOC7 (0x1u << 7) 201 #define ADC12B_IMR_OVRE0 (0x1u << 8) 202 #define ADC12B_IMR_OVRE1 (0x1u << 9) 203 #define ADC12B_IMR_OVRE2 (0x1u << 10) 204 #define ADC12B_IMR_OVRE3 (0x1u << 11) 205 #define ADC12B_IMR_OVRE4 (0x1u << 12) 206 #define ADC12B_IMR_OVRE5 (0x1u << 13) 207 #define ADC12B_IMR_OVRE6 (0x1u << 14) 208 #define ADC12B_IMR_OVRE7 (0x1u << 15) 209 #define ADC12B_IMR_DRDY (0x1u << 16) 210 #define ADC12B_IMR_GOVRE (0x1u << 17) 211 #define ADC12B_IMR_ENDRX (0x1u << 18) 212 #define ADC12B_IMR_RXBUFF (0x1u << 19) 214 #define ADC12B_CDR_DATA_Pos 0 215 #define ADC12B_CDR_DATA_Msk (0xfffu << ADC12B_CDR_DATA_Pos) 217 #define ADC12B_ACR_GAIN_Pos 0 218 #define ADC12B_ACR_GAIN_Msk (0x3u << ADC12B_ACR_GAIN_Pos) 219 #define ADC12B_ACR_GAIN(value) ((ADC12B_ACR_GAIN_Msk & ((value) << ADC12B_ACR_GAIN_Pos))) 220 #define ADC12B_ACR_IBCTL_Pos 8 221 #define ADC12B_ACR_IBCTL_Msk (0x3u << ADC12B_ACR_IBCTL_Pos) 222 #define ADC12B_ACR_IBCTL(value) ((ADC12B_ACR_IBCTL_Msk & ((value) << ADC12B_ACR_IBCTL_Pos))) 223 #define ADC12B_ACR_DIFF (0x1u << 16) 224 #define ADC12B_ACR_OFFSET (0x1u << 17) 226 #define ADC12B_EMR_OFFMODES (0x1u << 0) 227 #define ADC12B_EMR_OFF_MODE_STARTUP_TIME_Pos 16 228 #define ADC12B_EMR_OFF_MODE_STARTUP_TIME_Msk (0xffu << ADC12B_EMR_OFF_MODE_STARTUP_TIME_Pos) 229 #define ADC12B_EMR_OFF_MODE_STARTUP_TIME(value) ((ADC12B_EMR_OFF_MODE_STARTUP_TIME_Msk & ((value) << ADC12B_EMR_OFF_MODE_STARTUP_TIME_Pos))) 231 #define ADC12B_RPR_RXPTR_Pos 0 232 #define ADC12B_RPR_RXPTR_Msk (0xffffffffu << ADC12B_RPR_RXPTR_Pos) 233 #define ADC12B_RPR_RXPTR(value) ((ADC12B_RPR_RXPTR_Msk & ((value) << ADC12B_RPR_RXPTR_Pos))) 235 #define ADC12B_RCR_RXCTR_Pos 0 236 #define ADC12B_RCR_RXCTR_Msk (0xffffu << ADC12B_RCR_RXCTR_Pos) 237 #define ADC12B_RCR_RXCTR(value) ((ADC12B_RCR_RXCTR_Msk & ((value) << ADC12B_RCR_RXCTR_Pos))) 239 #define ADC12B_RNPR_RXNPTR_Pos 0 240 #define ADC12B_RNPR_RXNPTR_Msk (0xffffffffu << ADC12B_RNPR_RXNPTR_Pos) 241 #define ADC12B_RNPR_RXNPTR(value) ((ADC12B_RNPR_RXNPTR_Msk & ((value) << ADC12B_RNPR_RXNPTR_Pos))) 243 #define ADC12B_RNCR_RXNCTR_Pos 0 244 #define ADC12B_RNCR_RXNCTR_Msk (0xffffu << ADC12B_RNCR_RXNCTR_Pos) 245 #define ADC12B_RNCR_RXNCTR(value) ((ADC12B_RNCR_RXNCTR_Msk & ((value) << ADC12B_RNCR_RXNCTR_Pos))) 247 #define ADC12B_PTCR_RXTEN (0x1u << 0) 248 #define ADC12B_PTCR_RXTDIS (0x1u << 1) 249 #define ADC12B_PTCR_TXTEN (0x1u << 8) 250 #define ADC12B_PTCR_TXTDIS (0x1u << 9) 252 #define ADC12B_PTSR_RXTEN (0x1u << 0) 253 #define ADC12B_PTSR_TXTEN (0x1u << 8) RwReg ADC12B_MR
(Adc12b Offset: 0x04) Mode Register
Definition: component_adc12b.h:43
WoReg ADC12B_IER
(Adc12b Offset: 0x24) Interrupt Enable Register
Definition: component_adc12b.h:50
RoReg ADC12B_IMR
(Adc12b Offset: 0x2C) Interrupt Mask Register
Definition: component_adc12b.h:52
RoReg ADC12B_CHSR
(Adc12b Offset: 0x18) Channel Status Register
Definition: component_adc12b.h:47
volatile uint32_t RwReg
Definition: sam3n00a.h:54
WoReg ADC12B_IDR
(Adc12b Offset: 0x28) Interrupt Disable Register
Definition: component_adc12b.h:51
RoReg ADC12B_PTSR
(Adc12b Offset: 0x124) Transfer Status Register
Definition: component_adc12b.h:65
WoReg ADC12B_CHER
(Adc12b Offset: 0x10) Channel Enable Register
Definition: component_adc12b.h:45
volatile uint32_t WoReg
Definition: sam3n00a.h:53
RwReg ADC12B_RPR
(Adc12b Offset: 0x100) Receive Pointer Register
Definition: component_adc12b.h:58
RwReg ADC12B_ACR
(Adc12b Offset: 0x64) Analog Control Register
Definition: component_adc12b.h:55
RwReg ADC12B_RNCR
(Adc12b Offset: 0x114) Receive Next Counter Register
Definition: component_adc12b.h:62
RwReg ADC12B_RNPR
(Adc12b Offset: 0x110) Receive Next Pointer Register
Definition: component_adc12b.h:61
Adc12b hardware registers.
Definition: component_adc12b.h:41
RwReg ADC12B_RCR
(Adc12b Offset: 0x104) Receive Counter Register
Definition: component_adc12b.h:59
RwReg ADC12B_EMR
(Adc12b Offset: 0x68) Extended Mode Register
Definition: component_adc12b.h:56
RoReg ADC12B_SR
(Adc12b Offset: 0x1C) Status Register
Definition: component_adc12b.h:48
volatile const uint32_t RoReg
Definition: sam3n00a.h:49
WoReg ADC12B_PTCR
(Adc12b Offset: 0x120) Transfer Control Register
Definition: component_adc12b.h:64
WoReg ADC12B_CHDR
(Adc12b Offset: 0x14) Channel Disable Register
Definition: component_adc12b.h:46
WoReg ADC12B_CR
(Adc12b Offset: 0x00) Control Register
Definition: component_adc12b.h:42
RoReg ADC12B_LCDR
(Adc12b Offset: 0x20) Last Converted Data Register
Definition: component_adc12b.h:49