Date: Tue, 17 May 2011 14:45:35 +0200 From: Luca Pizzamiglio <l.pizzamiglio@bally-wulff.de> To: Hans Petter Selasky <hselasky@c2i.net> Cc: freebsd-usb@freebsd.org Subject: Re: SMARTCARD USB Reader Message-ID: <4DD26DEF.8030601@bally-wulff.de> In-Reply-To: <4DD240F7.60903@bally-wulff.de> References: <4DD134A7.1070208@bally-wulff.de> <201105171122.09942.hselasky@c2i.net> <4DD240F7.60903@bally-wulff.de>
next in thread | previous in thread | raw e-mail | index | archive | help
Hi, It was my mistake, I didn't understand that libusb20_tr_open() wants the bEndpointAddress provided by the end point descriptor as ep_no parameter. Man pages are not extremely detailed and I used usbconfig sources as documentation, but I didn't found examples on transfer functions usage, then my mistake. Does anyone know a project or library that use libusb20 that I could use as example? If HPS agree, I want to use the experience I'm collecting to improve documentation or to write examples and/or a tutorial. thanks again Regards, Luca On 05/17/11 11:33, Luca Pizzamiglio wrote: > On 05/17/11 11:22, Hans Petter Selasky wrote: >> On Monday 16 May 2011 16:28:55 Luca Pizzamiglio wrote: >>> libusb20_dev_open( pdev, 32 ) >>> libusb20_dev_set_config_index( pdev, 0) >>> bin_ep = libusb20_tr_get_pointer( pdev, 0 ); >>> libusb20_tr_open( bin_ep, 4096, 1, bin_ep_num ); >>> bout_ep = libusb20_tr_get_pointer( pdev, 1 ); >>> libusb20_tr_open( bout_ep, 4096, 1, bout_ep_num ); >>> irq_ep = libusb20_tr_get_pointer( pdev, 2 ); >>> libusb20_tr_open( irq_ep, 4096, 1, irq_ep_num ); >> >> What is the value of irq_ep_num ? >> >> --HPS > > irq_ep_num is 2 and the device has 3 end points (confirmed also by > usbconfig). > > the device is ugen2.2 then the output of ls /dev/usb/2.2* is > /dev/usb/2.2.0 /dev/usb/2.2.1 /dev/usb/2.2.2 /dev/usb/2.2.3 > > Regards, > > Luca > _______________________________________________ > freebsd-usb@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-usb > To unsubscribe, send any mail to "freebsd-usb-unsubscribe@freebsd.org"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4DD26DEF.8030601>