I'm not sure if this is an issue merely with the examples that come with the Csound 5.08 reference manual and the zip file of Boulanger's Chapter 1, but I get error messages such as the following:
:~/html/examples$ csound -odac:hw:0,0 -iadc:hw:0,0 oscil.csd
PortAudio real-time audio module for Csound
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
Csound version 5.08 (double samples) May 3 2008
libsndfile-1.0.17
UnifiedCSD: oscil.csd
STARTING FILE
Creating options
Creating orchestra
Creating score
orchname: /tmp/fileIKxhFe.orc
scorename: /tmp/fileGAaqbj.sco
rtaudio: PortAudio module enabled ... using blocking interface
orch compiler:
17 lines read
instr 1
Elapsed time at end of orchestra compile: real: 0.059s, CPU: 0.010s
sorting score ...
... done
Elapsed time at end of score sort: real: 0.059s, CPU: 0.010s
Csound version 5.08 (double samples) May 3 2008
displays suppressed
0dBFS level = 32768.0
orch now loaded
audio buffered in 256 sample-frame blocks
PortAudio V19-devel (built Apr 30 2008)
PortAudio: using ALSA device 'hw:0,0'
Expression 'snd_pcm_hw_params_set_channels( pcm, hwParams, self->numHostChannels )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1300
Expression 'PaAlsaStreamComponent_InitialConfigure( &self->capture, inParams, self->primeBuffers, hwParamsCapture, &realSr )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1862
Expression 'PaAlsaStream_Configure( stream, inputParameters, outputParameters, sampleRate, framesPerBuffer, &inputLatency, &outputLatency, &hostBufferSizeMode )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1986
*** PortAudio: error: -9998: Invalid number of channels
Failed to initialise real time audio input
inactive allocs returned to freespace
end of score. overall amps: 0.0
overall samples out of range: 0
1 errors in performance
Elapsed time at end of performance: real: 0.335s, CPU: 0.070s
/CsoundBookCh1$ csound -odac:hw:0,0 -iadc:hw:0,0 -rtaudio=alsa 101.orc 101.sco
PortAudio real-time audio module for Csound
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
Csound version 5.08 (double samples) May 3 2008
libsndfile-1.0.17
orchname: 101.orc
scorename: 101.sco
rtaudio: PortAudio module enabled ... using blocking interface
orch compiler:
9 lines read
instr 101
Elapsed time at end of orchestra compile: real: 0.378s, CPU: 0.000s
sorting score ...
... done
Elapsed time at end of score sort: real: 0.378s, CPU: 0.000s
Csound version 5.08 (double samples) May 3 2008
0dBFS level = 32768.0
orch now loaded
audio buffered in 256 sample-frame blocks
PortAudio V19-devel (built Apr 30 2008)
PortAudio: using ALSA device 'hw:0,0'
Expression 'snd_pcm_hw_params_set_channels( pcm, hwParams, self->numHostChannels )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1300
Expression 'PaAlsaStreamComponent_InitialConfigure( &self->capture, inParams, self->primeBuffers, hwParamsCapture, &realSr )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1862
Expression 'PaAlsaStream_Configure( stream, inputParameters, outputParameters, sampleRate, framesPerBuffer, &inputLatency, &outputLatency, &hostBufferSizeMode )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1986
*** PortAudio: error: -9998: Invalid number of channels
Failed to initialise real time audio input
inactive allocs returned to freespace
end of score. overall amps: 0.0
overall samples out of range: 0
1 errors in performance
Elapsed time at end of performance: real: 0.606s, CPU: 0.060s
I'm working from what I presume is a vanilla kernel, vmlinuz-huge-smp-2.6.24.5-smp. I made all the csound components in /usr/local/bin members of the audio group as well as me in order to avoid having to compile a new kernel. Is this going to be necessary after all?
Richard Benedict



That's a new one, alright.
I've never seen that one.
I'm not sure if this will help, but let's try to find what DOES work.
Try compiling the csound file with the following options:
csound -Wdo test.wav (your csd filename here)
Did it work? It should have made a file named test.wav
If it did, now try setting a generic output -- nothing specific, let csound and alsa figure it out.
csound -d -o dac (your csd filename here)
If you need to be more specific, try setting the alsa hardware for output as you did above -- but don't mess with the -i (input) options just yet. I have a feeling they're the wonky part, and if these two work, we've at least eliminated them as a source of error.
As for specifying input, I think you only really need to do it if you're processing an audio stream . . . most of the time just specifying a place for the sound to go is sufficient.
==
http://www.jamendo.com/en/artist/bruce.h.mccosar
http://bmccosar.wordpress.com/
Here goes...
richard@richard-laptop:~/html/examples$ csound -Wdo test.wav oscil.csd
PortAudio real-time audio module for Csound
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
Csound version 5.08 (double samples) May 3 2008
libsndfile-1.0.17
UnifiedCSD: oscil.csd
STARTING FILE
Creating options
Creating orchestra
Creating score
orchname: /tmp/fileQszB4N.orc
scorename: /tmp/fileSUF3Zr.sco
rtaudio: PortAudio module enabled ... using blocking interface
orch compiler:
17 lines read
instr 1
Elapsed time at end of orchestra compile: real: 0.060s, CPU: 0.000s
sorting score ...
... done
Elapsed time at end of score sort: real: 0.060s, CPU: 0.000s
Csound version 5.08 (double samples) May 3 2008
displays suppressed
0dBFS level = 32768.0
orch now loaded
audio buffered in 256 sample-frame blocks
PortAudio V19-devel (built Apr 30 2008)
PortAudio: available input devices:
0: /dev/dsp
1: /dev/dsp1
2: HDA NVidia: STAC92xx Analog (hw:0,0)
3: HDA NVidia: Si3054 Modem (hw:0,6)
4: MobilePre: USB Audio (hw:1,0)
5: modem
6: phoneline
7: default
PortAudio: selected input device '/dev/dsp'
reading 512-byte blks of shorts from adc (RAW)
writing 512-byte blks of shorts to test.wav (WAV)
SECTION 1:
ftable 1:
new alloc for instr 1:
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
Csound tidy up: Interrupt
Csound tidy up: Interrupt
inactive allocs returned to freespace
end of score. overall amps: 10000.0
overall samples out of range: 0
0 errors in performance
Elapsed time at end of performance: real: 932.522s, CPU: 0.050s
93 512-byte soundblks of shorts written to test.wav (WAV)
I CTRL-Ced it after about ten minutes. The test.wav blooped out a nice little sine tone. On to the next stage:
richard@richard-laptop:~/html/examples$ csound -d -o dac oscil.csd
PortAudio real-time audio module for Csound
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
Csound version 5.08 (double samples) May 3 2008
libsndfile-1.0.17
UnifiedCSD: oscil.csd
STARTING FILE
Creating options
Creating orchestra
Creating score
orchname: /tmp/fileZmENT4.orc
scorename: /tmp/file2wJqEZ.sco
rtaudio: PortAudio module enabled ... using blocking interface
orch compiler:
17 lines read
instr 1
Elapsed time at end of orchestra compile: real: 0.002s, CPU: 0.010s
sorting score ...
... done
Elapsed time at end of score sort: real: 0.002s, CPU: 0.010s
Csound version 5.08 (double samples) May 3 2008
displays suppressed
0dBFS level = 32768.0
orch now loaded
audio buffered in 256 sample-frame blocks
PortAudio V19-devel (built Apr 30 2008)
PortAudio: available input devices:
0: /dev/dsp
1: /dev/dsp1
2: HDA NVidia: STAC92xx Analog (hw:0,0)
3: HDA NVidia: Si3054 Modem (hw:0,6)
4: MobilePre: USB Audio (hw:1,0)
5: modem
6: phoneline
7: default
PortAudio: selected input device '/dev/dsp'
reading 512-byte blks of shorts from adc (RAW)
PortAudio: available output devices:
0: /dev/dsp
1: /dev/dsp1
2: HDA NVidia: STAC92xx Analog (hw:0,0)
3: HDA NVidia: Si3054 Modem (hw:0,6)
4: MobilePre: USB Audio (hw:1,0)
5: front
6: surround40
7: surround51
8: surround71
9: modem
10: phoneline
11: default
12: dmix
PortAudio: selected output device '/dev/dsp'
writing 512-byte blks of shorts to dac
SECTION 1:
ftable 1:
new alloc for instr 1:
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
WARNING: Buffer overrun in real-time audio input
Csound tidy up: Interrupt
Csound tidy up: Interrupt
inactive allocs returned to freespace
end of score. overall amps: 10000.0
overall samples out of range: 0
0 errors in performance
Elapsed time at end of performance: real: 56.404s, CPU: 0.050s
5 512-byte soundblks of shorts written to dac
Again, I CTRL-Ced the process. The warning message appeared roughly in 10-second intervals, accompanied by a clicking sound from my laptop speakers.
My usb audio interface, an M-Audio MobilePre, is listed as 'hw:1,0' because I plugged it in after booting into Slackware; if I had plugged it in beforehand, it would be listed as 'hw:0,0'. So now to be more specific with the output while leaving input alone:
richard@richard-laptop:~/html/examples$ csound -d -o dac:hw:1,0 oscil.csd
PortAudio real-time audio module for Csound
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
Csound version 5.08 (double samples) May 3 2008
libsndfile-1.0.17
UnifiedCSD: oscil.csd
STARTING FILE
Creating options
Creating orchestra
Creating score
orchname: /tmp/fileLoqkPj.orc
scorename: /tmp/file8Rn9ut.sco
rtaudio: PortAudio module enabled ... using blocking interface
orch compiler:
17 lines read
instr 1
Elapsed time at end of orchestra compile: real: 0.002s, CPU: 0.000s
sorting score ...
... done
Elapsed time at end of score sort: real: 0.002s, CPU: 0.000s
Csound version 5.08 (double samples) May 3 2008
displays suppressed
0dBFS level = 32768.0
orch now loaded
audio buffered in 256 sample-frame blocks
PortAudio V19-devel (built Apr 30 2008)
PortAudio: available input devices:
0: /dev/dsp
1: /dev/dsp1
2: HDA NVidia: STAC92xx Analog (hw:0,0)
3: HDA NVidia: Si3054 Modem (hw:0,6)
4: MobilePre: USB Audio (hw:1,0)
5: modem
6: phoneline
7: default
PortAudio: selected input device '/dev/dsp'
reading 512-byte blks of shorts from adc (RAW)
PortAudio: using ALSA device 'hw:1,0'
Expression 'snd_pcm_hw_params_set_channels( pcm, hwParams, self->numHostChannels )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1300
Expression 'PaAlsaStreamComponent_InitialConfigure( &self->playback, outParams, self->primeBuffers, hwParamsPlayback, &realSr )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1865
Expression 'PaAlsaStream_Configure( stream, inputParameters, outputParameters, sampleRate, framesPerBuffer, &inputLatency, &outputLatency, &hostBufferSizeMode )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 1986
*** PortAudio: error: -9998: Invalid number of channels
Failed to initialise real time audio output
inactive allocs returned to freespace
end of score. overall amps: 0.0
overall samples out of range: 0
1 errors in performance
Elapsed time at end of performance: real: 0.295s, CPU: 0.050s
I think you're right about it being an input issue ( but IANAProgrammer ;^). So from what I see, csound attempts to use real time with /dev/dsp input, but gives up altogether when I choose the usb interface, and if I'm less specific and only indicate '-o dac', csound doesn't get past the input/buffer overrun hurdle.
Someone call Batman...
...because this looks like something from the Riddler (Csound edition).
Try a similar experiment, except use some of the actual discrete .orc and .sco files from Dr. Boulanger's chapter. I'm seeing a line that says 'Creating options' over and over again . . . maybe your unified Csound file has some options set up that are causing the problem. If you try it with a pure .orc and .sco setup, there are only a few other ways that options can leak in to the system.
With Alsa, this really shouldn't be a problem. What exactly is going on in the file? If you're trying to generate a 3 second test sound, but the machine is hanging long enough for a message to repeat at 10-sec intervals, I have to think that something unusual is going on.
Here's another thought:
Sometimes there's another process running that grabs hold of the sound card resources and won't let go. If this is the case, csound could be hanging while it 'waits its turn'. That would explain why the audio file was written ok, but the program got stuck anyway.
The usual miscreants are the sound daemons. If your desktop has something like esound (esd) or aRts (artsd) running, they can take exclusive control over the sound card. If they're running, try turning them off (with, for instance, 'killall esd' or 'killall artsd') and see if it makes a difference.
--
http://www.jamendo.com/en/artist/bruce.h.mccosar
http://bmccosar.wordpress.com/
No problems yet with 101.orc and 101.sco
'oscil.csd' comes straight from the examples directory in 5.08, and renders a 2-second sine tone produced with the oscil opcode. I'm working with a fairly untweaked version of Slackware 12.1 and an xfce desktop, so artsd and esd aren't an issue as far as I can see:
~/CsoundBookCh1$ ps aux | grep esd
richard 3104 0.0 0.0 2056 636 pts/0 R+ 06:43 0:00 grep esd
~/CsoundBookCh1$ ps aux | grep artsd
richard 3106 0.0 0.0 2056 648 pts/0 S+ 06:43 0:00 grep artsd
$ csound -Wdo test.wav 101.orc 101.sco
PortAudio real-time audio module for Csound
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
Csound version 5.08 (double samples) May 3 2008
libsndfile-1.0.17
orchname: 101.orc
scorename: 101.sco
rtaudio: PortAudio module enabled ... using blocking interface
orch compiler:
9 lines read
instr 101
Elapsed time at end of orchestra compile: real: 0.059s, CPU: 0.000s
sorting score ...
... done
Elapsed time at end of score sort: real: 0.059s, CPU: 0.000s
Csound version 5.08 (double samples) May 3 2008
displays suppressed
0dBFS level = 32768.0
orch now loaded
audio buffered in 256 sample-frame blocks
writing 512-byte blks of shorts to test.wav (WAV)
SECTION 1:
ftable 1:
new alloc for instr 101:
B 0.000 .. 3.000 T 3.000 TT 3.000 M: 10000.0
Score finished in csoundPerform().
inactive allocs returned to freespace
end of score. overall amps: 10000.0
overall samples out of range: 0
0 errors in performance
Elapsed time at end of performance: real: 0.104s, CPU: 0.020s
517 512-byte soundblks of shorts written to test.wav (WAV)
$ aplay test.wav
Playing WAVE 'test.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Mono
$ csound -d -o dac 101.orc 101.sco
PortAudio real-time audio module for Csound
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
Csound version 5.08 (double samples) May 3 2008
libsndfile-1.0.17
orchname: 101.orc
scorename: 101.sco
rtaudio: PortAudio module enabled ... using blocking interface
orch compiler:
9 lines read
instr 101
Elapsed time at end of orchestra compile: real: 0.001s, CPU: 0.000s
sorting score ...
... done
Elapsed time at end of score sort: real: 0.002s, CPU: 0.000s
Csound version 5.08 (double samples) May 3 2008
displays suppressed
0dBFS level = 32768.0
orch now loaded
audio buffered in 256 sample-frame blocks
PortAudio V19-devel (built Apr 30 2008)
PortAudio: available output devices:
0: /dev/dsp
1: /dev/dsp1
2: MobilePre: USB Audio (hw:0,0)
3: HDA NVidia: STAC92xx Analog (hw:1,0)
4: HDA NVidia: Si3054 Modem (hw:1,6)
5: front
6: surround40
7: iec958
8: spdif
9: default
10: dmix
PortAudio: selected output device '/dev/dsp'
writing 512-byte blks of shorts to dac
SECTION 1:
ftable 1:
new alloc for instr 101:
B 0.000 .. 3.000 T 3.000 TT 3.000 M: 10000.0
Score finished in csoundPerform().
inactive allocs returned to freespace
end of score. overall amps: 10000.0
overall samples out of range: 0
0 errors in performance
Elapsed time at end of performance: real: 3.690s, CPU: 0.090s
517 512-byte soundblks of shorts written to dac
The test results aren't exactly pure compared to last time as I plugged in the MobilePre interface first before booting, so maybe it's time to do 'oscil.csd' again in the same fashion:
$ csound -Wdo test.wav oscil.csd
PortAudio real-time audio module for Csound
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
Csound version 5.08 (double samples) May 3 2008
libsndfile-1.0.17
UnifiedCSD: oscil.csd
STARTING FILE
Creating options
Creating orchestra
Creating score
orchname: /tmp/file5g4TrD.orc
scorename: /tmp/fileyjNxK6.sco
rtaudio: PortAudio module enabled ... using blocking interface
orch compiler:
17 lines read
instr 1
Elapsed time at end of orchestra compile: real: 0.415s, CPU: 0.000s
sorting score ...
... done
Elapsed time at end of score sort: real: 0.415s, CPU: 0.000s
Csound version 5.08 (double samples) May 3 2008
displays suppressed
0dBFS level = 32768.0
orch now loaded
audio buffered in 256 sample-frame blocks
PortAudio V19-devel (built Apr 30 2008)
PortAudio: available input devices:
0: /dev/dsp
1: /dev/dsp1
2: MobilePre: USB Audio (hw:0,0)
3: HDA NVidia: STAC92xx Analog (hw:1,0)
4: HDA NVidia: Si3054 Modem (hw:1,6)
5: spdif
6: default
PortAudio: selected input device '/dev/dsp'
reading 512-byte blks of shorts from adc (RAW)
writing 512-byte blks of shorts to test.wav (WAV)
SECTION 1:
ftable 1:
new alloc for instr 1:
B 0.000 .. 2.000 T 2.000 TT 2.000 M: 10000.0
Score finished in csoundPerform().
inactive allocs returned to freespace
end of score. overall amps: 10000.0
overall samples out of range: 0
0 errors in performance
Elapsed time at end of performance: real: 2.651s, CPU: 0.070s
345 512-byte soundblks of shorts written to test.wav (WAV)
$ aplay test.wav
Playing WAVE 'test.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Mono
$ csound -d oscil.csd
PortAudio real-time audio module for Csound
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
Csound version 5.08 (double samples) May 3 2008
libsndfile-1.0.17
UnifiedCSD: oscil.csd
STARTING FILE
Creating options
Creating orchestra
Creating score
orchname: /tmp/filewBxYF5.orc
scorename: /tmp/fileeE2nc1.sco
rtaudio: PortAudio module enabled ... using blocking interface
orch compiler:
17 lines read
instr 1
Elapsed time at end of orchestra compile: real: 0.002s, CPU: 0.010s
sorting score ...
... done
Elapsed time at end of score sort: real: 0.002s, CPU: 0.010s
Csound version 5.08 (double samples) May 3 2008
displays suppressed
0dBFS level = 32768.0
orch now loaded
audio buffered in 256 sample-frame blocks
PortAudio V19-devel (built Apr 30 2008)
PortAudio: available input devices:
0: /dev/dsp
1: /dev/dsp1
2: MobilePre: USB Audio (hw:0,0)
3: HDA NVidia: STAC92xx Analog (hw:1,0)
4: HDA NVidia: Si3054 Modem (hw:1,6)
5: spdif
6: default
PortAudio: selected input device '/dev/dsp'
reading 512-byte blks of shorts from adc (RAW)
PortAudio: available output devices:
0: /dev/dsp
1: /dev/dsp1
2: MobilePre: USB Audio (hw:0,0)
3: HDA NVidia: STAC92xx Analog (hw:1,0)
4: HDA NVidia: Si3054 Modem (hw:1,6)
5: front
6: surround40
7: iec958
8: spdif
9: default
10: dmix
PortAudio: selected output device '/dev/dsp'
writing 512-byte blks of shorts to dac
SECTION 1:
ftable 1:
new alloc for instr 1:
B 0.000 .. 2.000 T 2.000 TT 2.000 M: 10000.0
Score finished in csoundPerform().
inactive allocs returned to freespace
end of score. overall amps: 10000.0
overall samples out of range: 0
0 errors in performance
Elapsed time at end of performance: real: 2.255s, CPU: 0.080s
345 512-byte soundblks of shorts written to dac
These are the options in oscil.csd:
-odac -iadc -d
I'll try those with the Boulanger files:
$ csound -odac -iadc -d 101.orc 101.sco
PortAudio real-time audio module for Csound
virtual_keyboard real time MIDI plugin for Csound
0dBFS level = 32768.0
Csound version 5.08 (double samples) May 3 2008
libsndfile-1.0.17
orchname: 101.orc
scorename: 101.sco
rtaudio: PortAudio module enabled ... using blocking interface
orch compiler:
9 lines read
instr 101
Elapsed time at end of orchestra compile: real: 0.001s, CPU: 0.000s
sorting score ...
... done
Elapsed time at end of score sort: real: 0.002s, CPU: 0.000s
Csound version 5.08 (double samples) May 3 2008
displays suppressed
0dBFS level = 32768.0
orch now loaded
audio buffered in 256 sample-frame blocks
PortAudio V19-devel (built Apr 30 2008)
PortAudio: available input devices:
0: /dev/dsp
1: /dev/dsp1
2: MobilePre: USB Audio (hw:0,0)
3: HDA NVidia: STAC92xx Analog (hw:1,0)
4: HDA NVidia: Si3054 Modem (hw:1,6)
5: spdif
6: default
PortAudio: selected input device '/dev/dsp'
reading 512-byte blks of shorts from adc (RAW)
PortAudio: available output devices:
0: /dev/dsp
1: /dev/dsp1
2: MobilePre: USB Audio (hw:0,0)
3: HDA NVidia: STAC92xx Analog (hw:1,0)
4: HDA NVidia: Si3054 Modem (hw:1,6)
5: front
6: surround40
7: iec958
8: spdif
9: default
10: dmix
PortAudio: selected output device '/dev/dsp'
writing 512-byte blks of shorts to dac
SECTION 1:
ftable 1:
new alloc for instr 101:
B 0.000 .. 3.000 T 3.000 TT 3.000 M: 10000.0
Score finished in csoundPerform().
inactive allocs returned to freespace
end of score. overall amps: 10000.0
overall samples out of range: 0
0 errors in performance
Elapsed time at end of performance: real: 3.250s, CPU: 0.060s
517 512-byte soundblks of shorts written to dac
So as you suspected, csound shows that it's 'Creating options' in its output when compiling a unified .csd file, but not when compiling a pair of .orc and .sco files. I think 'Creating options' just means that it's parsing the section of the .csd file in turn. At any rate, now there isn't a problem so long as I plug in the usb interface first and use '-o dac'. Next I'm going to try using the tutorial*.csd files that come with the 5.07 Csound tutorial when I get the time, because I suspect midi-related stuff might have been giving me headaches in the first place. Thanks for the pointers!
..
Well, I'm trying . . . not sure how much I'm accomplishing, but I'm trying ;-)
I guess this makes me grateful that everything worked 'out of the box' on Kubuntu. Even when I custom compiled, the sound system was set up correctly. Before, on Debian, I tried figuring it all out myself -- quite a headache, and I preferred to make music.
--
http://www.jamendo.com/en/artist/bruce.h.mccosar
http://bmccosar.wordpress.com/
Yes, I don't mind testing out my problem-solving skillz...
but when you start to feel like a virtual salmon trying to swim upstream, it's time to do what csound was meant for! :)
Since apparently you are
Since apparently you are using ALSA you could try using the "-+rtaudio=alsa" (note the plus sign) argument appended to your commandline.
In the above example you're using "-rtaudio=alsa" which is not understood by Csound and will default to the PortAudio driver for realtime performance.
As a rule of thumb if you are using ALSA, you don't need to use PortAudio at all.