20 lines
643 B
C
20 lines
643 B
C
|
#ifndef __SWM320_WDT_H__
|
|||
|
#define __SWM320_WDT_H__
|
|||
|
|
|||
|
#define WDT_MODE_RESET 0
|
|||
|
#define WDT_MODE_INTERRUPT 1
|
|||
|
|
|||
|
void WDT_Init(WDT_TypeDef *WDTx, uint32_t peroid, uint32_t mode); //WDT<44><54><EFBFBD>Ź<EFBFBD><C5B9><EFBFBD>ʼ<EFBFBD><CABC>
|
|||
|
void WDT_Start(WDT_TypeDef *WDTx); //<2F><><EFBFBD><EFBFBD>ָ<EFBFBD><D6B8>WDT<44><54><EFBFBD><EFBFBD>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD>ʱ
|
|||
|
void WDT_Stop(WDT_TypeDef *WDTx); //<2F>ر<EFBFBD>ָ<EFBFBD><D6B8>WDT<44><54>ֹͣ<CDA3><D6B9><EFBFBD><EFBFBD>ʱ
|
|||
|
|
|||
|
void WDT_Feed(WDT_TypeDef *WDTx); //ι<><CEB9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>´<EFBFBD>װ<EFBFBD><D7B0>ֵ<EFBFBD><D6B5>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD>ʱ
|
|||
|
|
|||
|
int32_t WDT_GetValue(WDT_TypeDef *WDTx); //<2F><>ȡָ<C8A1><D6B8><EFBFBD><EFBFBD><EFBFBD>Ź<EFBFBD><C5B9><EFBFBD>ʱ<EFBFBD><CAB1><EFBFBD>ĵ<EFBFBD>ǰ<EFBFBD><C7B0><EFBFBD><EFBFBD>ʱֵ
|
|||
|
|
|||
|
|
|||
|
void WDT_INTClr(WDT_TypeDef *WDTx); //<2F>жϱ<D0B6>־<EFBFBD><D6BE><EFBFBD><EFBFBD>
|
|||
|
uint32_t WDT_INTStat(WDT_TypeDef *WDTx); //<2F>ж<EFBFBD>״̬<D7B4><CCAC>ѯ
|
|||
|
|
|||
|
#endif //__SWM320_WDT_H__
|