Skip to content

Refactor radio settings and localization updates#180

Merged
zjs81 merged 3 commits into
mainfrom
fix/radio-params-fw-compat
Feb 18, 2026
Merged

Refactor radio settings and localization updates#180
zjs81 merged 3 commits into
mainfrom
fix/radio-params-fw-compat

Conversation

@zjs81

@zjs81 zjs81 commented Feb 18, 2026

Copy link
Copy Markdown
Owner

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.

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.
@zjs81

zjs81 commented Feb 18, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 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".

Comment on lines +1832 to +1834
if (frame.length >= 81) {
_clientRepeat = frame[80] != 0;
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge 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 👍 / 👎.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 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".

Comment on lines +1832 to +1833
if (frame.length >= 81) {
_clientRepeat = frame[80] != 0;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge 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 👍 / 👎.

@zjs81

zjs81 commented Feb 18, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 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".

Comment on lines +1832 to +1833
if (frame.length >= 81) {
_clientRepeat = frame[80] != 0;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge 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 👍 / 👎.

@zjs81 zjs81 merged commit 5f2312e into main Feb 18, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] Radio presets

1 participant