reboot kommando
This commit is contained in:
parent
6b980f97ba
commit
5dc70bde82
@ -35,6 +35,7 @@ uint16_t set_dutyCyle (CLI_OutFunction pfvOutFunction, char *acCommands[], uint1
|
||||
uint16_t ist_werte(CLI_OutFunction pfvOutFunction, char *acCommands[], uint16_t u16ArgCount);
|
||||
uint16_t set_ucall(CLI_OutFunction pfvOutFunction, char *acCommands[], uint16_t u16ArgCount);
|
||||
uint16_t set_icall(CLI_OutFunction pfvOutFunction, char *acCommands[], uint16_t u16ArgCount);
|
||||
uint16_t reboot(CLI_OutFunction pfvOutFunction, char *acCommands[], uint16_t u16ArgCount);
|
||||
|
||||
static CLI_Command_t commands[] =
|
||||
{
|
||||
@ -42,7 +43,8 @@ static CLI_Command_t commands[] =
|
||||
{ "ist", "Zeige Istwerte an [-r für wiederholende Anzeige]", ist_werte },
|
||||
{ "fan", "Setze Tastverhältnis für Lüfter", set_dutyCyle },
|
||||
{ "icall", "Starte Strom Kalibrierung", set_icall },
|
||||
{ "ucall", "Starte Spannungs Kalibrierung", set_ucall }
|
||||
{ "ucall", "Starte Spannungs Kalibrierung", set_ucall },
|
||||
{ "reboot", "System neu starten", reboot },
|
||||
};
|
||||
|
||||
static std::uint32_t i_soll = 0U;
|
||||
@ -228,6 +230,13 @@ uint16_t set_icall(CLI_OutFunction pfvOutFunction, char *acCommands[], uint16_t
|
||||
return 0U;
|
||||
}
|
||||
|
||||
uint16_t reboot(CLI_OutFunction pfvOutFunction, char *acCommands[], uint16_t u16ArgCount)
|
||||
{
|
||||
printf("\r\nReboot System...");
|
||||
while(!LL_LPUART_IsActiveFlag_TC(LPUART1));
|
||||
NVIC_SystemReset();
|
||||
}
|
||||
|
||||
static bool do_icall(iADC& adc, iI2C& eeprom)
|
||||
{
|
||||
bool done = false;
|
||||
|
Loading…
x
Reference in New Issue
Block a user