And… here we are

This week what we have all been fearing has happened to me: GitHub Copilot generated code for me which seems to meet all the requirements but which I don’t understand very much at all.

To date GitHub Copilot for me has just been mostly a useful auto-complete tool and it hasn’t given me any code which I didn’t understand. But with this code (to control two different hardware timers/counters on my Arduino) I don’t really understand it at all. I have passing familiarity with some of the registers used because I saw them named in the datasheet (which I have only skimmed so far) but basically I don’t understand how this works.

It is tempting to ignore the fact that I don’t fully understand and move on, but there’s a part of me which wants to return to the datasheet so I can understand what every assignment GitHub Copilot offered actually does and what every value it calculated implies. Is that the best use of my time?