… another shell / aka.shell question :)
Hello all, it’s been a while since I’ve used Max.
I’m trying to run a SoX command from Max via the [shell] or [aka.shell] objects, but with no success. If I run this straight in Terminal:
sox test.wav test.aiff
… as expected a new aiff is created on my desktop, from the wav of the same name.
But running that exact text via [shell] or [aka.shell] does absolutely nothing. [aka.shell] politely prints out all the details about SoX to the Max window, but all I get from [shell] is a bang message.
Am I neglecting to include something in the message I’m sending from Max? I’m a bit stumped because the objects’ help files don’t have any extra info, leading me to believe this should be really straight-forward.
cheers for the help :)
(SoX is a command-line utility for various types of conversion of audio files – http://sox.sourceforge.net/)
Hi there, multiple sequential commands in the shell object need to be separated by ;
Here’s an example with cd and ls.
----------begin_max5_patcher---------- 327.3ocqSE0SCBCD94xuhl9LNokoYpOYh+KbKlBbtUS4JgVhSWl+1EJP1lNx XY6Etzu63tuuudcS.gkXVCVF8Q5qTBYS.g3gZ.HcmIrb45Tsz5KikCVqbIvB ay4f0NOdZF8maewjVkCnyNe9STssuHUluDSxG2D2i8tAcnLG7YdtTI08Yvpb EpAmedhNvBoKckBW9VIj5Z4qf+vjnPJeZafeuOLaRDcwtNYpb8shu2jspu8S lKp+oV31JceU.ssmwnKZxrMHn4S3H8GD9rVm+ydJJUn6H9g3L8C9I8CQbbSH dp+Pzf1Qz.1w0Sy1UfVeDMyu5ZlOS307cmPyhycEHjxRj3xCWE7MmoU3ee43 IXC9gdk0TUl12xtGAzcTLCrNEJcJCtWM7CpYkJKCv8u1xUYEl5cpNJLvt5XY DeDLRbALp9v1feQ4xVP2 -----------end_max5_patcher-----------
Cheers, that’s just the ticket :)
now I just have to remember how to format text strings with spaces in specific places :-/ … that’s always irked me :)
… and how to extract compatible directories from a folderpath :-o … need to find those regexp tutorials again
You don’t have any idea why:
cd ~/Desktop; sox AltoSax.wav AltoSax_44100.wav rate -s 44100
cd ~/Desktop/Test; sox AltoSax.wav AltoSax_44100.wav rate -s 44100
would work while:
cd ~/Untitled:/Users/Tim_Lloyd/Desktop/Test; sox AltoSax.wav AltoSax_44100.wav rate -s 44100
cd Untitled:/Users/Tim_Lloyd/Desktop/Test; sox AltoSax.wav AltoSax_44100.wav rate -s 44100
cd ~Untitled:/Users/Tim_Lloyd/Desktop/Test; sox AltoSax.wav AltoSax_44100.wav rate -s 44100
cd /Untitled:/Users/Tim_Lloyd/Desktop/Test; sox AltoSax.wav AltoSax_44100.wav rate -s 44100
cd :/Users/Tim_Lloyd/Desktop/Test; sox AltoSax.wav AltoSax_44100.wav rate -s 44100
This current directory thing in Terminal is confusing, and it’s very hard to know where one is going wrong when there isn’t any feedback apart from no new file being created :p
When I have a chance to sit in front of my computer again I could send you a lot of info about formatting but check the forums or even my profile for posts and you’ll find a bunch of shell/space related questions.
Is your main volume really called untitled? By default it should be Macintosh HD:/Users/username/Desktop/thing.wav
By the way, most commands have a -v tag (verbose) meaning if it fails to copy it’ll print out why if you have print hooked up to stderr out.
… nearly got something working … but why, whyyyyyy do sequential commands need to be separated by a *backslash*; of all things :-o … it’s so irritating trying to deal with via [sprintf] and/or [combine] …
I am also a bit stuck with shell formatting.
I have very little experience using Terminal. I would like to send Terminal a message from Max MSP telling it to open a vqs file using a hidden Command Interface application (hidden meaning no GUI). My objective here is to use Terminal to communicate with a Datapath X4 unit – a box which splits the image on my MacBook Pro from multiple screens
If I type this into Terminal it works as I want it to:
vqscmd -ConFigfile=tamquarter.vqs -DeviceNumber=0
But I am not sure how to format this through shell.
Just wondering if you were successful using the datapath x4 from your MBP. Any information appreciated!