From owner-freebsd-usb@FreeBSD.ORG Mon Jan 13 09:03:49 2014 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 7AA11522 for ; Mon, 13 Jan 2014 09:03:49 +0000 (UTC) Received: from mx1.h3q.net (mx1.h3q.net [IPv6:2001:16d8:ffe5:1::f1]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 3A9FE1301 for ; Mon, 13 Jan 2014 09:03:49 +0000 (UTC) Received: by mx1.h3q.net (Postfix, from userid 80) id 1EC8233C92; Mon, 13 Jan 2014 10:03:45 +0100 (CET) To: "Lundberg, Johannes" Subject: Re: GPS ports in uhso X-PHP-Originating-Script: 0:main.inc MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Date: Mon, 13 Jan 2014 10:03:45 +0100 From: Fredrik Lindberg In-Reply-To: References: Message-ID: <45d9ccac366912a0d241c67016714615@shapeshifter.se> X-Sender: fli@shapeshifter.se User-Agent: RoundCube Webmail/0.8.5 Cc: freebsd-usb@freebsd.org X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Jan 2014 09:03:49 -0000 On 13.01.2014 03:28, Lundberg, Johannes wrote: > Hi > > I've been playing around getting GPS working with my GTM661W and the > uhso driver. > > The ports are defined in uhso.c but in the method > uhso_probe_iface_auto > the GPS and GPSCTL ports are not in the switch(port) case. Is there a > reason for this? > The only reason is that I didn't have a modem with a GPS port to test with when I wrote it, so I never added it since I didn't know if anything else was needed to get it working. > I tried simply adding like this > > 823 case UHSO_PORT_TYPE_MODEM: > 824 return (UHSO_IFACE_SPEC(UHSO_IF_BULK, > 825 UHSO_PORT_SERIAL, port)); > 826 case UHSO_PORT_TYPE_MSD: > > to > > 823 case UHSO_PORT_TYPE_GPS: > 824 case UHSO_PORT_TYPE_GPSCTL: > 825 case UHSO_PORT_TYPE_MODEM: > 826 return (UHSO_IFACE_SPEC(UHSO_IF_BULK, > 827 UHSO_PORT_SERIAL, port)); > 828 case UHSO_PORT_TYPE_MSD: > > Sorry for the manual patch. I can send a patch file later if needed. > I don't have an antenna at the moment so I can't confirm that the > data is accurate > but I'm getting output similar to what I expect in the GPS port and I > can control it via the GPSCTL port. > If you get GPS data and are able to use the port, then just add it :) Fredrik