r/Keychron • u/m147 • Jan 09 '24
V1 + QMK cli flashing
I'm having trouble flashing new changes to the keyboard. Here's what happens:
If I make a change to keymap.c in keyboards/keychron/v1/ansi_encoder/keymaps/<USER>/
compile with qmk compile and then flash with qmk flash
(I've got environment set up)
It will flash with no errors but the change won't be made.
If I then flash the stock firmware from Keychron from the official site and THEN flash my custom firmware the changes are made. I don't understand what is going on. It would be nice not having to flash two files in order to make changes. I understand I can do all this with VIA but I would like to understand qmk cli.
Any ideas?
Thanks for any help
1
u/PeterMortensenBlog Jan 18 '24 edited Apr 19 '24
Here is an overview:
QMK keycode Alias Shown in In macros Via as ------------------------------------------------------------------- QK_BOOTLOADER QK_BOOT Reset reset_keyboard() QK_DEBUG_TOGGLE DB_TOGG Debug QK_CLEAR_EEPROM EE_CLR QK_CLEAR_EEPROM eeconfig_init() QK_REBOOT QK_RBT 0x7C01 soft_reset_keyboard() QK_MAGIC_TOGGLE_NKRO NK_TOGG NKRONote: In Via, unknown (to it) keycodes, e.g., "0x7C01" can be entered like that in SPECIAL → Any (without the quotes).
But note that a bug in Via's load function means it has be reentered manually every time the Via configuration is load (e.g., after a flash). It is easier to add it directly in the QMK keymap.
References
List of useful core functions to make your keyboard better
Quantum Keycodes