![]() |
Main Loop |
The main loop runs fast to improve responsiveness to the mauual switch, but the TIME system variable is used to control timing for actions which should be less frequent. At 8 MHz the TIME variable, a byte, increments at 2-second intervals At timed intervals the following actions occur: 1. For several seconds after power-up dial re-indexing is prevented since it is not necessary 2. Periodically an advertising message is displayed. 3. If the mode has changed, the fixed strings are immediately written to the display and the measurement display updated. 4. The manual switch is read every loop. 5. The sensor is read once every four seconds. 6. The measurement display is updated once every four seconds. |
![]() |