我正在寻找如何从主机控制器驱动程序初始化级别模拟USB键盘上的拔出和插回的方法?
我有一个使用PS2键盘的产品。由于PS2键盘不再可用,因此我们尝试切换到USB键盘。
我们拥有的系统使用Windows CE 5.0创建嵌入式应用程序。请多多包涵:)
系统启动到MS DOS,然后加载Windows CE。
在DOS中,USB键盘可以正常工作,只有1个例外。 当系统使用PS2键盘引导时,Num Lock指示灯点亮。使用USB键盘引导系统时,指示灯不亮。
Windows CE启动时,系统看不到键盘。用户必须拔下插头,然后重新插入才能激活它。从那里,键盘可以正常运行。这样驱动程序/硬件可以一起工作吗?
Windows CE具有2个活动的USB Host驱动程序。 OHCI USB驱动程序和EHCI usb驱动程序都分别枚举了HCD1:和HCD2:。
我正在尝试修改驱动程序初始化代码,以模拟拔下键盘然后再插回去的键盘,以便它可以继续正常运行。
驱动程序直接控制主机控制器硬件,因此我可以访问主机控制器寄存器。
我尝试过:
1. Setting the Power off for each root hub port, then turning them back on.
2. Cycling through and doing a Reset and Enable on each root hub port.
3. Cycling through and Disabling each root hub port then delay then Reset and Enable each root hub port.
*** NONE OF THESE FIX THE ISSUE ***
*一份以上的信息* 如果我手动启动Windows CE,那就是 引导至C提示符 输入LOADWINDOWS CE
The keyboard does function when CE Loads
Typing manually at the c prompt seems to activate the keyboard in dos
当我通过autoexec.bat调用LOADWINDOWS时,会出现问题。 系统启动,然后调用load命令 但键盘未激活... IE NUM LOCK未激活 点亮。
Does anyone have an idea how to simulate the unplug / plug at the Host Controller driver level???
The Host Controller hardware is reset at the start of the Host Controller driver initialization.
I cant reset the Keyboard as a device because it is not enumerated by Windows.
KNK53