[XAP] `info.json` transformation for XAP-related info
#15.600 aperta il 27 dic 2021
Metriche repository
- Star
- (20.368 star)
- Metriche merge PR
- (Merge medio 20g 9h) (27 PR mergiate in 30 g)
Descrizione
XAP Task Info
Original Issue Original spec document Current XAP Definitions Current XAP Generated Docs Placeholder PR
Description
Any work in this area needs to be discussed with QMK Collaborators first, and in this case primarily with @tzarc due to their prior work in this area.
The info.json needs to be "massaged" to only require relevant information for XAP. This includes enabled subsystems such as rgb_matrix and dynamic_keymap, as well as information like layout options.
Currently the xap branch of qmk_firmware compresses the entire output of qmk info -f json for a keyboard as a proof-of-concept; this is not sufficient as it currently does not include keymap-level selections (e.g. disabling rgb at the keymap is not reflected in the output), and the generated output also includes a lot of irrelevant information in the output that has no bearing on XAP's functionality.
For this issue, a transformation needs to be applied such that it filters for a set of known-used items from info.json into an appropriate equivalent to be embedded into the firmware.
A corresponding *.jsonschema file should also be provided so host applications can determine what information is to be available.
This blob of data should be compressed -- an appropriate algorithm should be chosen as part of this work.
NOTE: for simplified porting from Chinese vendors who don't bother upstreaming to QMK, relevant information such as pin definitions should be included in this output. This is intended as a future work item; the idea is to be able to connect to a XAP-enabled firmware with the XAP client and export as much of a keyboard's info.json as possible.