From owner-freebsd-arch@FreeBSD.ORG Fri Mar 2 16:10:34 2007 Return-Path: X-Original-To: freebsd-arch@FreeBSD.org Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5137A16A407; Fri, 2 Mar 2007 16:10:34 +0000 (UTC) (envelope-from trhodes@FreeBSD.org) Received: from chipmunk.ai.net (axe.ai.net [205.134.161.26]) by mx1.freebsd.org (Postfix) with ESMTP id 0F75713C48E; Fri, 2 Mar 2007 16:10:33 +0000 (UTC) (envelope-from trhodes@FreeBSD.org) Received: from localhost (ip70-177-190-239.dc.dc.cox.net [70.177.190.239]) by chipmunk.ai.net (8.13.4/8.13.4) with SMTP id l22GAbl5003004; Fri, 2 Mar 2007 11:10:38 -0500 (EST) (envelope-from trhodes@FreeBSD.org) Date: Fri, 2 Mar 2007 11:10:31 -0500 From: Tom Rhodes To: Tony Shadwick Message-Id: <20070302111031.6e485453.trhodes@FreeBSD.org> In-Reply-To: <45E846B7.9030801@oss-solutions.com> References: <45E3467E.2070000@oss-solutions.com> <200702270345.13194.markus@FreeBSD.org> <45E83FB7.1060002@oss-solutions.com> <20070302103957.7fd27ef9.trhodes@FreeBSD.org> <45E846B7.9030801@oss-solutions.com> Organization: The FreeBSD Project X-Mailer: Sylpheed version 1.0.6 (GTK+ 1.2.10; i386-portbld-freebsd7.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: trhodes@FreeBSD.org, markus@FreeBSD.org, freebsd-arch@FreeBSD.org Subject: Re: USB HID Driver help X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 02 Mar 2007 16:10:34 -0000 On Fri, 02 Mar 2007 09:45:59 -0600 Tony Shadwick wrote: > Tom Rhodes wrote: > > On Fri, 02 Mar 2007 09:16:07 -0600 > > Tony Shadwick wrote: > > > >> Sorry for being slow to respond. I tried doing kldload uhid, and was > >> told "file already exists", so I take that to presume uhid is getting > >> loaded at boot, thus perhaps you're right about needing to work around > >> this. How would you suggest? > > > > Or is included via the GENERIC kernel file. So you will need to > > remove it from your kernel before using the module. > > > >> > >> Markus Brueffer wrote: > >>> Hi Tony, > >>> > >>> On Monday 26 February 2007 21:43, Tony Shadwick wrote: > >>>> I'm definitely not a high-end programmer, but I have gone to the trouble > >>>> of working out the protocol for a USB light gun that is normally used on > >>>> a Playstation 2 video game console. It has 10 buttons, and can track > >>>> on-screen location if it has access to the composite sync video signal. > >>>> > >>>> http://forum.arcadecontrols.com/index.php?topic=60813.0 > >>>> > >>>> I've written just a basic parser for the gun. FreeBSD picks up the gun > >>>> and gives it a ugen character device that I then take continuous input > >>>> from. The protocol is 6 bytes long repeated pretty much as fast as the > >>>> gun can send it. > >>> Did you have uhid(4) in the kernel or loaded as module? If not, please try > >>> loading the module and see if the device gets picked up by it (you need to > >>> replug it after loading the module). > >>> > >>> Judging from the description of the protocol, it seems that the device is a > >>> regular USB HID device. If it doesn't get picked up by uhid(4), it suffers > >>> from the same problem as the gamepad of the Xbox360 by not exposing itself as > >>> being a regular USB HID device and not providing a HID descriptor. Both can > >>> be worked around but please verify first, that uhid(4) doesn't already > >>> support the device. Writing an extra driver for this device is not > >>> neccessary. > >>> > >>> Markus > >>> > >> _______________________________________________ > >> freebsd-arch@freebsd.org mailing list > >> http://lists.freebsd.org/mailman/listinfo/freebsd-arch > >> To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org" > >> > > > > > > We wre trying to establish that uhid was loaded to see whether the light > gun was really an HID device or not, and if it is similar to the XBox > controller that is, but doesn't get detected, we need to work around > that problem. I'm asking how it is suggested that I work around the > issue. I've never written a driver before. Oh, my bad. I thought you wanted to try the approach of unloading and then re-loading the module but was getting tripped up with the message above. Sorry, -- Tom Rhodes