Split main sketch into several modules, for the different functions to be
performed by the microcontroller.  Each module signals back to the sketch via
callbacks, which may result in writing data out to a serial port or raising a
pin.