From owner-freebsd-questions@FreeBSD.ORG Fri Sep 26 12:46:56 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 595D316A4C0 for ; Fri, 26 Sep 2003 12:46:56 -0700 (PDT) Received: from imf18aec.mail.bellsouth.net (imf18aec.mail.bellsouth.net [205.152.59.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2CA6F43FAF for ; Fri, 26 Sep 2003 12:46:55 -0700 (PDT) (envelope-from nickpub@imap.cc) Received: from imap.cc ([68.158.4.54]) by imf18aec.mail.bellsouth.net (InterMail vM.5.01.05.27 201-253-122-126-127-20021220) with ESMTP id <20030926194654.NSHP1874.imf18aec.mail.bellsouth.net@imap.cc> for ; Fri, 26 Sep 2003 15:46:54 -0400 Message-ID: <3F7497B7.3010006@imap.cc> Date: Fri, 26 Sep 2003 15:47:03 -0400 From: Nick Holley User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.5b) Gecko/20030909 X-Accept-Language: en-us, en MIME-Version: 1.0 To: questions@freebsd.org References: <26696831.59rnEVNmBy@graf.pompo.net> In-Reply-To: <26696831.59rnEVNmBy@graf.pompo.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: How-to use a USB joypad? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 26 Sep 2003 19:46:56 -0000 Thierry Thomas wrote: >Hello, > >I have got a USB joypad, and it is sensed by the system (either 4.9 or >5.1): > >uhid0: Microsoft Microsoft SideWinder Plug & Play Game Pad, rev >1.00/1.01, addr 2, iclass 3/0 > >I have got a new device /dev/uhid0 and kldloaded joy.ko. > >When I run > >perl -e 'open(JOY,"/dev/uhid0")||die;while(1) >{sysread(JOY,$x,16);@j=unpack("iiii",$x);print "@j\n";sleep(1);}' > >(adapted from `man 4 joy'), it returns a list of numbers for each action >on the pad, but nothing usable. > >I've tried to link /dev/joy0 -> /dev/uhid0, but without success with >several games. > >What am I missing? > > What program are you trying to use? I know there are some issues with joysticks and gamepads on FreeBSD. For example, the joystick code was removed from zsnes due to problems, but there are no problems with snes9x. I don't know who exactly would have more information. Nick