Close

20230217b -- Keyboard Indicators

A project log for ROM Disassembly - AlphaSmart Pro

Wherein I disassemble the ROM from a vintage typewriter-thing

ziggurat29ziggurat29 02/22/2023 at 01:120 Comments

While whizzing through the code, I did notice an interesting 'set cursor position' call to set it at the end of the screen (at position 159, or 9Fh).  Once set, the character 0x0f is sent.  The datasheet for the LCD indicates that 0x0f is a solid block.

F3C6             loc_F3C6:
F3C6 13 A1 01 0A     brclr   byte_A1 1 leave_F3D4 ; 
F3CA C6 9F           ldab    #$9F            ; cursor at end of screen
F3CC BD F7 60        jsr     commonSetCursorPos_F760 ; common set cursor position (abs pos in B)
F3CF C6 0F           ldab    #$F             ; solid block char
F3D1 BD F6 74        jsr     sendLCDbyteB_F674 ; send byte in B to LCD (w/ctrl as per 0x5b)
F3D4             leave_F3D4:
F3D4 39              rts

 The user manual shows that a solid block in the last screen position is the Caps Lock indicator.  Since the code to put this char in this place is controlled by the state of byte_A1 (previously marked as a flag of sorts), I am concluding that this location is the Cap Lock flag.  Aside from understanding this local bit of code, cross-referencing that location to other places should give some more insight into keyboard handling.

There are apparently meant to be other keyboard status indicators as well, but I haven't located them yet.

Discussions