1.. SPDX-License-Identifier: GPL-2.0+ 2.. Copyright 2022, Heinrich Schuchardt <xypron.glpk@gmx.de> 3 4sound command 5============= 6 7Synopsis 8-------- 9 10:: 11 12 sound init 13 sound play [[len freq] ...] [len [freq]] 14 15Description 16----------- 17 18The *sound* command is used to play one or multiple beep sounds. 19 20sound init 21 initializes the sound driver. 22 23sound play 24 plays a square wave sound. It does not depend on previously calling 25 *sound init*. 26 27len 28 duration of the sound in ms, defaults to 1000 ms 29 30freq 31 frequency of the sound in Hz, defaults to 400 Hz 32 33Examples 34-------- 35 36Beep at 400 Hz for 1000 ms:: 37 38 sound play 39 40Beep at 400 Hz for 600 ms:: 41 42 sound play 600 43 44Beep at 500 Hz for 600 ms:: 45 46 sound play 600 500 47 48Play melody:: 49 50 sound play 500 1047 500 880 500 0 500 1047 500 880 500 0 500 784 500 698 500 784 1000 698 51 52Configuration 53------------- 54 55The sound command is enabled by CONFIG_CMD_SOUND=y. 56 57Return value 58------------ 59 60The return value $? is 0 (true) if the command succeeds, 1 (false) otherwise. 61