[NUC472] Fix RTC macro function with no arguments in BSP

pull/5157/head
ccli8 2017-09-04 15:01:31 +08:00
parent 6eb4e11b37
commit 83fc132b97
1 changed files with 5 additions and 5 deletions

View File

@ -129,7 +129,7 @@ typedef struct {
* 1 = This year is a leap year.
* \hideinitializer
*/
#define RTC_IS_LEAP_YEAR ((RTC->LEAPYEAR & (RTC_LEAPYEAR_LEAPYEAR_Msk))?1:0)
#define RTC_IS_LEAP_YEAR() ((RTC->LEAPYEAR & (RTC_LEAPYEAR_LEAPYEAR_Msk))?1:0)
/**
* @brief Clear alarm interrupt status.
@ -139,7 +139,7 @@ typedef struct {
* @return None
* \hideinitializer
*/
#define RTC_CLEAR_ALARM_INT_FLAG (RTC->INTSTS = RTC_INTSTS_ALMIF_Msk)
#define RTC_CLEAR_ALARM_INT_FLAG() (RTC->INTSTS = RTC_INTSTS_ALMIF_Msk)
/**
* @brief Clear tick interrupt status.
@ -149,7 +149,7 @@ typedef struct {
* @return None
* \hideinitializer
*/
#define RTC_CLEAR_TICK_INT_FLAG (RTC->INTSTS = RTC_INTSTS_TICKIF_Msk)
#define RTC_CLEAR_TICK_INT_FLAG() (RTC->INTSTS = RTC_INTSTS_TICKIF_Msk)
/**
* @brief Clear tamper detect pin status.
@ -169,7 +169,7 @@ typedef struct {
* @return Alarm interrupt status
* \hideinitializer
*/
#define RTC_GET_ALARM_INT_FLAG ((RTC->INTSTS & RTC_INTSTS_ALMIF_Msk) >> RTC_INTSTS_ALMIF_Pos)
#define RTC_GET_ALARM_INT_FLAG() ((RTC->INTSTS & RTC_INTSTS_ALMIF_Msk) >> RTC_INTSTS_ALMIF_Pos)
/**
* @brief Get alarm interrupt status.
@ -179,7 +179,7 @@ typedef struct {
* @return Alarm interrupt status
* \hideinitializer
*/
#define RTC_GET_TICK_INT_FLAG ((RTC->INTSTS & RTC_INTSTS_TICKIF_Msk) >> RTC_INTSTS_TICKIF_Pos)
#define RTC_GET_TICK_INT_FLAG() ((RTC->INTSTS & RTC_INTSTS_TICKIF_Msk) >> RTC_INTSTS_TICKIF_Pos)
/**
* @brief Get tamper detect pin status.