aboutsummaryrefslogtreecommitdiff
path: root/src/mode.h
blob: db65fc810faaa619c670b11f3c7dc582d77acbb4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#ifndef _LOADED_MODE
#define _LOADED_MODE
#include <stdint.h>
enum Mode {
  ModeDisplayTime,
  ModeSetTime,
};

enum ButtonState {
  ButtonIdle = 0,
  ButtonActive = 1,
  ButtonPressed = 2,
  ButtonLongPressed = 3,
};

extern enum Mode current_mode;
extern volatile uint8_t new_minutes;
extern volatile uint8_t new_hours;

void apply_button_state(enum ButtonState button_state);

#endif