KurtE
Senior Member+
I'll try it out today, but I feel like it's using duct tape to fix a problem. Obviously commands need to begin in user code, but subsequent calls to queue_Data_Transfer should probably be done inside the callbacks so that they are initiated in the isr().
With the fix to pipeIn, my non-blocking USBDrive initialization is finally working. I must confess, however, that the pipeIn fix has made initialization about 500% faster, so the non-blocking initialization is not so important.
@wwatson
Are your drives initializing any faster, too?
Note: most of the cases that this would hopefully fix are those that are initiated from the user code. Like: please write 4096 bytes to the file... Things like Reads are mostly handled by first doing the queue out of the command, and then all data that comes back is under the control of the ISR. However I understand that some of MassStorageDriver the read requeue is done after the data is processed... Some of this code could be reorganized, to process the data on a callback, and state machine... But I believe a lot of this code is modelled after other code bases. Where for example if you wish to read 4096, you simply do the request and when the data is there your code continues, which fits pretty well in systems with some for of OS of threads or...
Again assuming what you said is you are about to retire. Congrats. I survived that for several years now!@yeahtuna - I just got home from work, I might be called back in tonight I am really glad this has solved your issues I will try it out tonight if I can. I also have some retirement things to take care of first. Will be glad when I finally retire and have more time to help...
Edit: And learn