Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AT protocol: apply QCFG settings #7

Closed
nfeske opened this issue Aug 11, 2022 · 1 comment
Closed

AT protocol: apply QCFG settings #7

nfeske opened this issue Aug 11, 2022 · 1 comment
Labels

Comments

@nfeske
Copy link
Member

nfeske commented Aug 11, 2022

Unfortunately, the PinePhone's Quectel modem stores some configuration information (QCFG) persistently inside the modem. Moreover, some settings - in particular the "usbnet" mode - cannot simply be changed at runtime but require the reboot of the modem to become effective.

Upon the start of Genode's modem driver, the driver cannot assume that the modem's current settings are consistent with the expectations of the driver. For example, for mobile-data connectivity, we need to ensure that the modem's "usbnet" setting is set to "1" (ECM mode).

Consequently, we need the ability to dynamically validate and - if needed - adjust persistent modem settings, and to schedule the reboot of the modem after such modifications.

@nfeske nfeske added the feature label Aug 11, 2022
nfeske added a commit that referenced this issue Aug 11, 2022
QCFG settings - such as the usbnet mode of operation - happen to be
stored persistently on the modem. When starting the modem driver, it
cannot assume the current settings to be compatible with the driver's
assumptions (e.g., that the modem appears as USB ECM device).
Unfortunately, the intuitive approach of unconditionally setting the
driver's desired values at start time is not practical become certain
settings ("usbnet") require a modem reboot in order to become effective.

This patch extends the AT protocol implementation with the support for
the validation and - if needed - adjustment of QCFG settings. At start,
the driver queries the current settings and compares them to the desired
values. Mismatching values are re-assigned to the desired values. Once
this QCFG value synchronization is complete, a modem reboot is scheduled
if any value was changed.

Fixes #7
@nfeske
Copy link
Member Author

nfeske commented Aug 11, 2022

Implemented by c9989b5

@nfeske nfeske closed this as completed in b31323c Aug 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant