            [javax.swing JFrame JPanel JSlider])
   (:use [clojure.stacktrace]
         [overtone.util lib]
-        [overtone.music time]
         [overtone.lib event deps]
         [overtone.sc defaults core synth ugen buffer node]
         [overtone.studio.util])
   (:require [clojure.set :as set]
-            [overtone.util.log :as log]))
+            [overtone.util.log :as log]
+            [overtone.at-at :as at-at]))
 
 (defonce SCOPE-BUF-SIZE 4096)
 (defonce FPS 10)
 (defonce scopes* (ref {}))
-(defonce scope-pool* (agent (make-pool)))
+(defonce scope-pool (at-at/mk-pool))
 (defonce scopes-running?* (ref false))
 (defonce WIDTH 600)
 (defonce HEIGHT 400)


(defn scopes-stop
  []
  (dosync
   (stop-and-reset-pool! scope-pool*)
   (empty-scope-data)
   (ref-set scopes-running?* false)))

(defn- start-bus-synth
  [bus buf]

(defonce Y-PADDING 10)
(defonce scope-group* (ref 0))

(on-deps :studio-setup-completed ::create-scope-group #(dosync
                                                        (ref-set scope-group* (group :tail ROOT-GROUP))
                                                        (satisfy-deps :scope-group-created)))

(defn- update-scope-data [s]
  (let [{:keys [buf size width height panel y-arrays x-array panel]} s
        frames    (buffer-data buf)
        step      (int (/ (buffer-size buf) width))
        y-scale   (- height (* 2 Y-PADDING))
        [y-a y-b] @y-arrays]
    (if-not (empty? frames)
      (dotimes [x width]
