logoalt Hacker News

wojciii • yesterday at 7:07 AM • 5 replies • view on HN

If you have no logging and no debugger .. you should run away. Fuck debugging something complex by blinking a led. This is a waste of your time.

I'm sure you can make Claude help you with this .. but still..logs are important. So is a good debugger and software support for it. It saves so much time in the end.


Replies

mrheosuper • today at 3:11 AM

>If you have no logging and no debugger .. you should run away.

That's a wrong mindset in embedded. In this field, your debugging toolbox should not stop at debugger(gdb) or logging(UART). It must include at least: LA/DMM/PSU/O-Scope.

aforwardslash • yesterday at 4:40 PM

Having done basically that a couple of weeks ago (with a scope to verify timing signals), its actually pretty common, specially when you are implementing protocols with hard timing requirements.

And in my case, I was actually troubleshooting the code that makes leds blink, with a bit-banged implementation on a deterministic processor.

voakbasda • yesterday at 4:34 PM

Have you never experienced a bug that goes away from adding/removing a logging statement?

I recently restructure a logging module in a client’s project, and the resulting performance gains exposed all sort of race conditions.

Sometime all you get is an LED.

➕ show 1 reply
unrented7977 • yesterday at 3:40 PM

> This is a waste of your time.

This is the reality of highly constrained embedded systems. If you don't like that, I'd suggest moving to web dev where you have state of the art debugging.

readthenotes1 • yesterday at 4:05 PM

That's kind of like saying "don't be a farmer--you have to go outside".