A note on GP usage: when generating a sequence in GP, you can use the write command to output to a file. This, however, is often slow, since it requires opening the file for every term of the sequence.
Alternately, you can have GP print all the terms of your sequence to the terminal window, and then "select all"-copy-paste into a text editor. This is probably the most straight-forward method.
Another
method is to use the tee command (in any unix-like environment, like Terminal on a Mac) and call gp like this:
gp | tee output.txtThis will start gp, but all output will be echoed to the file output.txt. Then, you can do something like
for(i=1,10^6,if(isprime(i),print(i)))to spit out all primes under 106 to the screen. Then quit gp, and open output.txt in a text editor and you will see all the primes there. Remove any extraneous lines, save, and you'll be ready to feed it to the list-to-sound code.