From this thread on MSFN:
http://www.msfn.org/...topic=99220&hl=
I learned how member Molecule found on an Italian site a supposedly Universal Win98 Mass Storage Driver.
Direct link:
http://www.wintricks...ad/wtgenusb.zip
I guess everyone knows about the very good work made by the known Maximus Decim Native USB drivers:
http://www.msfn.org/...topic=43605&hl=
But the info on the referenced site:
http://www.wintricks...q/usbpen98.html
is VERY interesting and the size of the package really luring for winimize projects.
Due to the mainly graphical nature of the article, I will only here roughly translate the part that I see as important:
[BEGIN ITALIAN]
[END ITALIAN]Dettagli sul nuovo driver
Come ho fatto a realizzare questo driver?
Beh, sono partito dalla considerazione che le versioni di Windows più recenti non richiedono driver particolari, ma ne utilizzano uno generico incluso nel sistema.
Ho quindi pensato che bastasse qualche modifica ai file della chiavetta Lexar che già possedevo, in particolare il riconoscimento della periferica da parte del sistema.
Ma come fa Windows a riconoscere le periferiche USB?
Senza tediarvi in dettagliate spiegazioni ho notato che le identifica tramite alcune informazioni lette dalla porta USB, precisamente VendorID (un codice identificativo del produttore) e ProductID (codice identificativo del prodotto).
Ogni driver per Windows 98, infatti, contiene nel file .INF questo codice, affinché il sistema possa riconoscere il dispositivo. Spesso in realtà c'è un elenco di codici, in modo da permettere il riconoscimento di una serie di prodotti della casa.
Per prima cosa ho provato a mettere ProductID e VendorID delativi alla mia chiavetta Samsung nel file .INF della Lexar.
Ha funzionato!
La chiavetta Samsung veniva riconosciuta e gestita regolarmente!
Dopo l'entusiasmo iniziale ho voluto cercare di rendere il mio driver universale.
Ho quindi cercato di vedere come questi dispositivi vengono gestiti dai Windows superiori.
La risposta l'ho trovata nle file USBSTOR.INF di Windows ME e di XP: il riconoscimento non veniva fatto tramite VendorID e ProductID, ma tramite classe e sottoclasse della periferica: insomma, se la periferica risulta fatta così allora il driver sarà questo.
Ciò rende il riconoscimento e la gestione della periferica indipendente dal produttore e modello!
Ho provato ad implementare questa modalità nel file .INF del mio driver.
Ero scettico sulle possibilità di funzionamento in quanto ritenevo che la possibilità che hanno le versioni superiori di Windows di utilizzare un driver universale sia legata alla differente gestione delle periferiche USB in generale.
Invece mi sbagliavo, la modifica ha funzionato al primo colpo!
In seguito ho provato a modificare anche altri driver di altre case, ma per buona parte non funzionavano o funzionavano male, il migliore, tra quelli provati, è proprio il Lexar.
Rough English translation:
Details on the new drive
How did I came out with this driver?
I started from the fact that more recent windows versions have a native generic USB driver.
So I thought that some slight modifications to the driver for a Lexar USB key I had, particularly to the way the key is recognized by plug 'n play would suffice.
How does Windows recognize USB devices?
Without bothering you with complex explanations, they are identified by some info read fro the USB port, i.e. VendorID (code identifying a manufacturer) and ProductID (code identifying the product).
Every Windows 98 driver contains, as a matter of fact these data in the .INF file, very often there is a list of such codes, so that more than one device can be used with same driver.
First thing I tried putting ProductID and VendorID of my Samsung key in the .INF file of the Lexar driver.
It worked!
The Samsung key was recognized and worked flawlessly!
Then I tried to make the driver universal.
I found the answer in the USBSTOR.INF of both Windows ME and XP: the device was not recognized through its VendorID and ProductID but rather through class and subclass of the device, in a nutshell, if the device belongs to a class and subclass that driver will be used.
This makes recognition and management of the device independent from make/model!
So I tried implementing same method in the .INF file of my driver.
At first I was skeptical, as I thought that this way of detecting devices was derived from some different way of managing USB devices later versions of Windows might have.
But I was wrong, the editing worked at first try!
Then I tried with other manufactuers' drivers, but in most cases they appeared to be not working or only partially working, best one, at least among those I tried is the Lexar one.
Have fun, mates
jaclaz