Según esta página hay 3 maneras
  Cita:  http://www.rgagnon.com/javadetails/java-0001.html 
Emit a beep
There are three ways to emit a beep in Java. 
Use an AU audio file
For Java, AU files need to be created at a sample rate of 8000. Any sample rate beyound that will not work. See also this How-to.  
Print the ASCII Bell character to the console public class testBeep {
  public static main(String args[]) {
     // ASCII bell
     System.out.print("\0007");
     System.out.flush();
     }
  }    
Starting with JDK 1.1, use the beep method in the Toolkit import java.awt.*;
public class beep {
  public static void main(String args[]) {
     Toolkit.getDefaultToolkit().beep();     
     }
  }