#ifndef _BSP_H
#define _BSP_H


#include "stm8l15x.h"
#include "math.h"
#include <stdio.h>
#include "bsp_gpio.h"
#include "bsp_time.h"
#include "bsp_usart.h"
#include "stm8l15x_itc.h"
#include "stm8l15x_iwdg.h"


#define  IWDG_500MS_REST  (uint8_t)250
#define  IWDG_400MS_REST  (uint8_t)200
#define  IWDG_300MS_REST  (uint8_t)150
#define  IWDG_250MS_REST  (uint8_t)125
#define  IWDG_200MS_REST  (uint8_t)100
#define  IWDG_100MS_REST  (uint8_t)50
#define  IWDG_50MS_REST   (uint8_t)25
#define  IWDG_4MS_REST    (uint8_t)2

void WatchDogInit(void);
void FeedWatchDog(void);
void bsp_init(void);
#endif