board.h 3.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. /****************************************************************************
  2. * boards/z80/ez80/z20x/include/board.h
  3. *
  4. * Licensed to the Apache Software Foundation (ASF) under one or more
  5. * contributor license agreements. See the NOTICE file distributed with
  6. * this work for additional information regarding copyright ownership. The
  7. * ASF licenses this file to you under the Apache License, Version 2.0 (the
  8. * "License"); you may not use this file except in compliance with the
  9. * License. You may obtain a copy of the License at
  10. *
  11. * http://www.apache.org/licenses/LICENSE-2.0
  12. *
  13. * Unless required by applicable law or agreed to in writing, software
  14. * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
  15. * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
  16. * License for the specific language governing permissions and limitations
  17. * under the License.
  18. *
  19. ****************************************************************************/
  20. #ifndef __BOARDS_Z80_EZ80_Z20X_INCLUDE_BOARD_H
  21. #define __BOARDS_Z80_EZ80_Z20X_INCLUDE_BOARD_H
  22. /****************************************************************************
  23. * Included Files
  24. ****************************************************************************/
  25. #include <stdint.h>
  26. /****************************************************************************
  27. * Pre-processor Definitions
  28. ****************************************************************************/
  29. /* Clocking
  30. *
  31. * The z20x CPU board has a 20Mhz crystal. The eZ80F92 has no PLL; the
  32. * system clock frequency is equal to the crystal frequency of 20MHz, the
  33. * maximum for the eZ80F92 part.
  34. */
  35. #define EZ80_SYS_CLK_FREQ 20000000
  36. /* LEDs */
  37. /* The D3 GREEN LED is driven by an eZ80 GPI/O pin. However, it has some
  38. * additional properties:
  39. *
  40. * 1. On input, it will be '1' if the I/O expansion board is present.
  41. * 2. Setting it to an output of '0' will generate a system reset.
  42. * 3. Setting it to an output of '1' will not only illuminate the LED
  43. * take the card out of reset and enable power to the SD card slot.
  44. *
  45. * As a consequence, the GREEN LED will not be illuminated if SD card
  46. * support or SPI is disabled. The only effect of CONFIG_ARCH_LEDS is that
  47. * the GREEN LED will turned off in the event of a crash.
  48. */
  49. #define LED_STARTED 0
  50. #define LED_HEAPALLOCATE 0
  51. #define LED_IRQSENABLED 0
  52. #define LED_STACKCREATED 0
  53. #define LED_IDLE 0
  54. #define LED_INIRQ 0
  55. #define LED_ASSERTION 0
  56. #define LED_SIGNAL 0
  57. #define LED_PANIC 1
  58. /* Button definitions
  59. * The z20x CPU board has no on-board buttons that can be sensed by the
  60. * eZ80.
  61. */
  62. /****************************************************************************
  63. * Public Functions
  64. ****************************************************************************/
  65. #undef EXTERN
  66. #if defined(__cplusplus)
  67. #define EXTERN extern "C"
  68. extern "C"
  69. {
  70. #else
  71. #define EXTERN extern
  72. #endif
  73. #undef EXTERN
  74. #if defined(__cplusplus)
  75. }
  76. #endif
  77. #endif /* __BOARDS_Z80_EZ80_Z20X_INCLUDE_BOARD_H */