Private Const METRONOMO As String = "|------||------|"
Public Sub Main()
Dim t, d, bpm As Short
Dim mtr As String
bpm = 90
t = 1
Print
Do
d += Sgn(Sin(2 * Pi(1) * (t / 32)))
mtr = METRONOMO
Mid(mtr, d, 1) = "\e[31m\e[1mO\e[0m"
Write #File.Out, "\r" & mtr & " = " & CStr(bpm) & " bpm "
Flush #File.Out
If t == 31 Then t = 1
Wait (60 / bpm) / 16
Inc t
Loop
End