1
0

Added userspace

Also made changes to Atreus62 Keymap to turn the red LEDs off on the ProMicro
This commit is contained in:
Ian Sterling
2019-06-28 20:45:28 -07:00
parent 6b502bc416
commit e267c53f71
5 changed files with 74 additions and 4 deletions

View File

@@ -139,15 +139,16 @@ void matrix_init_user(void) {
#ifdef BOOTLOADER_CATERINA
// This will disable the red LEDs on the ProMicros
setPinOutput(D5);
writePinLow(D5);
writePinHigh(D5);
setPinOutput(B0);
writePinLow(B0);
writePinHigh(B0);
#endif
};
uint32_t layer_state_set_user(uint32_t state) {
return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST);
}
};
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case DVORAK:
@@ -177,4 +178,4 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
return false;
}
return true;
}
};

14
users/xyverz/readme.md Normal file
View File

@@ -0,0 +1,14 @@
Copyright <year> <name> <email> @<github_username>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.

1
users/xyverz/rules.mk Normal file
View File

@@ -0,0 +1 @@
SRC += xyverz.c

46
users/xyverz/xyverz.c Normal file
View File

@@ -0,0 +1,46 @@
#include "_example.h"
void matrix_init_user(void) {
#ifdef BOOTLOADER_CATERINA
// This will disable the red LEDs on the ProMicros
setPinOutput(D5);
writePinHigh(D5);
setPinOutput(B0);
writePinHigh(B0);
#endif
};
uint32_t layer_state_set_user(uint32_t state) {
return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST);
};
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case DVORAK:
if (record->event.pressed) {
set_single_persistent_default_layer(_DVORAK);
}
return false;
case COLEMAK:
if (record->event.pressed) {
set_single_persistent_default_layer(_COLEMAK);
}
return false;
case QWERTY:
if (record->event.pressed) {
set_single_persistent_default_layer(_QWERTY);
}
return false;
case WOW:
if (record->event.pressed) {
set_single_persistent_default_layer(_WOW);
}
return false;
case DESTINY:
if (record->event.pressed) {
set_single_persistent_default_layer(_DESTINY);
}
return false;
}
return true;
};

8
users/xyverz/xyverz.h Normal file
View File

@@ -0,0 +1,8 @@
#ifndef USERSPACE
#define USERSPACE
#include "quantum.h"
void my_custom_function(void);
#endif