Page 1 of 1

USB Tip

Posted: Wed Feb 03, 2010 8:00 am
by neato
I noticed a lot of USB questions lately, and I figured that since I am also writing a USB driver, I might as well offer you a tip that might help. All tips are meant for the Windows user.

Tools Needed
01. You are going to need a USB packet sniffer. This is helpful for understanding your device.
02. You are going to need WinIO. This library allows Windows XP users to access ports.

Now using Visual C++ or whatever, link to the WinIO library, initialize it, and write your code whilst keeping in mind that you will need to port anything you use such as malloc or inb & outb, etc later on when you have a working driver. The advantages to developing a USB driver this way is that you do not have to reboot the system in order to test your code on real hardware, your testing your code on real hardware, and when you are through writing the code, it will work on real hardware and it is easy to port. This is a great approach to developing the USB driver, because it is time consuming to reboot to test on real hardware, and most Virtual PCs do not support or poorly support the USB device; at least on Windows. Later, you can adapt this same approach to other drivers as well.

I hope this helps.