extracted more immutable calculations
changed naming of count, countdown and countdown-store
changed '-state' to '-on?' for the device-state booleans