diff options
author | Danny Nguyen <danny@80pct.com> | 2017-04-03 13:04:34 -0400 |
---|---|---|
committer | Danny Nguyen <danny@80pct.com> | 2017-04-03 13:24:20 -0400 |
commit | e3aeab356afd52299bf6cf05b5c99995ce167275 (patch) | |
tree | b8a06a928e433dbcbb8395411930ad6fae2a23b0 | |
parent | d90ac762958eb77222a5277d64474f2aa3349176 (diff) | |
download | firmware-e3aeab356afd52299bf6cf05b5c99995ce167275.tar.gz firmware-e3aeab356afd52299bf6cf05b5c99995ce167275.tar.bz2 firmware-e3aeab356afd52299bf6cf05b5c99995ce167275.zip |
Move SSD1306 function declarations to header file
-rw-r--r-- | keyboards/lets_split/keymaps/OLED_sample/keymap.c | 3 | ||||
-rw-r--r-- | keyboards/lets_split/rev2/rev2.c | 1 | ||||
-rw-r--r-- | keyboards/lets_split/rev2/rev2.h | 11 | ||||
-rw-r--r-- | keyboards/lets_split/ssd1306.c | 3 | ||||
-rw-r--r-- | keyboards/lets_split/ssd1306.h | 17 |
5 files changed, 21 insertions, 14 deletions
diff --git a/keyboards/lets_split/keymaps/OLED_sample/keymap.c b/keyboards/lets_split/keymaps/OLED_sample/keymap.c index 072b825ab..493ebcd3f 100644 --- a/keyboards/lets_split/keymaps/OLED_sample/keymap.c +++ b/keyboards/lets_split/keymaps/OLED_sample/keymap.c @@ -6,6 +6,9 @@ #ifdef AUDIO_ENABLE #include "audio.h" #endif +#ifdef SSD1306OLED + #include "ssd1306.h" +#endif extern keymap_config_t keymap_config; diff --git a/keyboards/lets_split/rev2/rev2.c b/keyboards/lets_split/rev2/rev2.c index 8bfa171d0..20a4c6be1 100644 --- a/keyboards/lets_split/rev2/rev2.c +++ b/keyboards/lets_split/rev2/rev2.c @@ -37,4 +37,3 @@ void shutdown_user(void) { stop_all_notes(); #endif } - diff --git a/keyboards/lets_split/rev2/rev2.h b/keyboards/lets_split/rev2/rev2.h index 0603827e0..0c4e8e7de 100644 --- a/keyboards/lets_split/rev2/rev2.h +++ b/keyboards/lets_split/rev2/rev2.h @@ -13,17 +13,6 @@ #include <avr/io.h> #include <avr/interrupt.h> #endif -#ifdef SSD1306OLED - extern bool iota_gfx_init(void); - extern void iota_gfx_task(void); - extern bool iota_gfx_off(void); - extern bool iota_gfx_on(void); - extern void iota_gfx_flush(void); - extern void iota_gfx_write_char(uint8_t c); - extern void iota_gfx_write(const char *data); - extern void iota_gfx_write_P(const char *data); - extern void iota_gfx_clear_screen(void); -#endif #endif //void promicro_bootloader_jmp(bool program); diff --git a/keyboards/lets_split/ssd1306.c b/keyboards/lets_split/ssd1306.c index 3c7816bb3..76348ab7f 100644 --- a/keyboards/lets_split/ssd1306.c +++ b/keyboards/lets_split/ssd1306.c @@ -1,8 +1,7 @@ +#include "ssd1306.h" #include "config.h" #include "i2c.h" -#include <stdbool.h> #include <string.h> -#include <stdio.h> #include "print.h" #include "lets_split.h" #include "common/glcdfont.c" diff --git a/keyboards/lets_split/ssd1306.h b/keyboards/lets_split/ssd1306.h new file mode 100644 index 000000000..b0c74f987 --- /dev/null +++ b/keyboards/lets_split/ssd1306.h @@ -0,0 +1,17 @@ +#ifndef SSD1306_H +#define SSD1306_H + +#include <stdbool.h> +#include <stdio.h> + +bool iota_gfx_init(void); +void iota_gfx_task(void); +bool iota_gfx_off(void); +bool iota_gfx_on(void); +void iota_gfx_flush(void); +void iota_gfx_write_char(uint8_t c); +void iota_gfx_write(const char *data); +void iota_gfx_write_P(const char *data); +void iota_gfx_clear_screen(void); + +#endif |