/* 
 * File:   alarms.h
 * Author: User
 *
 * Created on 11 December 2015, 11:18 AM
 */

#ifndef ALARMS_H
#define	ALARMS_H

#ifdef	__cplusplus
extern "C" {
#endif


extern int alarm_timer, snooze;
extern unsigned char alarm_is_daily_type;

__attribute__((mips16)) void alarm_toggle_global_flag();
__attribute__((mips16)) void alarm_trigger(rtccTime* time, unsigned char daily_type);
__attribute__((mips16)) unsigned char alarm_get_piezo_state(rtccTime* time, rtccDate* date);
__attribute__((mips16)) void alarm_snooze(rtccDate* date);
__attribute__((mips16)) void alarm_cancel();
__attribute__((mips16)) unsigned char alarm_is_in_next_24_hours(rtccTime* time, rtccDate* date);
#define alarm_is_snoozed() (snooze > 0)
//__attribute__((mips16)) unsigned char alarm_is_snoozed();

#ifdef	__cplusplus
}
#endif

#endif	/* ALARMS_H */

