Add shared EEPROM configuration for Epomaker FS026 keyboards

This commit is contained in:
Carlos de Paula
2026-07-31 14:59:05 -03:00
parent c79270f3dd
commit 9cb36d91d5
12 changed files with 76 additions and 41 deletions
+2 -2
View File
@@ -60,8 +60,8 @@
#define NOP_FUDGE 0.4
#endif
#define DYNAMIC_KEYMAP_EEPROM_MAX_ADDR 1151
#define EEPROM_SIZE 1152
// Shared EEPROM sizing + layer count for all Epomaker FS026 boards
#include "fs026_eeprom.h"
#define FEE_PAGE_SIZE (0x200)
#define FEE_PAGE_COUNT (8)
#define FEE_PAGE_BASE_ADDRESS (0x1F000)
+2 -2
View File
@@ -36,8 +36,8 @@
# define NOP_FUDGE 0.4
#endif
#define DYNAMIC_KEYMAP_EEPROM_MAX_ADDR 1151
#define EEPROM_SIZE 1152
// Shared EEPROM sizing + layer count for all Epomaker FS026 boards
#include "fs026_eeprom.h"
#define FEE_PAGE_SIZE (0x200)
#define FEE_PAGE_COUNT (8)
#define FEE_PAGE_BASE_ADDRESS (0x1F000)
+1 -1
View File
@@ -9,7 +9,7 @@
"debounce": 2,
"diode_direction": "ROW2COL",
"dynamic_keymap": {
"layer_count": 5
"layer_count": 8
},
"eeprom": {
"driver": "wear_leveling",
+2 -2
View File
@@ -10,12 +10,12 @@
"debounce": 1,
"diode_direction": "ROW2COL",
"dynamic_keymap": {
"layer_count": 4
"layer_count": 8
},
"eeprom": {
"driver": "wear_leveling",
"wear_leveling": {
"backing_size": 4096,
"backing_size": 8192,
"driver": "spi_flash"
}
},
+2 -2
View File
@@ -9,12 +9,12 @@
"debounce": 1,
"diode_direction": "ROW2COL",
"dynamic_keymap": {
"layer_count": 4
"layer_count": 8
},
"eeprom": {
"driver": "wear_leveling",
"wear_leveling": {
"backing_size": 4096,
"backing_size": 8192,
"driver": "spi_flash"
}
},
+2 -2
View File
@@ -34,8 +34,8 @@
# define NOP_FUDGE 0.4
#endif
#define DYNAMIC_KEYMAP_EEPROM_MAX_ADDR 1151
#define EEPROM_SIZE 1152
// Shared EEPROM sizing + layer count for all Epomaker FS026 boards
#include "fs026_eeprom.h"
#define FEE_PAGE_SIZE (0x200)
#define FEE_PAGE_COUNT (8)
#define FEE_PAGE_BASE_ADDRESS (0x1F000)
+2 -2
View File
@@ -40,8 +40,8 @@
# define NOP_FUDGE 0.4
#endif
#define DYNAMIC_KEYMAP_EEPROM_MAX_ADDR 1151
#define EEPROM_SIZE 1152
// Shared EEPROM sizing + layer count for all Epomaker FS026 boards
#include "fs026_eeprom.h"
#define FEE_PAGE_SIZE (0x200)
#define FEE_PAGE_COUNT (8)
#define FEE_PAGE_BASE_ADDRESS (0x1F000)
@@ -16,18 +16,5 @@
#pragma once
#define DYNAMIC_KEYMAP_EEPROM_MAX_ADDR 1151
#define EEPROM_SIZE 1152
#define FEE_PAGE_SIZE (0x200)
#define FEE_PAGE_COUNT (8)
#define FEE_PAGE_BASE_ADDRESS (0x1F000)
#define FEE_MCU_FLASH_SIZE (0x1000)
#define EECONFIG_USER_DATA_SIZE 4
#define EECONFIG_KB_DATA_SIZE 1
#define TRANSIENT_EEPROM_SIZE 4096
// EEPROM sizing + layer count come from the shared header included by
// keyboards/epomaker/th85/config.h (lib/rdmctmzt_common/fs026_eeprom.h).
+2 -2
View File
@@ -11,7 +11,7 @@
"eeprom": {
"driver": "wear_leveling",
"wear_leveling": {
"backing_size": 4096,
"backing_size": 8192,
"driver": "spi_flash"
}
},
@@ -71,7 +71,7 @@
}
],
"dynamic_keymap": {
"layer_count": 7
"layer_count": 8
},
"matrix_pins": {
"cols": [
+2 -2
View File
@@ -11,7 +11,7 @@
"eeprom": {
"driver": "wear_leveling",
"wear_leveling": {
"backing_size": 4096,
"backing_size": 8192,
"driver": "spi_flash"
}
},
@@ -68,7 +68,7 @@
}
],
"dynamic_keymap": {
"layer_count": 5
"layer_count": 8
},
"matrix_pins": {
"cols": [
+46
View File
@@ -0,0 +1,46 @@
/* Copyright 2025 Carlos Eduardo de Paula <carlosedp@gmail.com>
*
* 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/>.
*/
/*
* Shared EEPROM sizing for all Epomaker FS026 (ES32, Cortex-M0) keyboards.
*
* These boards emulate EEPROM inside two 8 KB internal-flash pages via the
* custom driver in user_eeprom.c. For the wear-levelling page transfer to
* work, every live 16-bit variable must fit inside a single page, which caps
* the usable space at roughly 4092 bytes.
*
* We provision enough for 8 VIA layers on the largest FS026 matrix
* (6x16 = 96 keys => 192 bytes/layer):
*
* dynamic keymap start (eeconfig + VIA config) : 46
* 8 layers * 192 bytes : 1536 -> ends at 1582
* macro region : ~400 bytes (up to MAX_ADDR)
*
* EEPROM_SIZE is kept at DYNAMIC_KEYMAP_EEPROM_MAX_ADDR + 65 on purpose: the
* driver reserves 64 "private" bytes (NB_OF_PRIVATE_VAR) and refuses to persist
* any variable whose index is >= EEPROM_SIZE, so this margin guarantees every
* keymap/macro byte is actually written to flash.
*
* Smaller boards (e.g. th40, 5x12 = 60 keys => 120 bytes/layer) simply use less
* of the same budget. To raise the ceiling for a future larger-matrix board,
* bump both values here (staying under ~4000) -- every FS026 board inherits it.
*/
#pragma once
#define DYNAMIC_KEYMAP_LAYER_COUNT 8
#define DYNAMIC_KEYMAP_EEPROM_MAX_ADDR 1983
#define EEPROM_SIZE 2048
+11 -9
View File
@@ -6,7 +6,7 @@
[![GitHub contributors](https://img.shields.io/github/contributors/qmk/qmk_firmware.svg)](https://github.com/qmk/qmk_firmware/pulse/monthly)
[![GitHub forks](https://img.shields.io/github/forks/qmk/qmk_firmware.svg?style=social&label=Fork)](https://github.com/qmk/qmk_firmware/)
This is a keyboard firmware based on the [tmk\_keyboard firmware](https://github.com/tmk/tmk_keyboard) with some useful features for Atmel AVR and ARM controllers, and more specifically, the [OLKB product line](https://olkb.com), the [ErgoDox EZ](https://ergodox-ez.com) keyboard, and the Clueboard product line.
This is a keyboard firmware based on the [tmk_keyboard firmware](https://github.com/tmk/tmk_keyboard) with some useful features for Atmel AVR and ARM controllers, and more specifically, the [OLKB product line](https://olkb.com), the [ErgoDox EZ](https://ergodox-ez.com) keyboard, and the Clueboard product line.
## 🚨 Forked firmware remarks
@@ -24,11 +24,13 @@ They keyboards that have been incorporated are:
- Evoworks EVO80
- Epomaker Galaxy68
- Chosfox Geonix R2
- Chosfox Geonix R2.5
- Cidoo QK61 v2
- Chosfox Vero75
- Cerakey Zen75
- Epomaker TH85
- Epomaker Split 65
- Epomaker Split 70
These are keyboards I own or have been tested and reported back to work. There might be differences to the official firmware in keymaps, sleep times, battery consumption and other factors but the main features should work as the original (wireless, LEDs, etc).
@@ -43,13 +45,13 @@ These are keyboards I own or have been tested and reported back to work. There m
These untested keyboards compile but haven't been tested for all it's functionality so wireless, backlights, RGB or other functions might not work as expected or as the official firmware.
There are factory firmware files for some of these keyboards at https://github.com/carlosedp/qmk_firmware/releases/tag/0.31.2. Use them in case you need to revert to the original.
There are factory firmware files for some of these keyboards at <https://github.com/carlosedp/qmk_firmware/releases/tag/0.31.2>. Use them in case you need to revert to the original.
I welcome testers and PRs to have a broad open-source support of them.
## Documentation
* [See the official documentation on docs.qmk.fm](https://docs.qmk.fm)
- [See the official documentation on docs.qmk.fm](https://docs.qmk.fm)
The docs are powered by [VitePress](https://vitepress.dev/). They are also viewable offline; see [Previewing the Documentation](https://docs.qmk.fm/#/contributing?id=previewing-the-documentation) for more details.
@@ -57,12 +59,12 @@ You can request changes by making a fork and opening a [pull request](https://gi
## Supported Keyboards
* [Planck](/keyboards/planck/)
* [Preonic](/keyboards/preonic/)
* [ErgoDox EZ](/keyboards/ergodox_ez/)
* [Clueboard](/keyboards/clueboard/)
* [Cluepad](/keyboards/clueboard/17/)
* [Atreus](/keyboards/atreus/)
- [Planck](/keyboards/planck/)
- [Preonic](/keyboards/preonic/)
- [ErgoDox EZ](/keyboards/ergodox_ez/)
- [Clueboard](/keyboards/clueboard/)
- [Cluepad](/keyboards/clueboard/17/)
- [Atreus](/keyboards/atreus/)
The project also includes community support for [lots of other keyboards](/keyboards/).