board.h 969 B

12345678910111213141516171819202122232425262728293031323334353637
  1. /*
  2. * Copyright (c) 2006-2018, RT-Thread Development Team
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. *
  6. * Change Logs:
  7. * Date Author Notes
  8. * 2009-09-22 Bernard add board.h to this bsp
  9. */
  10. #ifndef __BOARD_H__
  11. #define __BOARD_H__
  12. #include "stm32f7xx_hal.h"
  13. /* whether use board external SDRAM memory */
  14. #define EXT_SDRAM_BEGIN (0xC0000000)
  15. #define EXT_SDRAM_SIZE (0x800000)
  16. #define EXT_SDRAM_END (EXT_SDRAM_BEGIN + EXT_SDRAM_SIZE)
  17. #if defined(__CC_ARM) || defined(__CLANG_ARM)
  18. extern int Image$$RW_IRAM1$$ZI$$Limit;
  19. #define HEAP_BEGIN (&Image$$RW_IRAM1$$ZI$$Limit)
  20. #elif __ICCARM__
  21. #pragma section="HEAP"
  22. #define HEAP_BEGIN (__segment_end("HEAP"))
  23. #else
  24. extern int __bss_end;
  25. #define HEAP_BEGIN (&__bss_end)
  26. #endif
  27. #define STM32_SRAM_SIZE (512)
  28. #define HEAP_END (0x20000000 + STM32_SRAM_SIZE * 1024)
  29. #define HEAP_SIZE (HEAP_END - (rt_uint32_t)HEAP_BEGIN)
  30. extern void rt_hw_board_init(void);
  31. #endif