ch55xduino icon indicating copy to clipboard operation
ch55xduino copied to clipboard

Keyboard with boot protocol enabled

Open OmerFS opened this issue 2 years ago • 8 comments

Hello,

ch55xduino/ch55x/libraries/Generic_Examples/examples/05.USB/HidKeyboard compiled to ch552 mcu HID working fine on windows and linux. it is not working on bios

How to made work on bios screen?

(by the way, it is working on new model computers bioses but not working on a bit old bioses like Asus N550JV)

Thanks in advance

OmerFS avatar Oct 26 '23 17:10 OmerFS

I can confirm the emulated keyboard does not work on the boot screen of a Mid-2014 macbook pro while a real Dell keyboard does work. So there must be some implementation problem in the boot protocol. I will take a look soon.

DeqingSun avatar Nov 11 '23 21:11 DeqingSun

For progress record:

There is some progress in https://github.com/DeqingSun/ch55xduino/blob/ec3b8958397dac77035ab4ae40cd06331b51320d/ch55xduino/ch55x/libraries/Generic_Examples/examples/05.USB/HidKeyboard/src/userUsbHidKeyboard/USBhandler.c that deal with HID report access on EP0. More work need to be done to do get EP0 IN work properly.

DeqingSun avatar Nov 12 '23 12:11 DeqingSun

@OmerFS I seems get it working on my Mac in boot screen. Let me know if this example work for you.

https://github.com/DeqingSun/ch55xduino/tree/19f3f8c1b5a86ab0c537f0cf059bbe71e6849bd1/ch55xduino/ch55x/libraries/Generic_Examples/examples/05.USB/HidKeyboard

DeqingSun avatar Nov 14 '23 04:11 DeqingSun

Updated in https://github.com/DeqingSun/ch55xduino/commit/b0067f063695398002138cd4994aa96d9a7055df No response from @OmerFS, consider fixed.

DeqingSun avatar Mar 29 '24 14:03 DeqingSun

Hello i am sorry for not returning in time i saw your post in my mail today i have variety of old notebooks i will test and post the results thank you so much.

OmerFS avatar Mar 30 '24 17:03 OmerFS

Hello i tested new update on 3 laptops ; Dell Latitude E6330 Fujitsu Lifebook LH532 Asus N550JV

it works on windows but it didn't work in bios screen i also changed keyboardProtocol varible but results were same;didn't work (//0 is boot protocol, 1 is report protocol __xdata uint8_t keyboardProtocol = 1; from 1 to 0 but it didnt work again) my humble opinion i suggest you to check stm32 libraries and HID-project library. i was able to make it with stm32 mcu using cubeide generated code for arduino(pro micro) i used HID-project both of them worked.

OmerFS avatar Apr 03 '24 18:04 OmerFS

Thanks for sharing. I suppose there must be some USB request that I did not handle properly.

I'll check it this weekend with a real windows machine. I suppose the bios in windows and mac still handle the USB differently.

DeqingSun avatar Apr 03 '24 19:04 DeqingSun

I've tested it on Lenovo Thinkpad t410 2518-f4u 2010 Acer Aspire 4930 JAL90 2008 They both work in Bios. I'll take a look at the other projects.

I tried to use

      Keyboard_press(KEY_DOWN_ARROW);
      delay(100); //a quick capslock press is not recognized on mac
      Keyboard_release(KEY_DOWN_ARROW);

And the cursor can be moved in BIOS

DeqingSun avatar Apr 04 '24 04:04 DeqingSun