driver writing != bus driving

Ilias Tsigkogiannis' Introduction to Windows Device Drivers and Windows Audio Concepts

Introductory driver writing resources

Introductory driver writing resources

Rate This
  • Comments 9
After having finished with the initial resources on the windows internals, it is time for a developer to start learning about windows drivers. The goal of this post is to provide a list of links that can be used by somebody to get accustomed with the idea of a driver, the tools that he needs to use, etc.

A very important url for this case is http://www.osronline.com. At the top of that page it says "Everything (About) Windows Driver Development" and this is (almost :) ) the case. In fact, this site has a lots of resources that are really useful both to new and to more experienced developers. The first thing that I suggest that you should do, after visiting this website is to become a member (by clicking on the "Join" button). Membership is free and it gives you access to a lot of additional helpful resources:
  1. First of all (and maybe most important for now) you'll find a list of "fundamental" resources at http://www.osronline.com/section.cfm?section=26. This list is consisted of several interesting subjects, like Getting Started with Windows Drivers (which is the very first document that you should read, in order to get answers to lots of your questions about drivers), Exactly what is a Driver (which gives a simple technical overview of a driver) and also some basic information about what are the threads, the rings, page fault and real mode (even though I hope that you've learned these by looking at the resources that I mentioned in my previous posts).
  2. Another important link in the website is the listserv. There are 3 lists that are being maintained by OSR: ntdev (various windows system-level topics), windbg (windows debugger or windbg is a really important tool for driver debugging) and ntfsd (file systems and file system filter drivers). The range of the members in these lists is pretty wide, from beginners to veterans. MOST IMPORTANTLY, there are many Microsoft employees, who participate actively in the list and answer the questions. All of the lists are a MUST-join (especially the 2 first ones, if you are not interested in file system drivers).
  3. Apart from the above very important links there are some more like the NT Insider (similar to an online magazine that covers articles relative to driver development), Downloads (includes many useful utilities like the Driver loader) and Hector's Memos (another interesting blog about driver development).
In addition, Microsoft also offers a lot of really valuable resources:
  1. By clicking here, you'll get redirected to an article that provides all the introductory information that you need about drivers: types of drivers, development environment, debugging tools (windbg rocks!), etc. It's more technical than the corresponding OSR paper, but it remains an all-encompassing easy-to-read paper.
  2. All the current windows drivers (excluding the legacy ones) are written in a way that is called the Windows Driver Model (WDM). However, the new model (from Windows Vista and afterwards it is the default model, however there will be versions for previous operating systems, too) is the Windows Driver Foundation (WDF). This model is much much simpler than WDM and is the model that will be used for drivers in the future (i.e. that's the model that a new driver developer should become accustomed with!). This model allows both the creation of kernel-mode and user-mode drivers. The former framework is called Kernel-Mode Driver Framework (KMDF) and you can find an introduction here. The latter framework is called User-Mode Driver Framework (UMDF) and you can find an introduction here. Also, the UMDF Beta, which includes  sample code, documentation, development tools, etc can be downloaded from here.
  3. Another very useful website with videos from Microsoft employees is http://channel9.msdn.com/. I think that the most interesting videos for driver developers are the ones in the "Going Deep" series and the ones marked with the "Drivers" tag. Some interesting relevant topics are (I'll try to update this list int the future):
  4. The Windows Driver Kit (try visiting the link with IE), which is an all-in-one driver development kit. It is the definitive source for driver development, since it includes Microsoft's public documentation about the driver model, as well as all the public APIs. The information in the WDK is relatively easy to read (up to a point). I suggest that you read "Getting started with Windows Drivers" and the "Kernel-Mode Driver Architecture Design Guide" (As much as possible. Most of the information there should be familiar after reading the Windows Internals book, too). After that, depending on the type of the driver that you are interested in (kernel-mode or user-mode) you should look at the "Kernel-Mode Framework Design Guide" or the "User-Mode Framework Design Guide" respectively. The former is more complete, but I think that the latter is written in a more simple style. Generally, the WDK is a valuable reference, so you can also find available tools, installation techniques, etc. Peter Wieland has written a post with extensive instructions on how to download the WDK (warning: it's 2.3GB!), which will allow you to take advantage of the development environment, the samples, etc.
  5. The public Microsoft newsgroups can be found at the newsgroup server msnews.microsoft.com (you'll need a newsgroup reader like Outlook Express to read them). The most important ones are Microsoft.pulbic.development.device.drivers, Microsoft.public.win32.programmer.kernel and Microsoft.public.windowsxp.device_driver.dev.
Leave a Comment
  • Please add 1 and 5 and type the answer here:
  • Post
  • http://jasonhaley.com/blog/archive/2006/09/28/136991.aspx
  • Excellent blog, very useful for those like me, whos interesting in dd development but got no clue to start. Keep up the good work. Thanks again
  • oh , can u tell me about MP-safe ?

  • zarob, what exactly do you need to know about MP-safe? If you want to learn about the synchronization primitives that will help you write MP-safe code, then you will find lots of useful information at http://www.microsoft.com/whdc/driver/kernel/locks.mspx as I mention in my next post.

  • im not sure really . but thx anyway ~.~

  • Hey,

    Thanks for information!

  • Thanks for the article. Very useful information. One small correction required. When you introduce osronline, you are giving links to the articles ("...also some basic information about what are the threads, the rings, page fault and real mode (even though... "), the links to real should be ...article=224. The present link takes you to article=225 which is the page for Real Mode.

  • In my previous comment, I made a typo. Actually the link to "rings" is not correct. I made a typo as "real" instead of rings. :)

  • i want to know how to write a printer driver

Page 1 of 1 (9 items)