drv_sdram.h 909 B

1234567891011121314151617181920212223242526272829303132333435
  1. /*
  2. * File : drv_sdram.h
  3. * This file is part of RT-Thread RTOS
  4. * COPYRIGHT (C) 2009-2013 RT-Thread Develop Team
  5. *
  6. * The license and distribution terms for this file may be
  7. * found in the file LICENSE in this distribution or at
  8. * http://www.rt-thread.org/license/LICENSE
  9. *
  10. * Change Logs:
  11. * Date Author Notes
  12. * 2013-05-19 Bernard The first version for LPC40xx
  13. */
  14. #ifndef __DRV_SDRAM_H__
  15. #define __DRV_SDRAM_H__
  16. #include <board.h>
  17. #define SDRAM_CONFIG_16BIT //use the 16 bitSDRAM
  18. //#define SDRAM_CONFIG_32BIT //use the 32 bitSDRAM
  19. #ifdef SDRAM_CONFIG_16BIT
  20. #define SDRAM_SIZE 0x2000000 // 256Mbit
  21. #elif defined SDRAM_CONFIG_32BIT //
  22. #define SDRAM_SIZE 0x4000000 // 512Mbit
  23. #else
  24. error Wrong SDRAM config, check ex_sdram.h
  25. #endif
  26. #define SDRAM_BASE 0xA0000000 /* CS0 */
  27. void lpc_sdram_hw_init(void);
  28. #endif