Yes, the modifier keys like shifts have their own scancodes. I got this with dumpkeys -f while on my PBP in Debian. But I'm not sure it's not just dumping some theoretical table in ROM instead of reading through the USB. The full 127 maps went over the 65k limit for a post so I only kept 3.
Looks the same when I do it on a Raspberrry Pi with a 101-key USB keyboard.
Seems like I've seen, for some keyboards, the scan codes the keyboard can output in a 2d array printed on a data sheet. It's rows and columns, when you push a key a switch there connects the row wires with the column wires at that point. It would probably be in a manufacturer's datasheet, thought I had one for this. The left and right shifts, ctrl, alt are different from each other. Software can tell which shift key you use. OK, shift is 42 and 54 here.
Looks the same when I do it on a Raspberrry Pi with a 101-key USB keyboard.
Code:
keymaps 0-127 (only 3 here)
keycode 1 = Escape Escape Escape
keycode 2 = one exclam one
keycode 3 = two at two
keycode 4 = three numbersign three
keycode 5 = four dollar four
keycode 6 = five percent five
keycode 7 = six asciicircum six
keycode 8 = seven ampersand seven
keycode 9 = eight asterisk eight
keycode 10 = nine parenleft nine
keycode 11 = zero parenright zero
keycode 12 = minus underscore minus
keycode 13 = equal plus equal
keycode 14 = Delete Delete Delete
keycode 15 = Tab Meta_Tab Tab
keycode 16 = +q +Q +q
keycode 17 = +w +W +w
keycode 18 = +e +E +e
keycode 19 = +r +R +r
keycode 20 = +t +T +t
keycode 21 = +y +Y +y
keycode 22 = +u +U +u
keycode 23 = +i +I +i
keycode 24 = +o +O +o
keycode 25 = +p +P +p
keycode 26 = bracketleft braceleft bracketleft
keycode 27 = bracketright braceright bracketright
keycode 28 = Return Return Return
keycode 29 = Control Control Control
keycode 30 = +a +A +a
keycode 31 = +s +S +s
keycode 32 = +d +D +d
keycode 33 = +f +F +f
keycode 34 = +g +G +g
keycode 35 = +h +H +h
keycode 36 = +j +J +j
keycode 37 = +k +K +k
keycode 38 = +l +L +l
keycode 39 = semicolon colon semicolon
keycode 40 = apostrophe quotedbl apostrophe
keycode 41 = grave asciitilde grave
keycode 42 = Shift Shift Shift
keycode 43 = backslash bar backslash
keycode 44 = +z +Z +z
keycode 45 = +x +X +x
keycode 46 = +c +C +c
keycode 47 = +v +V +v
keycode 48 = +b +B +b
keycode 49 = +n +N +n
keycode 50 = +m +M +m
keycode 51 = comma less comma
keycode 52 = period greater period
keycode 53 = slash question slash
keycode 54 = Shift Shift Shift
keycode 55 = KP_Multiply KP_Multiply Hex_C
keycode 56 = Alt Alt Alt
keycode 57 = space space space
keycode 58 = Caps_Lock Caps_Lock Caps_Lock
keycode 59 = F1 F13 Console_13
keycode 60 = F2 F14 Console_14
keycode 61 = F3 F15 Console_15
keycode 62 = F4 F16 Console_16
keycode 63 = F5 F17 Console_17
keycode 64 = F6 F18 Console_18
keycode 65 = F7 F19 Console_19
keycode 66 = F8 F20 Console_20
keycode 67 = F9 F21 Console_21
keycode 68 = F10 F22 Console_22
keycode 69 = Num_Lock Num_Lock Hex_A
keycode 70 = Scroll_Lock Show_Memory Show_Registers
keycode 71 = KP_7 KP_7 Hex_7
keycode 72 = KP_8 KP_8 Hex_8
keycode 73 = KP_9 KP_9 Hex_9
keycode 74 = KP_Subtract KP_Subtract Hex_D
keycode 75 = KP_4 KP_4 Hex_4
keycode 76 = KP_5 KP_5 Hex_5
keycode 77 = KP_6 KP_6 Hex_6
keycode 78 = KP_Add KP_Add Hex_E
keycode 79 = KP_1 KP_1 Hex_1
keycode 80 = KP_2 KP_2 Hex_2
keycode 81 = KP_3 KP_3 Hex_3
keycode 82 = KP_0 KP_0 Hex_0
keycode 83 = KP_Period KP_Period KP_Period
keycode 84 = Last_Console Last_Console Last_Console
keycode 85 = VoidSymbol VoidSymbol VoidSymbol
keycode 86 = less greater bar
keycode 87 = F11 F23 Console_23
keycode 88 = F12 F24 Console_24
keycode 89 = VoidSymbol VoidSymbol VoidSymbol
keycode 90 = VoidSymbol VoidSymbol VoidSymbol
keycode 91 = VoidSymbol VoidSymbol VoidSymbol
keycode 92 = VoidSymbol VoidSymbol VoidSymbol
keycode 93 = VoidSymbol VoidSymbol VoidSymbol
keycode 94 = VoidSymbol VoidSymbol VoidSymbol
keycode 95 = VoidSymbol VoidSymbol VoidSymbol
keycode 96 = KP_Enter KP_Enter Hex_F
keycode 97 = Control Control Control
keycode 98 = KP_Divide KP_Divide Hex_B
keycode 99 = VoidSymbol VoidSymbol Control_backslas
keycode 100 = Alt Alt Alt
keycode 101 = Break Break Break
keycode 102 = Find Find Find
keycode 103 = Up Up Up
keycode 104 = Prior Scroll_Backward Prior
keycode 105 = Left Left Left
keycode 106 = Right Right Right
keycode 107 = Select Select Select
keycode 108 = Down Down Down
keycode 109 = Next Scroll_Forward Next
keycode 110 = Insert Insert Insert
keycode 111 = Remove Remove Remove
keycode 112 = Macro Macro Macro
keycode 113 = F13 F13 F13
keycode 114 = F14 F14 F14
keycode 115 = Help Help Help
keycode 116 = Do Do Do
keycode 117 = F17 F17 F17
keycode 118 = KP_MinPlus KP_MinPlus KP_MinPlus
keycode 119 = Pause Pause Pause
keycode 120 = VoidSymbol VoidSymbol VoidSymbol
keycode 121 = KP_Period KP_Period KP_Period
keycode 122 = VoidSymbol VoidSymbol VoidSymbol
keycode 123 = VoidSymbol VoidSymbol VoidSymbol
keycode 124 = VoidSymbol VoidSymbol VoidSymbol
keycode 125 = Alt Alt Alt
keycode 126 = Alt Alt Alt
Seems like I've seen, for some keyboards, the scan codes the keyboard can output in a 2d array printed on a data sheet. It's rows and columns, when you push a key a switch there connects the row wires with the column wires at that point. It would probably be in a manufacturer's datasheet, thought I had one for this. The left and right shifts, ctrl, alt are different from each other. Software can tell which shift key you use. OK, shift is 42 and 54 here.