I’ve uploaded a zip file to the dropbox link here with 5 audio tracks and
three csound files. “MyPerform.csd” is the file that executes the program.
When I launch the program its takes a long time to load the samples into the
f-tables the RPI doesnt manage to load all the files i dont think and certainly doesnt manage to playback?
The sample rates are correct. I’m not sure why this is happing, perhaps something to do
with ram? Something inefficient with the way I’m loading the samples maybe?
I’ve tested the program on OSX it it works successfully. But
on raspbian lite i get the following errors im not sure what they mean?
This sounds like it tries to allocate a single 128MB memory block. It’s a lot of memory in a single block, and can easily fail, especially if paging / swap is disabled in the OS (not sure whether Raspbian Lite has it disabled by default or how large it is if it’s enabled)
The dropbox link seems broken, what are the file sizes and what is the format you’re using? If the audio files are compressed (like mp3), usually software first uncompresses the audio data into some raw audio format which can take a lot of memory.
For long duration files, it makes sense to open them in streaming mode, where only a small buffer is kept in memory for playback, and it gets updated as playback goes, so maybe there’s some alternative way you have to open samples with (I don’t know much about Csound to help you there)
interestingly i ran this script for ecasound to playback the tracks which did play the tracks back. If you have the audio files you may want to try the following:
Looks like you only have 20MB of available RAM, the audio files themselves are ~64MB each, so they don’t really fit in memory.
Try and see which process is using that much memory.
Ecasound may be able to play if it’s using the streaming method I described before. Try searching for ‘Csound streaming player’, maybe you can find info or some sample on how to do that with Csound.