caorr
驱动牛犊
驱动牛犊
  • 注册日期2005-03-24
  • 最后登录2007-10-24
  • 粉丝1
  • 关注1
  • 积分131分
  • 威望19点
  • 贡献值0点
  • 好评度6点
  • 原创分0分
  • 专家分0分
阅读:2019回复:6

请教,为什么编好的驱动没法安装?是否inf文件的错?

楼主#
更多 发布于:2005-03-25 20:15
我用DriverWorks编了一个PCI2040的驱动(实质的关于数据的操作什么都没有做,只是生成了一个框架),编译后生成了.inf文件和.sys文件,可是安装的时候win2000却提示“无法为该设备找到合适的驱动程序”,请问这到底是怎么回事啊,是不是仅仅生成个框架是没法安装的,还需要作些其他的什么工作?

我是初学者,还请不吝赐教啊!

另外,我用DS中的EzDrvInstaller动态加载了一次,发现没有问题,可以用DriverMoniter看到啊。
请问用EzDrvInstaller加载和通过硬件向导安装,这两者有什么区别吗?

.inf文件内容如下:
;; PCITest.inf

;; ********* PLEASE READ ***********
;; The wizard cannot create exact INF files for all buses and device types.
;; You may have to make changes to this file in order to get your device to
;; install. In particular, hardware IDs and logical configurations require
;; intervention.
;;
;; The Windows DDK documentation contains an excellent INF reference.

;--------- Version Section ---------------------------------------------------

[Version]
Signature=\"$Windows 95$\"
Provider=%ProviderName%

; If device fits one of the standard classes, use the name and GUID here,
; otherwise create your own device class and GUID as this example shows.

Class=NewDeviceClass
ClassGUID={ff646f80-8def-11d2-9449-00105a075f6b}

;--------- SourceDiskNames and SourceDiskFiles Section -----------------------

; These sections identify source disks and files for installation. They are
; shown here as an example, but commented out.

;[SourceDisksNames]
;1 = \"Install Disk\",Disk1,,

;[SourceDisksFiles]
;PCITest.sys = 1,,

;--------- ClassInstall/ClassInstall32 Section -------------------------------

; Not necessary if using a standard class

; 9X Style
[ClassInstall]
Addreg=Class_AddReg

; NT Style
[ClassInstall32]
Addreg=Class_AddReg

[Class_AddReg]
HKR,,,,%DeviceClassName%
HKR,,Icon,,\"-18\"

;--------- DestinationDirs Section -------------------------------------------

[DestinationDirs]
PCITest_Files_Driver = 10,System32\\Drivers

;--------- Manufacturer and Models Sections ----------------------------------

[Manufacturer]
%MfgName%=Mfg0

[Mfg0]

; PCI hardware IDs use the form
; PCI\\VEN_aaaa&DEV_bbbb&SUBSYS_cccccccc&REV_dd
;
%DeviceDesc%=PCITest_DDI, PCI\\VEN_104C&DEV_AC60&SUBSYS_00000000&REV_00

;---------- DDInstall Sections -----------------------------------------------
; --------- Windows 9X -----------------

; Experimentation has shown that DDInstall root names greater than 19 characters
; cause problems in Windows 98

[PCITest_DDI]
CopyFiles=PCITest_Files_Driver
AddReg=PCITest_9X_AddReg

[PCITest_9X_AddReg]
HKR,,DevLoader,,*ntkern
HKR,,NTMPDriver,,PCITest.sys
HKR, \"Parameters\", \"BreakOnEntry\", 0x00010001, 0

; --------- Windows NT -----------------

[PCITest_DDI.NT]
CopyFiles=PCITest_Files_Driver
AddReg=PCITest_NT_AddReg

[PCITest_DDI.NT.Services]
Addservice = PCITest, 0x00000002, PCITest_AddService

[PCITest_AddService]
DisplayName = %SvcDesc%
ServiceType = 1 ; SERVICE_KERNEL_DRIVER
StartType = 3 ; SERVICE_DEMAND_START
ErrorControl = 1 ; SERVICE_ERROR_NORMAL
ServiceBinary = %10%\\System32\\Drivers\\PCITest.sys

[PCITest_NT_AddReg]
HKLM, \"System\\CurrentControlSet\\Services\\PCITest\\Parameters\",\\
\"BreakOnEntry\", 0x00010001, 0


; --------- Files (common) -------------

[PCITest_Files_Driver]
PCITest.sys

;--------- Strings Section ---------------------------------------------------

[Strings]
ProviderName=\"Your Company Name here\"
MfgName=\"Name of HW Manufacturer here\"
DeviceDesc=\"Description of Device here\"
DeviceClassName=\"Description of PCITest Device class here\"
SvcDesc=\"Description of PCITest NT service here\"

以下是sys文件
附件名称/大小 下载次数 最后更新
2005-03-25_PCITest.sys (126KB)  7
AllenZh
驱动老牛
驱动老牛
  • 注册日期2001-08-19
  • 最后登录2015-11-27
  • 粉丝19
  • 关注10
  • 积分1316分
  • 威望2387点
  • 贡献值7点
  • 好评度321点
  • 原创分0分
  • 专家分0分
沙发#
发布于:2005-04-03 15:07
使用windows的添加新硬件能找到设备驱动吗?如果能看看是不是IRP_MJ_PNP中的IRP_MN_START_DEVICE没有处理好。
1,承接Windows下驱动/应用开发 2,本人原创虚拟鼠标/键盘,触摸屏,虚拟显卡,Mirror驱动,XP无盘的SCSI虚拟磁盘驱动等 3,windows下有尝技术服务(包括BUG调试,员工培训等) 欢迎深圳和海外企业联系.msn:mfczmh@sina.com
terran_lang
驱动牛犊
驱动牛犊
  • 注册日期2004-07-02
  • 最后登录2016-01-09
  • 粉丝0
  • 关注0
  • 积分142分
  • 威望15点
  • 贡献值0点
  • 好评度14点
  • 原创分0分
  • 专家分0分
板凳#
发布于:2005-04-12 12:38
我和楼主的问题一样呀,我用driverworks做pci9054的驱动,也是生成了一个框架,硬件的id号都填对了呀,可是怎么也装不上,错误跟楼主的一样,望那位大哥指教。
athlon228
驱动牛犊
驱动牛犊
  • 注册日期2007-03-18
  • 最后登录2007-06-12
  • 粉丝0
  • 关注0
  • 积分90分
  • 威望10点
  • 贡献值0点
  • 好评度9点
  • 原创分0分
  • 专家分0分
地板#
发布于:2007-06-12 10:47
我和楼主的问题一样呀,我用driverworks做USB用于输入输出的的驱动,也是生成了一个框架,硬件的id号都填对了呀,可是怎么也装不上,错误跟楼主的一样,望那位大哥指教。
lgp_my
驱动牛犊
驱动牛犊
  • 注册日期2005-09-21
  • 最后登录2010-01-19
  • 粉丝0
  • 关注0
  • 积分21分
  • 威望13点
  • 贡献值0点
  • 好评度2点
  • 原创分0分
  • 专家分0分
地下室#
发布于:2007-07-01 12:03
唉,我也出现同样的问题,真希望哪位大哥帮帮忙。
crffly
驱动牛犊
驱动牛犊
  • 注册日期2007-07-24
  • 最后登录2007-11-22
  • 粉丝0
  • 关注0
  • 积分20分
  • 威望3点
  • 贡献值0点
  • 好评度2点
  • 原创分0分
  • 专家分0分
5楼#
发布于:2007-07-26 23:31
我写了一个NDIS,也是这样的。
zhaozy1982
驱动牛犊
驱动牛犊
  • 注册日期2005-03-27
  • 最后登录2010-01-20
  • 粉丝0
  • 关注0
  • 积分9分
  • 威望60点
  • 贡献值0点
  • 好评度55点
  • 原创分0分
  • 专家分0分
6楼#
发布于:2007-08-10 19:56
我不知道你和我碰到的是不是同一个问题,不过我之前写完了INF也装不上去,结果发现是在“Choose your search and installation options”里面,选了include this location in the search。

应该选择最下面的那个选项“Don't search. I will choose the driver to install”,在下一步的对话框中再选择你的INF路径
游客

返回顶部