More changes for the PR

-I also deleted one unused function for led toggling on matrix.c (Now it uses layer dependent baklight, algo on of on start)
-Deleted commented function on keymaps.

Right now only needs testing and all pragma replaces.
pull/4126/head
DESKTOP-PU0QGTF\Fer 6 years ago
parent 0758785f6e
commit 21aca299c8

@ -1,8 +1,6 @@
#ifndef STM70_CONFIG_H_
#define STM70_CONFIG_H_
#include "../config.h"
/* USB Device descriptor parameter */
#define VENDOR_ID 0xFEED
#define PRODUCT_ID 0x6464
@ -14,8 +12,8 @@
#define MANUFACTURER "QMK"
#define USBSTR_MANUFACTURER 'T', '\x00', 'M', '\x00', 'K', '\x00', ' ', '\x00', '\xc6', '\x00'
#define PRODUCT "BluePill70"
#define USBSTR_PRODUCT 'C', '\x00', 'h', '\x00', 'i', '\x00', 'b', '\x00', 'i', '\x00', 'O', '\x00', 'S', '\x00', ' ', '\x00', 'Q', '\x00', 'M', '\x00', 'K', '\x00', ' ', '\x00', 't', '\x00', 'e', '\x00', 's', '\x00', 't', '\x00'
#define DESCRIPTION "QMK keyboard firmware test for ChibiOS"
#define USBSTR_PRODUCT 'C', '\x00', 'h', '\x00', 'i', '\x00', 'b', '\x00', 'i', '\x00', 'O', '\x00', 'S', '\x00', ' ', '\x00', 'Q', '\x00', 'M', '\x00', 'K', '\x00'
#define DESCRIPTION "QMK keyboard firmware with ChibiOS"
/* key matrix size */
// Modified by Xydane

@ -53,11 +53,29 @@ inline uint8_t matrix_cols(void){
/* generic STM32F103C8T6 board */
#ifdef BOARD_GENERIC_STM32_F103
// This could be removed, only used now in matrix_init()
#define LED_ON() do { palClearPad(GPIOA, 1) ;} while (0)
#define LED_OFF() do { palSetPad(GPIOA, 1); } while (0)
#define LED_TGL() do { palTogglePad(GPIOA, 1); } while (0)
#endif
__attribute__ ((weak))
void matrix_init_kb(void) {
matrix_init_user();
}
__attribute__ ((weak))
void matrix_scan_kb(void) {
matrix_scan_user();
}
__attribute__ ((weak))
void matrix_init_user(void) {
}
__attribute__ ((weak))
void matrix_scan_user(void) {
}
void matrix_init(void)
{
// initialize row and col
@ -73,6 +91,8 @@ void matrix_init(void)
LED_ON();
wait_ms(500);
LED_OFF();
matrix_init_quantum();
}
uint8_t matrix_scan(void){
@ -99,7 +119,7 @@ uint8_t matrix_scan(void){
}
}
}
matrix_scan_quantum();
return 1;
}

@ -49,11 +49,6 @@ KC_GRAVE, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,KC_TRNS,KC_TRNS ),
};
/*const uint16_t PROGMEM fn_actions[] = {
[0] = ACTION_LAYER_MOMENTARY(1), // to Fn overlay
[1] = ACTION_LAYER_TOGGLE(2), // to Fn overlay
};*/
/* Layer based ilumination, just binary */
uint32_t layer_state_set_user(uint32_t state) {
switch (biton32(state)) {

@ -49,11 +49,6 @@ KC_GRAVE, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,KC_TRNS,KC_TRNS ),
};
/*const uint16_t PROGMEM fn_actions[] = {
[0] = ACTION_LAYER_MOMENTARY(1), // to Fn overlay
[1] = ACTION_LAYER_TOGGLE(2), // to Fn overlay
};*/
/* Layer based ilumination, just binary */
uint32_t layer_state_set_user(uint32_t state) {
switch (biton32(state)) {

Loading…
Cancel
Save