Port init and GPS.
Aleksander Morgado
aleksander at aleksander.es
Sun Dec 29 01:29:42 PST 2013
On 28/12/13 23:34, Marc Murphy wrote:
> I have been having a step through the initialization code for MM and specifically where it tries to enumerate the ports for the modem.
>
> My main goal is to get the GPS recognized and used by MM.
> For the Sierra device I have MC8705 it MM correctly identifies the control AT port as ttyUSB3
> This is used for both modem and GPS control. NMEA output then is generated on ttyUSB2 when a stream is available.
>
> What I see in mm_base_modem_organize_ports() at initialization is that there is no gps_control or gps port identified. It has however managed to identify a secondary port ?? as far as I know the MC8705 only has 1 AT port.
> There are entries for primary, secondary, data_primary, qcdm everything else is NULL.
>
> Is there a way to specify the ports to use for a specific modem instead of allowing the auto detection ?
We always try to do auto-detection unless there is no other way to do
it. This approach helps to handle new untested modem devices, among
other things.
For what I can tell, there is no Sierra-specific AT command which would
let us know which the GPS port for NMEA traces is in advance. You may
know it for your specific modem+firmware version but there is no
guarantee that it will be the same for other modems or even for the same
modem with another firmware version. Therefore, there is no way we can
mark the port as NMEA-GPS port during port probing or in organize_ports().
What I would do in this case is to let the Location interface enable
GPS, using the GPS control port (the main AT port), and then let
ModemManager open all the non-AT ttys associated to the modem to see
which one of them ends up dumping NMEA traces. Another thing we could do
is to dig into the usb endpoints of each interface, and very likely the
GPS port for NMEA traces won't have an interrupt endpoint.
--
Aleksander
More information about the ModemManager-devel
mailing list