The prototype phase is nearly complete. Rejiggering things so the buttons are just read instead of generating interrupts worked with minimal effort. I was able to get the code running, almost completely bug-free, on the hardware this weekend. The board, buttons and LCD are still terribly jury-rigged, but things are generally looking good.
The one snag is that the code doesn't work quite the same way on the board as it does in the test run. I'm not sure if my test is incorrect (most likely scenario), or the code actually runs differently on the 328, but in a situation where there are multiple timers saved, deleting the first one then resetting the processor causes the program to claim there are no timers available. Testing for this exact scenario works perfectly, with no errors.
Of course, one of the things the tests don't do very well is test what happens when multiple operations are strung together, so it may be that I'm running into bad EEPROM state after adding and deleting timers -- the tests are all very precisely focused, and reset "EEPROM" each time. I may have to add a couple more larger-scale tests.
However, this one problem aside, it's pretty cool to see code that has only existed as a series of tests for many sporadically-active months actually work the way it's supposed to (mostly) on the hardware.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.