function updateTempo(new_tempo){
  if (new_tempo != tempo){
    tempo = new_tempo
    rate = 60000/tempo
    $("#tempo-scroll").val(tempo)
    $("#tempo-display").html(tempo);
  }
  toggleTempoButton();
}
// New tempo received, update if changed
New tempo received, update if changed
New tempo received update if changed
function updateTempo(new_tempo){
  if (new_tempo != tempo){
    tempo = new_tempo
    rate = 60000/tempo
    $("#tempo-scroll").val(tempo)
    $("#tempo-display").html(tempo);
  }
  toggleTempoButton();
}
function updateTempo ( new_tempo ) { if ( new_tempo != tempo ) { tempo = new_tempo rate = 60000 / tempo $ ( "#tempo-scroll" ) . val ( tempo ) $ ( "#tempo-display" ) . html ( tempo ) ; } toggleTempoButton ( ) ; }
New tempo received, update if changed
New tempo received update if changed