aboutsummaryrefslogtreecommitdiffstats
path: root/keyboards/cannonkeys/stm32f072/keyboard.h
blob: 94c973d6153f06666f81a9b3ec8a859b041cc887 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#pragma once

#include "quantum.h"

typedef union {
    uint8_t raw;
    struct {
        bool    enable :1;
        bool    breathing : 1;
        uint8_t level  :6;
    };
} backlight_config_t;

// Backlighting
extern backlight_config_t kb_backlight_config;
extern bool kb_backlight_breathing;
void backlight_init_ports(void);
void backlight_set(uint8_t level);
bool is_breathing(void);
void breathing_enable(void);
void breathing_disable(void);
void load_custom_config(void);
void save_backlight_config_to_eeprom(void);