mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-06-13 04:33:18 +08:00
bsp:ls2k:add reboot and power command
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
#include <rtthread.h>
|
||||
|
||||
static void reboot()
|
||||
{
|
||||
rt_hw_cpu_reset();
|
||||
}
|
||||
MSH_CMD_EXPORT(reboot, reboot sample);
|
||||
|
||||
|
||||
static void poweroff()
|
||||
{
|
||||
rt_hw_cpu_shutdown();
|
||||
}
|
||||
MSH_CMD_EXPORT(poweroff, shutdown power sample);
|
||||
|
||||
Reference in New Issue
Block a user