30 #ifndef _SAM4S_PMC_COMPONENT_ 31 #define _SAM4S_PMC_COMPONENT_ 39 #if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) 79 #define PMC_SCER_UDP (0x1u << 7) 80 #define PMC_SCER_PCK0 (0x1u << 8) 81 #define PMC_SCER_PCK1 (0x1u << 9) 82 #define PMC_SCER_PCK2 (0x1u << 10) 84 #define PMC_SCDR_UDP (0x1u << 7) 85 #define PMC_SCDR_PCK0 (0x1u << 8) 86 #define PMC_SCDR_PCK1 (0x1u << 9) 87 #define PMC_SCDR_PCK2 (0x1u << 10) 89 #define PMC_SCSR_UDP (0x1u << 7) 90 #define PMC_SCSR_PCK0 (0x1u << 8) 91 #define PMC_SCSR_PCK1 (0x1u << 9) 92 #define PMC_SCSR_PCK2 (0x1u << 10) 94 #define PMC_PCER0_PID2 (0x1u << 2) 95 #define PMC_PCER0_PID3 (0x1u << 3) 96 #define PMC_PCER0_PID4 (0x1u << 4) 97 #define PMC_PCER0_PID5 (0x1u << 5) 98 #define PMC_PCER0_PID6 (0x1u << 6) 99 #define PMC_PCER0_PID7 (0x1u << 7) 100 #define PMC_PCER0_PID8 (0x1u << 8) 101 #define PMC_PCER0_PID9 (0x1u << 9) 102 #define PMC_PCER0_PID10 (0x1u << 10) 103 #define PMC_PCER0_PID11 (0x1u << 11) 104 #define PMC_PCER0_PID12 (0x1u << 12) 105 #define PMC_PCER0_PID13 (0x1u << 13) 106 #define PMC_PCER0_PID14 (0x1u << 14) 107 #define PMC_PCER0_PID15 (0x1u << 15) 108 #define PMC_PCER0_PID16 (0x1u << 16) 109 #define PMC_PCER0_PID17 (0x1u << 17) 110 #define PMC_PCER0_PID18 (0x1u << 18) 111 #define PMC_PCER0_PID19 (0x1u << 19) 112 #define PMC_PCER0_PID20 (0x1u << 20) 113 #define PMC_PCER0_PID21 (0x1u << 21) 114 #define PMC_PCER0_PID22 (0x1u << 22) 115 #define PMC_PCER0_PID23 (0x1u << 23) 116 #define PMC_PCER0_PID24 (0x1u << 24) 117 #define PMC_PCER0_PID25 (0x1u << 25) 118 #define PMC_PCER0_PID26 (0x1u << 26) 119 #define PMC_PCER0_PID27 (0x1u << 27) 120 #define PMC_PCER0_PID28 (0x1u << 28) 121 #define PMC_PCER0_PID29 (0x1u << 29) 122 #define PMC_PCER0_PID30 (0x1u << 30) 123 #define PMC_PCER0_PID31 (0x1u << 31) 125 #define PMC_PCDR0_PID2 (0x1u << 2) 126 #define PMC_PCDR0_PID3 (0x1u << 3) 127 #define PMC_PCDR0_PID4 (0x1u << 4) 128 #define PMC_PCDR0_PID5 (0x1u << 5) 129 #define PMC_PCDR0_PID6 (0x1u << 6) 130 #define PMC_PCDR0_PID7 (0x1u << 7) 131 #define PMC_PCDR0_PID8 (0x1u << 8) 132 #define PMC_PCDR0_PID9 (0x1u << 9) 133 #define PMC_PCDR0_PID10 (0x1u << 10) 134 #define PMC_PCDR0_PID11 (0x1u << 11) 135 #define PMC_PCDR0_PID12 (0x1u << 12) 136 #define PMC_PCDR0_PID13 (0x1u << 13) 137 #define PMC_PCDR0_PID14 (0x1u << 14) 138 #define PMC_PCDR0_PID15 (0x1u << 15) 139 #define PMC_PCDR0_PID16 (0x1u << 16) 140 #define PMC_PCDR0_PID17 (0x1u << 17) 141 #define PMC_PCDR0_PID18 (0x1u << 18) 142 #define PMC_PCDR0_PID19 (0x1u << 19) 143 #define PMC_PCDR0_PID20 (0x1u << 20) 144 #define PMC_PCDR0_PID21 (0x1u << 21) 145 #define PMC_PCDR0_PID22 (0x1u << 22) 146 #define PMC_PCDR0_PID23 (0x1u << 23) 147 #define PMC_PCDR0_PID24 (0x1u << 24) 148 #define PMC_PCDR0_PID25 (0x1u << 25) 149 #define PMC_PCDR0_PID26 (0x1u << 26) 150 #define PMC_PCDR0_PID27 (0x1u << 27) 151 #define PMC_PCDR0_PID28 (0x1u << 28) 152 #define PMC_PCDR0_PID29 (0x1u << 29) 153 #define PMC_PCDR0_PID30 (0x1u << 30) 154 #define PMC_PCDR0_PID31 (0x1u << 31) 156 #define PMC_PCSR0_PID2 (0x1u << 2) 157 #define PMC_PCSR0_PID3 (0x1u << 3) 158 #define PMC_PCSR0_PID4 (0x1u << 4) 159 #define PMC_PCSR0_PID5 (0x1u << 5) 160 #define PMC_PCSR0_PID6 (0x1u << 6) 161 #define PMC_PCSR0_PID7 (0x1u << 7) 162 #define PMC_PCSR0_PID8 (0x1u << 8) 163 #define PMC_PCSR0_PID9 (0x1u << 9) 164 #define PMC_PCSR0_PID10 (0x1u << 10) 165 #define PMC_PCSR0_PID11 (0x1u << 11) 166 #define PMC_PCSR0_PID12 (0x1u << 12) 167 #define PMC_PCSR0_PID13 (0x1u << 13) 168 #define PMC_PCSR0_PID14 (0x1u << 14) 169 #define PMC_PCSR0_PID15 (0x1u << 15) 170 #define PMC_PCSR0_PID16 (0x1u << 16) 171 #define PMC_PCSR0_PID17 (0x1u << 17) 172 #define PMC_PCSR0_PID18 (0x1u << 18) 173 #define PMC_PCSR0_PID19 (0x1u << 19) 174 #define PMC_PCSR0_PID20 (0x1u << 20) 175 #define PMC_PCSR0_PID21 (0x1u << 21) 176 #define PMC_PCSR0_PID22 (0x1u << 22) 177 #define PMC_PCSR0_PID23 (0x1u << 23) 178 #define PMC_PCSR0_PID24 (0x1u << 24) 179 #define PMC_PCSR0_PID25 (0x1u << 25) 180 #define PMC_PCSR0_PID26 (0x1u << 26) 181 #define PMC_PCSR0_PID27 (0x1u << 27) 182 #define PMC_PCSR0_PID28 (0x1u << 28) 183 #define PMC_PCSR0_PID29 (0x1u << 29) 184 #define PMC_PCSR0_PID30 (0x1u << 30) 185 #define PMC_PCSR0_PID31 (0x1u << 31) 187 #define CKGR_MOR_MOSCXTEN (0x1u << 0) 188 #define CKGR_MOR_MOSCXTBY (0x1u << 1) 189 #define CKGR_MOR_WAITMODE (0x1u << 2) 190 #define CKGR_MOR_MOSCRCEN (0x1u << 3) 191 #define CKGR_MOR_MOSCRCF_Pos 4 192 #define CKGR_MOR_MOSCRCF_Msk (0x7u << CKGR_MOR_MOSCRCF_Pos) 193 #define CKGR_MOR_MOSCRCF_4_MHz (0x0u << 4) 194 #define CKGR_MOR_MOSCRCF_8_MHz (0x1u << 4) 195 #define CKGR_MOR_MOSCRCF_12_MHz (0x2u << 4) 196 #define CKGR_MOR_MOSCXTST_Pos 8 197 #define CKGR_MOR_MOSCXTST_Msk (0xffu << CKGR_MOR_MOSCXTST_Pos) 198 #define CKGR_MOR_MOSCXTST(value) ((CKGR_MOR_MOSCXTST_Msk & ((value) << CKGR_MOR_MOSCXTST_Pos))) 199 #define CKGR_MOR_KEY_Pos 16 200 #define CKGR_MOR_KEY_Msk (0xffu << CKGR_MOR_KEY_Pos) 201 #define CKGR_MOR_KEY(value) ((CKGR_MOR_KEY_Msk & ((value) << CKGR_MOR_KEY_Pos))) 202 #define CKGR_MOR_MOSCSEL (0x1u << 24) 203 #define CKGR_MOR_CFDEN (0x1u << 25) 205 #define CKGR_MCFR_MAINF_Pos 0 206 #define CKGR_MCFR_MAINF_Msk (0xffffu << CKGR_MCFR_MAINF_Pos) 207 #define CKGR_MCFR_MAINF(value) ((CKGR_MCFR_MAINF_Msk & ((value) << CKGR_MCFR_MAINF_Pos))) 208 #define CKGR_MCFR_MAINFRDY (0x1u << 16) 209 #define CKGR_MCFR_RCMEAS (0x1u << 20) 211 #define CKGR_PLLAR_DIVA_Pos 0 212 #define CKGR_PLLAR_DIVA_Msk (0xffu << CKGR_PLLAR_DIVA_Pos) 213 #define CKGR_PLLAR_DIVA(value) ((CKGR_PLLAR_DIVA_Msk & ((value) << CKGR_PLLAR_DIVA_Pos))) 214 #define CKGR_PLLAR_PLLACOUNT_Pos 8 215 #define CKGR_PLLAR_PLLACOUNT_Msk (0x3fu << CKGR_PLLAR_PLLACOUNT_Pos) 216 #define CKGR_PLLAR_PLLACOUNT(value) ((CKGR_PLLAR_PLLACOUNT_Msk & ((value) << CKGR_PLLAR_PLLACOUNT_Pos))) 217 #define CKGR_PLLAR_MULA_Pos 16 218 #define CKGR_PLLAR_MULA_Msk (0x7ffu << CKGR_PLLAR_MULA_Pos) 219 #define CKGR_PLLAR_MULA(value) ((CKGR_PLLAR_MULA_Msk & ((value) << CKGR_PLLAR_MULA_Pos))) 220 #define CKGR_PLLAR_ONE (0x1u << 29) 222 #define CKGR_PLLBR_DIVB_Pos 0 223 #define CKGR_PLLBR_DIVB_Msk (0xffu << CKGR_PLLBR_DIVB_Pos) 224 #define CKGR_PLLBR_DIVB(value) ((CKGR_PLLBR_DIVB_Msk & ((value) << CKGR_PLLBR_DIVB_Pos))) 225 #define CKGR_PLLBR_PLLBCOUNT_Pos 8 226 #define CKGR_PLLBR_PLLBCOUNT_Msk (0x3fu << CKGR_PLLBR_PLLBCOUNT_Pos) 227 #define CKGR_PLLBR_PLLBCOUNT(value) ((CKGR_PLLBR_PLLBCOUNT_Msk & ((value) << CKGR_PLLBR_PLLBCOUNT_Pos))) 228 #define CKGR_PLLBR_MULB_Pos 16 229 #define CKGR_PLLBR_MULB_Msk (0x7ffu << CKGR_PLLBR_MULB_Pos) 230 #define CKGR_PLLBR_MULB(value) ((CKGR_PLLBR_MULB_Msk & ((value) << CKGR_PLLBR_MULB_Pos))) 232 #define PMC_MCKR_CSS_Pos 0 233 #define PMC_MCKR_CSS_Msk (0x3u << PMC_MCKR_CSS_Pos) 234 #define PMC_MCKR_CSS_SLOW_CLK (0x0u << 0) 235 #define PMC_MCKR_CSS_MAIN_CLK (0x1u << 0) 236 #define PMC_MCKR_CSS_PLLA_CLK (0x2u << 0) 237 #define PMC_MCKR_CSS_PLLB_CLK (0x3u << 0) 238 #define PMC_MCKR_PRES_Pos 4 239 #define PMC_MCKR_PRES_Msk (0x7u << PMC_MCKR_PRES_Pos) 240 #define PMC_MCKR_PRES_CLK_1 (0x0u << 4) 241 #define PMC_MCKR_PRES_CLK_2 (0x1u << 4) 242 #define PMC_MCKR_PRES_CLK_4 (0x2u << 4) 243 #define PMC_MCKR_PRES_CLK_8 (0x3u << 4) 244 #define PMC_MCKR_PRES_CLK_16 (0x4u << 4) 245 #define PMC_MCKR_PRES_CLK_32 (0x5u << 4) 246 #define PMC_MCKR_PRES_CLK_64 (0x6u << 4) 247 #define PMC_MCKR_PRES_CLK_3 (0x7u << 4) 248 #define PMC_MCKR_PLLADIV2 (0x1u << 12) 249 #define PMC_MCKR_PLLBDIV2 (0x1u << 13) 251 #define PMC_USB_USBS (0x1u << 0) 252 #define PMC_USB_USBDIV_Pos 8 253 #define PMC_USB_USBDIV_Msk (0xfu << PMC_USB_USBDIV_Pos) 254 #define PMC_USB_USBDIV(value) ((PMC_USB_USBDIV_Msk & ((value) << PMC_USB_USBDIV_Pos))) 256 #define PMC_PCK_CSS_Pos 0 257 #define PMC_PCK_CSS_Msk (0x7u << PMC_PCK_CSS_Pos) 258 #define PMC_PCK_CSS_SLOW_CLK (0x0u << 0) 259 #define PMC_PCK_CSS_MAIN_CLK (0x1u << 0) 260 #define PMC_PCK_CSS_PLLA_CLK (0x2u << 0) 261 #define PMC_PCK_CSS_PLLB_CLK (0x3u << 0) 262 #define PMC_PCK_CSS_MCK (0x4u << 0) 263 #define PMC_PCK_PRES_Pos 4 264 #define PMC_PCK_PRES_Msk (0x7u << PMC_PCK_PRES_Pos) 265 #define PMC_PCK_PRES_CLK_1 (0x0u << 4) 266 #define PMC_PCK_PRES_CLK_2 (0x1u << 4) 267 #define PMC_PCK_PRES_CLK_4 (0x2u << 4) 268 #define PMC_PCK_PRES_CLK_8 (0x3u << 4) 269 #define PMC_PCK_PRES_CLK_16 (0x4u << 4) 270 #define PMC_PCK_PRES_CLK_32 (0x5u << 4) 271 #define PMC_PCK_PRES_CLK_64 (0x6u << 4) 273 #define PMC_IER_MOSCXTS (0x1u << 0) 274 #define PMC_IER_LOCKA (0x1u << 1) 275 #define PMC_IER_LOCKB (0x1u << 2) 276 #define PMC_IER_MCKRDY (0x1u << 3) 277 #define PMC_IER_PCKRDY0 (0x1u << 8) 278 #define PMC_IER_PCKRDY1 (0x1u << 9) 279 #define PMC_IER_PCKRDY2 (0x1u << 10) 280 #define PMC_IER_MOSCSELS (0x1u << 16) 281 #define PMC_IER_MOSCRCS (0x1u << 17) 282 #define PMC_IER_CFDEV (0x1u << 18) 284 #define PMC_IDR_MOSCXTS (0x1u << 0) 285 #define PMC_IDR_LOCKA (0x1u << 1) 286 #define PMC_IDR_LOCKB (0x1u << 2) 287 #define PMC_IDR_MCKRDY (0x1u << 3) 288 #define PMC_IDR_PCKRDY0 (0x1u << 8) 289 #define PMC_IDR_PCKRDY1 (0x1u << 9) 290 #define PMC_IDR_PCKRDY2 (0x1u << 10) 291 #define PMC_IDR_MOSCSELS (0x1u << 16) 292 #define PMC_IDR_MOSCRCS (0x1u << 17) 293 #define PMC_IDR_CFDEV (0x1u << 18) 295 #define PMC_SR_MOSCXTS (0x1u << 0) 296 #define PMC_SR_LOCKA (0x1u << 1) 297 #define PMC_SR_LOCKB (0x1u << 2) 298 #define PMC_SR_MCKRDY (0x1u << 3) 299 #define PMC_SR_OSCSELS (0x1u << 7) 300 #define PMC_SR_PCKRDY0 (0x1u << 8) 301 #define PMC_SR_PCKRDY1 (0x1u << 9) 302 #define PMC_SR_PCKRDY2 (0x1u << 10) 303 #define PMC_SR_MOSCSELS (0x1u << 16) 304 #define PMC_SR_MOSCRCS (0x1u << 17) 305 #define PMC_SR_CFDEV (0x1u << 18) 306 #define PMC_SR_CFDS (0x1u << 19) 307 #define PMC_SR_FOS (0x1u << 20) 309 #define PMC_IMR_MOSCXTS (0x1u << 0) 310 #define PMC_IMR_LOCKA (0x1u << 1) 311 #define PMC_IMR_LOCKB (0x1u << 2) 312 #define PMC_IMR_MCKRDY (0x1u << 3) 313 #define PMC_IMR_PCKRDY0 (0x1u << 8) 314 #define PMC_IMR_PCKRDY1 (0x1u << 9) 315 #define PMC_IMR_PCKRDY2 (0x1u << 10) 316 #define PMC_IMR_MOSCSELS (0x1u << 16) 317 #define PMC_IMR_MOSCRCS (0x1u << 17) 318 #define PMC_IMR_CFDEV (0x1u << 18) 320 #define PMC_FSMR_FSTT0 (0x1u << 0) 321 #define PMC_FSMR_FSTT1 (0x1u << 1) 322 #define PMC_FSMR_FSTT2 (0x1u << 2) 323 #define PMC_FSMR_FSTT3 (0x1u << 3) 324 #define PMC_FSMR_FSTT4 (0x1u << 4) 325 #define PMC_FSMR_FSTT5 (0x1u << 5) 326 #define PMC_FSMR_FSTT6 (0x1u << 6) 327 #define PMC_FSMR_FSTT7 (0x1u << 7) 328 #define PMC_FSMR_FSTT8 (0x1u << 8) 329 #define PMC_FSMR_FSTT9 (0x1u << 9) 330 #define PMC_FSMR_FSTT10 (0x1u << 10) 331 #define PMC_FSMR_FSTT11 (0x1u << 11) 332 #define PMC_FSMR_FSTT12 (0x1u << 12) 333 #define PMC_FSMR_FSTT13 (0x1u << 13) 334 #define PMC_FSMR_FSTT14 (0x1u << 14) 335 #define PMC_FSMR_FSTT15 (0x1u << 15) 336 #define PMC_FSMR_RTTAL (0x1u << 16) 337 #define PMC_FSMR_RTCAL (0x1u << 17) 338 #define PMC_FSMR_USBAL (0x1u << 18) 339 #define PMC_FSMR_FLPM_Pos 21 340 #define PMC_FSMR_FLPM_Msk (0x3u << PMC_FSMR_FLPM_Pos) 341 #define PMC_FSMR_FLPM_FLASH_STANDBY (0x0u << 21) 342 #define PMC_FSMR_FLPM_FLASH_DEEP_POWERDOWN (0x1u << 21) 343 #define PMC_FSMR_FLPM_FLASH_IDLE (0x2u << 21) 345 #define PMC_FSPR_FSTP0 (0x1u << 0) 346 #define PMC_FSPR_FSTP1 (0x1u << 1) 347 #define PMC_FSPR_FSTP2 (0x1u << 2) 348 #define PMC_FSPR_FSTP3 (0x1u << 3) 349 #define PMC_FSPR_FSTP4 (0x1u << 4) 350 #define PMC_FSPR_FSTP5 (0x1u << 5) 351 #define PMC_FSPR_FSTP6 (0x1u << 6) 352 #define PMC_FSPR_FSTP7 (0x1u << 7) 353 #define PMC_FSPR_FSTP8 (0x1u << 8) 354 #define PMC_FSPR_FSTP9 (0x1u << 9) 355 #define PMC_FSPR_FSTP10 (0x1u << 10) 356 #define PMC_FSPR_FSTP11 (0x1u << 11) 357 #define PMC_FSPR_FSTP12 (0x1u << 12) 358 #define PMC_FSPR_FSTP13 (0x1u << 13) 359 #define PMC_FSPR_FSTP14 (0x1u << 14) 360 #define PMC_FSPR_FSTP15 (0x1u << 15) 362 #define PMC_FOCR_FOCLR (0x1u << 0) 364 #define PMC_WPMR_WPEN (0x1u << 0) 365 #define PMC_WPMR_WPKEY_Pos 8 366 #define PMC_WPMR_WPKEY_Msk (0xffffffu << PMC_WPMR_WPKEY_Pos) 367 #define PMC_WPMR_WPKEY(value) ((PMC_WPMR_WPKEY_Msk & ((value) << PMC_WPMR_WPKEY_Pos))) 369 #define PMC_WPSR_WPVS (0x1u << 0) 370 #define PMC_WPSR_WPVSRC_Pos 8 371 #define PMC_WPSR_WPVSRC_Msk (0xffffu << PMC_WPSR_WPVSRC_Pos) 373 #define PMC_PCER1_PID32 (0x1u << 0) 374 #define PMC_PCER1_PID33 (0x1u << 1) 375 #define PMC_PCER1_PID34 (0x1u << 2) 377 #define PMC_PCDR1_PID32 (0x1u << 0) 378 #define PMC_PCDR1_PID33 (0x1u << 1) 379 #define PMC_PCDR1_PID34 (0x1u << 2) 381 #define PMC_PCSR1_PID32 (0x1u << 0) 382 #define PMC_PCSR1_PID33 (0x1u << 1) 383 #define PMC_PCSR1_PID34 (0x1u << 2) 385 #define PMC_OCR_CAL4_Pos 0 386 #define PMC_OCR_CAL4_Msk (0x7fu << PMC_OCR_CAL4_Pos) 387 #define PMC_OCR_CAL4(value) ((PMC_OCR_CAL4_Msk & ((value) << PMC_OCR_CAL4_Pos))) 388 #define PMC_OCR_SEL4 (0x1u << 7) 389 #define PMC_OCR_CAL8_Pos 8 390 #define PMC_OCR_CAL8_Msk (0x7fu << PMC_OCR_CAL8_Pos) 391 #define PMC_OCR_CAL8(value) ((PMC_OCR_CAL8_Msk & ((value) << PMC_OCR_CAL8_Pos))) 392 #define PMC_OCR_SEL8 (0x1u << 15) 393 #define PMC_OCR_CAL12_Pos 16 394 #define PMC_OCR_CAL12_Msk (0x7fu << PMC_OCR_CAL12_Pos) 395 #define PMC_OCR_CAL12(value) ((PMC_OCR_CAL12_Msk & ((value) << PMC_OCR_CAL12_Pos))) 396 #define PMC_OCR_SEL12 (0x1u << 23) volatile uint32_t RwReg
Definition: sam3n00a.h:54
volatile uint32_t WoReg
Definition: sam3n00a.h:53
volatile const uint32_t RoReg
Definition: sam3n00a.h:49
Pmc hardware registers.
Definition: component_pmc.h:41