Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Azerty: add Oem10 for '<'/'>' key (US '\'/'|') between left shift and 'W'/'Z'. #41

Closed
wants to merge 3 commits into from

Conversation

CHiPs44
Copy link
Contributor

@CHiPs44 CHiPs44 commented Oct 28, 2023

To resolve Neotron-Compute/Neotron-Desktop-BIOS#14, I added Oem10 for Azerty '<'/'>' key (US ''/'|') between left shift and 'W'/'Z'.

@CHiPs44 CHiPs44 changed the title Chips44 changes Azerty: add Oem10 for '<'/'>' key (US ''/'|') between left shift and 'W'/'Z'. Oct 28, 2023
@CHiPs44 CHiPs44 changed the title Azerty: add Oem10 for '<'/'>' key (US ''/'|') between left shift and 'W'/'Z'. Azerty: add Oem10 for '<'/'>' key (US '\'/'|') between left shift and 'W'/'Z'. Oct 28, 2023
@CHiPs44
Copy link
Contributor Author

CHiPs44 commented Oct 28, 2023

NB: I didn't remove the KeyCode::LShift => DecodedKey::Unicode('<'), line that looks like a wrongly or unfinished attempt at handling this.

@CHiPs44 CHiPs44 marked this pull request as draft October 28, 2023 14:19
@CHiPs44
Copy link
Contributor Author

CHiPs44 commented Oct 28, 2023

Changed to draft!

  • ù/% key shows as x/X (between M and Return in AZERTY)
  • =/+/} key shows as x/X (between ) and Backspace)

Update to this PR coming soon, hunt to map USB HID to PS/2 should be simpler, I hope ;-)

@thejpster
Copy link
Member

thejpster commented Oct 28, 2023

Do you have an ISO or ANSI keyboard? I thought I'd covered all 105 (or 104) keys already?!

Edit: Oem10 only exists on 106/109 key JIS keyboards so I don't think it makes sense to decode it for an Azerty layout. I'd want to see pictures of the keyboard in question if you really think that is the case.

@CHiPs44
Copy link
Contributor Author

CHiPs44 commented Oct 28, 2023

Well, I have a Lenovo laptop with an internal USB-like AZERTY keyboard and I try to have a functional AZERTY keyboard with Neotron-Desktop-BIOS, so it seems I made a boo-boo...

It looks like all USB AZERTY keyboards I know are ISO like, not ANSI. I have another (wired) one near me and layout is the same as my laptop.

I'm going to try to sort out this mess I created...

@CHiPs44
Copy link
Contributor Author

CHiPs44 commented Oct 30, 2023

I think I am done with bumping my head against walls!

Problem was SDL2 never returns NonUsHash (see https://github.com/libsdl-org/SDL/blob/main/include/SDL3/SDL_scancode.h#L116), but always Backslash, regardless of ISO or ANSI keyboard, so mapping against NonUsHash for Oem7 could not match in Neotron-Desktop-BIOS! I just mapped Backslash to Oem7 instead, and that seems to work fine now.

@CHiPs44 CHiPs44 closed this Oct 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Azerty keyboard swaps A and Q and so on, many others return X or nothing
2 participants