     return 3000000 / (unsigned long)bpm;
   }
 
+  float slew_hz(uint8_t slew_rate)
+  {
+    if(slew_rate)
+    {
+      return (float)(17 - slew_rate) / 4.0;
+    }
+    else
+    {
+      return 65536.0;
+    }
+  }
+
   void display_slew_rate(int16_t x, int16_t y, uint8_t rate, DUINO_SSD1306::SSD1306Color color)
   {
     display->draw_vline(x + rate - 1, y, 5, color);

              {
                params.vals.slew_rate = 16;
              }
              seq_values.slew_rate = params.vals.slew_rate;
              display->fill_rect(60, 13, 16, 5, DUINO_SSD1306::White);
              display_slew_rate(60, 13, params.vals.slew_rate, DUINO_SSD1306::Black);
              break;

    // TODO: attach GT3 to hardware clock isr that sets clock to EXT
    gt_attach_interrupt(GT3, clock_isr, CHANGE);
    gt_attach_interrupt(GT4, reset_isr, RISING);
  }

  virtual void loop()
