       :reference-z z
       :start-time (jvm-time-ms)
       :init-auto-shutter (core getAutoShutter)
-      :init-exposure (core getExposure)
+      :init-exposure exposure
+      :exposures {(core getCameraDevice) exposure}
       :default-z-drive default-z-drive
       :default-xy-stage default-xy-stage
       :init-z-position z

  (let [default-z-drive (core getFocusDevice)
        default-xy-stage (core getXYStageDevice)
        z (get-z-stage-position default-z-drive)
        xy (get-xy-stage-position default-xy-stage)]
    (swap! (.state this) assoc
      :pause false
      :stop false


;; hardware control

(defn set-exposure [camera exp]
  (when (not= exp (get-in @state [camera :exposures]))
    (device-best-effort (core setExposure exp))
    (swap! state assoc-in [camera :exposures] exp)))

(defn wait-for-device [dev]
  (when-not (empty? dev)
    (try
