From owner-freebsd-usb@FreeBSD.ORG Mon Feb 17 20:08:57 2014 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 3D31044D for ; Mon, 17 Feb 2014 20:08:57 +0000 (UTC) Received: from mta05.bitpro.no (mta05.bitpro.no [92.42.64.202]) by mx1.freebsd.org (Postfix) with ESMTP id BD8611B00 for ; Mon, 17 Feb 2014 20:08:56 +0000 (UTC) Received: from mail.lockless.no (mail.lockless.no [46.29.221.38]) by mta05.bitpro.no (Postfix) with ESMTPS id 0F57917F84C; Mon, 17 Feb 2014 21:08:54 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by mail.lockless.no (Postfix) with ESMTP id 978DE1619C2; Mon, 17 Feb 2014 21:09:50 +0100 (CET) X-Virus-Scanned: by amavisd-new-2.6.4 (20090625) (Debian) at lockless.no Received: from mail.lockless.no ([127.0.0.1]) by localhost (mail.lockless.no [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SwiLnKubcP2a; Mon, 17 Feb 2014 21:09:49 +0100 (CET) Received: from laptop015.home.selasky.org (cm-176.74.213.204.customer.telag.net [176.74.213.204]) by mail.lockless.no (Postfix) with ESMTPSA id A69311619C1; Mon, 17 Feb 2014 21:09:49 +0100 (CET) Message-ID: <53026C8C.5060005@bitfrost.no> Date: Mon, 17 Feb 2014 21:09:48 +0100 From: Hans Petter Selasky Organization: Bitfrost A/S User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0 MIME-Version: 1.0 To: Chris Duffy , freebsd-usb@freebsd.org Subject: Re: Question on Freebsd 9.1, usb interface to a UPSonic CXR 2000 using NUT code. References: <52FBAF6A.5000304@small-tree.com> <52FDD24F.40904@bitfrost.no> <53023448.3090509@small-tree.com> In-Reply-To: <53023448.3090509@small-tree.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit 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, 17 Feb 2014 20:08:57 -0000 On 02/17/14 17:09, Chris Duffy wrote: > Thx, > > I tried the: > > For ugen1.3 run: > > usbdump -i usbus1 -f 3 -s 65536 -vvv > > But it filtered out all packets. > > I then tried: > > usbdump -i usbus1 -s 65536 -vvv > > and it did get a lot of packets.... > I have attached the file....do the packets make > any sense and tell you anything? > > Thx > chris > > > > On 2/14/14, 2:22 AM, Hans Petter Selasky wrote: >> On 02/12/14 18:29, Chris Duffy wrote: >>> I have a customer of mine that just bought a >>> >>> UPSonic CXR 2000 >>> >>> and is trying to connect the usb cable from this UPS >>> to a Freebsd 9.1 system running the 2.6.5 NUT code. >>> Freebsd/NUT does not see the device properly. >>> >>> I have also been working with the NUT people and >>> they suggested that I discuss this issue with the freebsd-usb >>> folks..... >>> >>> Here are some command output that the NUT people asked for >>> and after seeing it, they think it may be a bug on Freebsd >>> so here I am asking for help :) They also stated that they >>> had thought that others may have gotten the blazer_usb >>> driver to work properly on Freebsd but........ >>> >>> I deactivated the uhidd stuff since NUT suggested this >>> in order to get more debug info.... >>> >>> >>> # uhidd -v -u /dev/ugen1.3 >>> >>> ugen1.3[0]-> Report descriptor size = 27 >>> ugen1.3[0]-> Kernel driver is active >>> ugen1.3[0]-> kernel driver detached! >>> ugen1.3[0]-> Find IN interrupt ep: 0x81 packet_size=0x8 >>> >>> >>> # /usr/local/libexec/nut/blazer_usb -a UPSonic -u root -DDDD >>> >>> 0.000000 debug level is '4' >>> 0.176793 Checking device (06DA/0005) (/dev/usb//dev/ugen1.3) >>> 0.183672 - VendorID: 06da >>> 0.183696 - ProductID: 0005 >>> 0.183699 - Manufacturer: PPC >>> 0.183703 - Product: USB UPS >>> 0.183707 - Serial Number: unknown >>> 0.183710 - Bus: /dev/usb >>> 0.183714 Trying to match device >>> 0.183718 Device matches >>> 0.183746 Trying megatec protocol... >>> 0.184566 send: Q1 >>> 0.423946 read: (239.3 239.3 229.9 027 50.0 2.19 22.8 00000001 >>> 0.423988 Status read in 1 tries >>> 0.424000 Supported UPS detected with megatec protocol >>> 1.455927 send: Unknown error >>> 1.455973 Permissions problem: Input/output error >>> >>> >>> Network UPS Tools - Megatec/Q1 protocol USB driver 0.09 >>> (2.6.5-Unversioned directory) >>> >>> I have checked all the ownership/permissions on the /dev >>> related files and confirmed with NUT the proper stuff.... >>> >>> Is there something I am missing to support the usb attachment >>> for UPS driver for this particular UPS? >>> >>> Thx for any pointers/help. >> >> Hi, >> >> For ugenX.Y run: >> >> usbdump -i usbusX -f Y -s 65536 -vvv >> >> And you will see right away what USB traffic is causing the problem. >> >> --HPS >> Hi, I don't see any errors in the USB log. The usbdump needs to be started before you plug the device and before starting blazer_usb. Also you need to find the exact bus and "-f" device number which corresponds to your device. Use usbconfig to find this information. Can you: ktrace /usr/local/libexec/nut/blazer_usb -a UPSonic -u root -DDDD When finished: kdump | gzip > blazer_usb.log.gz And send it to me off-list. The USB trace looks normal. --HPS