ADJ Install & Configuration Manual for Server 0.0.2

Installing & Using Adj_server

Installation

We recommend you install all components on your local PC or laptop, for the purposes of this manual we will assume you are installing on Ubuntu Linux OS or Debian and that Pure-Data and Perl are preinstalled.

You will need Perl installed and with this you will also need additional Debian, Ubuntu Packages which are identified below:

liblwp-protocol-http-socketunix-perl
libnet-server-perl

The above method is by far the simplest method to install Perl Modules but not the only method. To install these modules you need do the following.

Open a terminal session, if you don't know what a terminal session is find Applications => Accessories => Terminal from the menu.

sudo apt-get install liblwp-protocol-http-socketunix-perl
sudo apt-get install libnet-server-perl

This almost finishes the dependencies for Adj_server with Perl.

Download from the adj.mediashed.org programmers page, the tar file adj_server-0.0.2.tar.gz Grahams New Server and PD Patches to a directory on your local PC or Laptop. Use the following command (again we are assuming you are using Ubuntu or Debian).

tar xvf adj_server-0.0.1.tar.gz

This creates a directory called ADJ_server-0.0.1 change directory to this location and the files this server uses are available to you. Their are some files that need to be altered before you can run the server or patches. But first you will need to finish the dependencies for Perl, change directory to Pd-Socket-0.01 thus:

cd Pd-Socket-0.01

If you cannot access this location it is because you have downloaded and untared the files as root, not a good idea re-install as a standard user, follow again the steps above.

In the above directory you will need to do the following.

sudo perl Makefile.PL

sudo make test (If this fails and it shouldn't you have other Perl Modules that are needed)

sudo make install

If all the above is successful you can return to the previous directory.

cd ..

Configuring adj_server

Using an editor you are familiar with open the file adj_server.conf

sudo vim adj_server.conf

find this entry at the top of the file:

### user and group to become
user harwood
group wheel

Edit the entry for "harwood" and "wheel" to reflect your own user and group settings, if you don't know what they are the following command will help you.

ls -al

-rw-r--r-- 1 delboy delboy 752 2007-01-11 20:52 adj_netrecieve.pd
-rw-r--r-- 1 delboy delboy1046 2007-01-11 19:16 adj_netsend.pd

### user and group to become
user delboy
group delboy

Save your changes and exit for adj_server.conf

The next thing we need to do is create a file in /var/log, that the server when running can write to. Use the following command when prompted enter your own password not the root password.

sudo touch /var/log/adj_server.log

Also you need to change the permissions of this file so the server can write to it, use the command that follows:

sudo chown <user>:<group> /var/log/adj_server.log

The <> indicates in this case your own user and group settings as above so for example:

sudo chown delboy:delboy /var/log/adj_server.log

Run The Adj_server

Executing the above command returns you to the ADJ_Server-0.0.2 directory you are now ready to run the Perl Script which follows

sudo perl adj_server.pl

This process once initiated runs in the background so the file when it is run, returns the terminal session to the user. To check if adj_server.pl is running you can use the following command.

ps aux |grep adj_server.pl

If the above command returns two entries or more this is fine one of the entries will be the grep command looking for adj_server.pl the other will be for the adj_server.pl itself.

Using The PD~ Patches

Start PureData this should be located Applications => Sound and Video => PureData

Once you have the PD console, open the adj_netrecieve.pd this module prints out to the Pd console the output if any received from the adj_server. adj_netrecieve.pd needs no alteration and can be left as is for now.

rita 200000 -0.6 966.8 4.1 350 54 -74.72 -164.03

Is a test signal that can be injected into the Patch to test the Print output to the PD Console, it serves no other purpose, keep it handy when you suspect something may be wrong. To test ensure you are not in edit mode denoted by the hand, so if you have an arrow when you pass the cursor across the adj_netrecieve.pd patch you are not in edit mode. Click with the mouse on the rita 200000 -0.6 966.8 4.1 350 54 -74.72 -164.03 button the test will display to the PD console an output that matches the above.

adj_netsend.pd is the patch that does most of the work, this needs to be opened in addition to the adj_netrecieve.pd as the two patches work together. It seems to work better when adj_netrecieve.pd is called first and then adj_netsend.pd but sthis could equally be down to circumstances.

The value box below netsend contains a zero and should always do so. The value above set the number or seems to at least of iterations with which the program adj_server.pl calls to the defined site for data. The value to the far right contains the number of the site being accessed for data valid range is between 1 - 73 the default is set to 14, you can only edit this value when PD patch adj_netsend.pd is in edit mode.

login or register to post comments