I have tried your recommendation but I kept getting a error
ERROR: #63: '&1.&2' is incorrectly overridden in class '&3'|Screen|Height|Screen
If I remove the gb.ncurses the application runs with no issues.
I have tried your recommendation but I kept getting a error
You have to use "gb.ncurses" with a command line interface project (no graphics Components):
Public Sub Main()
OK, That's almost exactly what I get, with the beep very audible. The only difference isAndyGable wrote: ↑Monday 2nd October 2023 1:49pmI tried this one and I got the following show up in the console of the Gambas enveroment.
play WARN alsa: can't encode 0-bit Unknown or not applicable play: SoX v14.4.2 play INFO nulfile: sample rate not specified; using 48000 Input File : '' (null) Channels : 1 Sample Rate : 48000 Precision : 32-bit Output File : 'default' (alsa) Channels : 1 Sample Rate : 48000 Precision : 32-bit Sample Encoding: 32-bit Signed Integer PCM Endian Type : little Reverse Nibbles: no Reverse Bits : no play INFO sox: effects chain: input 48000Hz 1 channels play INFO sox: effects chain: synth 48000Hz 1 channels play INFO sox: effects chain: vol 48000Hz 1 channels play INFO sox: effects chain: output 48000Hz 1 channels
and no sound
Yea I did that and and it worked but it was the quietest beep ever lolBruceSteers wrote: ↑Tuesday 3rd October 2023 8:22pm How about installing beep?
sudo apt install beep
beep
Did you miss my post? It requires stdout or the play command does not exit so use "&" or "For Output" when using gambas Shell process then it can continueAndyGable wrote: ↑Sunday 1st October 2023 5:20pmThe problem with the above is the systems I am using do not have any sound cards on them they only have the PC speaker.cogier wrote: ↑Sunday 1st October 2023 12:42pmThere is no need for = Null, you could have just followed the equal sign with "speaker - test -t.....". Better still: -
Dim SpeakerData As String = Null SpeakerData = "speaker-test -t sine -f 1000 -l 1 & sleep .2 && kill -9 $!" Shell SpeakerData
Shell "speaker-test -t sine -f 1000 -l 1 & sleep .2 && kill -9 $!"
Which works for me
************************************You are correct, it doesn't work, and I have no idea why.
shell "play -n synth 0.1 sine 880 vol 5"
Shell "play -n synth 0.1 sine 880 &"
Shell "play -n synth 0.1 sine 880" For Output
Shell "play -n synth 0.1 sine 880 2>/dev/null &"
Sorry Bruce I did miss your postBruceSteers wrote: ↑Wednesday 4th October 2023 12:49pmDid you miss my post? It requires stdout or the play command does not exit so use "&" or "For Output" when using gambas Shell process then it can continueAndyGable wrote: ↑Sunday 1st October 2023 5:20pmThe problem with the above is the systems I am using do not have any sound cards on them they only have the PC speaker.cogier wrote: ↑Sunday 1st October 2023 12:42pm
There is no need for = Null, you could have just followed the equal sign with "speaker - test -t.....". Better still: -
Shell "speaker-test -t sine -f 1000 -l 1 & sleep .2 && kill -9 $!"
Which works for me
************************************
You are correct, it doesn't work, and I have no idea why.
Shell "play -n synth 0.1 sine 880 &"
or
Shell "play -n synth 0.1 sine 880" For Output
They both work fine here
Shell "play -n synth 0.1 sine 880 2>/dev/null &"
if you want to divert the text output (stderr) to null