What a structure has keyboard layout?

Started by MIRKOSOFT, August 16, 2010, 04:25 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

MIRKOSOFT

Hi!


I want to create my own C128 keyboard layout.
This is the solution:
Vector - Key
-----------------
830-831/$033E-$033F Unshifted
832-833/$0340-$0341 SHIFT
834-835/$0342-$0343 Commodore
836-837/$0344-$0345 CONTROL
838-839/$0346-$0347 ALT (same as unshifted)
840-841/$0348-$0349 CAPS LOCK

Address: International - National
-------------------------------------------
64128/$FA80 - 64809/$FD29 Unshifted
64217/$FAD9 - 64898/$FD82 SHIFT
64306/$FB32 - 64987/$FDDB Commodore
64395/$FB8B - 64395/$FB8B CONTROL
64128/$FA80 - 64809/$FD29 ALT (same as unshifted)
64484/$FBE4 - 64809/$FD29 CAPS LOCK (in case of ASCII/DIN same as unshifted)



But really don't know structure of layout.
Also German keyboard has ´ and ` which waits on some keys and when found match displays e.g. á...
So, can anybody explain to me this?


Many many thanks for every help.


Miro
MIRKOSOFT of megabytes

Commodore 64 was great, Commodore 128 is bigger, better, faster and more!!!

http://www.mirkosoft.sk

Hydrophilic

I don't know about special features of German C128, but I do know about layout for each "shift mode" (normal / Shift / Commodore / Control / Alternate / Caps Lock).  These are usually called a "keyboard matrix".  There are 6 matrices... one matrix for each "mode".  Each matrix is referenced by a pointer (vector) in RAM like you say ($033E ... $0349).

Each matrix is the same as shown below (for another perspective, see my web page)...


$xx00 [INST/DEL] [Return] [CRSR =>] [F7]        [F1]          [F3]  [F5]  [CRSR \/]
$xx08 [#/3]      [W/w]    [A/a]     [$/4]       [Z/z]         [S/s] [E/e] [Left/Shift Lock]
$xx10 [%/5]      [R/r]    [D/d]     [&/6]       [C/c]         [F/f] [T/t] [X/x]
$xx18 ['/7]      [Y/y]    [G/g]     [(/8]       [B/b]         [H/h] [U/u] [V/v]
$xx20 [)/9]      [I/i]    [J/j]     [  0]       [M/m]         [K/k] [O/o] [N/n]
$xx28 [  +]      [P/p]    [L/l]     [  -]       [>/.]         [[/:] [  @] [</,]
$xx30 [  £]      [  *]    []/;]     [CLR/HOME]  [Right Shift] [  =] [  ^] [?//]
$xx38 [!/1]      [<- ]    [CTRL]    ["/2]       [Space]       [ C=] [Q/q] [Run/Stop]
$xx40 [Help]     [ 8 ]    [ 5 ]     [Tab]       [ 2 ]         [ 4 ] [ 7 ] [ 1 ]
$xx48 [Esc]      [ + ]    [ - ]     [Line Feed] [Enter]       [ 6 ] [ 9 ] [ 3 ]
$xx50 [Alt]      [ 0 ]    [ . ]     [/|\]       [\|/]         [<- ] [-> ] [No Scroll]

There are a few things to note.  First, the address is almost never a simple number like $FC00; for example the normal (no shift) first row is $FA80, and so second row (above labeled $xx08) is at address $FA88.  I hope that makes sense!

Second, the values in the table(s) are PETSCII codes.  So for exampe the first entry (INST/DEL) is PETSCII code $14 (DELete) in most tables (unshifted) but is PETSCII code $94 (INSerT) in the SHIFT table.  As another example, the first key in the second row is often "number 3" ($33), but could be pound/number/octothorpe (#) in SHIFT table ($23), or could be PETSCII-Red ($1C) in Control table.  I hope that makes sense!!!

Third, many entries use an "undefined" value of $FF.  For example pressing [CTRL] + [INST/DEL] will look-up a value of $FF.  Normally this should do nothing, but I have not examined the ROM enough to be certain...

I hope that helps!
I'm kupo for kupo nuts!