board.h 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. /*
  2. * COPYRIGHT (C) 2013-2014, Shanghai Real-Thread Technology Co., Ltd
  3. *
  4. * All rights reserved.
  5. *
  6. * This program is free software; you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License as published by
  8. * the Free Software Foundation; either version 2 of the License, or
  9. * (at your option) any later version.
  10. *
  11. * This program is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. * GNU General Public License for more details.
  15. *
  16. * You should have received a copy of the GNU General Public License along
  17. * with this program; if not, write to the Free Software Foundation, Inc.,
  18. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  19. */
  20. #ifndef __BOARD_H__
  21. #define __BOARD_H__
  22. #include <zynq7000.h>
  23. /* Freq of all peripherals */
  24. #define APU_FREQ 666666667
  25. #define DDR_FREQ 533333313
  26. #define DCI_FREQ 10159000
  27. #define QSPI_FREQ 200000000
  28. #define SMC_FREQ 100000000
  29. #define ENET0_FREQ 125000000
  30. #define ENET1_FREQ 125000000
  31. #define USB0_FREQ 60000000
  32. #define USB1_FREQ 60000000
  33. #define SDIO_FREQ 50000000
  34. #define UART_FREQ 50000000
  35. #define SPI_FREQ 166666666
  36. #define I2C_FREQ 25000000
  37. #define WDT_FREQ 133333333
  38. #define TTC_FREQ 50000000
  39. #define CAN_FREQ 100000000
  40. #define PCAP_FREQ 200000000
  41. #define TPIU_FREQ 0
  42. #define FPGA0_FREQ 100000000
  43. #define FPGA1_FREQ 200000000
  44. #define FPGA2_FREQ 200000000
  45. #define FPGA3_FREQ 80000000
  46. #if defined(__CC_ARM)
  47. extern int Image$$RW_IRAM1$$ZI$$Limit;
  48. #define HEAP_BEGIN ((void*)&Image$$RW_IRAM1$$ZI$$Limit)
  49. #elif defined(__GNUC__)
  50. extern int __bss_end;
  51. #define HEAP_BEGIN ((void*)&__bss_end)
  52. #endif
  53. #define HEAP_END (void*)(0x20000000)
  54. void rt_hw_board_init();
  55. int rt_hw_uart_init(void);
  56. #endif