richardp
Posts: 117
Joined: Thu Jan 12, 2012 11:46 am

Re: USB redux

Sun Apr 28, 2013 8:23 pm

@M33P,

thanks for the reply. I appreciate all the effort in the drivers and a technical viewpoint, but at a consumer the USB is basically not fit for my purpose. (I don't rate echoing audio from one USB adapter to another as a big CPU eater- I have the same code running on a single core 800Mhz ARM7 Marvell Armada SoC.. albeit its not an OTG USB port)
I would liken it to buying a car that works all the time unless you drive near Essex.. then the engine stops randomly. When the car is taken back to the dealership the salesman says 'It was cheap, what did you expect?' Ridiculous as it sounds, but thats the way I feel it is...

The Pi works in ALL your cases except in the ones that involve sustained mass USB data transfer.

If the Pi's USB does not work as expected, then the foundation can say so, or even give an estimate on progress; Its quite easy to change the marketing blurb to 'USB2.0 Keyboard and Mouse ONLY' - then we can all move on and accept the limitation. If some help is needed, I am sure the community will help chew up some of the SLOC - even provide some device logs that seem to provoke the problems more... this all boils down to communication and expectations management.

Richard
RaspberryPi's galore
Solid run CuBox
ODroid U2

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 23663
Joined: Sat Jul 30, 2011 7:41 pm

Re: USB redux

Mon Apr 29, 2013 2:30 am

richardp wrote:@M33P,

thanks for the reply. I appreciate all the effort in the drivers and a technical viewpoint, but at a consumer the USB is basically not fit for my purpose. (I don't rate echoing audio from one USB adapter to another as a big CPU eater- I have the same code running on a single core 800Mhz ARM7 Marvell Armada SoC.. albeit its not an OTG USB port)
I would liken it to buying a car that works all the time unless you drive near Essex.. then the engine stops randomly. When the car is taken back to the dealership the salesman says 'It was cheap, what did you expect?' Ridiculous as it sounds, but thats the way I feel it is...

The Pi works in ALL your cases except in the ones that involve sustained mass USB data transfer.

If the Pi's USB does not work as expected, then the foundation can say so, or even give an estimate on progress; Its quite easy to change the marketing blurb to 'USB2.0 Keyboard and Mouse ONLY' - then we can all move on and accept the limitation. If some help is needed, I am sure the community will help chew up some of the SLOC - even provide some device logs that seem to provoke the problems more... this all boils down to communication and expectations management.

Richard
The vast majority of people see no issues whatsoever, so rather than Essex, I'd say a small village in Scotland, Largs perhaps. Most people never go to Largs (although it is a nice place), so most people never see the problems (I was born in Essex, and I never see any problems).

Just because your very specific purpose doesn't work very well, does not mean the device it not fit for purpose in a huge number of other areas. Saying it only works with keyboard and mouse is obviously quite quite wrong. I've used it with USB hard drives using OpenELEC with no problems (High data transfer). I've used it with wireless adapters with no problems, streaming video, no problems.

I have a USB slide scanner. It doesn't work on my Ubuntu PC. USB isn't quite as universal as its name implies.

As to the community helping - the problem is there, known about and M33P and gsh are the only two people (that I know of) working on it. Where is this community of which you speak? Why are they not helping out? I know why - it's a very hard problem and the community is filled with people who wouldn't be able to help. I know, I'm one of them. We've got this thread and the FIQ testing thread where people are more than welcome to contribute and have been doing, with logs and testing though and that seems to be working well.

As to timescales - well, software development is a notoriously difficult thing to predict. Most people now see no issues, only corner cases, of which your case seems to be one. are left, but corner cases take time, often unpredictable amounts of time.

So I'd suggest that if it still doesn't work for you, move on to something that does work for you - the new Beaglebone black for example might be a good choice (no guarantee your use case will work on that either though). Give the Raspi to someone else for whom it will work fine, or use it as a media centre or similar.
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
"My grief counseller just died, luckily, he was so good, I didn't care."

User avatar
eastpole
Posts: 21
Joined: Wed Feb 15, 2012 7:17 pm
Location: Toronto, Canada
Contact: Website

Re: USB redux

Mon Apr 29, 2013 3:02 am

M33P wrote: In short, providing a necessarily complex but efficient software implementation to cater for the underlying simplicity of the hardware is HARD.
Although I'm not totally happy with the problems I have seen with my webcams, I am extremely happy to have someone of M33P's calibre working on the problem and explaining, when asked, what the problem is and what can be done. I understood your whole post, M33P, and I am not a software person, or even (in this current career) a technical person. Cheers and thanks to M33P and gsh!

When some time presents itself, I will lock myself in a room with some problem cameras and see if I can produce some test cases or at least logs for you.

gordon77
Posts: 4165
Joined: Sun Aug 05, 2012 3:12 pm

Re: USB redux

Mon Apr 29, 2013 3:29 am

eastpole wrote:
M33P wrote: In short, providing a necessarily complex but efficient software implementation to cater for the underlying simplicity of the hardware is HARD.
Although I'm not totally happy with the problems I have seen with my webcams, I am extremely happy to have someone of M33P's calibre working on the problem and explaining, when asked, what the problem is and what can be done. I understood your whole post, M33P, and I am not a software person, or even (in this current career) a technical person. Cheers and thanks to M33P and gsh!

When some time presents itself, I will lock myself in a room with some problem cameras and see if I can produce some test cases or at least logs for you.
Hi,

Perhaps you could try with the Philips 740/840 webcams which are popular with astronomers, l can't get anything out of that. :D

richardp
Posts: 117
Joined: Thu Jan 12, 2012 11:46 am

Re: USB redux

Mon Apr 29, 2013 6:24 am

jamesh wrote: The vast majority of people see no issues whatsoever, so rather than Essex, I'd say a small village in Scotland, Largs perhaps. Most people never go to Largs (although it is a nice place), so most people never see the problems (I was born in Essex, and I never see any problems).
Still, if the problem persists in a village, then its broken and it needs to be understood why. Based on that there are 2 people working on the problem suggests that the village is large.
jamesh wrote: Just because your very specific purpose doesn't work very well, does not mean the device it not fit for purpose in a huge number of other areas. Saying it only works with keyboard and mouse is obviously quite quite wrong. I've used it with USB hard drives using OpenELEC with no problems (High data transfer). I've used it with wireless adapters with no problems, streaming video, no problems.
I don't class taking audio from one USB device and outputting it on another one as 'Specific'.. seems rather a basic example of audio to me. I have used Wireless adapters with good and very bad results (earlier USB problems were that the port stopped working) - but as to streaming video, I can stream from a NAS - but there is a data loss when using my WinTV USB adapers (dib0700) and a TechnoTrend 2400 DVB-S adapter on TVHeadend. (even using basic applications) - in the case of the video, lost packets show as broken macroblocks; and they happen often... Perhaps you are not as fussy as I am to what 'Data Loss' is.
jamesh wrote: I have a USB slide scanner. It doesn't work on my Ubuntu PC. USB isn't quite as universal as its name implies.
I have alot of devices that work on ubuntu and not on the RaspberryPi... what does that mean?
jamesh wrote: As to the community helping - the problem is there, known about and M33P and gsh are the only two people (that I know of) working on it. Where is this community of which you speak? Why are they not helping out? I know why - it's a very hard problem and the community is filled with people who wouldn't be able to help. I know, I'm one of them. We've got this thread and the FIQ testing thread where people are more than welcome to contribute and have been doing, with logs and testing though and that seems to be working well.

M33P and gsh are good chaps, I am not by any means criticising them - they are doing a stirling job; And as to the community, has anyone asked for help from the Community? USB protocol analysers, time to look through code? Pick a file, and review the code... you will be surprised how may clever people are on the forums.
jamesh wrote: As to timescales - well, software development is a notoriously difficult thing to predict. Most people now see no issues, only corner cases, of which your case seems to be one. are left, but corner cases take time, often unpredictable amounts of time.
I wish my boss accepted that as a reason.. doesn't fly with me.
jamesh wrote: So I'd suggest that if it still doesn't work for you, move on to something that does work for you - the new Beaglebone black for example might be a good choice (no guarantee your use case will work on that either though). Give the Raspi to someone else for whom it will work fine, or use it as a media centre or similar.
And what will that solve? My Interest is the Pi, and I want to see it working the way it was sold to me.
RaspberryPi's galore
Solid run CuBox
ODroid U2

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 23663
Joined: Sat Jul 30, 2011 7:41 pm

Re: USB redux

Mon Apr 29, 2013 6:45 am

richardp wrote:
jamesh wrote: The vast majority of people see no issues whatsoever, so rather than Essex, I'd say a small village in Scotland, Largs perhaps. Most people never go to Largs (although it is a nice place), so most people never see the problems (I was born in Essex, and I never see any problems).
Still, if the problem persists in a village, then its broken and it needs to be understood why. Based on that there are 2 people working on the problem suggests that the village is large.
jamesh wrote: Just because your very specific purpose doesn't work very well, does not mean the device it not fit for purpose in a huge number of other areas. Saying it only works with keyboard and mouse is obviously quite quite wrong. I've used it with USB hard drives using OpenELEC with no problems (High data transfer). I've used it with wireless adapters with no problems, streaming video, no problems.
I don't class taking audio from one USB device and outputting it on another one as 'Specific'.. seems rather a basic example of audio to me. I have used Wireless adapters with good and very bad results (earlier USB problems were that the port stopped working) - but as to streaming video, I can stream from a NAS - but there is a data loss when using my WinTV USB adapers (dib0700) and a TechnoTrend 2400 DVB-S adapter on TVHeadend. (even using basic applications) - in the case of the video, lost packets show as broken macroblocks; and they happen often... Perhaps you are not as fussy as I am to what 'Data Loss' is.
jamesh wrote: I have a USB slide scanner. It doesn't work on my Ubuntu PC. USB isn't quite as universal as its name implies.
I have alot of devices that work on ubuntu and not on the RaspberryPi... what does that mean?
jamesh wrote: As to the community helping - the problem is there, known about and M33P and gsh are the only two people (that I know of) working on it. Where is this community of which you speak? Why are they not helping out? I know why - it's a very hard problem and the community is filled with people who wouldn't be able to help. I know, I'm one of them. We've got this thread and the FIQ testing thread where people are more than welcome to contribute and have been doing, with logs and testing though and that seems to be working well.

M33P and gsh are good chaps, I am not by any means criticising them - they are doing a stirling job; And as to the community, has anyone asked for help from the Community? USB protocol analysers, time to look through code? Pick a file, and review the code... you will be surprised how may clever people are on the forums.
jamesh wrote: As to timescales - well, software development is a notoriously difficult thing to predict. Most people now see no issues, only corner cases, of which your case seems to be one. are left, but corner cases take time, often unpredictable amounts of time.
I wish my boss accepted that as a reason.. doesn't fly with me.
jamesh wrote: So I'd suggest that if it still doesn't work for you, move on to something that does work for you - the new Beaglebone black for example might be a good choice (no guarantee your use case will work on that either though). Give the Raspi to someone else for whom it will work fine, or use it as a media centre or similar.
And what will that solve? My Interest is the Pi, and I want to see it working the way it was sold to me.
Hmm. I really think you should give up on the Pi and get something else. You seem to be expecting the earth, and that ain't gonna happen. In my book taking audio from one USB device and outputting on another is an unusual use case - I've never done it, on any machine I've ever used, in the last 25 years. Don't know any who has. For most (like 99.999%, given there have been >1.2 sold) people the Raspi works fine, for you it doesn't. I'm sorry that is the case, but what I wrote above is what's going on. There are no timescales, schedule etc for a fix for your specific case. Just a note, my 30 years of experience in this field had lead me to the conclusion that debugging HW/SW issues is about an unpredictable as you can get.

As to the community - there have been threads on the forum for a year. I'm pretty sure those clever people you talk about would by now have made a contribution if they wanted to- it's a known problem. But there have been no takers, which is why gsh (who is paid to work on this) is working on it. The problem is that clever people within this area of expertise who will work for free are few and far between.

Final thought- sell your Pi and get the money back. It wasn't sold to you as a panacea that would do everything you throw at it. It was sold to you as a $35 teaching device. I'd like mine to be able to do protein folding calculation at the speed of a £1000 desktop, but I accept that a $25/35 device is not going to do everything a £1000 device will do. What's great about the Raspi is it actually does more than I would expect a $35 device to do, just not everything people might want.

EDIT: Out of interest, have you tried the latest updates and gsh's FIQ fix (I think you need to rebuild the kernel to use that one)? Have they improved things?
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
"My grief counseller just died, luckily, he was so good, I didn't care."

Bakul Shah
Posts: 320
Joined: Sun Sep 25, 2011 1:25 am

Re: USB redux

Mon Apr 29, 2013 7:27 am

M33P wrote:The crux of the matter is, the hardware within the R-pi was never intended to be a PC-level host. The Designware OTG controller is just that - an on-the-go USB controller which has "dual role" capability - in that it can act as either a host or a device - but as an OTG host would only ever be expected to talk to 1-2 devices. Think mobile telephone plugged into USB pendrive, or a USB hdd plugged into a TV.

While the actual silicon is technically capable of implementing all the features of each type of individual USB transaction, it stops far short of providing the level of hardware integration that EHCI/xHCI compliant controllers found in desktop computers offer.

[deleted]

In addition to the FIQ removing most of the overhead, the expansion to the FIQ will integrate split-transaction completion (which is VERY timing sensitive due to the nature of hub implementations - if a hub is ignored for 125uS with completed split-transaction transfers stored in its transaction translator, it will drop them - leading to missed keypresses, garbled audio) which should eliminate dropped split packets. This also neatly avoids situations where a particularly slow codepath in kernel contexts blocks interrupts for a long period of time - it doesn't block FIQs.

In short, providing a necessarily complex but efficient software implementation to cater for the underlying simplicity of the hardware is HARD.
Would it make sense to split the work up beween the GPU and the ARM? The idea would be to set up a small numer of circular buffers (FIFOs) in each direction, may be one per low speed endpoint, to decouple the more complicated but less time sensitive processing on the ARM from the hard realtime but simpler processing on the GPU. In a way you are sort of doing this kind of split between the FIQ handler and the IRQ handler but moving this to GPU can mean fewer (or no) missed events. Very likely at the microframe level a finite state machine will do most of the work and FSMs can be table driven -- and can even be updated at boot time! If this is feasible and not too complex, it would help all the other OSes on the Raspi as well. Of course, this may just be moving the complexity around and may not be worth the trouble and may even not be possible at all.

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 23663
Joined: Sat Jul 30, 2011 7:41 pm

Re: USB redux

Mon Apr 29, 2013 7:51 am

Bakul Shah wrote:
M33P wrote:The crux of the matter is, the hardware within the R-pi was never intended to be a PC-level host. The Designware OTG controller is just that - an on-the-go USB controller which has "dual role" capability - in that it can act as either a host or a device - but as an OTG host would only ever be expected to talk to 1-2 devices. Think mobile telephone plugged into USB pendrive, or a USB hdd plugged into a TV.

While the actual silicon is technically capable of implementing all the features of each type of individual USB transaction, it stops far short of providing the level of hardware integration that EHCI/xHCI compliant controllers found in desktop computers offer.

[deleted]

In addition to the FIQ removing most of the overhead, the expansion to the FIQ will integrate split-transaction completion (which is VERY timing sensitive due to the nature of hub implementations - if a hub is ignored for 125uS with completed split-transaction transfers stored in its transaction translator, it will drop them - leading to missed keypresses, garbled audio) which should eliminate dropped split packets. This also neatly avoids situations where a particularly slow codepath in kernel contexts blocks interrupts for a long period of time - it doesn't block FIQs.

In short, providing a necessarily complex but efficient software implementation to cater for the underlying simplicity of the hardware is HARD.
Would it make sense to split the work up beween the GPU and the ARM? The idea would be to set up a small numer of circular buffers (FIFOs) in each direction, may be one per low speed endpoint, to decouple the more complicated but less time sensitive processing on the ARM from the hard realtime but simpler processing on the GPU. In a way you are sort of doing this kind of split between the FIQ handler and the IRQ handler but moving this to GPU can mean fewer (or no) missed events. Very likely at the microframe level a finite state machine will do most of the work and FSMs can be table driven -- and can even be updated at boot time! If this is feasible and not too complex, it would help all the other OSes on the Raspi as well. Of course, this may just be moving the complexity around and may not be worth the trouble and may even not be possible at all.
I think that was the original plan, not sure why it was decided to go a different route - maybe the timing issues with moving stuff to and from the gpu. Also note the GPU runs at 250Mhz, so is quite a bit slower than the ARM anyway.
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
"My grief counseller just died, luckily, he was so good, I didn't care."

gsh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 1438
Joined: Sat Sep 10, 2011 11:43 am

Re: USB redux

Mon Apr 29, 2013 8:01 am

In general moving the FIQ code to the GPU is quite simple but doesn't really get you very much (it's just removing a very small piece of code that probably executes something like 0.01% of the CPU).

To move any more complexity into the GPU means ripping the driver apart, and as I've spent quite a lot of time working on this driver is a very bad thing to do...

Overall as James says the hardware was never designed to do this, which is why it's a bit of a square peg, but as for inputting and outputting audio, works fine on my desk. I just use a daffodil audio dongle with no problems...

What device are you using?

Gordon
--
Gordon Hollingworth PhD
Raspberry Pi - Director of Software Engineering

Bakul Shah
Posts: 320
Joined: Sun Sep 25, 2011 1:25 am

Re: USB redux

Mon Apr 29, 2013 9:21 am

gsh wrote:In general moving the FIQ code to the GPU is quite simple but doesn't really get you very much (it's just removing a very small piece of code that probably executes something like 0.01% of the CPU).
This is much better; I didn't think it would be quite so simple. Anyway, if you did just that, would the GPU be able to respond faster than the fiq handler (dwc_otg_hcd_handle_fiq)? Can it be set up to poll on a regular interval? Freeing up fiq for other uses can be valuable too.
To move any more complexity into the GPU means ripping the driver apart, and as I've spent quite a lot of time working on this driver is a very bad thing to do...
Indeed... May be you can leave most of the driver alone and just add some new fifos for the gpu<->driver comm? Guess I will have to study the driver to see how bad this is! Having worked on drivers for controllers from hell in the past you have my full sympathy and appreciation!
What device are you using?
This was more of a general question, to understand the issues involved. Thanks for your response.

richardp
Posts: 117
Joined: Thu Jan 12, 2012 11:46 am

Re: USB redux

Mon Apr 29, 2013 10:16 am

jamesh wrote: Hmm. I really think you should give up on the Pi and get something else.
I wont even justify that with a response..
jamesh wrote: You seem to be expecting the earth, and that ain't gonna happen. In my book taking audio from one USB device and outputting on another is an unusual use case - I've never done it, on any machine I've ever used, in the last 25 years.
I will tell my 12 year daughter that she is a visionary! But James has never done it so its not possible.
jamesh wrote: Don't know any who has. For most (like 99.999%, given there have been >1.2 sold) people the Raspi works fine, for you it doesn't. I'm sorry that is the case, but what I wrote above is what's going on. There are no timescales, schedule etc for a fix for your specific case. Just a note, my 30 years of experience in this field had lead me to the conclusion that debugging HW/SW issues is about an unpredictable as you can get.

I am in the industry, so I will ignore that block :D
jamesh wrote: As to the community - there have been threads on the forum for a year. I'm pretty sure those clever people you talk about would by now have made a contribution if they wanted to- it's a known problem. But there have been no takers, which is why gsh (who is paid to work on this) is working on it. The problem is that clever people within this area of expertise who will work for free are few and far between.
Did anyone ask ? I can get my hands on an Ellisys USB analyser at short notice for a short period of time... but no-one asked.
jamesh wrote: Final thought- sell your Pi and get the money back. It wasn't sold to you as a panacea that would do everything you throw at it. It was sold to you as a $35 teaching device. I'd like mine to be able to do protein folding calculation at the speed of a £1000 desktop, but I accept that a $25/35 device is not going to do everything a £1000 device will do. What's great about the Raspi is it actually does more than I would expect a $35 device to do, just not everything people might want.
The project was BASED on a 12yr old Girls idea of a simple intercom and I really resent your sarcasm by taking a perfectly simple idea and expanding it in to the ridiculous - Again, the price comes in and the expectation of 'Its $35, what do you expect' - I expect it to have a working USB 2.0 port as it says on the tin.
jamesh wrote: EDIT: Out of interest, have you tried the latest updates and gsh's FIQ fix (I think you need to rebuild the kernel to use that one)? Have they improved things?
yes, tried the weekend. It has improved greatly! and Kudos to all
RaspberryPi's galore
Solid run CuBox
ODroid U2

richardp
Posts: 117
Joined: Thu Jan 12, 2012 11:46 am

Re: USB redux

Mon Apr 29, 2013 10:21 am

gsh wrote:In general moving the FIQ code to the GPU is quite simple but doesn't really get you very much (it's just removing a very small piece of code that probably executes something like 0.01% of the CPU).

To move any more complexity into the GPU means ripping the driver apart, and as I've spent quite a lot of time working on this driver is a very bad thing to do...

Overall as James says the hardware was never designed to do this, which is why it's a bit of a square peg, but as for inputting and outputting audio, works fine on my desk. I just use a daffodil audio dongle with no problems...

What device are you using?

Gordon
Thanks Gsh,

One audio dongle works pretty much okay... its when two are in operation that the major problems occur. The devices are the ebay cheap-n-nasty devices

http://www.ebay.co.uk/itm/USB-External- ... 2565425376

Richard
RaspberryPi's galore
Solid run CuBox
ODroid U2

User avatar
Burngate
Posts: 6006
Joined: Thu Sep 29, 2011 4:34 pm
Location: Berkshire UK Tralfamadore
Contact: Website

Re: USB redux

Mon Apr 29, 2013 10:21 am

Three thoughts occur having read M33P's post
1) I understood most of that, so I can't be as ignorant as I thought I was
2) Faced with those problems I would have given up and started sheep-farming
3) I've forgotten what the third thought was

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 23663
Joined: Sat Jul 30, 2011 7:41 pm

Re: USB redux

Mon Apr 29, 2013 11:31 am

richardp wrote:
jamesh wrote: Hmm. I really think you should give up on the Pi and get something else.
I wont even justify that with a response..
jamesh wrote: You seem to be expecting the earth, and that ain't gonna happen. In my book taking audio from one USB device and outputting on another is an unusual use case - I've never done it, on any machine I've ever used, in the last 25 years.
I will tell my 12 year daughter that she is a visionary! But James has never done it so its not possible.
jamesh wrote: Don't know any who has. For most (like 99.999%, given there have been >1.2 sold) people the Raspi works fine, for you it doesn't. I'm sorry that is the case, but what I wrote above is what's going on. There are no timescales, schedule etc for a fix for your specific case. Just a note, my 30 years of experience in this field had lead me to the conclusion that debugging HW/SW issues is about an unpredictable as you can get.

I am in the industry, so I will ignore that block :D
jamesh wrote: As to the community - there have been threads on the forum for a year. I'm pretty sure those clever people you talk about would by now have made a contribution if they wanted to- it's a known problem. But there have been no takers, which is why gsh (who is paid to work on this) is working on it. The problem is that clever people within this area of expertise who will work for free are few and far between.
Did anyone ask ? I can get my hands on an Ellisys USB analyser at short notice for a short period of time... but no-one asked.
jamesh wrote: Final thought- sell your Pi and get the money back. It wasn't sold to you as a panacea that would do everything you throw at it. It was sold to you as a $35 teaching device. I'd like mine to be able to do protein folding calculation at the speed of a £1000 desktop, but I accept that a $25/35 device is not going to do everything a £1000 device will do. What's great about the Raspi is it actually does more than I would expect a $35 device to do, just not everything people might want.
The project was BASED on a 12yr old Girls idea of a simple intercom and I really resent your sarcasm by taking a perfectly simple idea and expanding it in to the ridiculous - Again, the price comes in and the expectation of 'Its $35, what do you expect' - I expect it to have a working USB 2.0 port as it says on the tin.
jamesh wrote: EDIT: Out of interest, have you tried the latest updates and gsh's FIQ fix (I think you need to rebuild the kernel to use that one)? Have they improved things?
yes, tried the weekend. It has improved greatly! and Kudos to all
You want a fully working USB 2.0 implementation that works with every device ever made for USB. You won't get that. You'll probably never get that with a Raspi for the reasons outlined above. There are issues that the majority of people don't see. You do see issues. Therefor the device is NOT fit for your purpose, therefor either use it for something else or get rid of it. Simply. That's not sarcasm. That's telling you how it is. Why can you not see that?

Where on the tin does it say it has a USB 2.0 port that works with every device, just out of interest?

No one asked you to help? Are you taking the pee? Were you waiting for a personal invitation? Did you email gsh or M33P or post of the forum saying you were willing to help out? Since you seem to have access to the requisite equipment, and knew there was a problem, why didn't you take a look yourself - it's all OSS.

Arggghhh. Bored by this nonsense now. It's all want want want, with no common sense. I'm off to enjoy my jetlag and lack of sleep whilst sitting in a hot customer office getting inundated with bug reports.
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
"My grief counseller just died, luckily, he was so good, I didn't care."

User avatar
pluggy
Posts: 3635
Joined: Thu May 31, 2012 3:52 pm
Location: Barnoldswick, Lancashire,UK
Contact: Website

Re: USB redux

Mon Apr 29, 2013 12:06 pm

Maybe not the time for James' 'ol USB nemesis to put his tuppence worth in...... ;)

Relax James, I'm not going to give you any more flak. I'm prepared to live with the remaining flaws. Its a cheap computer for kids to learn to program on. I'm over expecting it to work like my Linux PC, its fit for purpose.

Keep up the good work.
Don't judge Linux by the Pi.......
I must not tread on too many sacred cows......

richardp
Posts: 117
Joined: Thu Jan 12, 2012 11:46 am

Re: USB redux

Mon Apr 29, 2013 12:16 pm

jamesh wrote: You want a fully working USB 2.0 implementation that works with every device ever made for USB. You won't get that. You'll probably never get that with a Raspi for the reasons outlined above. There are issues that the majority of people don't see. You do see issues. Therefor the device is NOT fit for your purpose, therefor either use it for something else or get rid of it. Simply. That's not sarcasm. That's telling you how it is. Why can you not see that?

Where on the tin does it say it has a USB 2.0 port that works with every device, just out of interest?

No one asked you to help? Are you taking the pee? Were you waiting for a personal invitation? Did you email gsh or M33P or post of the forum saying you were willing to help out? Since you seem to have access to the requisite equipment, and knew there was a problem, why didn't you take a look yourself - it's all OSS.

Arggghhh. Bored by this nonsense now. It's all want want want, with no common sense. I'm off to enjoy my jetlag and lack of sleep whilst sitting in a hot customer office getting inundated with bug reports.
Did you read anything I typed?... again you changed my message to the ridiculous and have lost the plot completely. I am offering some help and you feel it necessary to attack - I am not a domain expert on USB but I do know when to ask for help.

The foundation has asked and have employed some great chaps; who I take my hat of for being civil and constructive in the face of my horrible mails; yourself on other hand is a completely different story. There is nothing more irritating than a person interfering with your product, so I have kept out of it with the assumption that the foundation have got the problem in their sights and are sorting it... in a way they are sorting it, but you keep on telling people to 'F...k off if you don't like it' mentality which is quite destructive; Its unnecessary and uncalled for. I am not the only one asking for the USB fix, but yet you feel its appropriate to take pot-shots at me, just 'cos I asked for more information that you are not comfortable with.

I will not be giving up on the USB issue, or the rPi - they are fantastic products; Just yourself as an ambassador is really doing the product a dis-service.

As I previously asked... is help needed or not? Or is your standard reply of 'Screw you' going to be the reply. Either way, I wont lose any sleep over it.
RaspberryPi's galore
Solid run CuBox
ODroid U2

feverish
Posts: 486
Joined: Wed Jun 27, 2012 2:29 pm

Re: USB redux

Mon Apr 29, 2013 1:26 pm

Moderator(s), may I with some regret suggest this thread is being subverted and as a result has ceased to be productive in support of the basic objectives of these Raspi forums? Could you please ask these prickly protagonists to this aspect at least to take any further such traffic to PMs or silence, and let what previously seemed to be instructive traffic resume and continue? One effective way to deal with a refusal to desist would be to delete any 'I will have the last word on this'.
If discrimination is not challenged then we are effectively in collusion with the perpetrators of such behaviour:-Oxford dictionaries

User avatar
scrishton
Posts: 49
Joined: Mon May 07, 2012 8:48 pm
Location: Settle, in the Yorkshire Dales
Contact: Website

Re: USB redux

Mon Apr 29, 2013 1:37 pm

Perhaps there should be a separate forum section for USB problems. And another one for slagging each other off - but perhaps if our moderator jamesh could moderate himself a bit more and stop winding people up we wouldn't need the second one.

Simon R.

mweinberg
Posts: 4
Joined: Sat Apr 27, 2013 3:51 am

Re: USB redux

Mon Apr 29, 2013 2:25 pm

I don't mean to stir up more dust here, but I am a little late to the game and was directed here because of a problem I was seeing. My pi would crash when doing an isochronous usb transfer from a dslr camera. Not video or time critical, just a mass download of a picture file. I read through various threads and it seemed to me that this was a known issue and was being worked on. I am more than willing to provide logs or try things in order to help the debug. I am not qualified to dig into the driver code to debug, so I won't offer that, but I do think that a simple large file transfer is a fundamental usb function, so my expectation is that there would be an attempt to fix it. It doesn't look like a corner case to me, but maybe I'm not qualified to make that judgement.
I don't expect the world from a $35 piece of hardware, but I would expect to be able to connect a standard device and transfer data. If that is not the case, then just write a disclaimer and I'll move on and use it within whatever functionality domain that it is capable of.

--Mark

gsh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 1438
Joined: Sat Sep 10, 2011 11:43 am

Re: USB redux

Mon Apr 29, 2013 2:40 pm

Mark,

What speed is the camera... (USB 1.0 (LS), 1.1(FS) or 2.0(HS))

Can you do a lsusb -v

Its unlikely to be a problem with the mass storage driver or USB stack unless it's a USB 1.0 device, but still I'd not expect a crash. Do you have a crash log?

I assume you've updated to the latest firmware with rpi-update

Gordon
--
Gordon Hollingworth PhD
Raspberry Pi - Director of Software Engineering

User avatar
abishur
Posts: 4477
Joined: Thu Jul 28, 2011 4:10 am
Location: USA
Contact: Website

Re: USB redux

Mon Apr 29, 2013 2:50 pm

scrishton wrote:Perhaps there should be a separate forum section for USB problems. And another one for slagging each other off - but perhaps if our moderator jamesh could moderate himself a bit more and stop winding people up we wouldn't need the second one.

Simon R.
Actually, reading through this converstation in one go, James has been rather nice. He's also been direct and forthright against a user whose first post said
a FUNDAMENTAL function on the RaspberryPi is yet to be clarified, or even fixed
and then when asked about what "FUNDAMENTAL" issue had not yet been fixed he revealed that it was passing audio between two USB->audio devices. Now I don't think this is a revolutionary idea, nor did anything James said imply it was revolutionary so while your daughter may indeed be very bright, this is hardly visionary :-p, but it is an uncommon one, indeed doing a quick mental sampling of my tech friends/family I can't even claim that any of us have owned a *SINGLE* USB->audio device, let alone two such devices. Of course I also like the general idea as it sounds like it's taking the pi media center to the next level by turning it into some kind of audio receiver, I digress.

So maybe rather than publically getting onto a mod for moderating, which is quite frankly, foolish, we should re-evaluate what consitutes as a fundamental issue in concerns to USB and choose the wording of posts more accurately?
Dear forum: Play nice ;-)

tvjon
Posts: 710
Joined: Mon Jan 07, 2013 9:11 am

Re: USB redux

Mon Apr 29, 2013 3:05 pm

"Please try to stay on topic in this one, and be polite!"

In the course of trying to help another poster with a v4l2 problem, i've just firmware updated about 2 hours ago, plugged in a USB capture device, & here's the resulting Oops:
SANY0032lr2.jpg
SANY0032lr2.jpg (55.17 KiB) Viewed 5274 times
Resolution is limited by attachment file size, but it is readable if the page is zoomed.

mweinberg
Posts: 4
Joined: Sat Apr 27, 2013 3:51 am

Re: USB redux

Mon Apr 29, 2013 3:10 pm

Hi Gordon,
Camera is 1.1(FS).

lsusb -v:

Code: Select all

[email protected] ~ $ lsusb -v

Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp.
Couldn't open device, some information will be missing
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            9 Hub
  bDeviceSubClass         0 Unused
  bDeviceProtocol         2 TT per port
  bMaxPacketSize0        64
  idVendor           0x0424 Standard Microsystems Corp.
  idProduct          0x9512
  bcdDevice            2.00
  iManufacturer           0
  iProduct                0
  iSerial                 0
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           41
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          0
    bmAttributes         0xe0
      Self Powered
      Remote Wakeup
    MaxPower                2mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           1
      bInterfaceClass         9 Hub
      bInterfaceSubClass      0 Unused
      bInterfaceProtocol      1 Single TT
      iInterface              0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0001  1x 1 bytes
        bInterval              12
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       1
      bNumEndpoints           1
      bInterfaceClass         9 Hub
      bInterfaceSubClass      0 Unused
      bInterfaceProtocol      2 TT per port
      iInterface              0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0001  1x 1 bytes
        bInterval              12

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Couldn't open device, some information will be missing
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            9 Hub
  bDeviceSubClass         0 Unused
  bDeviceProtocol         1 Single TT
  bMaxPacketSize0        64
  idVendor           0x1d6b Linux Foundation
  idProduct          0x0002 2.0 root hub
  bcdDevice            3.06
  iManufacturer           3
  iProduct                2
  iSerial                 1
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           25
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          0
    bmAttributes         0xe0
      Self Powered
      Remote Wakeup
    MaxPower                0mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           1
      bInterfaceClass         9 Hub
      bInterfaceSubClass      0 Unused
      bInterfaceProtocol      0 Full speed (or root) hub
      iInterface              0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0004  1x 4 bytes
        bInterval              12

Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp.
Couldn't open device, some information will be missing
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass          255 Vendor Specific Class
  bDeviceSubClass         0
  bDeviceProtocol         1
  bMaxPacketSize0        64
  idVendor           0x0424 Standard Microsystems Corp.
  idProduct          0xec00
  bcdDevice            2.00
  iManufacturer           0
  iProduct                0
  iSerial                 0
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           39
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          0
    bmAttributes         0xe0
      Self Powered
      Remote Wakeup
    MaxPower                2mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           3
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass      0
      bInterfaceProtocol    255
      iInterface              0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x02  EP 2 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0010  1x 16 bytes
        bInterval               4

Bus 001 Device 004: ID 07b4:0110 Olympus Optical Co., Ltd
Couldn't open device, some information will be missing
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               1.10
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0
  bDeviceProtocol         0
  bMaxPacketSize0         8
  idVendor           0x07b4 Olympus Optical Co., Ltd
  idProduct          0x0110
  bcdDevice            1.00
  iManufacturer           1
  iProduct                2
  iSerial                 3
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           39
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          0
    bmAttributes         0xc0
      Self Powered
    MaxPower              100mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           3
      bInterfaceClass         8 Mass Storage
      bInterfaceSubClass      6 SCSI
      bInterfaceProtocol     80 Bulk-Only
      iInterface              0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x01  EP 1 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x83  EP 3 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0040  1x 64 bytes
        bInterval             100
[email protected] ~ $
Sorry, I'm a little rusty in the linux environment. If you can tell me where to retrieve it, I'm sure I can repeat and get the crash log.

--Mark
gsh wrote:Mark,

What speed is the camera... (USB 1.0 (LS), 1.1(FS) or 2.0(HS))

Can you do a lsusb -v

Its unlikely to be a problem with the mass storage driver or USB stack unless it's a USB 1.0 device, but still I'd not expect a crash. Do you have a crash log?

I assume you've updated to the latest firmware with rpi-update

Gordon

gsh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 1438
Joined: Sat Sep 10, 2011 11:43 am

Re: USB redux

Mon Apr 29, 2013 3:19 pm

tvjon wrote:"Please try to stay on topic in this one, and be polite!"

In the course of trying to help another poster with a v4l2 problem, i've just firmware updated about 2 hours ago, plugged in a USB capture device, & here's the resulting Oops:
SANY0032lr2.jpg
Resolution is limited by attachment file size, but it is readable if the page is zoomed.

That looks like it crashed inside the USBVision driver not the USB stack...

Probably due to something else happening which the driver doesn't handle correctly... Of course it could be the thing that isn't being handled is a bug in the dwc_otg driver, but still it shouldn't crash!

Gordon
--
Gordon Hollingworth PhD
Raspberry Pi - Director of Software Engineering

gsh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 1438
Joined: Sat Sep 10, 2011 11:43 am

Re: USB redux

Mon Apr 29, 2013 3:21 pm

OK,

So the camera is a USB1.1 device which does mean it could be an effect of the split transaction stuff...

Can't help any further until I've release the FIQ implementation... Soon...

Gordon
--
Gordon Hollingworth PhD
Raspberry Pi - Director of Software Engineering

Return to “Troubleshooting”