at91_ebi.h 5.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123
  1. #ifndef _ARCH_ARM_AT91_EBI_H_
  2. #define _ARCH_ARM_AT91_EBI_H_
  3. /*
  4. * Copyright (C) 2005-2006 by egnite Software GmbH. All rights reserved.
  5. *
  6. * Redistribution and use in source and binary forms, with or without
  7. * modification, are permitted provided that the following conditions
  8. * are met:
  9. *
  10. * 1. Redistributions of source code must retain the above copyright
  11. * notice, this list of conditions and the following disclaimer.
  12. * 2. Redistributions in binary form must reproduce the above copyright
  13. * notice, this list of conditions and the following disclaimer in the
  14. * documentation and/or other materials provided with the distribution.
  15. * 3. Neither the name of the copyright holders nor the names of
  16. * contributors may be used to endorse or promote products derived
  17. * from this software without specific prior written permission.
  18. *
  19. * THIS SOFTWARE IS PROVIDED BY EGNITE SOFTWARE GMBH AND CONTRIBUTORS
  20. * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  21. * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
  22. * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL EGNITE
  23. * SOFTWARE GMBH OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
  24. * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
  25. * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
  26. * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
  27. * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  28. * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
  29. * THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  30. * SUCH DAMAGE.
  31. *
  32. * For additional information see http://www.ethernut.de/
  33. */
  34. /*!
  35. * \file arch/arm/at91_ebi.h
  36. * \brief AT91 peripherals.
  37. *
  38. * \verbatim
  39. *
  40. * $Log: at91_ebi.h,v $
  41. * Revision 1.1 2006/07/05 07:45:25 haraldkipp
  42. * Split on-chip interface definitions.
  43. *
  44. *
  45. * \endverbatim
  46. */
  47. /*!
  48. * \addtogroup xgNutArchArmAt91Ebi
  49. */
  50. /*@{*/
  51. /*! \name Chip Select Register */
  52. /*@{*/
  53. #define EBI_CSR(i) (EBI_BASE + i * 4) /*!< \brief Chip select register address. */
  54. #define EBI_DBW 0x00000003 /*!< \brief Masks data bus width. */
  55. #define EBI_DBW_16 0x00000001 /*!< \brief 16-bit data bus width. */
  56. #define EBI_DBW_8 0x00000002 /*!< \brief 8-bit data bus width. */
  57. #define EBI_NWS 0x0000001C /*!< \brief Masks number of wait states. */
  58. #define EBI_NWS_1 0x00000000 /*!< \brief 1 wait state. */
  59. #define EBI_NWS_2 0x00000004 /*!< \brief 2 wait states. */
  60. #define EBI_NWS_3 0x00000008 /*!< \brief 3 wait states. */
  61. #define EBI_NWS_4 0x0000000C /*!< \brief 4 wait states. */
  62. #define EBI_NWS_5 0x00000010 /*!< \brief 5 wait states. */
  63. #define EBI_NWS_6 0x00000014 /*!< \brief 6 wait states. */
  64. #define EBI_NWS_7 0x00000018 /*!< \brief 7 wait states. */
  65. #define EBI_NWS_8 0x0000001C /*!< \brief 8 wait states. */
  66. #define EBI_WSE 0x00000020 /*!< \brief Wait state enable. */
  67. #define EBI_PAGES 0x00000180 /*!< \brief Page size mask. */
  68. #define EBI_PAGES_1M 0x00000000 /*!< \brief 1 MByte page size. */
  69. #define EBI_PAGES_4M 0x00000080 /*!< \brief 4 MBytes page size. */
  70. #define EBI_PAGES_16M 0x00000100 /*!< \brief 16 MBytes page size. */
  71. #define EBI_PAGES_64M 0x00000180 /*!< \brief 64 MBytes page size. */
  72. #define EBI_TDF 0x00000E00 /*!< \brief Masks data float output time clock cycles. */
  73. #define EBI_TDF_0 0x00000000 /*!< \brief No added cycles. */
  74. #define EBI_TDF_1 0x00000200 /*!< \brief 1 cycle. */
  75. #define EBI_TDF_2 0x00000400 /*!< \brief 2 cycles. */
  76. #define EBI_TDF_3 0x00000600 /*!< \brief 3 cycles. */
  77. #define EBI_TDF_4 0x00000800 /*!< \brief 4 cycles. */
  78. #define EBI_TDF_5 0x00000A00 /*!< \brief 5 cycles. */
  79. #define EBI_TDF_6 0x00000C00 /*!< \brief 6 cycles. */
  80. #define EBI_TDF_7 0x00000E00 /*!< \brief 7 cycles. */
  81. #define EBI_BAT 0x00001000 /*!< \brief Byte access type */
  82. #define EBI_BAT_BYTE_WRITE 0x00000000 /*!< \brief Byte write access type */
  83. #define EBI_BAT_BYTE_SELECT 0x00001000 /*!< \brief Byte select access type */
  84. #define EBI_CSEN 0x00002000 /*!< \brief Chip select enable */
  85. #define EBI_BA 0xFFF00000 /*!< \brief Page base address mask. */
  86. /*@}*/
  87. /*! \name Remap Control Register */
  88. /*@{*/
  89. #define EBI_RCR (EBI_BASE + 0x20) /*!< \brief Remap control register address. */
  90. #define EBI_RCB 0x00000001 /*!< \brief Remap command. */
  91. /*@}*/
  92. /*! \name Memory Control Register */
  93. /*@{*/
  94. #define EBI_MCR (EBI_BASE + 0x24) /*!< \brief Memory control register address. */
  95. #define EBI_ALE 0x00000007 /*!< \brief Address line enable */
  96. #define EBI_ALE_16M 0x00000000 /*!< \brief 16 Mbytes total address space. */
  97. #define EBI_ALE_8M 0x00000004 /*!< \brief 8 Mbytes total address space. */
  98. #define EBI_ALE_4M 0x00000005 /*!< \brief 4 Mbytes total address space. */
  99. #define EBI_ALE_2M 0x00000006 /*!< \brief 2 Mbytes total address space. */
  100. #define EBI_ALE_1M 0x00000007 /*!< \brief 1 Mbyte total address space. */
  101. #define EBI_DRP 0x00000010 /*!< \brief Data read protocol mask. */
  102. #define EBI_DRP_STANDARD 0x00000000 /*!< \brief Standard read protocol. */
  103. #define EBI_DRP_EARLY 0x00000010 /*!< \brief Early read protocol. */
  104. /*@}*/
  105. /*@} xgNutArchArmAt91Ebi */
  106. #endif /* _ARCH_ARM_AT91_EBI_H_ */