To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.roboticsOpen lugnet.robotics in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / 17070
17069  |  17071
Subject: 
Re: USB tower flow control question
Newsgroups: 
lugnet.robotics
Date: 
Thu, 17 Jan 2002 01:42:32 GMT
Original-From: 
Stuart Northfield <stu@^ihatespam^janitorium.co.uk>
Viewed: 
671 times
  
At 13:21 -0500 2002-01-16, PC CHAN wrote:
Hi there,

The more serious problem observed when trying to get legousbtower,
usb-uhci and nqc to work togeher was that the tower hanged after one
complete round trip. (nqc and legousbtower works with uhci on my
setup but not with usb-uhci.)

Yup - this is what happens for me also.

Usb-uhci managed to transport the first echo command and responses
between the RCX brick and nqc correctly (7 bytes forth and 7 bytes
back).

The tower then stopped flashing when usb-uhci seemed dma'ing happily
as usual. That's not right.  On rmmod and insmod usb-uhci, the tower
came into life again for another round trip.

Yup (although often needs a physical unplug/replug as well for me).

Why would the tower stop working, Could it be jammed because of
traffic?  Would the tower do flow control and how?

I believe it's not the tower, it's the USB subsystem that is
'jammed'.  The 0.5 version of the legousbtower.c driver is not
driving USB correctly (though it's a nightmare trying to discover how
it is meant to be driven) - you cannot submit the same URB twice
without unlinking it in between calls (or you shouldn't be able to -
I have a suspicion that uhci.c may not enforce this).  This is the
stage I am stuck at because the unlink doesn't work correctly on my
machine which uses usb-ohci.c!  I refer you to my earlier message to
the legousb developer list which documented what I believe to be the
correct logic for using interrupt URBs - which has subsequently been
confirmed as fundamentally correct by David Brownell on the linux-usb
developer list.  He was puzzled as to why I never get completion
events for asynchronous unlinks though...

I am currently trying to switch to the 2.5.2 kernel in order to try
some experiments for him as that is where the real USB development is
going on at the moment.  If it gets fixed there it may then be
back-ported into the 2.4 trees.  Don't hold your breath though!

Legousbtower is using interrupt urb's to transport data while it
also uses control urb's to configure the tower.  The control urb's
works OK for multiple rounds without the need for restarting.

I want to test my code on the other (uhci.c & usb-uhci.c) sub-systems
in the next day or two at work and then I'll post my updated version
again (whether it works or not!)

Have fun

Stu
--
The Janitorium <http://www.janitorium.co.uk/>



Message is in Reply To:
  USB tower flow control question
 
Hi there, The more serious problem observed when trying to get legousbtower, usb-uhci and nqc to work togeher was that the tower hanged after one complete round trip. (nqc and legousbtower works with uhci on my setup but not with usb-uhci.) Usb-uhci (...) (23 years ago, 16-Jan-02, to lugnet.robotics)

2 Messages in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR