Commit Graph
12 Commits
Author SHA1 Message Date
Dan Williams c320e50753 examples: add sms-watch-python
Add an example that watches for and prints all SMS messages of
all modems.

Signed-off-by: Dan Williams <dan@ioncontrol.co>
2025-02-17 21:57:33 +00:00
Dan Williams b178d46265 cli: set higher 3GPP Scan(), Register(), and Connect() method timeouts
Similar to voice call mmcli timeouts, set larger proxy-wide timeouts for
long-running operations. Match these timeouts with the internal ModemManager
timeouts for the AT/MBIM/QMI operation timeouts.

Fixes: https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/941
Fixes: https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/942

Signed-off-by: Dan Williams <dan@ioncontrol.co>
2025-01-11 20:53:15 -06:00
Dan Williams 60de5751b4 port-probe: add some QCDM/DIAG response bytes to non-AT responses
Seen on a Qualcomm-based Quectel EG915Q on the diag port:

ModemManager[34547]: <dbg> [1732077670.330527] [ttyUSB0/at] <-- ' \0\0\0\8\0\0\0\2\0\0\0\0`%\160$"\6\169\128\200\1\30\197\142\0G\184\225\128\0\1+\127\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254\255\255\255\255\255\255\255\254'

Signed-off-by: Dan Williams <dan@ioncontrol.co>
2024-12-27 23:42:09 -06:00
Dan Williams 72e8ac2e80 port-serial: clean up whitespace formatting
Remove stray tabs.

Signed-off-by: Dan Williams <dan@ioncontrol.co>
2024-12-23 01:06:53 -06:00
Dan Williams ed13e053cd port-probe: fix custom init probing not having open AT port
Referenced commit broke custom init flows because the AT port
was not opened when custom inits were run, which was the case
before the commit landed.

Rework probing flow to follow a step model like much of our
other code, and ensure that the AT port is opened as part
of the custom init flow.

Fixes: 7937a89a37 port-probe: rework and consolidate port probe flow for AT/QCDM/QMI/MBIM

Signed-off-by: Dan Williams <dan@ioncontrol.co>
2024-11-20 11:50:43 +00:00
Dan Williams 64646b98cd plugins/quectel: support modem power operations for AT-based devices
Signed-off-by: Dan Williams <dan@ioncontrol.co>
2024-09-24 23:52:13 -05:00
Dan Williams f19f20c008 helpers: consolidate some uses of mm_kernel_device_get_subsystem()
Signed-off-by: Dan Williams <dan@ioncontrol.co>
2024-09-17 12:20:46 -05:00
Dan Williams 0b5f2adb4b port-probe: restart AT probing if "NO CARRIER" is received during QCDM probing
If the system and modem are independently powered, a system restart may
leave one of the modem's AT ports in PPP mode. On restart this may cause
AT probing to fail. The modem may terminate PPP after receiving bogus
HDLC frames from QCDM probing (since PPP also uses HDLC framing), and
return "NO CARRIER". We can use this to restart AT probing now that
PPP is down and auto-detect the expected additional AT ports.

Feb 08 20:22:53 ModemManager[385]: <debug> [1675887773.887574] [ttyUSB2/at] <-- '\8\158\239~'
Feb 08 20:22:54 ModemManager[385]: <debug> [1675887774.215054] [ttyUSB2/at] <-- '\8\214\137~'
Feb 08 20:22:54 ModemManager[385]: <debug> [1675887774.851349] [ttyUSB2/at] <-- '\8\250\177~'
Feb 08 20:22:55 ModemManager[385]: <debug> [1675887775.576776] [ttyUSB2/at] <-- '\8\168u~'
Feb 08 20:22:55 ModemManager[385]: <debug> [1675887775.612694] [ttyUSB2/at] <-- '\8w\25~'
Feb 08 20:22:55 ModemManager[385]: <debug> [1675887775.862886] [ttyUSB2/at] <-- '\8!&~'
Feb 08 20:22:56 ModemManager[385]: <debug> [1675887776.614747] [ttyUSB2/at] <-- '\8%\254~'
Feb 08 20:22:56 ModemManager[385]: <debug> [1675887776.686207] [ttyUSB2/probe] port is not AT-capable
Feb 08 20:22:56 ModemManager[385]: <debug> [1675887776.686447] [ttyUSB2/probe] probing QCDM...
Feb 08 20:22:56 ModemManager[385]: <debug> [1675887776.725483] [ttyUSB2/qcdm] --> 7e 00 78 f0 7e
Feb 08 20:22:56 ModemManager[385]: <debug> [1675887776.880941] [ttyUSB2/qcdm] <-- 0d 0a 4e 4f 20 43 41 52 52 49 45 52 0d 0a

Signed-off-by: Dan Williams <dan@ioncontrol.co>
2024-09-17 11:26:06 -05:00
Dan Williams 7937a89a37 port-probe: rework and consolidate port probe flow for AT/QCDM/QMI/MBIM
Open the AT port from the regular port probe flow rather than doing
that one-off at the beginning of probing. That lets us re-open the AT
port later if needed, based on QCDM/QMI/MBIM probing results.

Signed-off-by: Dan Williams <dan@ioncontrol.co>
2024-09-17 11:23:01 -05:00
Dan Williams 6664d3740d port-probe: consolidate serial port closure and cleanup
Signed-off-by: Dan Williams <dan@ioncontrol.co>
2024-09-17 11:11:23 -05:00
Dan Williams 478e9645ca tests: test mm_split_string_groups()
Signed-off-by: Dan Williams <dan@ioncontrol.co>
2024-09-10 19:03:31 -05:00
Dan Williams 1a43833d99 modem-helpers: remove duplicate include
Signed-off-by: Dan Williams <dan@ioncontrol.co>
2024-09-10 19:03:31 -05:00