With the flash blank, everything had to be written from scratch: startup code, interrupt vectors, display driver, encoder handling, menu, timers. The toolchain is Toshiba's 2009-era TLCS-870/C1 IDE with the cc870c C compiler — C89, 2 KB of RAM, no debugger, no UART free for printf (the UART pins are the programming interface).
The only output device is the 4-digit 7-segment display. So the display
became the debug console. display_hex16() shows any 16-bit value as hex
(the segment font grew letters A–F), and a compile-time diagnostic mode
turns the encoder into a channel selector: millisecond counter, raw timer
capture register, interrupt counter, register readbacks. It sounds
primitive. It found every bug in this project.
The board mapping came first — tracing which MCU pins drive the display digit selects
wichers
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.