Difference between revisions of "SynthAModelerFireFaderLab"

From CCRMA Wiki
Jump to: navigation, search
 
(18 intermediate revisions by the same user not shown)
Line 2: Line 2:
  
 
== Installing Synth-A-Modeler ==
 
== Installing Synth-A-Modeler ==
* First install XCode Developer tools (see [https://developer.apple.com/xcode/ this link] or go to the App Store) and make sure that command line tools are installed. (Alternative to XCode: [https://github.com/kennethreitz/osx-gcc-installer] and choose a package GCC-10.6.pkg, GCC-10.7.pkg, etc.)
+
* First check if the C++ compiler is already installed by running the following line in the Terminal application:
  
 +
''g++ --version''
  
 +
* If not, then you will need to install it. You can do so by first installing the XCode Developer tools (see [https://developer.apple.com/xcode/ this link] or go to the App Store) and '''make sure that command line tools are installed.''' (Possible alternative to XCode: [https://github.com/kennethreitz/osx-gcc-installer] and choose a package GCC-10.6.pkg, GCC-10.7.pkg, etc.)
  
* Download "Qt libraries 4.8.4 for Mac (185 MB)" from the [http://qt-project.org/downloads following link] and install it (installation takes about 5 minutes).
+
* Download "Qt libraries 4.8.6 for Mac" from the [https://download.qt.io/archive/qt/4.8/4.8.6/ following link] and install it (installation takes about 5 minutes).
  
 
+
* Download the file faust-0.9.67.zip from [https://ccrma.stanford.edu/~eberdahl/faust-0.9.67.zip here]. (Currently the newer versions of Faust don't work.)
 
+
* Download the file faust-0.9.58.zip from the [http://sourceforge.net/projects/faudiostream/files/?source=navbar Faust repository].
+
 
* Then open the Terminal program. Probably the ZIP file wound up in your Downloads directory, and you could move it into the current (i.e. home) directory by typing:
 
* Then open the Terminal program. Probably the ZIP file wound up in your Downloads directory, and you could move it into the current (i.e. home) directory by typing:
mv ~/Downloads/faust-0.9.58.zip .
+
''mv ~/Downloads/faust-0.9.67.zip .''
 
* Unzip it by typing
 
* Unzip it by typing
unzip faust-0.9.58.zip
+
''unzip faust-0.9.67.zip''
* Enter the new faust-0.9.58 directory by typing
+
* Enter the new faust-0.9.67 directory by typing
cd faust-0.9.58
+
''cd faust-0.9.67''
 
* Finally, run the following commands to compile and install Faust. You will have to enter the administrator password to install Faust:
 
* Finally, run the following commands to compile and install Faust. You will have to enter the administrator password to install Faust:
make
+
''make''
  
sudo make install
+
''sudo make install''
  
 +
* Then you will need to install the Jack Audio server. Download the 64/32 bit version from [http://jackaudio.org/downloads/ Jack Audio Server for OS X] (after you install this you will need to restart).
  
 +
* To download Synth-A-Modeler (SaM), click on the Zip button near the upper-lefthand corner of [https://github.com/eberdahl/SaM this page].
 +
* Now open up the Terminal again, and make sure you are in your home directory by typing
  
 +
''cd ~''
  
* Then you will need to install the Jack Audio server. Download the 64/32 bit version from [http://www.jackosx.com/ Jack Audio Server for OS X] (after you install this you will need to restart).
+
* Now, move SaM into your home directory by typing
  
 +
''mv ~/Downloads/SaM-master.zip .''
  
 +
* Extract Synth-A-Modeler using
  
 +
''unzip SaM-master.zip .''
  
* Now open up the Terminal again.
+
* To enter the Synth-A-Modeler directory, type
  
Finally, install the Synth-A-Modeler software into the directory ~/SAM
+
''cd SaM-master''
  
Before you plug in your FireFader, run the command
+
* Before you plug in your FireFader, run the command
  
 
''ls /dev/cu*''
 
''ls /dev/cu*''
Line 40: Line 47:
 
for a list of the serial devices. Then, after plugging in the FireFader, run
 
for a list of the serial devices. Then, after plugging in the FireFader, run
  
ls /dev/cu*
+
''ls /dev/cu*''
  
again. The new path you see is the path to your FireFader. For instance, on my machine it is /dev/cu.usbmodem1d11. Then edit the file ~/SAM/WhichDevice.txt so that it contains only the new path, that is for me it contains only the following:
+
again. The new path you see is the path to your FireFader. For instance, on my machine it is /dev/cu.usbmodem1d11. Then edit the file ~/SAM/PathToDevice.txt so that it contains only the new path, that is for me it contains only the following:
  
/dev/cu.usbmodem1d11
+
''/dev/cu.usbmodem1d11''
  
(Old way: update PATH_TO_SERIAL in jack-qt.cpp)
+
* Now copy PathToDevice.txt to your root directory by typing
  
Then try to compile the guiro model by typing
+
''sudo cp PathToDevice.txt /''
make jackqt SAMTARGET=guiro
+
  
 +
(You will have to enter the administrator password to make this happen.)
  
  
'''Make sure that in the Jack settings, the frames/period is set to 32.'''
 
  
 +
== Exploring Synth-A-Modeler ==
 +
* Open the JackPilot program. Go to the pull-down menu JackPilot | Preferences. Make sure they look approximately like mine:
  
 +
<center>
 +
[[Image:JackPilotSaMSettings.jpg]]
 +
</center>
  
 +
(If you have problems with dropouts, you can change the Buffer Size to 64 instead -- but 32 works fine for me as long as I am not running too many other applications.)
  
(Ran fine on Mac Book Pro Late 2008 Intel Core 2 Duo running OS X 10.8.2 at 32 samples per frame, MacBook Pro Intel Core i7 running OS X 10.7.5 with Qt version 4.7.4 at 32 samples per frame, and iMac running OS X 10.6.8 at 32 samples per frame, Ran fine on dual-core 2.53GHz Intel Core 2 Duo OS X 10.6.8)
+
* Click on the 'Save' button and then start the Jack audio server by clicking on the ''Start'' button.
 +
 
 +
* To build all of the models stored in MDL files into QT applications for the Jack audio server, run the command
 +
 
 +
''make jackqt''
 +
 
 +
Browse to your home directory in the Finder, and then go inside SaM-master. The make command should've caused the subdirectory jackqt to be created containing a compiled application for each model. (If that didn't work, then talk to one of us.)
 +
 
 +
* You should be able to run any model now by double-clicking on it in the Finder.  
 +
 
 +
* Now, try editing the models. The ''make jackqt'' command should detect any MDL files that have changed and recompile the corresponding applications.
 +
 
 +
* For information on the syntax, please see the [https://github.com/ptrv/Synth-A-Modeler/wiki Synth-A-Modeler Wiki]
 +
 
 +
 
 +
 
 +
== Notes ==
 +
* You can only run one model at a time!
 +
 
 +
 
 +
 
 +
 
 +
== Going Further ==
 +
* To force Synth-A-Modeler to only compile one model, such as guiro.mdl, you can run the following command:
 +
 
 +
''make jackqt SAMTARGET=guiro''
 +
 
 +
* Setup the Pure Data (pd) header files for Faust and try the ''make puredata'' command.
 +
 
 +
* Install the MaxMSP SDK and then try the ''make msp'' command (you might need to adjust where it is looking for the header files).
  
  
Line 71: Line 112:
  
 
== Troubleshooting ==
 
== Troubleshooting ==
Requires minimum Perl version 5.10
+
* If Synth-A-Modeler crashes badly, it can also crash the Jack audio server. In this case, don't forget to restart the Jack audio server.
  
The following kinds of errors can for instance happen if you ever upgraded Faust but forgot to remove the older version of Faust:  
+
* Requires minimum Perl version 5.10
 +
 
 +
* The following kinds of errors can for instance happen if you ever upgraded Faust but forgot to remove the older version of Faust:  
 
error: macro "max" passed 3 arguments, but takes just 2
 
error: macro "max" passed 3 arguments, but takes just 2
 
or other particularly errors involving some standard template libraries, then please make sure you only have one version of Faust installed. You can remove all older versions of Faust by entering into each of their source directories and running
 
or other particularly errors involving some standard template libraries, then please make sure you only have one version of Faust installed. You can remove all older versions of Faust by entering into each of their source directories and running
 
sudo make uninstall
 
sudo make uninstall
(Then of course you will need to reinstall you favorite version of Faust 0.9.58 by going into its source directory and running ''sudo make install'')
+
(Then of course you will need to reinstall you favorite version of Faust 0.9.58 by going into its source directory and running ''sudo make install''
 +
 
 +
* Ran fine on Mac Book Pro Late 2008 Intel Core 2 Duo running OS X 10.8.2 at 32 samples per frame, MacBook Pro Intel Core i7 running OS X 10.7.5 with Qt version 4.7.4 at 32 samples per frame, and iMac running OS X 10.6.8 at 32 samples per frame, Ran fine on dual-core 2.53GHz Intel Core 2 Duo OS X 10.6.8

Latest revision as of 11:07, 6 October 2015

Current Requirements: Intel CPU and Mac OS X 10.6 or greater

Installing Synth-A-Modeler

  • First check if the C++ compiler is already installed by running the following line in the Terminal application:

g++ --version

  • If not, then you will need to install it. You can do so by first installing the XCode Developer tools (see this link or go to the App Store) and make sure that command line tools are installed. (Possible alternative to XCode: [1] and choose a package GCC-10.6.pkg, GCC-10.7.pkg, etc.)
  • Download "Qt libraries 4.8.6 for Mac" from the following link and install it (installation takes about 5 minutes).
  • Download the file faust-0.9.67.zip from here. (Currently the newer versions of Faust don't work.)
  • Then open the Terminal program. Probably the ZIP file wound up in your Downloads directory, and you could move it into the current (i.e. home) directory by typing:

mv ~/Downloads/faust-0.9.67.zip .

  • Unzip it by typing

unzip faust-0.9.67.zip

  • Enter the new faust-0.9.67 directory by typing

cd faust-0.9.67

  • Finally, run the following commands to compile and install Faust. You will have to enter the administrator password to install Faust:

make

sudo make install

  • Then you will need to install the Jack Audio server. Download the 64/32 bit version from Jack Audio Server for OS X (after you install this you will need to restart).
  • To download Synth-A-Modeler (SaM), click on the Zip button near the upper-lefthand corner of this page.
  • Now open up the Terminal again, and make sure you are in your home directory by typing

cd ~

  • Now, move SaM into your home directory by typing

mv ~/Downloads/SaM-master.zip .

  • Extract Synth-A-Modeler using

unzip SaM-master.zip .

  • To enter the Synth-A-Modeler directory, type

cd SaM-master

  • Before you plug in your FireFader, run the command

ls /dev/cu*

for a list of the serial devices. Then, after plugging in the FireFader, run

ls /dev/cu*

again. The new path you see is the path to your FireFader. For instance, on my machine it is /dev/cu.usbmodem1d11. Then edit the file ~/SAM/PathToDevice.txt so that it contains only the new path, that is for me it contains only the following:

/dev/cu.usbmodem1d11

  • Now copy PathToDevice.txt to your root directory by typing

sudo cp PathToDevice.txt /

(You will have to enter the administrator password to make this happen.)


Exploring Synth-A-Modeler

  • Open the JackPilot program. Go to the pull-down menu JackPilot | Preferences. Make sure they look approximately like mine:

JackPilotSaMSettings.jpg

(If you have problems with dropouts, you can change the Buffer Size to 64 instead -- but 32 works fine for me as long as I am not running too many other applications.)

  • Click on the 'Save' button and then start the Jack audio server by clicking on the Start button.
  • To build all of the models stored in MDL files into QT applications for the Jack audio server, run the command

make jackqt

Browse to your home directory in the Finder, and then go inside SaM-master. The make command should've caused the subdirectory jackqt to be created containing a compiled application for each model. (If that didn't work, then talk to one of us.)

  • You should be able to run any model now by double-clicking on it in the Finder.
  • Now, try editing the models. The make jackqt command should detect any MDL files that have changed and recompile the corresponding applications.


Notes

  • You can only run one model at a time!



Going Further

  • To force Synth-A-Modeler to only compile one model, such as guiro.mdl, you can run the following command:

make jackqt SAMTARGET=guiro

  • Setup the Pure Data (pd) header files for Faust and try the make puredata command.
  • Install the MaxMSP SDK and then try the make msp command (you might need to adjust where it is looking for the header files).






Troubleshooting

  • If Synth-A-Modeler crashes badly, it can also crash the Jack audio server. In this case, don't forget to restart the Jack audio server.
  • Requires minimum Perl version 5.10
  • The following kinds of errors can for instance happen if you ever upgraded Faust but forgot to remove the older version of Faust:

error: macro "max" passed 3 arguments, but takes just 2 or other particularly errors involving some standard template libraries, then please make sure you only have one version of Faust installed. You can remove all older versions of Faust by entering into each of their source directories and running sudo make uninstall (Then of course you will need to reinstall you favorite version of Faust 0.9.58 by going into its source directory and running sudo make install

  • Ran fine on Mac Book Pro Late 2008 Intel Core 2 Duo running OS X 10.8.2 at 32 samples per frame, MacBook Pro Intel Core i7 running OS X 10.7.5 with Qt version 4.7.4 at 32 samples per frame, and iMac running OS X 10.6.8 at 32 samples per frame, Ran fine on dual-core 2.53GHz Intel Core 2 Duo OS X 10.6.8