c33regs.inc 40 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098
  1. ;;; c33regs.inc - Epson S1C33E07 soc register definitions
  2. ;;;
  3. ;;; Copyright (c) 2009 Openmoko Inc.
  4. ;;;
  5. ;;; Authors Christopher Hall <hsw@openmoko.com>
  6. ;;;
  7. ;;; Redistribution and use in source and binary forms, with or without
  8. ;;; modification, are permitted provided that the following conditions are
  9. ;;; met:
  10. ;;;
  11. ;;; 1. Redistributions of source code must retain the above copyright
  12. ;;; notice, this list of conditions and the following disclaimer.
  13. ;;;
  14. ;;; 2. Redistributions in binary form must reproduce the above copyright
  15. ;;; notice, this list of conditions and the following disclaimer in
  16. ;;; the documentation and/or other materials provided with the
  17. ;;; distribution.
  18. ;;;
  19. ;;; THIS SOFTWARE IS PROVIDED BY THE CONTRIBUTORS ``AS IS'' AND ANY
  20. ;;; EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  21. ;;; IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  22. ;;; PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE
  23. ;;; FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  24. ;;; CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  25. ;;; SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
  26. ;;; BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
  27. ;;; WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
  28. ;;; OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
  29. ;;; IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  30. ;;; this is derived from the Epson datasheet entitled:
  31. ;;; CMOS 32-BIT SINGLE CHIP MICROCOMPUTER
  32. ;;; S1C33E07 Technical Manual
  33. ;;; The symbols in the appendix are of the form: pUPPERCASE_NAME
  34. ;;; and the USB symbols are mixed case with no usb prefix
  35. ;;; the 'p' was deleted and USB_ added to USB symbols
  36. ;;; create two macros before including this file
  37. ;;; here is an example that simple defines symbols
  38. ;;; for each item:
  39. ;;;
  40. ;;; .macro REGDEF, address, bits, name
  41. ;;; R\bits\()_\name = \address
  42. ;;; .endm
  43. ;;;
  44. ;;; .macro REGBIT, name, value
  45. ;;; \name = \value
  46. ;;; .endm
  47. REGDEF 0x00300010 8 MISC_RTCWT
  48. REGDEF 0x00300012 8 MISC_USBWT
  49. REGDEF 0x00300014 8 MISC_PMUX
  50. REGDEF 0x00300016 8 MISC_PAC
  51. REGDEF 0x00300018 8 MISC_BOOT
  52. REGDEF 0x0030001A 8 MISC_COROM
  53. REGDEF 0x00300020 8 MISC_PROT
  54. REGDEF 0x00300260 8 INT_PP01L
  55. REGDEF 0x00300261 8 INT_PP23L
  56. REGDEF 0x00300262 8 INT_PK01L
  57. REGDEF 0x00300263 8 INT_PHSD01L
  58. REGDEF 0x00300264 8 INT_PHSD23L
  59. REGDEF 0x00300265 8 INT_PDM
  60. REGDEF 0x00300266 8 INT_P16T01
  61. REGDEF 0x00300267 8 INT_P16T23
  62. REGDEF 0x00300268 8 INT_P16T45
  63. REGDEF 0x00300269 8 INT_PLCDC_PSIO0
  64. REGDEF 0x0030026A 8 INT_PSIO1_PAD
  65. REGDEF 0x0030026B 8 INT_PRTC
  66. REGDEF 0x0030026C 8 INT_PP45L
  67. REGDEF 0x0030026D 8 INT_PP67L
  68. REGDEF 0x0030026E 8 INT_PSIO2_PSPI
  69. REGDEF 0x00300270 8 INT_EK01_EP03
  70. REGDEF 0x00300271 8 INT_EDMA
  71. REGDEF 0x00300272 8 INT_E16T01
  72. REGDEF 0x00300273 8 INT_E16T23
  73. REGDEF 0x00300274 8 INT_E16T45
  74. REGDEF 0x00300276 8 INT_ESIF01
  75. REGDEF 0x00300277 8 INT_EP47_ERTC_EAD
  76. REGDEF 0x00300278 8 INT_ELCDC
  77. REGDEF 0x00300279 8 INT_ESIF2_ESPI
  78. REGDEF 0x00300280 8 INT_FK01_FP03
  79. REGDEF 0x00300281 8 INT_FDMA
  80. REGDEF 0x00300282 8 INT_F16T01
  81. REGDEF 0x00300283 8 INT_F16T23
  82. REGDEF 0x00300284 8 INT_F16T45
  83. REGDEF 0x00300286 8 INT_FSIF01
  84. REGDEF 0x00300287 8 INT_FP47_FRTC_FAD
  85. REGDEF 0x00300288 8 INT_FLCDC
  86. REGDEF 0x00300289 8 INT_FSIF2_FSPI
  87. REGDEF 0x00300290 8 IDMAREQ_RP03_RHS_R16T0
  88. REGDEF 0x00300291 8 IDMAREQ_R16T14
  89. REGDEF 0x00300292 8 IDMAREQ_R16T5_RSIF0
  90. REGDEF 0x00300293 8 IDMAREQ_RSIF1_RAD_RP47
  91. REGDEF 0x00300294 8 IDMAEN_DEP03_DEHS_DE16T0
  92. REGDEF 0x00300295 8 IDMAEN_DE16T14
  93. REGDEF 0x00300296 8 IDMAEN_DE16T5_DESIF0
  94. REGDEF 0x00300297 8 IDMAEN_DESIF1_DEAD_DEP47
  95. REGDEF 0x00300298 8 HSDMA_HTGR1
  96. REGDEF 0x00300299 8 HSDMA_HTGR2
  97. REGDEF 0x0030029A 8 HSDMA_HSOFTTGR
  98. REGDEF 0x0030029B 8 IDMAREQ_RLCDC_RSIF2_RSPI
  99. REGDEF 0x0030029C 8 IDMAEN_DELCDC_DESIF2_DESPI
  100. REGDEF 0x0030029F 8 RST_RESET
  101. REGDEF 0x003002A0 8 INT_PP89L
  102. REGDEF 0x003002A1 8 INT_PP1011L
  103. REGDEF 0x003002A2 8 INT_PP1213L
  104. REGDEF 0x003002A3 8 INT_PP1415L
  105. REGDEF 0x003002A4 8 INT_PI2S
  106. REGDEF 0x003002A6 8 INT_EP815
  107. REGDEF 0x003002A7 8 INT_EI2S
  108. REGDEF 0x003002A9 8 INT_FP815
  109. REGDEF 0x003002AA 8 INT_FI2S
  110. REGDEF 0x003002AC 8 IDMAREQ_RP815
  111. REGDEF 0x003002AD 8 IDMAREQ_RI2S
  112. REGDEF 0x003002AE 8 IDMAEN_DEP815
  113. REGDEF 0x003002AF 8 IDMAEN_DEI2S
  114. REGDEF 0x00300300 8 CARDSETUP
  115. REGDEF 0x00300302 8 CARDFUNCSEL05
  116. REGDEF 0x00300310 8 ECCTRIGSEL
  117. REGDEF 0x00300311 8 ECCRSTRDY
  118. REGDEF 0x00300312 8 ECCENA
  119. REGDEF 0x00300313 8 ECCMD
  120. REGDEF 0x00300314 8 ECC0CP
  121. REGDEF 0x00300316 8 ECC0LPL
  122. REGDEF 0x00300317 8 ECC0LPH
  123. REGDEF 0x00300318 8 ECC1CP
  124. REGDEF 0x0030031A 8 ECC1LPL
  125. REGDEF 0x0030031B 8 ECC1LPH
  126. REGDEF 0x00300380 8 P0_P0D
  127. REGDEF 0x00300381 8 P0_IOC0
  128. REGDEF 0x00300382 8 P1_P1D
  129. REGDEF 0x00300383 8 P1_IOC1
  130. REGDEF 0x00300384 8 P2_P2D
  131. REGDEF 0x00300385 8 P2_IOC2
  132. REGDEF 0x00300386 8 P3_P3D
  133. REGDEF 0x00300387 8 P3_IOC3
  134. REGDEF 0x00300388 8 P4_P4D
  135. REGDEF 0x00300389 8 P4_IOC4
  136. REGDEF 0x0030038A 8 P5_P5D
  137. REGDEF 0x0030038B 8 P5_IOC5
  138. REGDEF 0x0030038C 8 P6_P6D
  139. REGDEF 0x0030038D 8 P6_IOC6
  140. REGDEF 0x0030038E 8 P7_P7D
  141. REGDEF 0x00300390 8 P8_P8D
  142. REGDEF 0x00300391 8 P8_IOC8
  143. REGDEF 0x00300392 8 P9_P9D
  144. REGDEF 0x00300393 8 P9_IOC9
  145. REGDEF 0x003003A0 8 P0_03_CFP
  146. REGDEF 0x003003A1 8 P0_47_CFP
  147. REGDEF 0x003003A2 8 P1_03_CFP
  148. REGDEF 0x003003A3 8 P1_47_CFP
  149. REGDEF 0x003003A4 8 P2_03_CFP
  150. REGDEF 0x003003A5 8 P2_47_CFP
  151. REGDEF 0x003003A6 8 P3_03_CFP
  152. REGDEF 0x003003A7 8 P3_46_CFP
  153. REGDEF 0x003003A8 8 P4_03_CFP
  154. REGDEF 0x003003A9 8 P4_47_CFP
  155. REGDEF 0x003003AA 8 P5_03_CFP
  156. REGDEF 0x003003AB 8 P5_47_CFP
  157. REGDEF 0x003003AC 8 P6_03_CFP
  158. REGDEF 0x003003AD 8 P6_47_CFP
  159. REGDEF 0x003003AE 8 P7_03_CFP
  160. REGDEF 0x003003AF 8 P7_4_CFP
  161. REGDEF 0x003003B0 8 P8_03_CFP
  162. REGDEF 0x003003B1 8 P8_45_CFP
  163. REGDEF 0x003003B2 8 P9_03_CFP
  164. REGDEF 0x003003B3 8 P9_47_CFP
  165. REGDEF 0x003003C0 8 PINTSEL_SPT03
  166. REGDEF 0x003003C1 8 PINTSEL_SPT47
  167. REGDEF 0x003003C2 8 PINTPOL_SPP07
  168. REGDEF 0x003003C3 8 PINTEL_SEPT07
  169. REGDEF 0x003003C4 8 PINTSEL_SPT811
  170. REGDEF 0x003003C5 8 PINTSEL_SPT1215
  171. REGDEF 0x003003C6 8 PINTPOL_SPP815
  172. REGDEF 0x003003C7 8 PINTEL_SEPT815
  173. REGDEF 0x003003D0 8 KINTSEL_SPPK01
  174. REGDEF 0x003003D2 8 KINTCOMP_SCPK0
  175. REGDEF 0x003003D3 8 KINTCOMP_SCPK1
  176. REGDEF 0x003003D4 8 KINTCOMP_SMPK0
  177. REGDEF 0x003003D5 8 KINTCOMP_SMPK1
  178. REGDEF 0x00300520 16 AD_CLKCTL
  179. REGDEF 0x00300540 16 AD_ADD
  180. REGDEF 0x00300542 16 AD_TRIG_CHNL
  181. REGDEF 0x00300544 16 AD_EN_SMPL_STAT
  182. REGDEF 0x00300546 16 AD_END
  183. REGDEF 0x00300548 16 AD_CH0_BUF
  184. REGDEF 0x0030054A 16 AD_CH1_BUF
  185. REGDEF 0x0030054C 16 AD_CH2_BUF
  186. REGDEF 0x0030054E 16 AD_CH3_BUF
  187. REGDEF 0x00300550 16 AD_CH4_BUF
  188. REGDEF 0x00300558 16 AD_UPPER
  189. REGDEF 0x0030055A 16 AD_LOWER
  190. REGDEF 0x0030055C 16 AD_CH04_INTMASK
  191. REGDEF 0x0030055E 16 AD_ADVMODE
  192. REGDEF 0x00300660 16 WD_WP
  193. REGDEF 0x00300662 16 WD_EN
  194. REGDEF 0x00300664 32 WD_COMP
  195. REGDEF 0x00300664 16 WD_COMP_LOW
  196. REGDEF 0x00300666 16 WD_COMP_HIGH
  197. REGDEF 0x00300668 32 WD_CNT
  198. REGDEF 0x00300668 16 WD_CNT_LOW
  199. REGDEF 0x0030066A 16 WD_CNT_HIGH
  200. REGDEF 0x0030066C 16 WD_CNTL
  201. REGDEF 0x00300780 16 T16_CR0A
  202. REGDEF 0x00300782 16 T16_CR0B
  203. REGDEF 0x00300784 16 T16_TC0
  204. REGDEF 0x00300786 16 T16_CTL0
  205. REGDEF 0x00300788 16 T16_CR1A
  206. REGDEF 0x0030078A 16 T16_CR1B
  207. REGDEF 0x0030078C 16 T16_TC1
  208. REGDEF 0x0030078E 16 T16_CTL1
  209. REGDEF 0x00300790 16 T16_CR2A
  210. REGDEF 0x00300792 16 T16_CR2B
  211. REGDEF 0x00300794 16 T16_TC2
  212. REGDEF 0x00300796 16 T16_CTL2
  213. REGDEF 0x00300798 16 T16_CR3A
  214. REGDEF 0x0030079A 16 T16_CR3B
  215. REGDEF 0x0030079C 16 T16_TC3
  216. REGDEF 0x0030079E 16 T16_CTL3
  217. REGDEF 0x003007A0 16 T16_CR4A
  218. REGDEF 0x003007A2 16 T16_CR4B
  219. REGDEF 0x003007A4 16 T16_TC4
  220. REGDEF 0x003007A6 16 T16_CTL4
  221. REGDEF 0x003007A8 16 T16_CR5A
  222. REGDEF 0x003007AA 16 T16_CR5B
  223. REGDEF 0x003007AC 16 T16_TC5
  224. REGDEF 0x003007AE 16 T16_CTL5
  225. REGDEF 0x003007D0 16 DA16_CR0A
  226. REGDEF 0x003007D2 16 DA16_CR1A
  227. REGDEF 0x003007D4 16 DA16_CR2A
  228. REGDEF 0x003007DC 16 T16_CNT_PAUSE
  229. REGDEF 0x003007DE 16 T16_ADVMODE
  230. REGDEF 0x003007E0 16 T16_CLKCTL_0
  231. REGDEF 0x003007E2 16 T16_CLKCTL_1
  232. REGDEF 0x003007E4 16 T16_CLKCTL_2
  233. REGDEF 0x003007E6 16 T16_CLKCTL_3
  234. REGDEF 0x003007E8 16 T16_CLKCTL_4
  235. REGDEF 0x003007EA 16 T16_CLKCTL_5
  236. REGDEF 0x00300900 16 USB_MainIntStat
  237. REGDEF 0x00300901 8 USB_SIE_IntStat
  238. REGDEF 0x00300902 8 USB_EPrIntStat
  239. REGDEF 0x00300903 8 USB_DMA_IntStat
  240. REGDEF 0x00300904 8 USB_FIFO_IntStat
  241. REGDEF 0x00300907 8 USB_EP0IntStat
  242. REGDEF 0x00300908 8 USB_EPaIntStat
  243. REGDEF 0x00300909 8 USB_EPbIntStat
  244. REGDEF 0x0030090A 8 USB_EPcIntStat
  245. REGDEF 0x0030090B 8 USB_EPdIntStat
  246. REGDEF 0x00300910 8 USB_MainIntEnb
  247. REGDEF 0x00300911 8 USB_SIE_IntEnb
  248. REGDEF 0x00300912 8 USB_EPrIntEnb
  249. REGDEF 0x00300913 8 USB_DMA_IntEnb
  250. REGDEF 0x00300914 8 USB_FIFO_IntEnb
  251. REGDEF 0x00300917 8 USB_EP0IntEnb
  252. REGDEF 0x00300918 8 USB_EPaIntEnb
  253. REGDEF 0x00300919 8 USB_EPbIntEnb
  254. REGDEF 0x0030091A 8 USB_EPcIntEnb
  255. REGDEF 0x0030091B 8 USB_EPdIntEnb
  256. REGDEF 0x00300920 8 USB_RevisionNum
  257. REGDEF 0x00300921 8 USB_USB_Control
  258. REGDEF 0x00300922 8 USB_USB_Status
  259. REGDEF 0x00300923 8 USB_XcvrControl
  260. REGDEF 0x00300924 8 USB_USB_Test
  261. REGDEF 0x00300925 8 USB_EPnControl
  262. REGDEF 0x00300926 8 USB_EPrFIFO_Clr
  263. REGDEF 0x0030092E 8 USB_FrameNumber_H
  264. REGDEF 0x0030092F 8 USB_FrameNumber_L
  265. REGDEF 0x00300930 8 USB_EP0Setup_0
  266. REGDEF 0x00300931 8 USB_EP0Setup_1
  267. REGDEF 0x00300932 8 USB_EP0Setup_2
  268. REGDEF 0x00300933 8 USB_EP0Setup_3
  269. REGDEF 0x00300934 8 USB_EP0Setup_4
  270. REGDEF 0x00300935 8 USB_EP0Setup_5
  271. REGDEF 0x00300936 8 USB_EP0Setup_6
  272. REGDEF 0x00300937 8 USB_EP0Setup_7
  273. REGDEF 0x00300938 8 USB_USB_Address
  274. REGDEF 0x00300939 8 USB_EP0Control
  275. REGDEF 0x0030093A 8 USB_EP0ControlIN
  276. REGDEF 0x0030093B 8 USB_EP0ControlOUT
  277. REGDEF 0x0030093F 8 USB_EP0MaxSize
  278. REGDEF 0x00300940 8 USB_EPaControl
  279. REGDEF 0x00300941 8 USB_EPbControl
  280. REGDEF 0x00300942 8 USB_EPcControl
  281. REGDEF 0x00300943 8 USB_EPdControl
  282. REGDEF 0x00300950 8 USB_EPaMaxSize_H
  283. REGDEF 0x00300951 8 USB_EPaMaxSize_L
  284. REGDEF 0x00300952 8 USB_EPaConfig_0
  285. REGDEF 0x00300953 8 USB_EPaConfig_1
  286. REGDEF 0x00300954 8 USB_EPbMaxSize_H
  287. REGDEF 0x00300955 8 USB_EPbMaxSize_L
  288. REGDEF 0x00300956 8 USB_EPbConfig_0
  289. REGDEF 0x00300957 8 USB_EPbConfig_1
  290. REGDEF 0x00300958 8 USB_EPcMaxSize_H
  291. REGDEF 0x00300959 8 USB_EPcMaxSize_L
  292. REGDEF 0x0030095A 8 USB_EPcConfig_0
  293. REGDEF 0x0030095B 8 USB_EPcConfig_1
  294. REGDEF 0x0030095C 8 USB_EPdMaxSize_H
  295. REGDEF 0x0030095D 8 USB_EPdMaxSize_L
  296. REGDEF 0x0030095E 8 USB_EPdConfig_0
  297. REGDEF 0x0030095F 8 USB_EPdConfig_1
  298. REGDEF 0x00300970 8 USB_EPaStartAdrs_H
  299. REGDEF 0x00300971 8 USB_EPaStartAdrs_L
  300. REGDEF 0x00300972 8 USB_EPbStartAdrs_H
  301. REGDEF 0x00300973 8 USB_EPbStartAdrs_L
  302. REGDEF 0x00300974 8 USB_EPcStartAdrs_H
  303. REGDEF 0x00300975 8 USB_EPcStartAdrs_L
  304. REGDEF 0x00300976 8 USB_EPdStartAdrs_H
  305. REGDEF 0x00300977 8 USB_EPdStartAdrs_L
  306. REGDEF 0x00300980 8 USB_CPU_JoinRd
  307. REGDEF 0x00300981 8 USB_CPU_JoinWr
  308. REGDEF 0x00300982 8 USB_EnEPnFIFO
  309. REGDEF 0x00300983 8 USB_EPnFIFOforCPU
  310. REGDEF 0x00300984 8 USB_EPnRdRemain_H
  311. REGDEF 0x00300985 8 USB_EPnRdRemain_L
  312. REGDEF 0x00300986 8 USB_EPnWrRemain_H
  313. REGDEF 0x00300987 8 USB_EPnWrRemain_L
  314. REGDEF 0x00300988 8 USB_DescAdrs_H
  315. REGDEF 0x00300989 8 USB_DescAdrs_L
  316. REGDEF 0x0030098A 8 USB_DescSize_H
  317. REGDEF 0x0030098B 8 USB_DescSize_L
  318. REGDEF 0x0030098F 8 USB_DescDoor
  319. REGDEF 0x00300990 8 USB_DMA_FIFO_Control
  320. REGDEF 0x00300991 8 USB_DMA_Join
  321. REGDEF 0x00300992 8 USB_DMA_Control
  322. REGDEF 0x00300994 8 USB_DMA_Config_0
  323. REGDEF 0x00300995 8 USB_DMA_Config_1
  324. REGDEF 0x00300997 8 USB_DMA_Latency
  325. REGDEF 0x00300998 8 USB_DMA_Remain_H
  326. REGDEF 0x00300999 8 USB_DMA_Remain_L
  327. REGDEF 0x0030099C 8 USB_DMA_Count_HH
  328. REGDEF 0x0030099D 8 USB_DMA_Count_HL
  329. REGDEF 0x0030099E 8 USB_DMA_Count_LH
  330. REGDEF 0x0030099F 8 USB_DMA_Count_LL
  331. REGDEF 0x00300B00 8 EFSIF0_TXD
  332. REGDEF 0x00300B01 8 EFSIF0_RXD
  333. REGDEF 0x00300B02 8 EFSIF0_STATUS
  334. REGDEF 0x00300B03 8 EFSIF0_CTL
  335. REGDEF 0x00300B04 8 EFSIF0_IRDA
  336. REGDEF 0x00300B05 8 EFSIF0_BRTRUN
  337. REGDEF 0x00300B06 8 EFSIF0_BRTRDL
  338. REGDEF 0x00300B07 8 EFSIF0_BRTRDM
  339. REGDEF 0x00300B08 8 EFSIF0_BRTCDL
  340. REGDEF 0x00300B09 8 EFSIF0_BRTCDM
  341. REGDEF 0x00300B10 8 EFSIF1_TXD
  342. REGDEF 0x00300B11 8 EFSIF1_RXD
  343. REGDEF 0x00300B12 8 EFSIF1_STATUS
  344. REGDEF 0x00300B13 8 EFSIF1_CTL
  345. REGDEF 0x00300B14 8 EFSIF1_IRDA
  346. REGDEF 0x00300B15 8 EFSIF1_BRTRUN
  347. REGDEF 0x00300B16 8 EFSIF1_BRTRDL
  348. REGDEF 0x00300B17 8 EFSIF1_BRTRDM
  349. REGDEF 0x00300B18 8 EFSIF1_BRTCDL
  350. REGDEF 0x00300B19 8 EFSIF1_BRTCDM
  351. REGDEF 0x00300B1A 8 EFSIF1_7816CTL
  352. REGDEF 0x00300B1B 8 EFSIF1_7816STA
  353. REGDEF 0x00300B1C 8 EFSIF1_FIDIL
  354. REGDEF 0x00300B1D 8 EFSIF1_FIDIM
  355. REGDEF 0x00300B1E 8 EFSIF1_TTGR
  356. REGDEF 0x00300B1F 8 EFSIF1_CLKNUM
  357. REGDEF 0x00300B20 8 EFSIF2_TXD
  358. REGDEF 0x00300B21 8 EFSIF2_RXD
  359. REGDEF 0x00300B22 8 EFSIF2_STATUS
  360. REGDEF 0x00300B23 8 EFSIF2_CTL
  361. REGDEF 0x00300B24 8 EFSIF2_IRDA
  362. REGDEF 0x00300B25 8 EFSIF2_BRTRUN
  363. REGDEF 0x00300B26 8 EFSIF2_BRTRDL
  364. REGDEF 0x00300B27 8 EFSIF2_BRTRDM
  365. REGDEF 0x00300B28 8 EFSIF2_BRTCDL
  366. REGDEF 0x00300B29 8 EFSIF2_BRTCDM
  367. REGDEF 0x00300B4F 8 EFSIF_ADV
  368. REGDEF 0x00300C00 8 PA_IOC
  369. REGDEF 0x00300C01 8 PA_DATA
  370. REGDEF 0x00300C02 8 PB_IOC
  371. REGDEF 0x00300C03 8 PB_DATA
  372. REGDEF 0x00300C04 8 PC_IOC
  373. REGDEF 0x00300C05 8 PC_DATA
  374. REGDEF 0x00300C20 8 PA_03_CFP
  375. REGDEF 0x00300C21 8 PA_4_CFP
  376. REGDEF 0x00300C22 8 PB_03_CFP
  377. REGDEF 0x00300C24 8 PC_03_CFP
  378. REGDEF 0x00300C25 8 PC_47_CFP
  379. REGDEF 0x00300C40 8 MISC_BUSPUP
  380. REGDEF 0x00300C41 8 MISC_BUSLOW
  381. REGDEF 0x00300C42 8 MISC_PUP0
  382. REGDEF 0x00300C43 8 MISC_PUP1
  383. REGDEF 0x00300C44 8 MISC_PUP2
  384. REGDEF 0x00300C45 8 MISC_PUP3
  385. REGDEF 0x00300C46 8 MISC_PUP4
  386. REGDEF 0x00300C47 8 MISC_PUP5
  387. REGDEF 0x00300C48 8 MISC_PUP6
  388. REGDEF 0x00300C49 8 MISC_PUP7
  389. REGDEF 0x00300C4A 8 MISC_PUP8
  390. REGDEF 0x00300C4B 8 MISC_PUP9
  391. REGDEF 0x00300C4C 8 MISC_PUPA
  392. REGDEF 0x00300C4D 8 MISC_PUPB
  393. REGDEF 0x00301100 16 IDMABASE
  394. REGDEF 0x00301102 16 IDMABASE_H
  395. REGDEF 0x00301104 8 IDMA_START
  396. REGDEF 0x00301105 8 IDMA_EN
  397. REGDEF 0x00301120 16 HS0_CNT
  398. REGDEF 0x00301122 16 HS0_CNT_H
  399. REGDEF 0x00301124 16 HS0_SADR
  400. REGDEF 0x00301126 16 HS0_SADR_h
  401. REGDEF 0x00301128 16 HS0_DADR
  402. REGDEF 0x0030112A 16 HS0_DADR_H
  403. REGDEF 0x0030112C 16 HS0_EN
  404. REGDEF 0x0030112E 16 HS0_TF
  405. REGDEF 0x00301130 16 HS1_CNT
  406. REGDEF 0x00301132 16 HS1_CNT_H
  407. REGDEF 0x00301134 16 HS1_SADR
  408. REGDEF 0x00301136 16 HS1_SADR_H
  409. REGDEF 0x00301138 16 HS1_DADR
  410. REGDEF 0x0030113A 16 HS1_DADR_H
  411. REGDEF 0x0030113C 16 HS1_EN
  412. REGDEF 0x0030113E 16 HS1_TF
  413. REGDEF 0x00301140 16 HS2_CNT
  414. REGDEF 0x00301142 16 HS2_CNT_H
  415. REGDEF 0x00301144 16 HS2_SADR
  416. REGDEF 0x00301146 16 HS2_SADR_H
  417. REGDEF 0x00301148 16 HS2_DADR
  418. REGDEF 0x0030114A 16 HS2_DADR_H
  419. REGDEF 0x0030114C 16 HS2_EN
  420. REGDEF 0x0030114E 16 HS2_TF
  421. REGDEF 0x00301150 16 HS3_CNT
  422. REGDEF 0x00301152 16 HS3_CNT_H
  423. REGDEF 0x00301154 16 HS3_SADR
  424. REGDEF 0x00301156 16 HS3_SADR_H
  425. REGDEF 0x00301158 16 HS3_DADR
  426. REGDEF 0x0030115A 16 HS3_DADR_H
  427. REGDEF 0x0030115C 16 HS3_EN
  428. REGDEF 0x0030115E 16 HS3_TF
  429. REGDEF 0x00301162 16 HS0_ADVMODE
  430. REGDEF 0x00301164 16 HS0_ADV_SADR
  431. REGDEF 0x00301166 16 HS0_ADV_SADR_H
  432. REGDEF 0x00301168 16 HS0_ADV_DADR
  433. REGDEF 0x0030116A 16 HS0_ADV_DADR_H
  434. REGDEF 0x00301172 16 HS1_ADVMODE
  435. REGDEF 0x00301174 16 HS1_ADV_SADR
  436. REGDEF 0x00301176 16 HS1_ADV_SADR_H
  437. REGDEF 0x00301178 16 HS1_ADV_DADR
  438. REGDEF 0x0030117A 16 HS1_ADV_DADR_H
  439. REGDEF 0x00301182 16 HS2_ADVMODE
  440. REGDEF 0x00301184 16 HS2_ADV_SADR
  441. REGDEF 0x00301186 16 HS2_ADV_SADR_H
  442. REGDEF 0x00301188 16 HS2_ADV_DADR
  443. REGDEF 0x0030118A 16 HS2_ADV_DADR_H
  444. REGDEF 0x00301192 16 HS3_ADVMODE
  445. REGDEF 0x00301194 16 HS3_ADV_SADR
  446. REGDEF 0x00301196 16 HS3_ADV_SADR_H
  447. REGDEF 0x00301198 16 HS3_ADV_DADR
  448. REGDEF 0x0030119A 16 HS3_ADV_DADR_H
  449. REGDEF 0x0030119C 16 HS_CNTLMODE
  450. REGDEF 0x0030119E 16 HS_ACCTIME
  451. REGDEF 0x00301500 32 SRAMC_BCLK_SETUP
  452. REGDEF 0x00301504 32 SRAMC_SWAIT
  453. REGDEF 0x00301508 32 SRAMC_SLV_SIZE
  454. REGDEF 0x0030150C 32 SRAMC_A0_BSL
  455. REGDEF 0x00301510 32 SRAMC_ALS
  456. REGDEF 0x00301600 32 SDRAMC_INI
  457. REGDEF 0x00301604 32 SDRAMC_CTL
  458. REGDEF 0x00301608 32 SDRAMC_REF
  459. REGDEF 0x00301610 32 SDRAMC_APP
  460. REGDEF 0x00301700 32 SPI_RXD
  461. REGDEF 0x00301704 32 SPI_TXD
  462. REGDEF 0x00301708 32 SPI_CTL1
  463. REGDEF 0x0030170C 32 SPI_CTL2
  464. REGDEF 0x00301710 32 SPI_WAIT
  465. REGDEF 0x00301714 32 SPI_STAT
  466. REGDEF 0x00301718 32 SPI_INT
  467. REGDEF 0x0030171C 32 SPI_RXMK
  468. REGDEF 0x00301800 32 DCSIO_CTL
  469. REGDEF 0x00301804 32 DCSIO_LOAD
  470. REGDEF 0x00301808 32 DCSIO_RCV
  471. REGDEF 0x00301814 32 DCSIO_INT
  472. REGDEF 0x00301818 32 DCSIO_STAT
  473. REGDEF 0x0030181C 32 DCSIO_DIR
  474. REGDEF 0x00301900 32 RTCINTSTAT
  475. REGDEF 0x00301904 32 RTCINTMODE
  476. REGDEF 0x00301908 32 RTC_CNTL0
  477. REGDEF 0x0030190C 32 RTC_CNTL1
  478. REGDEF 0x00301910 32 RTCSEC
  479. REGDEF 0x00301914 32 RTCMIN
  480. REGDEF 0x00301918 32 RTCHOUR
  481. REGDEF 0x0030191C 32 RTCDAY
  482. REGDEF 0x00301920 32 RTCMONTH
  483. REGDEF 0x00301924 32 RTCYEAR
  484. REGDEF 0x00301928 32 RTCDAYWEEK
  485. REGDEF 0x00301A00 32 LCDC_INT
  486. REGDEF 0x00301A04 32 LCDC_PS
  487. REGDEF 0x00301A10 32 LCDC_HD
  488. REGDEF 0x00301A14 32 LCDC_VD
  489. REGDEF 0x00301A18 32 LCDC_MR
  490. REGDEF 0x00301A20 32 LCDC_HDPS
  491. REGDEF 0x00301A24 32 LCDC_VDPS
  492. REGDEF 0x00301A28 32 LCDC_L
  493. REGDEF 0x00301A2C 32 LCDC_F
  494. REGDEF 0x00301A30 32 LCDC_FO
  495. REGDEF 0x00301A40 32 LCDC_TSO
  496. REGDEF 0x00301A44 32 LCDC_TC1
  497. REGDEF 0x00301A48 32 LCDC_TC0
  498. REGDEF 0x00301A4C 32 LCDC_TC2
  499. REGDEF 0x00301A60 32 LCDC_DMD
  500. REGDEF 0x00301A64 32 LCDC_IRAM
  501. REGDEF 0x00301A70 32 LCDC_MADD
  502. REGDEF 0x00301A74 32 LCDC_MLADD
  503. REGDEF 0x00301A80 32 LCDC_SADD
  504. REGDEF 0x00301A88 32 LCDC_SSP
  505. REGDEF 0x00301A8C 32 LCDC_SEP
  506. REGDEF 0x00301AA0 32 LCDC_LUT_03
  507. REGDEF 0x00301AA4 32 LCDC_LUT_47
  508. REGDEF 0x00301AA8 32 LCDC_LUT_8B
  509. REGDEF 0x00301AAC 32 LCDC_LUT_CF
  510. REGDEF 0x00301B00 32 CMU_GATEDCLK0
  511. REGDEF 0x00301B04 32 CMU_GATEDCLK1
  512. REGDEF 0x00301B08 32 CMU_CLKCNTL
  513. REGDEF 0x00301B0C 32 CMU_PLL
  514. REGDEF 0x00301B10 32 CMU_SSCG
  515. REGDEF 0x00301B14 32 CMU_OPT
  516. REGDEF 0x00301B24 32 CMU_PROTECT
  517. REGDEF 0x00301C00 32 I2S_CONTRL
  518. REGDEF 0x00301C04 32 I2S_DV_MCLK
  519. REGDEF 0x00301C08 32 I2S_DV_LRCLK
  520. REGDEF 0x00301C0C 32 I2S_START
  521. REGDEF 0x00301C10 32 I2S_HSDMAMD
  522. REGDEF 0x00301C14 32 I2S_FIFO_EMPTY
  523. REGDEF 0x00301C20 32 I2S_FIFO
  524. ;;; bit definitions for various registers
  525. ;;;
  526. ;;; Clock Management Unit
  527. ;;;
  528. ;;; codes for: REG_CMU_PROTECT
  529. REGBIT CMU_PROTECT_OFF 0x96
  530. REGBIT CMU_PROTECT_ON 0x00
  531. ;;; bits for: REG_CMU_CLKCNTL
  532. REGBIT CMU_CLK_SEL_OSC3_DIV_32 "(10 << 24)"
  533. REGBIT CMU_CLK_SEL_OSC3_DIV_16 "(9 << 24)"
  534. REGBIT CMU_CLK_SEL_OSC3_DIV_8 "(8 << 24)"
  535. REGBIT CMU_CLK_SEL_OSC3_DIV_4 "(7 << 24)"
  536. REGBIT CMU_CLK_SEL_OSC3_DIV_2 "(6 << 24)"
  537. REGBIT CMU_CLK_SEL_OSC3_DIV_1 "(5 << 24)"
  538. REGBIT CMU_CLK_SEL_LCDC_CLK "(4 << 24)"
  539. REGBIT CMU_CLK_SEL_MCLK "(3 << 24)"
  540. REGBIT CMU_CLK_SEL_PLL "(2 << 24)"
  541. REGBIT CMU_CLK_SEL_OSC1 "(1 << 24)"
  542. REGBIT CMU_CLK_SEL_OSC3 "(0 << 24)"
  543. REGBIT PLLINDIV_MASK "(15 << 20)"
  544. REGBIT PLLINDIV_10 "(9 << 20)"
  545. REGBIT PLLINDIV_9 "(8 << 20)"
  546. REGBIT PLLINDIV_8 "(7 << 20)"
  547. REGBIT PLLINDIV_7 "(6 << 20)"
  548. REGBIT PLLINDIV_6 "(5 << 20)"
  549. REGBIT PLLINDIV_5 "(4 << 20)"
  550. REGBIT PLLINDIV_4 "(3 << 20)"
  551. REGBIT PLLINDIV_3 "(2 << 20)"
  552. REGBIT PLLINDIV_2 "(1 << 20)"
  553. REGBIT PLLINDIV_1 "(0 << 20)"
  554. REGBIT LCDCDIV_MASK "(15 << 16)"
  555. REGBIT LCDCDIV_16 "(15 << 16)"
  556. REGBIT LCDCDIV_15 "(14 << 16)"
  557. REGBIT LCDCDIV_14 "(13 << 16)"
  558. REGBIT LCDCDIV_13 "(12 << 16)"
  559. REGBIT LCDCDIV_12 "(11 << 16)"
  560. REGBIT LCDCDIV_11 "(10 << 16)"
  561. REGBIT LCDCDIV_10 "(9 << 16)"
  562. REGBIT LCDCDIV_9 "(8 << 16)"
  563. REGBIT LCDCDIV_8 "(7 << 16)"
  564. REGBIT LCDCDIV_7 "(6 << 16)"
  565. REGBIT LCDCDIV_6 "(5 << 16)"
  566. REGBIT LCDCDIV_5 "(4 << 16)"
  567. REGBIT LCDCDIV_4 "(3 << 16)"
  568. REGBIT LCDCDIV_3 "(2 << 16)"
  569. REGBIT LCDCDIV_2 "(1 << 16)"
  570. REGBIT LCDCDIV_1 "(0 << 16)"
  571. REGBIT MCLKDIV "(1 << 12)"
  572. REGBIT OSC3DIV_MASK "(7 << 8)"
  573. REGBIT OSC3DIV_32 "(5 << 8)"
  574. REGBIT OSC3DIV_16 "(4 << 8)"
  575. REGBIT OSC3DIV_8 "(3 << 8)"
  576. REGBIT OSC3DIV_4 "(2 << 8)"
  577. REGBIT OSC3DIV_2 "(1 << 8)"
  578. REGBIT OSC3DIV_1 "(0 << 8)"
  579. REGBIT OSCSEL_MASK "(3 << 2)"
  580. REGBIT OSCSEL_PLL "(3 << 2)"
  581. REGBIT OSCSEL_OSC3x "(2 << 2)"
  582. REGBIT OSCSEL_OSC1 "(1 << 2)"
  583. REGBIT OSCSEL_OSC3 "(0 << 2)"
  584. REGBIT SOSC3 "(1 << 1)"
  585. REGBIT SOSC1 "(1 << 0)"
  586. ;;; Bits for: REG_CMU_GATEDCLK0
  587. REGBIT USBSAPB_CKE "(1 << 9)"
  588. REGBIT USB_CKE "(1 << 8)"
  589. REGBIT SDAPCPU_HCKE "(1 << 7)"
  590. REGBIT SDAPCPU_CKE "(1 << 6)"
  591. REGBIT SDAPLCDC_CKE "(1 << 5)"
  592. REGBIT SDSAPB_CKE "(1 << 4)"
  593. REGBIT DSTRAM_CKE "(1 << 3)"
  594. REGBIT LCDCAHBIF_CKE "(1 << 2)"
  595. REGBIT LCDCSAPB_CKE "(1 << 1)"
  596. REGBIT LCDC_CKE "(1 << 0)"
  597. ;;; Bits for: REG_CMU_GATEDCLK1
  598. REGBIT CPUAHB_HCKE "(1 << 29)"
  599. REGBIT LCDCAHB_HCKE "(1 << 28)"
  600. REGBIT GPIONSTP_HCKE "(1 << 27)"
  601. REGBIT SRAMC_HCKE "(1 << 26)"
  602. REGBIT EFSIOBR_HCKE "(1 << 25)"
  603. REGBIT MISC_HCKE "(1 << 24)"
  604. REGBIT IVRAMARB_CKE "(1 << 19)"
  605. REGBIT TM5_CKE "(1 << 18)"
  606. REGBIT TM4_CKE "(1 << 17)"
  607. REGBIT TM3_CKE "(1 << 16)"
  608. REGBIT TM2_CKE "(1 << 15)"
  609. REGBIT TM1_CKE "(1 << 14)"
  610. REGBIT TM0_CKE "(1 << 13)"
  611. REGBIT EGPIO_MISC_CK "(1 << 12)"
  612. REGBIT I2S_CKE "(1 << 11)"
  613. REGBIT DCSIO_CKE "(1 << 10)"
  614. REGBIT WDT_CKE "(1 << 9)"
  615. REGBIT GPIO_CKE "(1 << 8)"
  616. REGBIT SRAMSAPB_CKE "(1 << 7)"
  617. REGBIT SPI_CKE "(1 << 6)"
  618. REGBIT EFSIOSAPB_CKE "(1 << 5)"
  619. REGBIT CARD_CKE "(1 << 4)"
  620. REGBIT ADC_CKE "(1 << 3)"
  621. REGBIT ITC_CKE "(1 << 2)"
  622. REGBIT DMA_CKE "(1 << 1)"
  623. REGBIT RTCSAPB_CKE "(1 << 0)"
  624. ;;; Bits for: REG_CMU_OPT
  625. REGBIT OSCTM_SHIFT 8
  626. REGBIT OSC3OFF "(1 << 3)"
  627. REGBIT TMHSP "(1 << 2)"
  628. REGBIT WAKEUPWT "(1 << 0)"
  629. ;;;
  630. ;;; Serial Controller
  631. ;;;
  632. ;;; Bits for: REG_EFSIFx_STATUS
  633. REGBIT RXDxNUM1 "(1 << 7)"
  634. REGBIT RXDxNUM0 "(1 << 6)"
  635. REGBIT TENDx "(1 << 5)"
  636. REGBIT FERx "(1 << 4)"
  637. REGBIT PERx "(1 << 3)"
  638. REGBIT OERx "(1 << 2)"
  639. REGBIT TDBEx "(1 << 1)"
  640. REGBIT RDBFx "(1 << 0)"
  641. ;;; Bits for: REG_EFSIFx_CTL
  642. REGBIT TXENx "(0x1 << 7)"
  643. REGBIT TX_DISENx "(0x0 << 7)"
  644. REGBIT RXENx "(0x1 << 6)"
  645. REGBIT RX_DISENx "(0x0 << 6)"
  646. REGBIT PARx "(0x1 << 5)"
  647. REGBIT NO_PARx "(0x0 << 5)"
  648. REGBIT ODDx "(0x1 << 4)"
  649. REGBIT EVENx "(0x0 << 4)"
  650. REGBIT ONE_STPBx "(0x1 << 3)"
  651. REGBIT TWO_STPBx "(0x0 << 3)"
  652. REGBIT SCLKx "(0x1 << 2)"
  653. REGBIT INT_CLKx "(0x0 << 2)"
  654. REGBIT EIGHT_BIT_ASYNx 0x3
  655. REGBIT SEVEN_BIT_ASYNx 0x2
  656. REGBIT CLK_SLAVEx 0x1
  657. REGBIT CLK_MASTERx 0x0
  658. ;;; Bits for: REG_EFSIFx_IrDA
  659. REGBIT DIVMD_8x "(0x1 << 4)"
  660. REGBIT DIVMD_16x "(0x0 << 4)"
  661. REGBIT IRMD_IRDAx 0x10
  662. REGBIT IRMD_GEN_IFx 0x00
  663. ;;; Bits for: REG_EFSIFx_BRTCTL
  664. REGBIT BRTRUN_STARx 0x1
  665. REGBIT BRTRUN_STOPx 0x0
  666. ;;;
  667. ;;; Interrupt Controller
  668. ;;;
  669. ;;; Bits for: REG_INT_ESIF01
  670. REGBIT ESTX1 "(1 << 5)"
  671. REGBIT ESRX1 "(1 << 4)"
  672. REGBIT ESERR1 "(1 << 3)"
  673. REGBIT ESTX0 "(1 << 2)"
  674. REGBIT ESRX0 "(1 << 1)"
  675. REGBIT ESERR0 "(1 << 0)"
  676. ;;; Bits for: REG_INT_FSIF01
  677. REGBIT FSTX1 "(1 << 5)"
  678. REGBIT FSRX1 "(1 << 4)"
  679. REGBIT FSERR1 "(1 << 3)"
  680. REGBIT FSTX0 "(1 << 2)"
  681. REGBIT FSRX0 "(1 << 1)"
  682. REGBIT FSERR0 "(1 << 0)"
  683. ;;; Bits for: REG_RST_RESET
  684. REGBIT DENONLY "(1 << 2)"
  685. REGBIT IDMAONLY "(1 << 1)"
  686. REGBIT RSTONLY "(1 << 0)"
  687. ;;; Bits for: REG_INT_EK01_EP03
  688. REGBIT EK1 "(1 << 5)"
  689. REGBIT EK0 "(1 << 4)"
  690. REGBIT EP3 "(1 << 3)"
  691. REGBIT EP2 "(1 << 2)"
  692. REGBIT EP1 "(1 << 1)"
  693. REGBIT EP0 "(1 << 0)"
  694. ;;; Bits for: INT_FK01_FP03
  695. REGBIT FK1 "(1 << 5)"
  696. REGBIT FK0 "(1 << 4)"
  697. REGBIT FP3 "(1 << 3)"
  698. REGBIT FP2 "(1 << 2)"
  699. REGBIT FP1 "(1 << 1)"
  700. REGBIT FP0 "(1 << 0)"
  701. ;;;
  702. ;;; GPIO
  703. ;;;
  704. ;;; Bits for REG_PINTPOL_SPP07
  705. REGBIT SPPT7 "(1 << 7)"
  706. REGBIT SPPT6 "(1 << 6)"
  707. REGBIT SPPT5 "(1 << 5)"
  708. REGBIT SPPT4 "(1 << 4)"
  709. REGBIT SPPT3 "(1 << 3)"
  710. REGBIT SPPT2 "(1 << 2)"
  711. REGBIT SPPT1 "(1 << 1)"
  712. REGBIT SPPT0 "(1 << 0)"
  713. ;;; Bits for REG_PINTPOL_SPP815
  714. REGBIT SPPTF "(1 << 7)"
  715. REGBIT SPPTE "(1 << 6)"
  716. REGBIT SPPTD "(1 << 5)"
  717. REGBIT SPPTC "(1 << 4)"
  718. REGBIT SPPTB "(1 << 3)"
  719. REGBIT SPPTA "(1 << 2)"
  720. REGBIT SPPT9 "(1 << 1)"
  721. REGBIT SPPT8 "(1 << 0)"
  722. ;;; Bits for REG_PINTEL_SEPT07
  723. REGBIT SEPT7 "(1 << 7)"
  724. REGBIT SEPT6 "(1 << 6)"
  725. REGBIT SEPT5 "(1 << 5)"
  726. REGBIT SEPT4 "(1 << 4)"
  727. REGBIT SEPT3 "(1 << 3)"
  728. REGBIT SEPT2 "(1 << 2)"
  729. REGBIT SEPT1 "(1 << 1)"
  730. REGBIT SEPT0 "(1 << 0)"
  731. ;;; Bits for REG_PINTEL_SEPT815
  732. REGBIT SEPTF "(1 << 7)"
  733. REGBIT SEPTE "(1 << 6)"
  734. REGBIT SEPTD "(1 << 5)"
  735. REGBIT SEPTC "(1 << 4)"
  736. REGBIT SEPTB "(1 << 3)"
  737. REGBIT SEPTA "(1 << 2)"
  738. REGBIT SEPT9 "(1 << 1)"
  739. REGBIT SEPT8 "(1 << 0)"
  740. ;;;
  741. ;;; SDRAM Controller
  742. ;;;
  743. ;;; bits for: REG_SDRAMC_CTL
  744. REGBIT T24NS_SHIFT 12
  745. REGBIT T60NS_SHIFT 8
  746. REGBIT T80NS_SHIFT 4
  747. REGBIT ADDRC_32M_x_16_bits_x_1 0x7
  748. REGBIT ADDRC_16M_x__8_bits_x_2 0x6
  749. REGBIT ADDRC__8M_x__8_bits_x_2 0x5
  750. REGBIT ADDRC__2M_x__8_bits_x_2 0x4
  751. REGBIT ADDRC_16M_x_16_bits_x_1 0x3
  752. REGBIT ADDRC__8M_x_16_bits_x_1 0x2
  753. REGBIT ADDRC__4M_x_16_bits_x_1 0x1
  754. REGBIT ADDRC__1M_x_16_bits_x_1 0x0
  755. ;;; Bits for: REG_SDRAMC_REF
  756. REGBIT SELDO "(1 << 25)"
  757. REGBIT SCKON "(1 << 24)"
  758. REGBIT SELEN "(1 << 23)"
  759. REGBIT SELCO_SHIFT 16
  760. REGBIT AURCO_SHIFT 0
  761. ;;; Bits for: REG_SDRAMC_INI
  762. REGBIT SDON "(1 << 4)"
  763. REGBIT SDEN "(1 << 3)"
  764. REGBIT INIMRS "(1 << 2)"
  765. REGBIT INIPRE "(1 << 1)"
  766. REGBIT INIREF "(1 << 0)"
  767. ;;; SDRAM controller commands for REG_SDRAMC_INI
  768. REGBIT SDRAM_CMD_FIRST "(SDON)"
  769. REGBIT SDRAM_CMD_FINAL "(SDON)"
  770. REGBIT SDRAM_CMD_REF "(SDON | INIREF)"
  771. REGBIT SDRAM_CMD_PALL "(SDON | INIPRE)"
  772. REGBIT SDRAM_CMD_MRS "(SDON | INIMRS)"
  773. ;;; Bits for: REG_SDRAMC_APP
  774. REGBIT ARBON "(1 << 31)"
  775. REGBIT DBF "(1 << 5)"
  776. REGBIT INCR "(1 << 4)"
  777. REGBIT CAS1 "(1 << 3)"
  778. REGBIT CAS0 "(1 << 2)"
  779. REGBIT APPON "(1 << 1)"
  780. REGBIT IQB "(1 << 0)"
  781. ;;; Bits for: REG_CH1_INT_PRIORITY
  782. REGBIT SERIAL_CH1_INT_PRI_7 0x7
  783. REGBIT SERIAL_CH1_INT_PRI_6 0x6
  784. REGBIT SERIAL_CH1_INT_PRI_5 0x5
  785. REGBIT SERIAL_CH1_INT_PRI_4 0x4
  786. REGBIT SERIAL_CH1_INT_PRI_3 0x3
  787. REGBIT SERIAL_CH1_INT_PRI_2 0x2
  788. REGBIT SERIAL_CH1_INT_PRI_1 0x1
  789. REGBIT SERIAL_CH1_INT_PRI_0 0x0
  790. ;;;
  791. ;;; LCD controller
  792. ;;;
  793. ;;; Bits for: REG_LCDC_PS
  794. REGBIT INTF "(1 << 31)"
  795. REGBIT VNDPF "(1 << 7)"
  796. REGBIT PSAVE_NORMAL "(3 << 0)"
  797. REGBIT PSAVE_DOZE "(2 << 0)"
  798. REGBIT PSAVE_POWER_SAVE "(0 << 0)"
  799. ;;; Bits for: REG_LCDC_HD
  800. REGBIT HTCNT_SHIFT 16
  801. REGBIT HDPCNT_SHIFT 0
  802. ;;; Bits for: REG_LCDC_VD
  803. REGBIT VTCNT_SHIFT 16
  804. REGBIT VDPCNT_SHIFT 0
  805. ;;; Bits for: REG_LCDC_DMD
  806. REGBIT TFTSEL "(1 << 31)"
  807. REGBIT COLOR "(1 << 30)"
  808. REGBIT FPSMASK "(1 << 29)"
  809. REGBIT DWD_8_BIT_2 "(3 << 26)"
  810. REGBIT DWD_8_BIT_1 "(1 << 26)"
  811. REGBIT DWD_4_BIT "(0 << 26)"
  812. REGBIT SWINV "(1 << 25)"
  813. REGBIT BLANK "(1 << 24)"
  814. REGBIT FRMRPT "(1 << 7)"
  815. REGBIT DITHEN "(1 << 6)"
  816. REGBIT LUTPASS "(1 << 4)"
  817. REGBIT BPP_16 "(5 << 0)"
  818. REGBIT BPP_12 "(4 << 0)"
  819. REGBIT BPP_8 "(3 << 0)"
  820. REGBIT BPP_4 "(2 << 0)"
  821. REGBIT BPP_2 "(1 << 0)"
  822. REGBIT BPP_1 "(0 << 0)"
  823. ;;;
  824. ;;; Timers
  825. ;;;
  826. ;;; Bits for: REG_T16_ADVMODE
  827. REGBIT T16ADV "(1 << 0)"
  828. ;;; Bits for: REG_T16_CNT_PAUSE
  829. REGBIT PAUSE5 "(1 << 5)"
  830. REGBIT PAUSE4 "(1 << 4)"
  831. REGBIT PAUSE3 "(1 << 3)"
  832. REGBIT PAUSE2 "(1 << 2)"
  833. REGBIT PAUSE1 "(1 << 1)"
  834. REGBIT PAUSE0 "(1 << 0)"
  835. ;;; Bits for: REG_T16_CTLx
  836. REGBIT INITOLx "(1 << 8)"
  837. ;;; REGBIT (TMODEx) "(1 << 7)" - reserved, do not set to 1
  838. REGBIT SELFMx "(1 << 6)"
  839. REGBIT SELCRBx "(1 << 5)"
  840. REGBIT OUTINVx "(1 << 4)"
  841. REGBIT CKSLx "(1 << 3)"
  842. REGBIT PTMx "(1 << 2)"
  843. REGBIT PRESETx "(1 << 1)"
  844. REGBIT PRUNx "(1 << 0)"
  845. ;;;Bits for: REG_T16_CLKCTL_x
  846. REGBIT P16TONx "(1 << 3)"
  847. REGBIT P16TSx_MCLK_DIV_4096 "(7 << 0)"
  848. REGBIT P16TSx_MCLK_DIV_1024 "(6 << 0)"
  849. REGBIT P16TSx_MCLK_DIV_256 "(5 << 0)"
  850. REGBIT P16TSx_MCLK_DIV_64 "(4 << 0)"
  851. REGBIT P16TSx_MCLK_DIV_16 "(3 << 0)"
  852. REGBIT P16TSx_MCLK_DIV_4 "(2 << 0)"
  853. REGBIT P16TSx_MCLK_DIV_2 "(1 << 0)"
  854. REGBIT P16TSx_MCLK_DIV_1 "(0 << 0)"
  855. ;;;
  856. ;;; watchdog
  857. ;;;
  858. ;;; Bits for: REG_WD_WP
  859. REGBIT WD_WP_OFF 0x96
  860. REGBIT WD_WP_ON 0x00
  861. ;;; Bits for: REG_WD_EN
  862. REGBIT CLKSEL "(1 << 6)"
  863. REGBIT CLKEN "(1 << 5)"
  864. REGBIT RUNSTP "(1 << 4)"
  865. REGBIT NMIEN "(1 << 1)"
  866. REGBIT RESEN "(1 << 0)"
  867. ;;; Bits for: REG_WD_CNTL
  868. REGBIT WDRESEN "(1 << 0)"
  869. ;;;
  870. ;;; SPI module
  871. ;;;
  872. ;;; Bits for: REG_SPI_CTL1
  873. REGBIT BPT_32_BITS "(31 << 10)"
  874. REGBIT BPT_16_BITS "(15 << 10)"
  875. REGBIT BPT_8_BITS "( 7 << 10)"
  876. REGBIT BPT_1_BITS "( 0 << 10)"
  877. REGBIT CPHA "(1 << 9)"
  878. REGBIT CPOL "(1 << 8)"
  879. REGBIT MCBR_MCLK_DIV_512 "(7 << 4)"
  880. REGBIT MCBR_MCLK_DIV_256 "(6 << 4)"
  881. REGBIT MCBR_MCLK_DIV_128 "(5 << 4)"
  882. REGBIT MCBR_MCLK_DIV_64 "(4 << 4)"
  883. REGBIT MCBR_MCLK_DIV_32 "(3 << 4)"
  884. REGBIT MCBR_MCLK_DIV_16 "(2 << 4)"
  885. REGBIT MCBR_MCLK_DIV_8 "(1 << 4)"
  886. REGBIT MCBR_MCLK_DIV_4 "(0 << 4)"
  887. REGBIT TXDE "(1 << 3)"
  888. REGBIT RXDE "(1 << 2)"
  889. REGBIT MODE_MASTER "(1 << 1)"
  890. REGBIT MODE_SLAVE "(0 << 1)"
  891. REGBIT ENA "(1 << 0)"
  892. ;;; Bits for: REG_SPI_STAT
  893. REGBIT BSYF "(1 << 6)"
  894. REGBIT MFEF "(1 << 5)"
  895. REGBIT TDEF "(1 << 4)"
  896. REGBIT RDOF "(1 << 3)"
  897. REGBIT RDFF "(1 << 2)"
  898. ;;; Bits for REG_HS_CNTLMODE
  899. REGBIT HSDMAADV "(1 << 0)"
  900. ;;; Bits for DMA advanced channels
  901. REGBIT DMA_ENABLED "(1 << 0)"
  902. REGBIT DMA_DISABLED "(0 << 0)"
  903. ;;;
  904. ;;; Interrupt vectors
  905. ;;;
  906. VECTOR Reset 0
  907. VECTOR reserved_1 1
  908. VECTOR ext_exception 2
  909. VECTOR Undefined_instruction_exception 3
  910. VECTOR reserved_4 4
  911. VECTOR reserved_5 5
  912. VECTOR Address_misaligned_exception 6
  913. VECTOR NMI 7
  914. VECTOR reserved_8 8
  915. VECTOR reserved_9 9
  916. VECTOR reserved_10 10
  917. VECTOR Illegal_interrupt_exception 11
  918. VECTOR Software_exception_0 12
  919. VECTOR Software_exception_1 13
  920. VECTOR Software_exception_2 14
  921. VECTOR Software_exception_3 15
  922. VECTOR Port_input_interrupt_0 16
  923. VECTOR Port_input_interrupt_1 17
  924. VECTOR Port_input_interrupt_2 18
  925. VECTOR Port_input_interrupt_3 19
  926. VECTOR Key_input_interrupt_0 20
  927. VECTOR Key_input_interrupt_1 21
  928. VECTOR High_speed_DMA_Ch_0 22
  929. VECTOR High_speed_DMA_Ch_1 23
  930. VECTOR High_speed_DMA_Ch_2 24
  931. VECTOR High_speed_DMA_Ch_3 25
  932. VECTOR Intelligent_DMA 26
  933. VECTOR reserved_27 27
  934. VECTOR reserved_28 28
  935. VECTOR reserved_29 29
  936. VECTOR 16_bit_timer_0_compare_match_B 30
  937. VECTOR 16_bit_timer_0_compare_match_A 31
  938. VECTOR reserved_32 32
  939. VECTOR reserved_33 33
  940. VECTOR 16_bit_timer_1_compare_match_B 34
  941. VECTOR 16_bit_timer_1_compare_match_A 35
  942. VECTOR reserved_36 36
  943. VECTOR reserved_37 37
  944. VECTOR 16_bit_timer_2_compare_match_B 38
  945. VECTOR 16_bit_timer_2_compare_match_A 39
  946. VECTOR reserved_40 40
  947. VECTOR reserved_41 41
  948. VECTOR 16_bit_timer_3_compare_match_B 42
  949. VECTOR 16_bit_timer_3_compare_match_A 43
  950. VECTOR reserved_44 44
  951. VECTOR reserved_45 45
  952. VECTOR 16_bit_timer_4_compare_match_B 46
  953. VECTOR 16_bit_timer_4_compare_match_A 47
  954. VECTOR reserved_48 48
  955. VECTOR reserved_49 49
  956. VECTOR 16_bit_timer_5_compare_match_B 50
  957. VECTOR 16_bit_timer_5_compare_match_A 51
  958. VECTOR reserved_52 52
  959. VECTOR reserved_53 53
  960. VECTOR reserved_54 54
  961. VECTOR reserved_55 55
  962. VECTOR Serial_interface_Ch_0_Receive_error 56
  963. VECTOR Serial_interface_Ch_0_Receive_buffer_full 57
  964. VECTOR Serial_interface_Ch_0_Transmit_buffer_empty 58
  965. VECTOR reserved_59 59
  966. VECTOR Serial_interface_Ch_1_Receive_error 60
  967. VECTOR Serial_interface_Ch_1_Receive_buffer_full 61
  968. VECTOR Serial_interface_Ch_1_Transmit_buffer_empty 62
  969. VECTOR A_D_converter_Result_out_of_range 63
  970. VECTOR A_D_converter_End_of_conversion 64
  971. VECTOR RTC 65
  972. VECTOR reserved_66 66
  973. VECTOR reserved_67 67
  974. VECTOR Port_input_interrupt_4 68
  975. VECTOR Port_input_interrupt_5 69
  976. VECTOR Port_input_interrupt_6 70
  977. VECTOR Port_input_interrupt_7 71
  978. VECTOR reserved_72 72
  979. VECTOR LCDC 73
  980. VECTOR reserved_74 74
  981. VECTOR reserved_75 75
  982. VECTOR Serial_interface_Ch_2_Receive_error 76
  983. VECTOR Serial_interface_Ch_2_Receive_buffer_full 77
  984. VECTOR Serial_interface_Ch_2_Transmit_buffer_empty 78
  985. VECTOR reserved_79 79
  986. VECTOR reserved_80 80
  987. VECTOR SPI_Receive_DMA_request 81
  988. VECTOR SPI_Transmit_DMA_request 82
  989. VECTOR reserved_83 83
  990. VECTOR Port_input_interrupt_8_SPI_SPI_interrupt 84
  991. VECTOR Port_input_interrupt_9_USB_PDREQ_USB_DMA_request 85
  992. VECTOR Port_input_interrupt_10_USB_USBinterrupt 86
  993. VECTOR Port_input_interrupt_11_DCSIO_DCSIO_interrupt 87
  994. VECTOR Port_input_interrupt_12 88
  995. VECTOR Port_input_interrupt_13 89
  996. VECTOR Port_input_interrupt_14 90
  997. VECTOR Port_input_interrupt_15 91
  998. VECTOR reserved_92 92
  999. VECTOR reserved_93 93
  1000. VECTOR I2S_interface_I2S_FIFO_empty 94
  1001. VECTOR reserved_95 95
  1002. VECTOR reserved_96 96
  1003. VECTOR reserved_97 97
  1004. VECTOR reserved_98 98
  1005. VECTOR reserved_99 99
  1006. VECTOR reserved_100 100
  1007. VECTOR reserved_101 101
  1008. VECTOR reserved_102 102
  1009. VECTOR reserved_103 103
  1010. VECTOR reserved_104 104
  1011. VECTOR reserved_105 105
  1012. VECTOR reserved_106 106
  1013. VECTOR reserved_107 107