Go to the documentation of this file.00001 #ifndef _ARCH_ARM_AT91_PWMC_H_
00002 #define _ARCH_ARM_AT91_PWMC_H_
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00052
00055 #define PWMC_MR_OFF 0x00000000
00056 #define PWMC_MR (PWMC_BASE + PWMC_MR_OFF)
00058 #define PWMC_DIVA 0x000000FF
00059 #define PWMC_DIVA_LSB 0
00061 #define PWMC_PREA 0x00000F00
00062 #define PWMC_PREA_MCK2 0x00000100
00063 #define PWMC_PREA_MCK4 0x00000200
00064 #define PWMC_PREA_MCK8 0x00000300
00065 #define PWMC_PREA_MCK16 0x00000400
00066 #define PWMC_PREA_MCK32 0x00000500
00067 #define PWMC_PREA_MCK64 0x00000600
00068 #define PWMC_PREA_MCK128 0x00000700
00069 #define PWMC_PREA_MCK256 0x00000800
00070 #define PWMC_PREA_MCK512 0x00000900
00071 #define PWMC_PREA_MCK1024 0x00000A00
00073 #define PWMC_DIVB 0x00FF0000
00074 #define PWMC_DIVB_LSB 16
00076 #define PWMC_PREB 0x0F000000
00077 #define PWMC_PREB_MCK2 0x01000000
00078 #define PWMC_PREB_MCK4 0x02000000
00079 #define PWMC_PREB_MCK8 0x03000000
00080 #define PWMC_PREB_MCK16 0x04000000
00081 #define PWMC_PREB_MCK32 0x05000000
00082 #define PWMC_PREB_MCK64 0x06000000
00083 #define PWMC_PREB_MCK128 0x07000000
00084 #define PWMC_PREB_MCK256 0x08000000
00085 #define PWMC_PREB_MCK512 0x09000000
00086 #define PWMC_PREB_MCK1024 0x0A000000
00088
00089
00091 #define PWMC_ENA_OFF 0x00000004
00092 #define PWMC_ENA (PWMC_BASE + PWMC_ENA_OFF)
00093 #define PWMC_DIS_OFF 0x00000008
00094 #define PWMC_DIS (PWMC_BASE + PWMC_DIS_OFF)
00095 #define PWMC_SR_OFF 0x0000000C
00096 #define PWMC_SR (PWMC_BASE + PWMC_SR_OFF)
00097 #define PWMC_IER_OFF 0x00000010
00098 #define PWMC_IER (PWMC_BASE + PWMC_IER_OFF)
00099 #define PWMC_IDR_OFF 0x00000014
00100 #define PWMC_IDR (PWMC_BASE + PWMC_IDR_OFF)
00101 #define PWMC_IMR_OFF 0x00000018
00102 #define PWMC_IMR (PWMC_BASE + PWMC_IMR_OFF)
00103 #define PWMC_ISR_OFF 0x0000001C
00104 #define PWMC_ISR (PWMC_BASE + PWMC_ISR_OFF)
00105 #define PWMC_CHID0 0x00000001
00106 #define PWMC_CHID1 0x00000002
00107 #define PWMC_CHID2 0x00000004
00108 #define PWMC_CHID3 0x00000008
00110
00111
00113 #define PWMC_CMR_OFF 0x00000200
00115 #define PWMC_CMR(i) (PWMC_BASE + ((i) * 32) + PWMC_CMR_OFF)
00116
00117 #define PWMC_CPRE 0x0000000F
00118 #define PWMC_CPRE_MCK2 0x00000001
00119 #define PWMC_CPRE_MCK4 0x00000002
00120 #define PWMC_CPRE_MCK8 0x00000003
00121 #define PWMC_CPRE_MCK16 0x00000004
00122 #define PWMC_CPRE_MCK32 0x00000005
00123 #define PWMC_CPRE_MCK64 0x00000006
00124 #define PWMC_CPRE_MCK128 0x00000007
00125 #define PWMC_CPRE_MCK256 0x00000008
00126 #define PWMC_CPRE_MCK512 0x00000009
00127 #define PWMC_CPRE_MCK1024 0x0000000A
00128 #define PWMC_CPRE_CLKA 0x0000000B
00129 #define PWMC_CPRE_CLKB 0x0000000C
00131 #define PWMC_CALG 0x00000100
00132 #define PWMC_CPOL 0x00000200
00133 #define PWMC_CPD 0x00000400
00135
00136
00138 #define PWMC_CDTY_OFF 0x00000204
00140 #define PWMC_CDTY(i) (PWMC_BASE + PWMC_CDTY_OFF + ((i) * 32))
00141
00145 #define PWMC_CPRD_OFF 0x00000208
00147 #define PWMC_CPRD(i) (PWMC_BASE + PWMC_CPRD_OFF + ((i) * 32))
00148
00152 #define PWMC_CCNT_OFF 0x0000020C
00154 #define PWMC_CCNT(i) (PWMC_BASE + PWMC_CCNT_OFF + ((i) * 32))
00155
00159 #define PWMC_CUPD_OFF 0x00000210
00161 #define PWMC_CUPD(i) (PWMC_BASE + PWMC_CUPD_OFF + ((i) * 32))
00162
00165
00167 #endif