2017-05-19 01:02:19 +02:00
|
|
|
/*
|
|
|
|
* Copyright (C) Baptiste Clenet
|
|
|
|
*
|
|
|
|
* This file is subject to the terms and conditions of the GNU Lesser
|
|
|
|
* General Public License v2.1. See the file LICENSE in the top level
|
|
|
|
* directory for more details.
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @{
|
|
|
|
* @ingroup net
|
|
|
|
* @file
|
|
|
|
* @brief Implementation of OpenThread misc platform abstraction
|
|
|
|
*
|
|
|
|
* @author Baptiste Clenet <bapclenet@gmail.com>
|
|
|
|
* @}
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
#include "openthread/platform/misc.h"
|
|
|
|
#include "periph/pm.h"
|
|
|
|
|
2018-06-12 17:40:27 +02:00
|
|
|
#define ENABLE_DEBUG (0)
|
|
|
|
#include "debug.h"
|
|
|
|
|
2017-05-19 01:02:19 +02:00
|
|
|
void otPlatReset(otInstance *aInstance)
|
|
|
|
{
|
|
|
|
(void)aInstance;
|
2018-06-12 17:40:27 +02:00
|
|
|
DEBUG("reboot...\n");
|
2017-05-19 01:02:19 +02:00
|
|
|
pm_reboot();
|
|
|
|
}
|
|
|
|
|
|
|
|
otPlatResetReason otPlatGetResetReason(otInstance *aInstance)
|
|
|
|
{
|
|
|
|
(void)aInstance;
|
|
|
|
/* TODO: Write me! */
|
2018-06-12 17:40:27 +02:00
|
|
|
return OT_PLAT_RESET_REASON_POWER_ON;
|
|
|
|
}
|
|
|
|
|
|
|
|
void otPlatWakeHost(void)
|
|
|
|
{
|
|
|
|
/* TODO: implement an operation to wake the host from sleep state. */
|
2017-05-19 01:02:19 +02:00
|
|
|
}
|