You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When uploading the user configuration to the UHK, there is a phase when the lauchEepromTransfer USB command gets called, and then getKeyboardState is getting polled until it returns 0 as the first byte.
This phase is critical because if some for some reason it gets interrupted, the configuration will be left in an inconsistent state.
In order to make Agent more robust, let's do the following:
When the user clicks on the "Save to keyboard button", save the user configuration to the file system automatically to "${agentDirectory}/${uhkUuid}.json" and only after that execute the already implemented transfer.
After loading the configuration from the UHK, if the config serializer fails to parse it, display a restoration screen to the user.
The restoration screen should contain the following:
Title: [fa-exclamation-circle icon] Fix configuration
Paragraph: Your on-board device configuration is invalid. (1.5 rem above and below spacing just like for the "Device configuration" screen)
Button: Restore the last valid device configuration (blue button)
Before displaying the above screen, check if there is a previous configuration saved, and also check if it's valid (the configuration parser can successfully parse it). If not, then rather display the following button:
Button: Reset device configuration (red button, no confirmation)
Also create a menu item for this page as the first child of the Device node. Name the menu item "Fix configuration" and remove it once the button (whichever is displayed) gets clicked and the restoration process finished.
The text was updated successfully, but these errors were encountered:
Just added packages/usb/{write-userconfig.js,invalid.config} to this branch. You can mess up the user config of your UKH by running write-userconfig.js invalid-config.bin. If you reconnect your UHK then the display will show FTY just as expected. When starting up Agent instead of displaying the recovery screen, it will simply display the default config which is not the expected behavior.
When uploading the user configuration to the UHK, there is a phase when the lauchEepromTransfer USB command gets called, and then getKeyboardState is getting polled until it returns 0 as the first byte.
This phase is critical because if some for some reason it gets interrupted, the configuration will be left in an inconsistent state.
In order to make Agent more robust, let's do the following:
The restoration screen should contain the following:
Before displaying the above screen, check if there is a previous configuration saved, and also check if it's valid (the configuration parser can successfully parse it). If not, then rather display the following button:
Also create a menu item for this page as the first child of the Device node. Name the menu item "Fix configuration" and remove it once the button (whichever is displayed) gets clicked and the restoration process finished.
The text was updated successfully, but these errors were encountered: