/*
 * hal.c
 *
 *  Created on: 14.06.2017
 *      Author: balbekova
 */


#include "stm32f4xx.h"
#ifndef BT6702_SERVICE
#include "log.h"
#include "snmp_api.h"
#include "trap_api.h"
#endif
#include <stddef.h>
#include "FreeRTOS.h"
#include "task.h"

void Reboot(void) {
#ifndef BT6702_SERVICE
	SNMP_SendUserTrap(DEVICE_REBOOTED);
#if defined HARDWARE_BT6707 || HARDWARE_BT6709
	  if(telnet_act)
		  log_event_data(LOG_SYSTEM_BOOT, name_login_telnet);
	  else
#endif
		  log_event_data(LOG_SYSTEM_BOOT, name_login);

	vTaskDelay(1010);
	LOG_Disable();
#endif
    NVIC_SystemReset();
}

