7 ms·
Printing a string is luxury! When I was working on a Linux port to the Treo 650 ages ago, I had a single bit of output: an LED that I could turn on or off at ce
by mmastrac 12y ago
Printing a string is luxury! When I was working on a Linux port to the Treo 650 ages ago, I had a single bit of output: an LED that I could turn on or off at certain parts of the boot sequence. That was good enough to get me to the point where the LCD could be initialized and I could do proper screen logging.
I've done this for a handful of other projects as well. My first step is always locating a processor GPIO that controls something obvious (camera flash, status LED, etc) that I can use to figure out where I am in the boot process.
- crb3 12y agoOne bit/pin can be more than enough if you can code some state behind it. On one embedded MCU job, I ended up with just one port pin free. I tied it to a piezo-oscillator and played short Morse strings through it; that was my printf. (It helps that I'm a ham, so I could head-copy those messages.) Once I turned it over to production use, the techs found the difference in overall sound between "OK" and an error message useful enough that they kept it jumper-enabled. They did put tape over the oscillator's opening to cut down the amplitude, though.
- themodelplumber 12y ago"// If the camera flash fires five times in a row, the string was successfully changed"