http://www.johnath.com/beep/
#!/bin/bash
# Frequenzen für Töne:
C=261.63; Cis=277.18; Des=$Cis; D=293.66; Dis=311.13; Es=$Dis;
E=329.63; F=349.23; Fis=369.99; Ges=$Fis; G=392.00;
Gis=415.30; As=$Gis; A=440.00; Ais=466.16; B=$Ais; H=493.88;
# Achtung: Schleife benötigt einiges an CPU Zeit...
for (( i=2; i<3; i++ )); do
eval C$i=$(echo $C*2^\($i-1\) | bc);
eval Cis$i=$(echo $Cis*2^\($i-1\) | bc);
eval Des$i=\$Cis$i;
eval D$i=$(echo $D*2^\($i-1\) | bc);
eval Dis$i=$(echo $Dis*2^\($i-1\) | bc);
eval Es$i=\$Dis$i;
eval E$i=$(echo $E*2^\($i-1\) | bc);
eval F$i=$(echo $F*2^\($i-1\) | bc);
eval Fis$i=$(echo $Fis*2^\($i-1\) | bc);
eval Ges$i=\$Fis$i;
eval G$i=$(echo $G*2^\($i-1\) | bc);
eval Gis$i=$(echo $Gis*2^\($i-1\) | bc);
eval As$i=\$Gis$i;
eval A$i=$(echo $A*2^\($i-1\) | bc);
eval Ais$i=$(echo $Ais*2^\($i-1\) | bc);
eval B$i=\$Ais$i;
eval H$i=$(echo $H*2^\($i-1\) | bc);
done
beep \
-f $D \
-n -f $G -l 100 \
-n -f $A -l 100 \
-n -f $H \
-n -f $D2 \
-n -f $H \
-n -f $A \
-n -f $G -l 500