Robobo
instance_pwm.h
1 /* ----------------------------------------------------------------------------
2  * SAM Software Package License
3  * ----------------------------------------------------------------------------
4  * Copyright (c) 2012, Atmel Corporation
5  *
6  * All rights reserved.
7  *
8  * Redistribution and use in source and binary forms, with or without
9  * modification, are permitted provided that the following condition is met:
10  *
11  * - Redistributions of source code must retain the above copyright notice,
12  * this list of conditions and the disclaimer below.
13  *
14  * Atmel's name may not be used to endorse or promote products derived from
15  * this software without specific prior written permission.
16  *
17  * DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR
18  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
19  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE
20  * DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT,
21  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
22  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
23  * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
24  * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
25  * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
26  * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27  * ----------------------------------------------------------------------------
28  */
29 
30 #ifndef _SAM3U_PWM_INSTANCE_
31 #define _SAM3U_PWM_INSTANCE_
32 
33 /* ========== Register definition for PWM peripheral ========== */
34 #if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__))
35 #define REG_PWM_CLK (0x4008C000U)
36 #define REG_PWM_ENA (0x4008C004U)
37 #define REG_PWM_DIS (0x4008C008U)
38 #define REG_PWM_SR (0x4008C00CU)
39 #define REG_PWM_IER1 (0x4008C010U)
40 #define REG_PWM_IDR1 (0x4008C014U)
41 #define REG_PWM_IMR1 (0x4008C018U)
42 #define REG_PWM_ISR1 (0x4008C01CU)
43 #define REG_PWM_SCM (0x4008C020U)
44 #define REG_PWM_SCUC (0x4008C028U)
45 #define REG_PWM_SCUP (0x4008C02CU)
46 #define REG_PWM_SCUPUPD (0x4008C030U)
47 #define REG_PWM_IER2 (0x4008C034U)
48 #define REG_PWM_IDR2 (0x4008C038U)
49 #define REG_PWM_IMR2 (0x4008C03CU)
50 #define REG_PWM_ISR2 (0x4008C040U)
51 #define REG_PWM_OOV (0x4008C044U)
52 #define REG_PWM_OS (0x4008C048U)
53 #define REG_PWM_OSS (0x4008C04CU)
54 #define REG_PWM_OSC (0x4008C050U)
55 #define REG_PWM_OSSUPD (0x4008C054U)
56 #define REG_PWM_OSCUPD (0x4008C058U)
57 #define REG_PWM_FMR (0x4008C05CU)
58 #define REG_PWM_FSR (0x4008C060U)
59 #define REG_PWM_FCR (0x4008C064U)
60 #define REG_PWM_FPV (0x4008C068U)
61 #define REG_PWM_FPE (0x4008C06CU)
62 #define REG_PWM_ELMR (0x4008C07CU)
63 #define REG_PWM_WPCR (0x4008C0E4U)
64 #define REG_PWM_WPSR (0x4008C0E8U)
65 #define REG_PWM_TPR (0x4008C108U)
66 #define REG_PWM_TCR (0x4008C10CU)
67 #define REG_PWM_TNPR (0x4008C118U)
68 #define REG_PWM_TNCR (0x4008C11CU)
69 #define REG_PWM_PTCR (0x4008C120U)
70 #define REG_PWM_PTSR (0x4008C124U)
71 #define REG_PWM_CMPV0 (0x4008C130U)
72 #define REG_PWM_CMPVUPD0 (0x4008C134U)
73 #define REG_PWM_CMPM0 (0x4008C138U)
74 #define REG_PWM_CMPMUPD0 (0x4008C13CU)
75 #define REG_PWM_CMPV1 (0x4008C140U)
76 #define REG_PWM_CMPVUPD1 (0x4008C144U)
77 #define REG_PWM_CMPM1 (0x4008C148U)
78 #define REG_PWM_CMPMUPD1 (0x4008C14CU)
79 #define REG_PWM_CMPV2 (0x4008C150U)
80 #define REG_PWM_CMPVUPD2 (0x4008C154U)
81 #define REG_PWM_CMPM2 (0x4008C158U)
82 #define REG_PWM_CMPMUPD2 (0x4008C15CU)
83 #define REG_PWM_CMPV3 (0x4008C160U)
84 #define REG_PWM_CMPVUPD3 (0x4008C164U)
85 #define REG_PWM_CMPM3 (0x4008C168U)
86 #define REG_PWM_CMPMUPD3 (0x4008C16CU)
87 #define REG_PWM_CMPV4 (0x4008C170U)
88 #define REG_PWM_CMPVUPD4 (0x4008C174U)
89 #define REG_PWM_CMPM4 (0x4008C178U)
90 #define REG_PWM_CMPMUPD4 (0x4008C17CU)
91 #define REG_PWM_CMPV5 (0x4008C180U)
92 #define REG_PWM_CMPVUPD5 (0x4008C184U)
93 #define REG_PWM_CMPM5 (0x4008C188U)
94 #define REG_PWM_CMPMUPD5 (0x4008C18CU)
95 #define REG_PWM_CMPV6 (0x4008C190U)
96 #define REG_PWM_CMPVUPD6 (0x4008C194U)
97 #define REG_PWM_CMPM6 (0x4008C198U)
98 #define REG_PWM_CMPMUPD6 (0x4008C19CU)
99 #define REG_PWM_CMPV7 (0x4008C1A0U)
100 #define REG_PWM_CMPVUPD7 (0x4008C1A4U)
101 #define REG_PWM_CMPM7 (0x4008C1A8U)
102 #define REG_PWM_CMPMUPD7 (0x4008C1ACU)
103 #define REG_PWM_CMR0 (0x4008C200U)
104 #define REG_PWM_CDTY0 (0x4008C204U)
105 #define REG_PWM_CDTYUPD0 (0x4008C208U)
106 #define REG_PWM_CPRD0 (0x4008C20CU)
107 #define REG_PWM_CPRDUPD0 (0x4008C210U)
108 #define REG_PWM_CCNT0 (0x4008C214U)
109 #define REG_PWM_DT0 (0x4008C218U)
110 #define REG_PWM_DTUPD0 (0x4008C21CU)
111 #define REG_PWM_CMR1 (0x4008C220U)
112 #define REG_PWM_CDTY1 (0x4008C224U)
113 #define REG_PWM_CDTYUPD1 (0x4008C228U)
114 #define REG_PWM_CPRD1 (0x4008C22CU)
115 #define REG_PWM_CPRDUPD1 (0x4008C230U)
116 #define REG_PWM_CCNT1 (0x4008C234U)
117 #define REG_PWM_DT1 (0x4008C238U)
118 #define REG_PWM_DTUPD1 (0x4008C23CU)
119 #define REG_PWM_CMR2 (0x4008C240U)
120 #define REG_PWM_CDTY2 (0x4008C244U)
121 #define REG_PWM_CDTYUPD2 (0x4008C248U)
122 #define REG_PWM_CPRD2 (0x4008C24CU)
123 #define REG_PWM_CPRDUPD2 (0x4008C250U)
124 #define REG_PWM_CCNT2 (0x4008C254U)
125 #define REG_PWM_DT2 (0x4008C258U)
126 #define REG_PWM_DTUPD2 (0x4008C25CU)
127 #define REG_PWM_CMR3 (0x4008C260U)
128 #define REG_PWM_CDTY3 (0x4008C264U)
129 #define REG_PWM_CDTYUPD3 (0x4008C268U)
130 #define REG_PWM_CPRD3 (0x4008C26CU)
131 #define REG_PWM_CPRDUPD3 (0x4008C270U)
132 #define REG_PWM_CCNT3 (0x4008C274U)
133 #define REG_PWM_DT3 (0x4008C278U)
134 #define REG_PWM_DTUPD3 (0x4008C27CU)
135 #else
136 #define REG_PWM_CLK (*(RwReg*)0x4008C000U)
137 #define REG_PWM_ENA (*(WoReg*)0x4008C004U)
138 #define REG_PWM_DIS (*(WoReg*)0x4008C008U)
139 #define REG_PWM_SR (*(RoReg*)0x4008C00CU)
140 #define REG_PWM_IER1 (*(WoReg*)0x4008C010U)
141 #define REG_PWM_IDR1 (*(WoReg*)0x4008C014U)
142 #define REG_PWM_IMR1 (*(RoReg*)0x4008C018U)
143 #define REG_PWM_ISR1 (*(RoReg*)0x4008C01CU)
144 #define REG_PWM_SCM (*(RwReg*)0x4008C020U)
145 #define REG_PWM_SCUC (*(RwReg*)0x4008C028U)
146 #define REG_PWM_SCUP (*(RwReg*)0x4008C02CU)
147 #define REG_PWM_SCUPUPD (*(WoReg*)0x4008C030U)
148 #define REG_PWM_IER2 (*(WoReg*)0x4008C034U)
149 #define REG_PWM_IDR2 (*(WoReg*)0x4008C038U)
150 #define REG_PWM_IMR2 (*(RoReg*)0x4008C03CU)
151 #define REG_PWM_ISR2 (*(RoReg*)0x4008C040U)
152 #define REG_PWM_OOV (*(RwReg*)0x4008C044U)
153 #define REG_PWM_OS (*(RwReg*)0x4008C048U)
154 #define REG_PWM_OSS (*(WoReg*)0x4008C04CU)
155 #define REG_PWM_OSC (*(WoReg*)0x4008C050U)
156 #define REG_PWM_OSSUPD (*(WoReg*)0x4008C054U)
157 #define REG_PWM_OSCUPD (*(WoReg*)0x4008C058U)
158 #define REG_PWM_FMR (*(RwReg*)0x4008C05CU)
159 #define REG_PWM_FSR (*(RoReg*)0x4008C060U)
160 #define REG_PWM_FCR (*(WoReg*)0x4008C064U)
161 #define REG_PWM_FPV (*(RwReg*)0x4008C068U)
162 #define REG_PWM_FPE (*(RwReg*)0x4008C06CU)
163 #define REG_PWM_ELMR (*(RwReg*)0x4008C07CU)
164 #define REG_PWM_WPCR (*(WoReg*)0x4008C0E4U)
165 #define REG_PWM_WPSR (*(RoReg*)0x4008C0E8U)
166 #define REG_PWM_TPR (*(RwReg*)0x4008C108U)
167 #define REG_PWM_TCR (*(RwReg*)0x4008C10CU)
168 #define REG_PWM_TNPR (*(RwReg*)0x4008C118U)
169 #define REG_PWM_TNCR (*(RwReg*)0x4008C11CU)
170 #define REG_PWM_PTCR (*(WoReg*)0x4008C120U)
171 #define REG_PWM_PTSR (*(RoReg*)0x4008C124U)
172 #define REG_PWM_CMPV0 (*(RwReg*)0x4008C130U)
173 #define REG_PWM_CMPVUPD0 (*(WoReg*)0x4008C134U)
174 #define REG_PWM_CMPM0 (*(RwReg*)0x4008C138U)
175 #define REG_PWM_CMPMUPD0 (*(WoReg*)0x4008C13CU)
176 #define REG_PWM_CMPV1 (*(RwReg*)0x4008C140U)
177 #define REG_PWM_CMPVUPD1 (*(WoReg*)0x4008C144U)
178 #define REG_PWM_CMPM1 (*(RwReg*)0x4008C148U)
179 #define REG_PWM_CMPMUPD1 (*(WoReg*)0x4008C14CU)
180 #define REG_PWM_CMPV2 (*(RwReg*)0x4008C150U)
181 #define REG_PWM_CMPVUPD2 (*(WoReg*)0x4008C154U)
182 #define REG_PWM_CMPM2 (*(RwReg*)0x4008C158U)
183 #define REG_PWM_CMPMUPD2 (*(WoReg*)0x4008C15CU)
184 #define REG_PWM_CMPV3 (*(RwReg*)0x4008C160U)
185 #define REG_PWM_CMPVUPD3 (*(WoReg*)0x4008C164U)
186 #define REG_PWM_CMPM3 (*(RwReg*)0x4008C168U)
187 #define REG_PWM_CMPMUPD3 (*(WoReg*)0x4008C16CU)
188 #define REG_PWM_CMPV4 (*(RwReg*)0x4008C170U)
189 #define REG_PWM_CMPVUPD4 (*(WoReg*)0x4008C174U)
190 #define REG_PWM_CMPM4 (*(RwReg*)0x4008C178U)
191 #define REG_PWM_CMPMUPD4 (*(WoReg*)0x4008C17CU)
192 #define REG_PWM_CMPV5 (*(RwReg*)0x4008C180U)
193 #define REG_PWM_CMPVUPD5 (*(WoReg*)0x4008C184U)
194 #define REG_PWM_CMPM5 (*(RwReg*)0x4008C188U)
195 #define REG_PWM_CMPMUPD5 (*(WoReg*)0x4008C18CU)
196 #define REG_PWM_CMPV6 (*(RwReg*)0x4008C190U)
197 #define REG_PWM_CMPVUPD6 (*(WoReg*)0x4008C194U)
198 #define REG_PWM_CMPM6 (*(RwReg*)0x4008C198U)
199 #define REG_PWM_CMPMUPD6 (*(WoReg*)0x4008C19CU)
200 #define REG_PWM_CMPV7 (*(RwReg*)0x4008C1A0U)
201 #define REG_PWM_CMPVUPD7 (*(WoReg*)0x4008C1A4U)
202 #define REG_PWM_CMPM7 (*(RwReg*)0x4008C1A8U)
203 #define REG_PWM_CMPMUPD7 (*(WoReg*)0x4008C1ACU)
204 #define REG_PWM_CMR0 (*(RwReg*)0x4008C200U)
205 #define REG_PWM_CDTY0 (*(RwReg*)0x4008C204U)
206 #define REG_PWM_CDTYUPD0 (*(WoReg*)0x4008C208U)
207 #define REG_PWM_CPRD0 (*(RwReg*)0x4008C20CU)
208 #define REG_PWM_CPRDUPD0 (*(WoReg*)0x4008C210U)
209 #define REG_PWM_CCNT0 (*(RoReg*)0x4008C214U)
210 #define REG_PWM_DT0 (*(RwReg*)0x4008C218U)
211 #define REG_PWM_DTUPD0 (*(WoReg*)0x4008C21CU)
212 #define REG_PWM_CMR1 (*(RwReg*)0x4008C220U)
213 #define REG_PWM_CDTY1 (*(RwReg*)0x4008C224U)
214 #define REG_PWM_CDTYUPD1 (*(WoReg*)0x4008C228U)
215 #define REG_PWM_CPRD1 (*(RwReg*)0x4008C22CU)
216 #define REG_PWM_CPRDUPD1 (*(WoReg*)0x4008C230U)
217 #define REG_PWM_CCNT1 (*(RoReg*)0x4008C234U)
218 #define REG_PWM_DT1 (*(RwReg*)0x4008C238U)
219 #define REG_PWM_DTUPD1 (*(WoReg*)0x4008C23CU)
220 #define REG_PWM_CMR2 (*(RwReg*)0x4008C240U)
221 #define REG_PWM_CDTY2 (*(RwReg*)0x4008C244U)
222 #define REG_PWM_CDTYUPD2 (*(WoReg*)0x4008C248U)
223 #define REG_PWM_CPRD2 (*(RwReg*)0x4008C24CU)
224 #define REG_PWM_CPRDUPD2 (*(WoReg*)0x4008C250U)
225 #define REG_PWM_CCNT2 (*(RoReg*)0x4008C254U)
226 #define REG_PWM_DT2 (*(RwReg*)0x4008C258U)
227 #define REG_PWM_DTUPD2 (*(WoReg*)0x4008C25CU)
228 #define REG_PWM_CMR3 (*(RwReg*)0x4008C260U)
229 #define REG_PWM_CDTY3 (*(RwReg*)0x4008C264U)
230 #define REG_PWM_CDTYUPD3 (*(WoReg*)0x4008C268U)
231 #define REG_PWM_CPRD3 (*(RwReg*)0x4008C26CU)
232 #define REG_PWM_CPRDUPD3 (*(WoReg*)0x4008C270U)
233 #define REG_PWM_CCNT3 (*(RoReg*)0x4008C274U)
234 #define REG_PWM_DT3 (*(RwReg*)0x4008C278U)
235 #define REG_PWM_DTUPD3 (*(WoReg*)0x4008C27CU)
236 #endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */
237 
238 #endif /* _SAM3U_PWM_INSTANCE_ */