beep()

Syntax:

[void] sysinfo.beep(Int frequency, Int duration)

Description:

The beep method produces a beep tone in a specified frequency for a specified duration.

Argument:

Note: The maximum and minimum values for frequency are naturally device-specific. If the specified frequency is out of the device's supported range, the maximum frequency is applied.

Return value:

This method does not return a value.

Remarks:

To stop an infinitive beep, call the beep method again with any value that is different from 0.

Example code:

function beepAlert()
{
   // call the beep function with frequency 220Hz 
   // for the duration 2 seconds
   sysinfo.beep(220, 2000);
}