Utility

The components of the GR-SAKURA Utility library can be found below.

system_reboot

Description
Reset
Syntax
void system_reboot(mode)
Parameters
mode: Specify the mode of reset (REBOOT_USERAPP or REBOOT_FIRMWARE).
Returns
None
Note
Specify #include <reboot.h> for use.

Sample Program

This example shows a reset every 1 second.


#include <Arduino.h>
#include <reboot.h>

void setup()
{
    pinMode(PIN_LED0, OUTPUT);
    digitalWrite(PIN_LED0, HIGH);
 
    delay(1000);
 
    system_reboot(REBOOT_USERAPP);
//    system_reboot(REBOOT_FIRMWARE);
 
}
 
void loop()
{
}