Rename ledmatrix.h to match .c file (#7949)
This commit is contained in:
parent
8fc8a940b9
commit
6b3e56b889
20 changed files with 31 additions and 31 deletions
|
@ -5,7 +5,7 @@
|
||||||
#include "matrix.h"
|
#include "matrix.h"
|
||||||
|
|
||||||
#include "i2c_master.h"
|
#include "i2c_master.h"
|
||||||
#include "led_matrix.h" //For led keycodes
|
#include "md_rgb_matrix.h" //For led keycodes
|
||||||
#include "usb/udi_cdc.h"
|
#include "usb/udi_cdc.h"
|
||||||
#include "usb/usb2422.h"
|
#include "usb/usb2422.h"
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifdef RGB_MATRIX_ENABLE
|
#ifdef RGB_MATRIX_ENABLE
|
||||||
#include "alt.h"
|
#include "alt.h"
|
||||||
|
|
||||||
#include "led_matrix.h"
|
#include "md_rgb_matrix.h"
|
||||||
#include "rgb_matrix.h"
|
#include "rgb_matrix.h"
|
||||||
#include "config_led.h"
|
#include "config_led.h"
|
||||||
|
|
||||||
|
@ -52,7 +52,7 @@ led_config_t g_led_config = { {
|
||||||
#ifdef USB_LED_INDICATOR_ENABLE
|
#ifdef USB_LED_INDICATOR_ENABLE
|
||||||
void rgb_matrix_indicators_kb(void)
|
void rgb_matrix_indicators_kb(void)
|
||||||
{
|
{
|
||||||
led_matrix_indicators();
|
md_rgb_matrix_indicators();
|
||||||
}
|
}
|
||||||
#endif // USB_LED_INDICATOR_ENABLE
|
#endif // USB_LED_INDICATOR_ENABLE
|
||||||
|
|
||||||
|
|
|
@ -173,7 +173,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||||
led_instruction_t led_instructions[] = {
|
led_instruction_t led_instructions[] = {
|
||||||
//LEDs are normally inactive, no processing is performed on them
|
//LEDs are normally inactive, no processing is performed on them
|
||||||
//Flags are used in matching criteria for an LED to be active and indicate how to color it
|
//Flags are used in matching criteria for an LED to be active and indicate how to color it
|
||||||
//Flags can be found in tmk_core/protocol/arm_atsam/led_matrix.h (prefixed with LED_FLAG_)
|
//Flags can be found in tmk_core/protocol/arm_atsam/md_rgb_matrix.h (prefixed with LED_FLAG_)
|
||||||
//LED IDs can be found in config_led.h in the keyboard's directory
|
//LED IDs can be found in config_led.h in the keyboard's directory
|
||||||
//Examples are below
|
//Examples are below
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#include "quantum.h"
|
#include "quantum.h"
|
||||||
#include "led_matrix.h"
|
#include "md_rgb_matrix.h"
|
||||||
|
|
||||||
extern issi3733_led_t *led_cur;
|
extern issi3733_led_t *led_cur;
|
||||||
extern uint8_t led_per_run;
|
extern uint8_t led_per_run;
|
||||||
|
@ -76,7 +76,7 @@ void rgb_matrix_init_user(void) {
|
||||||
led_cur_index = 0;
|
led_cur_index = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void led_matrix_run(void) {
|
void md_rgb_matrix_run(void) {
|
||||||
uint8_t led_this_run = 0;
|
uint8_t led_this_run = 0;
|
||||||
|
|
||||||
if (led_cur == 0) { //Denotes start of new processing cycle in the case of chunked processing
|
if (led_cur == 0) { //Denotes start of new processing cycle in the case of chunked processing
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifdef RGB_MATRIX_ENABLE
|
#ifdef RGB_MATRIX_ENABLE
|
||||||
#include "ctrl.h"
|
#include "ctrl.h"
|
||||||
|
|
||||||
#include "led_matrix.h"
|
#include "md_rgb_matrix.h"
|
||||||
#include "rgb_matrix.h"
|
#include "rgb_matrix.h"
|
||||||
#include "config_led.h"
|
#include "config_led.h"
|
||||||
|
|
||||||
|
@ -75,7 +75,7 @@ led_config_t g_led_config = { {
|
||||||
#ifdef USB_LED_INDICATOR_ENABLE
|
#ifdef USB_LED_INDICATOR_ENABLE
|
||||||
void rgb_matrix_indicators_kb(void)
|
void rgb_matrix_indicators_kb(void)
|
||||||
{
|
{
|
||||||
led_matrix_indicators();
|
md_rgb_matrix_indicators();
|
||||||
}
|
}
|
||||||
#endif // USB_LED_INDICATOR_ENABLE
|
#endif // USB_LED_INDICATOR_ENABLE
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
#include "matrix.h"
|
#include "matrix.h"
|
||||||
|
|
||||||
#include "i2c_master.h"
|
#include "i2c_master.h"
|
||||||
#include "led_matrix.h" //For led keycodes
|
#include "md_rgb_matrix.h" //For led keycodes
|
||||||
#include "usb/udi_cdc.h"
|
#include "usb/udi_cdc.h"
|
||||||
#include "usb/usb2422.h"
|
#include "usb/usb2422.h"
|
||||||
|
|
||||||
|
|
|
@ -186,7 +186,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||||
led_instruction_t led_instructions[] = {
|
led_instruction_t led_instructions[] = {
|
||||||
//LEDs are normally inactive, no processing is performed on them
|
//LEDs are normally inactive, no processing is performed on them
|
||||||
//Flags are used in matching criteria for an LED to be active and indicate how to color it
|
//Flags are used in matching criteria for an LED to be active and indicate how to color it
|
||||||
//Flags can be found in tmk_core/protocol/arm_atsam/led_matrix.h (prefixed with LED_FLAG_)
|
//Flags can be found in tmk_core/protocol/arm_atsam/md_rgb_matrix.h (prefixed with LED_FLAG_)
|
||||||
//LED IDs can be found in config_led.h in the keyboard's directory
|
//LED IDs can be found in config_led.h in the keyboard's directory
|
||||||
//Examples are below
|
//Examples are below
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifdef RGB_MATRIX_ENABLE
|
#ifdef RGB_MATRIX_ENABLE
|
||||||
#include "ctrl.h"
|
#include "ctrl.h"
|
||||||
|
|
||||||
#include "led_matrix.h"
|
#include "md_rgb_matrix.h"
|
||||||
#include "rgb_matrix.h"
|
#include "rgb_matrix.h"
|
||||||
#include "config_led.h"
|
#include "config_led.h"
|
||||||
|
|
||||||
|
@ -75,7 +75,7 @@ led_config_t g_led_config = { {
|
||||||
#ifdef USB_LED_INDICATOR_ENABLE
|
#ifdef USB_LED_INDICATOR_ENABLE
|
||||||
void rgb_matrix_indicators_kb(void)
|
void rgb_matrix_indicators_kb(void)
|
||||||
{
|
{
|
||||||
led_matrix_indicators();
|
md_rgb_matrix_indicators();
|
||||||
}
|
}
|
||||||
#endif // USB_LED_INDICATOR_ENABLE
|
#endif // USB_LED_INDICATOR_ENABLE
|
||||||
|
|
||||||
|
|
|
@ -19,7 +19,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#ifdef RGB_MATRIX_ENABLE
|
#ifdef RGB_MATRIX_ENABLE
|
||||||
# include "ctrl.h"
|
# include "ctrl.h"
|
||||||
|
|
||||||
# include "led_matrix.h"
|
# include "md_rgb_matrix.h"
|
||||||
# include "rgb_matrix.h"
|
# include "rgb_matrix.h"
|
||||||
# include "config_led.h"
|
# include "config_led.h"
|
||||||
// clang-format off
|
// clang-format off
|
||||||
|
@ -91,7 +91,7 @@ led_config_t g_led_config = { {
|
||||||
// clang-format on
|
// clang-format on
|
||||||
|
|
||||||
# ifdef USB_LED_INDICATOR_ENABLE
|
# ifdef USB_LED_INDICATOR_ENABLE
|
||||||
void rgb_matrix_indicators_kb(void) { led_matrix_indicators(); }
|
void rgb_matrix_indicators_kb(void) { md_rgb_matrix_indicators(); }
|
||||||
# endif // USB_LED_INDICATOR_ENABLE
|
# endif // USB_LED_INDICATOR_ENABLE
|
||||||
|
|
||||||
#endif
|
#endif
|
|
@ -659,7 +659,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||||
led_instruction_t led_instructions[] = {
|
led_instruction_t led_instructions[] = {
|
||||||
//LEDs are normally inactive, no processing is performed on them
|
//LEDs are normally inactive, no processing is performed on them
|
||||||
//Flags are used in matching criteria for an LED to be active and indicate how to color it
|
//Flags are used in matching criteria for an LED to be active and indicate how to color it
|
||||||
//Flags can be found in tmk_core/protocol/arm_atsam/led_matrix.h (prefixed with LED_FLAG_)
|
//Flags can be found in tmk_core/protocol/arm_atsam/md_rgb_matrix.h (prefixed with LED_FLAG_)
|
||||||
//LED IDs can be found in config_led.h in the keyboard's directory
|
//LED IDs can be found in config_led.h in the keyboard's directory
|
||||||
//Examples are below
|
//Examples are below
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
#include "quantum.h"
|
#include "quantum.h"
|
||||||
#include "ledmatrix.h"
|
#include "led_matrix.h"
|
||||||
#include "progmem.h"
|
#include "progmem.h"
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
#include "eeprom.h"
|
#include "eeprom.h"
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
#include "quantum.h"
|
#include "quantum.h"
|
||||||
#include "ledmatrix.h"
|
#include "led_matrix.h"
|
||||||
|
|
||||||
/* Each driver needs to define a struct:
|
/* Each driver needs to define a struct:
|
||||||
*
|
*
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
|
|
||||||
#ifdef BACKLIGHT_ENABLE
|
#ifdef BACKLIGHT_ENABLE
|
||||||
# ifdef LED_MATRIX_ENABLE
|
# ifdef LED_MATRIX_ENABLE
|
||||||
# include "ledmatrix.h"
|
# include "led_matrix.h"
|
||||||
# else
|
# else
|
||||||
# include "backlight.h"
|
# include "backlight.h"
|
||||||
# endif
|
# endif
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#include "matrix.h"
|
#include "matrix.h"
|
||||||
#include "i2c_master.h"
|
#include "i2c_master.h"
|
||||||
#include "led_matrix.h"
|
#include "md_rgb_matrix.h"
|
||||||
#include "suspend.h"
|
#include "suspend.h"
|
||||||
|
|
||||||
/** \brief Suspend idle
|
/** \brief Suspend idle
|
||||||
|
|
|
@ -5,8 +5,8 @@ SRC += $(ARM_ATSAM_DIR)/clks.c
|
||||||
SRC += $(ARM_ATSAM_DIR)/d51_util.c
|
SRC += $(ARM_ATSAM_DIR)/d51_util.c
|
||||||
SRC += $(ARM_ATSAM_DIR)/i2c_master.c
|
SRC += $(ARM_ATSAM_DIR)/i2c_master.c
|
||||||
ifeq ($(RGB_MATRIX_ENABLE),custom)
|
ifeq ($(RGB_MATRIX_ENABLE),custom)
|
||||||
SRC += $(ARM_ATSAM_DIR)/led_matrix_programs.c
|
SRC += $(ARM_ATSAM_DIR)/md_rgb_matrix_programs.c
|
||||||
SRC += $(ARM_ATSAM_DIR)/led_matrix.c
|
SRC += $(ARM_ATSAM_DIR)/md_rgb_matrix.c
|
||||||
endif
|
endif
|
||||||
SRC += $(ARM_ATSAM_DIR)/main_arm_atsam.c
|
SRC += $(ARM_ATSAM_DIR)/main_arm_atsam.c
|
||||||
SRC += $(ARM_ATSAM_DIR)/spi.c
|
SRC += $(ARM_ATSAM_DIR)/spi.c
|
||||||
|
|
|
@ -35,7 +35,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
# include "main_arm_atsam.h"
|
# include "main_arm_atsam.h"
|
||||||
# ifdef RGB_MATRIX_ENABLE
|
# ifdef RGB_MATRIX_ENABLE
|
||||||
# include "led_matrix.h"
|
# include "md_rgb_matrix.h"
|
||||||
# include "rgb_matrix.h"
|
# include "rgb_matrix.h"
|
||||||
# endif
|
# endif
|
||||||
# include "issi3733_driver.h"
|
# include "issi3733_driver.h"
|
||||||
|
|
|
@ -23,7 +23,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
#ifdef USE_MASSDROP_CONFIGURATOR
|
#ifdef USE_MASSDROP_CONFIGURATOR
|
||||||
__attribute__((weak)) led_instruction_t led_instructions[] = {{.end = 1}};
|
__attribute__((weak)) led_instruction_t led_instructions[] = {{.end = 1}};
|
||||||
static void led_matrix_massdrop_config_override(int i);
|
static void md_rgb_matrix_config_override(int i);
|
||||||
#endif // USE_MASSDROP_CONFIGURATOR
|
#endif // USE_MASSDROP_CONFIGURATOR
|
||||||
|
|
||||||
void SERCOM1_0_Handler(void) {
|
void SERCOM1_0_Handler(void) {
|
||||||
|
@ -188,7 +188,7 @@ void issi3733_prepare_arrays(void) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void led_matrix_prepare(void) {
|
void md_rgb_matrix_prepare(void) {
|
||||||
for (uint8_t i = 0; i < ISSI3733_LED_COUNT; i++) {
|
for (uint8_t i = 0; i < ISSI3733_LED_COUNT; i++) {
|
||||||
*led_map[i].rgb.r = 0;
|
*led_map[i].rgb.r = 0;
|
||||||
*led_map[i].rgb.g = 0;
|
*led_map[i].rgb.g = 0;
|
||||||
|
@ -199,7 +199,7 @@ void led_matrix_prepare(void) {
|
||||||
void led_set_one(int i, uint8_t r, uint8_t g, uint8_t b) {
|
void led_set_one(int i, uint8_t r, uint8_t g, uint8_t b) {
|
||||||
if (i < ISSI3733_LED_COUNT) {
|
if (i < ISSI3733_LED_COUNT) {
|
||||||
#ifdef USE_MASSDROP_CONFIGURATOR
|
#ifdef USE_MASSDROP_CONFIGURATOR
|
||||||
led_matrix_massdrop_config_override(i);
|
md_rgb_matrix_config_override(i);
|
||||||
#else
|
#else
|
||||||
led_buffer[i].r = r;
|
led_buffer[i].r = r;
|
||||||
led_buffer[i].g = g;
|
led_buffer[i].g = g;
|
||||||
|
@ -219,7 +219,7 @@ void init(void) {
|
||||||
|
|
||||||
issi3733_prepare_arrays();
|
issi3733_prepare_arrays();
|
||||||
|
|
||||||
led_matrix_prepare();
|
md_rgb_matrix_prepare();
|
||||||
|
|
||||||
gcr_min_counter = 0;
|
gcr_min_counter = 0;
|
||||||
v_5v_cat_hit = 0;
|
v_5v_cat_hit = 0;
|
||||||
|
@ -290,7 +290,7 @@ void flush(void) {
|
||||||
i2c_led_q_run();
|
i2c_led_q_run();
|
||||||
}
|
}
|
||||||
|
|
||||||
void led_matrix_indicators(void) {
|
void md_rgb_matrix_indicators(void) {
|
||||||
uint8_t kbled = keyboard_leds();
|
uint8_t kbled = keyboard_leds();
|
||||||
if (kbled && rgb_matrix_config.enable) {
|
if (kbled && rgb_matrix_config.enable) {
|
||||||
for (uint8_t i = 0; i < ISSI3733_LED_COUNT; i++) {
|
for (uint8_t i = 0; i < ISSI3733_LED_COUNT; i++) {
|
||||||
|
@ -397,7 +397,7 @@ static void led_run_pattern(led_setup_t* f, float* ro, float* go, float* bo, flo
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void led_matrix_massdrop_config_override(int i) {
|
static void md_rgb_matrix_config_override(int i) {
|
||||||
float ro = 0;
|
float ro = 0;
|
||||||
float go = 0;
|
float go = 0;
|
||||||
float bo = 0;
|
float bo = 0;
|
|
@ -86,7 +86,7 @@ extern uint8_t gcr_actual_last;
|
||||||
|
|
||||||
void gcr_compute(void);
|
void gcr_compute(void);
|
||||||
|
|
||||||
void led_matrix_indicators(void);
|
void md_rgb_matrix_indicators(void);
|
||||||
|
|
||||||
/*------------------------- Legacy Lighting Support ------------------------*/
|
/*------------------------- Legacy Lighting Support ------------------------*/
|
||||||
|
|
|
@ -17,7 +17,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
#ifdef USE_MASSDROP_CONFIGURATOR
|
#ifdef USE_MASSDROP_CONFIGURATOR
|
||||||
|
|
||||||
# include "led_matrix.h"
|
# include "md_rgb_matrix.h"
|
||||||
|
|
||||||
// Teal <-> Salmon
|
// Teal <-> Salmon
|
||||||
led_setup_t leds_teal_salmon[] = {
|
led_setup_t leds_teal_salmon[] = {
|
Loading…
Reference in a new issue