未验证 提交 47e79990 编写于 作者: B Bernard Xiong 提交者: GitHub

Merge pull request #4438 from supperthomas/supperthomas

[bsp/max32660]add the fixed code
......@@ -66,3 +66,16 @@ void rt_hw_board_init(void)
#endif
}
void rt_hw_us_delay(rt_uint32_t us)
{
rt_uint32_t start, now, delta, reload, us_tick;
start = SysTick->VAL;
reload = SysTick->LOAD;
us_tick = SystemCoreClock / 1000000UL;
do
{
now = SysTick->VAL;
delta = start >= now ? start - now : reload + start - now;
}
while (delta < us_tick * us);
}
......@@ -62,6 +62,7 @@ if PLATFORM == 'gcc':
elif PLATFORM == 'armcc':
# toolchains
CC = 'armcc'
CXX = 'armcc'
AS = 'armasm'
AR = 'armar'
LINK = 'armlink'
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册