Refactor radio settings and localization updates#180
Conversation
fixes #72 - Removed preset configurations for 915 MHz, 868 MHz, and 433 MHz from the RadioSettings model. - Introduced a new list of regional preset configurations for various countries. - Updated the settings screen to use a dropdown for selecting presets instead of chips. - Added a switch for enabling client repeat functionality with appropriate warnings for frequency usage. - Updated localization files for multiple languages to reflect changes in settings related to client repeat functionality.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 947fafbbb7
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (frame.length >= 81) { | ||
| _clientRepeat = frame[80] != 0; | ||
| } |
There was a problem hiding this comment.
Parse client repeat from the correct response frame
_handleDeviceInfo is still structured around the 4-byte RESP_CODE_DEVICE_INFO payload ([code][protocol_ver][max_contacts_div2][max_channels]), so this frame[80] read will never run for normal device-info replies and clientRepeat remains unset. In that state, the radio settings dialog initializes the switch to false, and saving settings on devices that already have repeat enabled can unintentionally turn repeat off because the app sends an explicit clientRepeat value based on stale/null state.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5fae2e5f73
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (frame.length >= 81) { | ||
| _clientRepeat = frame[80] != 0; |
There was a problem hiding this comment.
Parse client-repeat from the correct response payload
_handleDeviceInfo reads frame[80] for client_repeat, but this handler processes RESP_CODE_DEVICE_INFO, whose documented payload is only 4 bytes ([code][protocol_ver][max_contacts_div2][max_channels] in docs/BLE_PROTOCOL.md). In this path the new read never executes, so connector.clientRepeat stays null and the radio dialog initializes _clientRepeat to false; on devices where repeat was already enabled, saving any radio change will send clientRepeat: false and unintentionally turn repeat off.
Useful? React with 👍 / 👎.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4239fb11ed
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (frame.length >= 81) { | ||
| _clientRepeat = frame[80] != 0; |
There was a problem hiding this comment.
Read client-repeat from the response that actually carries it
_handleDeviceInfo only sets _clientRepeat when frame.length >= 81, but the documented RESP_CODE_DEVICE_INFO payload is 4 bytes ([code][protocol_ver][max_contacts_div2][max_channels] in docs/BLE_PROTOCOL.md), so this branch never runs on devices following the current protocol. In that case clientRepeat stays null, the settings switch never appears, and buildSetRadioParamsFrame is called without the repeat byte, making the new off-grid repeat setting effectively unusable.
Useful? React with 👍 / 👎.
fixes #72