写了个demo亮led,改了之后Finsh不能在输入了,这是怎么回事
void led_thread_init(void *ctx)
{
rt_kprintf("Hello, led
");
rt_pin_mode(24, PIN_MODE_OUTPUT);
while(1)
{
//rt_kprintf("set high
");
rt_pin_write(24,PIN_HIGH);
rt_thread_delay(50);
//rt_kprintf("set low
");
rt_pin_write(24,PIN_LOW);
rt_thread_delay(50);
}
}
int main(void)
{
rt_kprintf("Hello, world
");
rt_thread_t tid;
tid = rt_thread_create("led",
led_thread_init, RT_NULL,
512, 8, 10);
if(tid != RT_NULL)
{
rt_thread_startup(tid);
}
return 0;
}
这个是打印的Log,但无法在输入了。
initialize rt_hw_pin_init:0 done
\ | /
RT - Thread Operating System
/ | \ 4.0.2 build Aug 23 2019
2006 - 2019 Copyright by rt-thread team
do components initialization.
initialize rti_board_end:0 done
initialize dfs_init:0 done
initialize rt_hw_spi_init:0 done
initialize elm_init:0 done
initialize libc_system_init:0 done
initialize mnt_init:0 done
initialize finsh_system_init:0 done
Hsh />world
Hello, led
更多回帖