Skip to content

Conversation

@giuliof
Copy link
Contributor

@giuliof giuliof commented Jun 17, 2025

This way, the user's keyboard layout doesn't affect how actual keys are mapped inside the emulator.

@giuliof giuliof requested a review from giomba June 17, 2025 14:25
@giuliof
Copy link
Contributor Author

giuliof commented Jun 17, 2025

Obv, since the SANCO keyboard is not an ISO/ANSI compliant one, this PR would need some changes on CP/M-side keymap, i.e. SLF80037_US.TXT (rename it to .COM, github don't allow me to upload this file). But this is the same one used on the physical machine to have an usable layout. Original SLF file would produce a french(ish) keyboard layout.

@giuliof giuliof force-pushed the keyboard-with-scancodes branch from 44fff4b to e13dc5e Compare June 17, 2025 14:36
@giomba
Copy link
Collaborator

giomba commented Jun 19, 2025

I report here what we discussed on the phone.

  • since SDL2 allows us to handle different keyboard layouts using scancodes, we should use scancodes instead of keycodes
  • then, we should pass the ISO/ANSI-like scancodes from the user's keyboard, to the emulator logic, and to the emulator software
  • the Sanco's CP/M can already handle different keyboard layouts (using different SLF800* autoexec-like executable)
  • we can then modify the unofficial CP/M disk image in order to allow the user to select its preferred keyboard layout
  • we want to support the following keyboard layouts: US English (because it's widespread and well-known), IT (because me and other Italian contributors use it), and obviously FR (because this actually is a French computer)
    Linked CP/M issue: Modify SLF800* in order to support different keyboard layouts ceda-cpm#2

giuliof and others added 2 commits June 20, 2025 08:27
This way, the user's keyboard layout doesn't affect how actual keys are
mapped inside the emulator.
CARET key is unused in the current SLF800* map, so it can be useful to
function as the additional key in modern ISO keyboards.
For example, this key can be commonly found on contemporary French and
Italian keyboards.
@giomba giomba force-pushed the keyboard-with-scancodes branch from a33406d to b1e4e88 Compare June 20, 2025 06:27
@giomba
Copy link
Collaborator

giomba commented Jun 20, 2025

I added a commit on top of your in order to support the extra key in ISO keyboards, which is iseful for European layouts.

@giuliof giuliof merged commit 14844d7 into main Jun 21, 2025
1 check passed
@giuliof giuliof deleted the keyboard-with-scancodes branch June 21, 2025 16:28
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.

3 participants