When NCP starts-up some of the initialisation functions of a regular OpenThread device do not need to be called, because they get triggered by wpantund via UART. Instead NCP initialisation needs to be called. A small typo has been fixed as well. Also initialisation for raw link packet interface has been added. Can be used for picking up 802.15.4 frames and interpreting them in the application. Signed-off-by: Markus Becker <markus.becker@tridonic.com>
33 lines
575 B
C
33 lines
575 B
C
/*
|
|
* Copyright (c) 2018 Nordic Semiconductor ASA
|
|
*
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
|
|
#include <kernel.h>
|
|
#include <power/reboot.h>
|
|
#include <openthread/instance.h>
|
|
#include <openthread/platform/misc.h>
|
|
|
|
#include "platform-zephyr.h"
|
|
|
|
void otPlatReset(otInstance *aInstance)
|
|
{
|
|
ARG_UNUSED(aInstance);
|
|
|
|
/* This function does nothing on the Posix platform. */
|
|
sys_reboot(SYS_REBOOT_WARM);
|
|
}
|
|
|
|
otPlatResetReason otPlatGetResetReason(otInstance *aInstance)
|
|
{
|
|
ARG_UNUSED(aInstance);
|
|
|
|
return OT_PLAT_RESET_REASON_POWER_ON;
|
|
}
|
|
|
|
void otPlatWakeHost(void)
|
|
{
|
|
/* TODO */
|
|
}
|