Debugging Complex Situations

I have been working my way through debugging the refactored code.

There have been countless bugs to resolve. But I am happy with the new code architecture. Bugs are easy to resolve now.

One bug seemed like an Engine bug where my exported var settings were erased. This kind of bug surfaced in the past as an issue and was apparently resolved. I would report it, but I am unable to set up a mini-project to repeat the bug.

I had a complex scene containing all the Parts with their exported var settings that kept being reset. So I resorted to replacing all the exported vars with concrete values set in each of the individual part class scripts.

Bus Circuit

By creating various circuits such as the above one I was able to find unusual bug scenarios that I hadn’t foreseen.

The busses have to act like bidirectional wires. This entailed naturally propagating values when connecting wires. And the loop back bus has introduced a stack-overflow error due to a feedback loop I guess.

Also, I needed to take into consideration what port affected a change to a bus since it may have been a single wire. Hard to explain all that here.

Funny bug: I displayed a backwards C in the 7-segment display. It can be a mind-bender when mapping the LED segments to values.

Making progress …

More Devlog entries

Most recent first