at32f403a_407_xmc.h 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567
  1. /**
  2. **************************************************************************
  3. * @file at32f403a_407_xmc.h
  4. * @brief at32f403a_407 xmc header file
  5. **************************************************************************
  6. * Copyright notice & Disclaimer
  7. *
  8. * The software Board Support Package (BSP) that is made available to
  9. * download from Artery official website is the copyrighted work of Artery.
  10. * Artery authorizes customers to use, copy, and distribute the BSP
  11. * software and its related documentation for the purpose of design and
  12. * development in conjunction with Artery microcontrollers. Use of the
  13. * software is governed by this copyright notice and the following disclaimer.
  14. *
  15. * THIS SOFTWARE IS PROVIDED ON "AS IS" BASIS WITHOUT WARRANTIES,
  16. * GUARANTEES OR REPRESENTATIONS OF ANY KIND. ARTERY EXPRESSLY DISCLAIMS,
  17. * TO THE FULLEST EXTENT PERMITTED BY LAW, ALL EXPRESS, IMPLIED OR
  18. * STATUTORY OR OTHER WARRANTIES, GUARANTEES OR REPRESENTATIONS,
  19. * INCLUDING BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY,
  20. * FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT.
  21. *
  22. **************************************************************************
  23. */
  24. /* Define to prevent recursive inclusion -------------------------------------*/
  25. #ifndef __AT32F403A_407_XMC_H
  26. #define __AT32F403A_407_XMC_H
  27. #ifdef __cplusplus
  28. extern "C" {
  29. #endif
  30. /* Includes ------------------------------------------------------------------*/
  31. #include "at32f403a_407.h"
  32. /** @addtogroup AT32F403A_407_periph_driver
  33. * @{
  34. */
  35. /** @addtogroup XMC
  36. * @{
  37. */
  38. /** @defgroup XMC_exported_types
  39. * @{
  40. */
  41. /**
  42. * @brief xmc data address bus multiplexing type
  43. */
  44. typedef enum
  45. {
  46. XMC_DATA_ADDR_MUX_DISABLE = 0x00000000, /*!< xmc address/data multiplexing disable */
  47. XMC_DATA_ADDR_MUX_ENABLE = 0x00000002 /*!< xmc address/data multiplexing enable */
  48. } xmc_data_addr_mux_type;
  49. /**
  50. * @brief xmc burst access mode type
  51. */
  52. typedef enum
  53. {
  54. XMC_BURST_MODE_DISABLE = 0x00000000, /*!< xmc burst mode disable */
  55. XMC_BURST_MODE_ENABLE = 0x00000100 /*!< xmc burst mode enable */
  56. } xmc_burst_access_mode_type;
  57. /**
  58. * @brief xmc asynchronous wait type
  59. */
  60. typedef enum
  61. {
  62. XMC_ASYN_WAIT_DISABLE = 0x00000000, /*!< xmc wait signal during asynchronous transfers disbale */
  63. XMC_ASYN_WAIT_ENABLE = 0x00008000 /*!< xmc wait signal during asynchronous transfers enable */
  64. } xmc_asyn_wait_type;
  65. /**
  66. * @brief xmc wrapped mode type
  67. */
  68. typedef enum
  69. {
  70. XMC_WRAPPED_MODE_DISABLE = 0x00000000, /*!< xmc direct wrapped burst is disbale */
  71. XMC_WRAPPED_MODE_ENABLE = 0x00000400 /*!< xmc direct wrapped burst is enable */
  72. } xmc_wrap_mode_type;
  73. /**
  74. * @brief xmc write operation type
  75. */
  76. typedef enum
  77. {
  78. XMC_WRITE_OPERATION_DISABLE = 0x00000000, /*!< xmc write operations is disable */
  79. XMC_WRITE_OPERATION_ENABLE = 0x00001000 /*!< xmc write operations is enable */
  80. } xmc_write_operation_type;
  81. /**
  82. * @brief xmc wait signal type
  83. */
  84. typedef enum
  85. {
  86. XMC_WAIT_SIGNAL_DISABLE = 0x00000000, /*!< xmc nwait signal is disable */
  87. XMC_WAIT_SIGNAL_ENABLE = 0x00002000 /*!< xmc nwait signal is enable */
  88. } xmc_wait_signal_type;
  89. /**
  90. * @brief xmc write burst type
  91. */
  92. typedef enum
  93. {
  94. XMC_WRITE_BURST_SYN_DISABLE = 0x00000000, /*!< xmc write operations are always performed in asynchronous mode */
  95. XMC_WRITE_BURST_SYN_ENABLE = 0x00080000 /*!< xmc write operations are performed in synchronous mode */
  96. } xmc_write_burst_type;
  97. /**
  98. * @brief xmc extended mode type
  99. */
  100. typedef enum
  101. {
  102. XMC_WRITE_TIMING_DISABLE = 0x00000000, /*!< xmc write timing disable */
  103. XMC_WRITE_TIMING_ENABLE = 0x00004000 /*!< xmc write timing enable */
  104. } xmc_extended_mode_type;
  105. /**
  106. * @brief xmc nand wait type
  107. */
  108. typedef enum
  109. {
  110. XMC_WAIT_OPERATION_DISABLE = 0x00000000, /*!< xmc wait operation for the nand flash memory bank disable */
  111. XMC_WAIT_OPERATION_ENABLE = 0x00000002 /*!< xmc wait operation for the nand flash memory bank enable */
  112. } xmc_nand_wait_type;
  113. /**
  114. * @brief xmc ecc enable type
  115. */
  116. typedef enum
  117. {
  118. XMC_ECC_OPERATION_DISABLE = 0x00000000, /*!< xmc ecc module disable */
  119. XMC_ECC_OPERATION_ENABLE = 0x00000040 /*!< xmc ecc module enable */
  120. } xmc_ecc_enable_type;
  121. /**
  122. * @brief xmc nor/sram bank type
  123. */
  124. typedef enum
  125. {
  126. XMC_BANK1_NOR_SRAM1 = 0x00000000, /*!< xmc nor/sram subbank1 */
  127. XMC_BANK1_NOR_SRAM4 = 0x00000003 /*!< xmc nor/sram subbank4 */
  128. } xmc_nor_sram_subbank_type;
  129. /**
  130. * @brief xmc class bank type
  131. */
  132. typedef enum
  133. {
  134. XMC_BANK2_NAND = 0x00000010, /*!< xmc nand flash bank2 */
  135. } xmc_class_bank_type;
  136. /**
  137. * @brief xmc memory type
  138. */
  139. typedef enum
  140. {
  141. XMC_DEVICE_SRAM = 0x00000000, /*!< xmc device choice sram */
  142. XMC_DEVICE_PSRAM = 0x00000004, /*!< xmc device choice psram */
  143. XMC_DEVICE_NOR = 0x00000008 /*!< xmc device choice nor flash */
  144. } xmc_memory_type;
  145. /**
  146. * @brief xmc data width type
  147. */
  148. typedef enum
  149. {
  150. XMC_BUSTYPE_8_BITS = 0x00000000, /*!< xmc databuss width 8bits */
  151. XMC_BUSTYPE_16_BITS = 0x00000010 /*!< xmc databuss width 16bits */
  152. } xmc_data_width_type;
  153. /**
  154. * @brief xmc wait signal polarity type
  155. */
  156. typedef enum
  157. {
  158. XMC_WAIT_SIGNAL_LEVEL_LOW = 0x00000000, /*!< xmc nwait active low */
  159. XMC_WAIT_SIGNAL_LEVEL_HIGH = 0x00000200 /*!< xmc nwait active high */
  160. } xmc_wait_signal_polarity_type;
  161. /**
  162. * @brief xmc wait timing type
  163. */
  164. typedef enum
  165. {
  166. XMC_WAIT_SIGNAL_SYN_BEFORE = 0x00000000, /*!< xmc nwait signal is active one data cycle before wait state */
  167. XMC_WAIT_SIGNAL_SYN_DURING = 0x00000800 /*!< xmc nwait signal is active during wait state */
  168. } xmc_wait_timing_type;
  169. /**
  170. * @brief xmc access mode type
  171. */
  172. typedef enum
  173. {
  174. XMC_ACCESS_MODE_A = 0x00000000, /*!< xmc access mode A */
  175. XMC_ACCESS_MODE_B = 0x10000000, /*!< xmc access mode B */
  176. XMC_ACCESS_MODE_C = 0x20000000, /*!< xmc access mode C */
  177. XMC_ACCESS_MODE_D = 0x30000000 /*!< xmc access mode D */
  178. } xmc_access_mode_type;
  179. /**
  180. * @brief xmc ecc page size type
  181. */
  182. typedef enum
  183. {
  184. XMC_ECC_PAGESIZE_256_BYTES = 0x00000000, /*!< xmc ecc page size 256 bytes */
  185. XMC_ECC_PAGESIZE_512_BYTES = 0x00020000, /*!< xmc ecc page size 512 bytes */
  186. XMC_ECC_PAGESIZE_1024_BYTES = 0x00040000, /*!< xmc ecc page size 1024 bytes */
  187. XMC_ECC_PAGESIZE_2048_BYTES = 0x00060000, /*!< xmc ecc page size 2048 bytes */
  188. XMC_ECC_PAGESIZE_4096_BYTES = 0x00080000, /*!< xmc ecc page size 4096 bytes */
  189. XMC_ECC_PAGESIZE_8192_BYTES = 0x000A0000 /*!< xmc ecc page size 8192 bytes */
  190. } xmc_ecc_pagesize_type;
  191. /**
  192. * @brief xmc interrupt sources type
  193. */
  194. typedef enum
  195. {
  196. XMC_INT_RISING_EDGE = 0x00000008, /*!< xmc rising edge detection interrupt enable */
  197. XMC_INT_LEVEL = 0x00000010, /*!< xmc high-level edge detection interrupt enable */
  198. XMC_INT_FALLING_EDGE = 0x00000020 /*!< xmc falling edge detection interrupt enable */
  199. } xmc_interrupt_sources_type;
  200. /**
  201. * @brief xmc interrupt flag type
  202. */
  203. typedef enum
  204. {
  205. XMC_RISINGEDGE_FLAG = 0x00000001, /*!< xmc interrupt rising edge detection flag */
  206. XMC_LEVEL_FLAG = 0x00000002, /*!< xmc interrupt high-level edge detection flag */
  207. XMC_FALLINGEDGE_FLAG = 0x00000004, /*!< xmc interrupt falling edge detection flag */
  208. XMC_FEMPT_FLAG = 0x00000040 /*!< xmc fifo empty flag */
  209. } xmc_interrupt_flag_type;
  210. /**
  211. * @brief nor/sram banks timing parameters
  212. */
  213. typedef struct
  214. {
  215. xmc_nor_sram_subbank_type subbank; /*!< xmc nor/sram subbank */
  216. xmc_extended_mode_type write_timing_enable; /*!< xmc nor/sram write timing enable */
  217. uint32_t addr_setup_time; /*!< xmc nor/sram address setup time */
  218. uint32_t addr_hold_time; /*!< xmc nor/sram address hold time */
  219. uint32_t data_setup_time; /*!< xmc nor/sram data setup time */
  220. uint32_t bus_latency_time; /*!< xmc nor/sram bus latency time */
  221. uint32_t clk_psc; /*!< xmc nor/sram clock prescale */
  222. uint32_t data_latency_time; /*!< xmc nor/sram data latency time */
  223. xmc_access_mode_type mode; /*!< xmc nor/sram access mode */
  224. } xmc_norsram_timing_init_type;
  225. /**
  226. * @brief xmc nor/sram init structure definition
  227. */
  228. typedef struct
  229. {
  230. xmc_nor_sram_subbank_type subbank; /*!< xmc nor/sram subbank */
  231. xmc_data_addr_mux_type data_addr_multiplex; /*!< xmc nor/sram address/data multiplexing enable */
  232. xmc_memory_type device; /*!< xmc nor/sram memory device */
  233. xmc_data_width_type bus_type; /*!< xmc nor/sram data bus width */
  234. xmc_burst_access_mode_type burst_mode_enable; /*!< xmc nor/sram burst mode enable */
  235. xmc_asyn_wait_type asynwait_enable; /*!< xmc nor/sram nwait in asynchronous transfer enable */
  236. xmc_wait_signal_polarity_type wait_signal_lv; /*!< xmc nor/sram nwait polarity */
  237. xmc_wrap_mode_type wrapped_mode_enable; /*!< xmc nor/sram wrapped enable */
  238. xmc_wait_timing_type wait_signal_config; /*!< xmc nor/sram nwait timing configuration */
  239. xmc_write_operation_type write_enable; /*!< xmc nor/sram write enable */
  240. xmc_wait_signal_type wait_signal_enable; /*!< xmc nor/sram nwait in synchronous transfer enable */
  241. xmc_extended_mode_type write_timing_enable; /*!< xmc nor/sram read-write timing different */
  242. xmc_write_burst_type write_burst_syn; /*!< xmc nor/sram memory write mode control */
  243. } xmc_norsram_init_type;
  244. /**
  245. * @brief nand timing parameters xmc
  246. */
  247. typedef struct
  248. {
  249. xmc_class_bank_type class_bank; /*!< xmc nand bank */
  250. uint32_t mem_setup_time; /*!< xmc nand memory setup time */
  251. uint32_t mem_waite_time; /*!< xmc nand memory wait time */
  252. uint32_t mem_hold_time; /*!< xmc nand memory hold time */
  253. uint32_t mem_hiz_time; /*!< xmc nand memory databus high resistance time */
  254. } xmc_nand_timinginit_type;
  255. /**
  256. * @brief xmc nand init structure definition
  257. */
  258. typedef struct
  259. {
  260. xmc_class_bank_type nand_bank; /*!< xmc nand bank */
  261. xmc_nand_wait_type wait_enable; /*!< xmc wait feature enable */
  262. xmc_data_width_type bus_type; /*!< xmc nand bus width */
  263. xmc_ecc_enable_type ecc_enable; /*!< xmc nand ecc enable */
  264. xmc_ecc_pagesize_type ecc_pagesize; /*!< xmc nand ecc page size */
  265. uint32_t delay_time_cycle; /*!< xmc nand cle to re delay */
  266. uint32_t delay_time_ar; /*!< xmc nand ale to re delay */
  267. } xmc_nand_init_type;
  268. typedef struct
  269. {
  270. /**
  271. * @brief xmc bank1 bk1ctrl register, offset:0x00+0x08*(x-1) x= 1 or 4
  272. */
  273. union
  274. {
  275. __IO uint32_t bk1ctrl;
  276. struct
  277. {
  278. __IO uint32_t en : 1; /* [0] */
  279. __IO uint32_t admuxen : 1; /* [1] */
  280. __IO uint32_t dev : 2; /* [3:2] */
  281. __IO uint32_t extmdbw : 2; /* [5:4] */
  282. __IO uint32_t noren : 1; /* [6] */
  283. __IO uint32_t reserved1 : 1; /* [7] */
  284. __IO uint32_t syncben : 1; /* [8] */
  285. __IO uint32_t nwpol : 1; /* [9] */
  286. __IO uint32_t wrapen : 1; /* [10] */
  287. __IO uint32_t nwtcfg : 1; /* [11] */
  288. __IO uint32_t wen : 1; /* [12] */
  289. __IO uint32_t nwsen : 1; /* [13] */
  290. __IO uint32_t rwtd : 1; /* [14] */
  291. __IO uint32_t nwasen : 1; /* [15] */
  292. __IO uint32_t crpgs : 3; /* [18:16] */
  293. __IO uint32_t mwmc : 1; /* [19] */
  294. __IO uint32_t reserved2 : 12;/* [31:20] */
  295. } bk1ctrl_bit;
  296. };
  297. /**
  298. * @brief xmc bank1 bk1tmg register, offset:0x04+0x08*(x-1) x= 1 or 4
  299. */
  300. union
  301. {
  302. __IO uint32_t bk1tmg;
  303. struct
  304. {
  305. __IO uint32_t addrst : 4; /* [3:0] */
  306. __IO uint32_t addrht : 4; /* [7:4] */
  307. __IO uint32_t dtst : 8; /* [15:8] */
  308. __IO uint32_t buslat : 4; /* [19:16] */
  309. __IO uint32_t clkpsc : 4; /* [23:20] */
  310. __IO uint32_t dtlat : 4; /* [27:24] */
  311. __IO uint32_t asyncm : 2; /* [29:28] */
  312. __IO uint32_t reserved1 : 2; /* [31:30] */
  313. } bk1tmg_bit;
  314. };
  315. } xmc_bank1_ctrl_tmg_reg_type;
  316. typedef struct
  317. {
  318. /**
  319. * @brief xmc bank1 bk1tmgwr register, offset:0x104+0x08*(x-1) x= 1 or 4
  320. */
  321. union
  322. {
  323. __IO uint32_t bk1tmgwr;
  324. struct
  325. {
  326. __IO uint32_t addrst : 4; /* [3:0] */
  327. __IO uint32_t addrht : 4; /* [7:4] */
  328. __IO uint32_t dtst : 8; /* [15:8] */
  329. __IO uint32_t buslat : 4; /* [19:16] */
  330. __IO uint32_t reserved1 : 8; /* [27:20] */
  331. __IO uint32_t asyncm : 2; /* [29:28] */
  332. __IO uint32_t reserved2 : 2; /* [31:30] */
  333. } bk1tmgwr_bit;
  334. };
  335. /**
  336. * @brief xmc bank1 reserved register
  337. */
  338. __IO uint32_t reserved1;
  339. } xmc_bank1_tmgwr_reg_type;
  340. /**
  341. * @brief xmc bank1 registers
  342. */
  343. typedef struct
  344. {
  345. /**
  346. * @brief xmc bank1 ctrl and tmg register, offset:0x00~0x1C
  347. */
  348. xmc_bank1_ctrl_tmg_reg_type ctrl_tmg_group[4];
  349. /**
  350. * @brief xmc bank1 reserved register, offset:0x20~0x100
  351. */
  352. __IO uint32_t reserved1[57];
  353. /**
  354. * @brief xmc bank1 tmgwr register, offset:0x104~0x11C
  355. */
  356. xmc_bank1_tmgwr_reg_type tmgwr_group[4];
  357. /**
  358. * @brief xmc bank1 reserved register, offset:0x120~0x21C
  359. */
  360. __IO uint32_t reserved2[63];
  361. /**
  362. * @brief xmc bank1 ext register, offset:0x220~0x22C
  363. */
  364. union
  365. {
  366. __IO uint32_t ext[4];
  367. struct
  368. {
  369. __IO uint32_t buslatw2w : 8; /* [7:0] */
  370. __IO uint32_t buslatr2r : 8; /* [15:8] */
  371. __IO uint32_t reserved1 : 16;/* [31:16] */
  372. } ext_bit[4];
  373. };
  374. } xmc_bank1_type;
  375. /**
  376. * @brief xmc bank2 registers
  377. */
  378. typedef struct
  379. {
  380. /**
  381. * @brief xmc bk2ctrl register, offset:0x60
  382. */
  383. union
  384. {
  385. __IO uint32_t bk2ctrl;
  386. struct
  387. {
  388. __IO uint32_t reserved1 : 1; /* [0] */
  389. __IO uint32_t nwen : 1; /* [1] */
  390. __IO uint32_t en : 1; /* [2] */
  391. __IO uint32_t dev : 1; /* [3] */
  392. __IO uint32_t extmdbw : 2; /* [5:4] */
  393. __IO uint32_t eccen : 1; /* [6] */
  394. __IO uint32_t reserved2 : 2; /* [8:7] */
  395. __IO uint32_t tcr : 4; /* [12:9] */
  396. __IO uint32_t tar : 4; /* [16:13] */
  397. __IO uint32_t eccpgs : 3; /* [19:17] */
  398. __IO uint32_t reserved3 : 12;/* [31:20] */
  399. } bk2ctrl_bit;
  400. };
  401. /**
  402. * @brief xmc bk2is register, offset:0x64
  403. */
  404. union
  405. {
  406. __IO uint32_t bk2is;
  407. struct
  408. {
  409. __IO uint32_t res : 1; /* [0] */
  410. __IO uint32_t hls : 1; /* [1] */
  411. __IO uint32_t fes : 1; /* [2] */
  412. __IO uint32_t reien : 1; /* [3] */
  413. __IO uint32_t hlien : 1; /* [4] */
  414. __IO uint32_t feien : 1; /* [5] */
  415. __IO uint32_t fifoe : 1; /* [6] */
  416. __IO uint32_t reserved1 : 25;/* [31:7] */
  417. } bk2is_bit;
  418. };
  419. /**
  420. * @brief xmc bk2tmgmem register, offset:0x68
  421. */
  422. union
  423. {
  424. __IO uint32_t bk2tmgmem;
  425. struct
  426. {
  427. __IO uint32_t cmst : 8; /* [7:0] */
  428. __IO uint32_t cmwt : 8; /* [15:8] */
  429. __IO uint32_t cmht : 8; /* [23:16] */
  430. __IO uint32_t cmdhizt : 8; /* [31:24] */
  431. } bk2tmgmem_bit;
  432. };
  433. /**
  434. * @brief xmc bk2tmgatt register, offset:0x6C
  435. */
  436. union
  437. {
  438. __IO uint32_t bk2tmgatt;
  439. struct
  440. {
  441. __IO uint32_t amst : 8; /* [7:0] */
  442. __IO uint32_t amwt : 8; /* [15:8] */
  443. __IO uint32_t amht : 8; /* [23:16] */
  444. __IO uint32_t amdhizt : 8; /* [31:24] */
  445. } bk2tmgatt_bit;
  446. };
  447. /**
  448. * @brief xmc reserved register, offset:0x70
  449. */
  450. __IO uint32_t reserved1;
  451. /**
  452. * @brief xmc bk2ecc register, offset:0x74
  453. */
  454. union
  455. {
  456. __IO uint32_t bk2ecc;
  457. struct
  458. {
  459. __IO uint32_t ecc : 32; /* [31:0] */
  460. } bk2ecc_bit;
  461. };
  462. } xmc_bank2_type;
  463. /**
  464. * @}
  465. */
  466. #define XMC_BANK1 ((xmc_bank1_type *) XMC_BANK1_REG_BASE)
  467. #define XMC_BANK2 ((xmc_bank2_type *) XMC_BANK2_REG_BASE)
  468. /** @defgroup XMC_exported_functions
  469. * @{
  470. */
  471. void xmc_nor_sram_reset(xmc_nor_sram_subbank_type xmc_subbank);
  472. void xmc_nor_sram_init(xmc_norsram_init_type* xmc_norsram_init_struct);
  473. void xmc_nor_sram_timing_config(xmc_norsram_timing_init_type* xmc_rw_timing_struct,
  474. xmc_norsram_timing_init_type* xmc_w_timing_struct);
  475. void xmc_norsram_default_para_init(xmc_norsram_init_type* xmc_nor_sram_init_struct);
  476. void xmc_norsram_timing_default_para_init(xmc_norsram_timing_init_type* xmc_rw_timing_struct,
  477. xmc_norsram_timing_init_type* xmc_w_timing_struct);
  478. void xmc_nor_sram_enable(xmc_nor_sram_subbank_type xmc_subbank, confirm_state new_state);
  479. void xmc_ext_timing_config(volatile xmc_nor_sram_subbank_type xmc_sub_bank, uint16_t w2w_timing, uint16_t r2r_timing);
  480. void xmc_nand_reset(xmc_class_bank_type xmc_bank);
  481. void xmc_nand_init(xmc_nand_init_type* xmc_nand_init_struct);
  482. void xmc_nand_timing_config(xmc_nand_timinginit_type* xmc_common_spacetiming_struct,
  483. xmc_nand_timinginit_type* xmc_attribute_spacetiming_struct);
  484. void xmc_nand_default_para_init(xmc_nand_init_type* xmc_nand_init_struct);
  485. void xmc_nand_timing_default_para_init(xmc_nand_timinginit_type* xmc_common_spacetiming_struct,
  486. xmc_nand_timinginit_type* xmc_attribute_spacetiming_struct);
  487. void xmc_nand_enable(xmc_class_bank_type xmc_bank, confirm_state new_state);
  488. void xmc_nand_ecc_enable(xmc_class_bank_type xmc_bank, confirm_state new_state);
  489. uint32_t xmc_ecc_get(xmc_class_bank_type xmc_bank);
  490. void xmc_interrupt_enable(xmc_class_bank_type xmc_bank, xmc_interrupt_sources_type xmc_int, confirm_state new_state);
  491. flag_status xmc_flag_status_get(xmc_class_bank_type xmc_bank, xmc_interrupt_flag_type xmc_flag);
  492. flag_status xmc_interrupt_flag_status_get(xmc_class_bank_type xmc_bank, xmc_interrupt_flag_type xmc_flag);
  493. void xmc_flag_clear(xmc_class_bank_type xmc_bank, xmc_interrupt_flag_type xmc_flag);
  494. /**
  495. * @}
  496. */
  497. /**
  498. * @}
  499. */
  500. /**
  501. * @}
  502. */
  503. #ifdef __cplusplus
  504. }
  505. #endif
  506. #endif