board.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /*
  2. * Copyright (c) 2006-2022, 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. // <<< Use Configuration Wizard in Context Menu >>>
  11. #ifndef __BOARD_H__
  12. #define __BOARD_H__
  13. #include "fsl_common.h"
  14. #include "clock_config.h"
  15. #define SOC_IMXRT1020_SERIES
  16. #if defined(__CC_ARM) || defined (__CLANG_ARM) || defined (__CLANG_ARM)
  17. extern int Image$$RTT_HEAP$$ZI$$Base;
  18. extern int Image$$RTT_HEAP$$ZI$$Limit;
  19. #define HEAP_BEGIN (&Image$$RTT_HEAP$$ZI$$Base)
  20. #define HEAP_END (&Image$$RTT_HEAP$$ZI$$Limit)
  21. #elif __ICCARM__
  22. #pragma section="HEAP"
  23. #define HEAP_BEGIN (__segment_end("HEAP"))
  24. extern void __RTT_HEAP_END;
  25. #define HEAP_END (&__RTT_HEAP_END)
  26. #else
  27. extern int heap_start;
  28. extern int heap_end;
  29. #define HEAP_BEGIN (&heap_start)
  30. #define HEAP_END (&heap_end)
  31. #endif
  32. #define HEAP_SIZE ((uint32_t)HEAP_END - (uint32_t)HEAP_BEGIN)
  33. /*! @brief The board flash size */
  34. #define BOARD_FLASH_SIZE (0x800000U)
  35. void rt_hw_board_init(void);
  36. #endif