Alarm Code

The alarm code is available in both Arduino and CircuitPython version. They both work in the same general way, which is:

  1. Wait for a button to be pressed.
  2. Provide a countdown timer with the NeoPixels. (the diary should be placed on Circuit Playground during countdown)
  3. Read and store the value of the light sensor.
  4. Loop forever reading the light sensor value.
  5. If value exceeds the stored value from step 3, sound the alarm.
This guide was first published on Oct 11, 2016. It was last updated on Oct 11, 2016. This page (Alarm Code) was last updated on Dec 03, 2019.