GNOME Bugzilla – Bug 696696
[MM 0.8] novatel: QCDM probing interferes with AT$NWDMAT=1
Last modified: 2013-03-28 16:06:33 UTC
Created attachment 239954 [details] novatel probe log with dm/at mixup Grr. So if the DM port gets probed before we're able to send AT$NWDMAT=1 to switch the port from DM to AT, then ModemManager always thinks the second port is DM even though it's now AT. Really not sure how to handle this other than to block GSM/UMTS devices from using QCDM at all. But during probing, we don't know whether they are GSM or not, right? And we definitely want QCDM for the CDMA devices. Ideally we'd have some way to retrigger probing of a port after performing some operation that might change its status, but that sounds complicated.
How about calling NWDMAT=1 in a new custom_init() sequence in the plugin? That should call the command very early, as soon as we get the ports available, and before even AT or QCDM probing.
Please review and test the 'aleksander/novatel-nwdmat' branch in git. It will try to flip the secondary ports during AT port probing. The command will also be used to mark the ports as being AT. This is the easy/fast solution, so if it works, nice. Otherwise, we could just write a custom_init() command in which we make sure that we at least probe an AT port before going on with the remaining ports.
Looks good to merge, tested both CDMA and GSM devices. Since CDMA devices only have one AT port, it does slow down port probing a bit, but not enough to care about. In the future we could use the number-of-endpoints patch I proposed on the list a few months ago to only issue NWDMAT on the 3-endpoint ports, because those are the only ports that can do PPP and thus are also AT capable. But that's the future.
Merged to git master.