学习编写 Windows 驱动程序
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/566426/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
learning to program Windows drivers
提问by Samuel
what would you recommend for a resource on learning to program drivers. i am working my way through Programming the Microsoft Windows Driver Model, but i was wondering if any of the examples are vista compatible. additionally, the book is more of a reference of the kernel functions so far. is their a resource that will take the beginner by the hand in making a more intermidiate wdm driver? i have done the basic "hello world" driver.
对于学习编程驱动程序的资源,您有什么建议。我正在通过 Microsoft Windows 驱动程序模型编程,但我想知道是否有任何示例与 vista 兼容。此外,本书更多是迄今为止内核函数的参考。他们是一种可以帮助初学者制作更中级 wdm 驱动程序的资源吗?我已经完成了基本的“hello world”驱动程序。
thanks
谢谢
采纳答案by Matt Davison
I would strongly recommend starting with KMDF. It is dramatically easier to learn than WDM but still requires you to learn the fundamentals of windows kernel development. Also just hanging out in the OsrOnlinefourm is a great way to learn.
我强烈建议从KMDF开始。它比 WDM 更容易学习,但仍然需要您学习 Windows 内核开发的基础知识。另外,在OsrOnline 上闲逛也是一种很好的学习方式。
回答by Mark
Not really answering your question, but as you learn to write drivers, don't forget to regularly check out Doron Holan's blog. His job is to improve the driver development process, and he discusses a lot of common pitfalls and subtleties of driver programming.
不是真正回答您的问题,但是当您学习编写驱动程序时,不要忘记定期查看Doron Holan 的博客。他的工作是改进驱动程序开发过程,他讨论了驱动程序编程的许多常见陷阱和微妙之处。
回答by Jelmoli
I'm going through the book "Developing Drivers with the Windows Driver Foundation" - which seems to present things in a logical order for new developers, while going well into real world solutions with tips on how to handle them. From Amazon
我正在阅读“使用 Windows 驱动程序基础开发驱动程序”一书——这本书似乎为新开发人员按逻辑顺序呈现事物,同时深入介绍现实世界的解决方案,并提供有关如何处理它们的技巧。 来自亚马逊
回答by Don Johe
I actually searched a while for the example code that is mentioned in the WDK documentation (but not linked there). As I found it, it actually became a great help. It's not even hidden, it it just below the "src"-directory that I mistook for being the src of Windows DDK. (Just in case someone else is searching for these examples.)
我实际上搜索了 WDK 文档中提到的示例代码(但没有链接到那里)。当我发现它时,它实际上成为了一个很大的帮助。它甚至没有隐藏,它就在我误认为是 Windows DDK 的 src 的“src”目录下。(以防万一其他人正在搜索这些示例。)
Well that and examples from rootkit.com. It's often the sneaky ones that understand such matters best.
好吧,还有来自rootkit.com 的示例。通常是那些鬼鬼祟祟的人最了解这些事情。
Update: I found this tutorialreferenced somewhere on stackoverflow. It is a nice slow and well written introduction. (Obviously I am searching and learning myself currently, daily improvements are intentional.)
更新:我在 stackoverflow 上的某个地方发现了这个教程。这是一个很好的缓慢而写得很好的介绍。(显然我目前正在搜索和学习自己,每天的改进都是有意的。)
And it probably is useful to link to a question of minewhere the topic of "communicating with your driver" is discussed.
链接到我的一个问题,其中讨论了“与您的驱动程序交流”的主题,这可能很有用。
回答by ChrisW
I learned from the help file that came with the DDK, and (importantly) from the sample drivers (source code) which came with the DDK: look for sample drivers of the same type of driver (e.g. network driver, video driver, whatever) as the kind you're interested in.
我从 DDK 附带的帮助文件以及(重要的是)从 DDK 附带的示例驱动程序(源代码)中了解到:寻找相同类型驱动程序的示例驱动程序(例如网络驱动程序、视频驱动程序,等等)作为你感兴趣的那种。