beep
—
emit tone from console speaker
beep |
[-v ] [-d
⟨device⟩] [-p
⟨pitch⟩]
[⟨duration⟩] |
beep
causes a tone to be emitted from the console
speaker.
The following options are available:
-V
- Display version of
beep
.
-v
- Verbose mode. Print details of the tone to
stderr
before playing.
-d
- Specify the device to use. The default is usually
/dev/speaker.
-h
- Display usage message.
-p
- Specify the pitch of the tone in Hz. The default is usually 800Hz.
The optional operand can be used to specify the duration of the
tone in centi-seconds. The default is usually 5cs.
/dev/speaker default console speaker device
beep
prints diagnostic messages to
stderr
. In addition beep
may
exit with with the following codes:
- EX_OK
- All was aparently successful.
- EX_USAGE
- The flags or operands specified were incorrect or a parameter was out of
range.
- EX_OSFILE
- The speaker device specified could not be opened. This may be because of a
permission problem, the device not being configured in the running kernel
or some other such error.
- EX_IOERR
- A problem occured while trying to play the tone or close the speaker
device afterwards.
beep
was developed under FreeBSD
4.6.
beep
was written by Andrew
Stevenson ⟨andrew@ugh.net.au⟩.