1 /*
2  * Copyright (c) 2006-2021, RT-Thread Development Team
3  *
4  * SPDX-License-Identifier: Apache-2.0
5  *
6  * Change Logs:
7  * Date           Author       Notes
8  * 2020-08-20     zx.chen      add T-HEAD header file csi_core.h
9  */
10 
11 #include <rthw.h>
12 #include <rtthread.h>
13 
14 #include "board.h"
15 #include "csi_core.h"
16 #include "drv_usart.h"
17 
18 extern int __bss_end__;
19 #define SYS_HEAP_BEGIN    (&__bss_end__)
20 
21 #include "core_rv32.h"
22 
23 
24 extern usart_handle_t console_handle;
25 extern void ioreuse_initial(void);
26 extern int rt_hw_usart_init(void);
27 
28 /**
29  * This function will initial smart-evb board.
30  */
rt_hw_board_init(void)31 void rt_hw_board_init(void)
32 {
33 #ifdef RT_USING_COMPONENTS_INIT
34     rt_components_board_init();
35 #endif
36     /* initialize hardware usart */
37     rt_hw_usart_init();
38 
39 #if defined(RT_USING_CONSOLE) && defined(RT_USING_DEVICE)
40     rt_console_set_device(RT_CONSOLE_DEVICE_NAME);
41 #endif
42 
43 #ifdef RT_USING_HEAP
44     rt_system_heap_init((void *)SYS_HEAP_BEGIN, (void *)E906FD_IRAM_END);
45 #endif
46 }
47 
48 /*@}*/
49