                                (mtr-ctrl x)))]
                (close! p))))
     (loop [time-sm time-sm]
-      (recur (trans-sm! timer (read! light-ain))))))
+      (recur (trans-sm! timer (safe-read! light-ain))))))
 
 
 (defn play []

    (println "initialized successfully")
    (doseq [_ (range)]
      (try
        (println "Reading light" (read! a1))
        (println "Reading temp" (read! a2))
        (println "Reading btn" (read! g))
        (println "")
        (catch Exception e



(defn time-sm [state day-fn! night-fn!]
  (let [dusk 0.12
        dawn 0.20]
    {:state state
     :trans
        {:day
