Case Study: Using Jamulus to Play With Other Musicians Over The Internet In Real Time

About This Document

This document was written by Chris Timson, a musician based in Bath and is based on his experiences rehearsing and playing with other folk musicians. It was originally published in Sound on Sound, June 2020. We are grateful to Sound on Sound for their permission to republish the article.

Background

Many members of morris may well have tried to dance to music played over the Internet and musicians may have tried to play tunes – and encountered problems due to the technical challenges which are particularly problematic for audio.

There are possible solutions with one approach – based on the open source Jamulus software – described in this document. However you should note that this isn’t simply a question of installing a piece of software: rather there will be a need to have an understanding of Internet networking technologies and to have a good network connection.

We hope this document will be of use to sides, especially if you have a IT expert in your side who is able to understand the issues and implement the software in a way which works for your musicians.

The Context

Latency

Anyone concerned with trying to create live music over the internet will have become very familiar with that word. As I explain in my article How to Make Zoom Work for Music (Sound on Sound, June 2020) latency is like death and taxes, you can minimise it but you can’t avoid it completely and normally it defeats attempts to play live together. As anyone who has tried it with the various video conferencing applications like Zoom and Teams will know it results in everyone being out of time with everyone else with consequent cacophony!

So you may be as surprised as I was to learn there are a small number of applications where the developers refuse to admit defeat on this and are determined to allow musicians to play together live across the net. Among these are JamKazam, Soundjack and the subject of this article, Jamulus.

Environment

The first thing to note about all of these applications is they all set quite a high bar on the environment in order to ensure the only source of latency they have to deal with is the internet itself. You have to watch out for the following factors:

Hardware: A powerful computer is always nice to have but these apps don’t put too much demand on on the host machine. Any decent computer from the last few years should do fine. For Jamulus Windows, Mac and Linux are all good. Tablets and phones, unfortunately, are right out!

A separate audio interface is a necessity and needs to provide a low latency connection to the computer. In our own usage UAD’s Apollo hardware worked well while a Blue Icicle XLR-USB adapter wasn’t so effective, adding pops and clicks to the sound that is one of the hallmarks of inadequate latency. For Windows Jamulus recommend an AI with a native ASIO driver. Decent microphones to plug into the interface give the best sound, obviously, and are well worth having.

Ethernet: You need a fast internet connection. Jamulus specify a minimum of 1 Mbps both up and downstream, but faster is better and a low ping time essential. Jamulus recommend the ping time to the Jamulus server (see below) should be no more than 40 ms and the lower the very much better.

All the applications make the same recommendation with regard to Wi-Fi, and that is simply not to use it. You must set up a wired ethernet connection between your router and computer.  They don’t mention Homeplug and other powerline solutions but I would be inclined to avoid them too if you possibly can.

Distance: That is, geographical distance between the participants. More on this below but it is very important to be as close as possible, geographically speaking.

Headphones: You need them. Jamulus doesn’t screen out sound from your mic the way that, say, Zoom does so your speakers must be off or otherwise you’re heading for feedback big time.

Much of this might not be available to the average person but is likely meat-and-drink to the readers of this esteemed magazine.

Free & Easy

And so to the application itself. Jamulus is an open source product developed under the GNU General Public License and as befits such software to use it you don’t need to create an account with anybody! The way they achieve this is ingenious. The application has two parts: a server and a client. In order to work a client has to attach to a server. It sends sound to the server and plays the sound it receives from the server. A server is a very simple beast in that any sound received by the server from any attached client is bounced out to all attached clients.

Of course there’s a little bit more to it than that and we’ll talk about the mixing the server performs later but you’ll see immediately that with a public server the idea of a private session is not possible. So connecting to a public server is fine if you’re looking for a jam session to join in with and like the idea of jamming with strangers, and indeed a lot of people use Jamulus for exactly that, but if what you want is to have a quiet little rehearsal with the rest of your band then it’s not going to cut the mustard. The solution Jamulus have come up with is quite elegant and known as the private server. How this is achieved is another thing we’ll be looking at later.

Jamulus Client

First we’ll talk about the client and how you install and set it up. An installer can be downloaded from the Jamulus website. On Windows it will install both Jamulus client and Jamulus server; on the Mac you’re offered a choice. You will always need the client but the server only if you are intending to run one. After installation start the client and you get a screen like this:

Figure 1: Jamulus client

This is pretty spartan so you need to click on the Settings button on the lower left hand side. This then gives you the Settings screen where lots of interesting stuff lives:

Figure 2 Jamulus settings menu

You can see I’ve set this up to use with my UAD Apollo.  This is on a Mac; if you’re setting up on a Windows machine then you’ll need to specify the ASIO driver – as mentioned above a native ASIO driver is much preferable. Jamulus permits two mic inputs per client but as I’m using only one mic I’ve set both channels to it. I set the outputs appropriately and that’s just about all the setup I did, all the other settings I left at default. There’s a Profile page tucked away in the menus that you can use to provide a name for yourself and an instrument you play, which is useful for ID purposes but by no means mandatory. Incidentally Jamulus requires that you turn direct monitoring off for your mics in your audio interface.

To make Jamulus actually do anything you must connect to a server, so click on the Connect button and you’ll see something like this:

Figure 3 Jamulus Connect interface

This is showing a list of public servers organised by latency with respect to you. You can see that at the time I was connecting (a Sunday morning) there weren’t too many musicians around but a couple of servers had people waiting for others to play with. Once you’ve connected to a server the appearance of the client suddenly gets richer. There’s a fader for each participant including yourself so that you can mix a balance for yourself to hear in your headphones. Note that the mix is actually performed by the server which sends the resulting stereo mix down the line to you. Were the mix to be made at the client end then each client stream would need to be sent to you requiring lots more data and potential for the streams to get out of step.

Figure 4 Jamulus ‘Mix’ interface

Now you can start playing!

Pass The Port

So you’ve had a good session but now you want a rehearsal with your band. Obviously you can’t use a public server for this because anybody could gatecrash your rehearsal. The answer is for one member of the band to install a private server. Running a private server is trivially easy (you just click on it and away it goes) except for one thing. If you’ve started the server running on a computer on your own network then it will be inside the firewall which should be running on your router. This means anybody outside your firewall (e.g. your bandmates) won’t be able to access the server. You need (imagine some spooky and threatening music here) to open a port in your firewall. Now that’s not nearly as bad as it sounds but it does need careful explaining. 

To most people the idea of opening a port in the firewall feels tantamount to opening the front door of your house and posting a sign saying: come in and help yourself! It’s nothing like as bad as that. An open port is not a risk as such, and indeed there are quite a few ports open already in every firewall. There has to be as otherwise the internet simply would not work. Port 25 is open for email transmission, for instance and port 80 for Hypertext Transfer Protocol which makes the World Wide Web work.

The Bad Guys are interested in open ports because whatever process of yours is running on the inside of the port receiving data through it (“listening” as they say) may have bugs or otherwise be vulnerable to attack. If there is no process running on the inside to receive data the operating system simply throws away any incoming packets (including any sent by a hacker). That is, an open port is not like an open window. You can’t just peer through. I only run the Jamulus server as a foreground application and close it down when playing has finished so it’s not listening for very long and nothing else uses that port.

As a private server Jamulus listens on UDP port 21224. On your router you need to open that port and set it to forward to the IP address of your computer on your own network – if that changes from time to time (e.g. you’re using DHCP) just set it to forward to all. Each router is different in how you do this; here’s a picture taken from the Jamulus website that shows the task being performed on a Linksys router where it’s called Port Forwarding:

Figure 5 Port Forwarding on a Linksys router

And here’s the same thing on my Draytek router where it’s called Port Redirection and is lurking behind the NAT menu.

Figure 6 Port Redirection on a Draytek router

Apart from a little research to find out how to do port opening on your router it’s not difficult and it’s not particularly risky.

Once you’ve got your private server running then you need to inform your bandmates of your public IP address on the internet (if you need to find this out then use the website http://ip4.me. It’s quick, free and ad-free). When you and your bandmates start their Jamulus clients and click on Connect you all ignore the list of public servers and in the box down the bottom labelled Server Name/Address you type that public IP address and click on Connect. Everything else being equal you will hear your bandmates in your headphones and you can get on with your rehearsal.

Geography

In our own band rehearsals two of us are in the same building and the third is just 10 miles away. We do have a little latency, just enough to notice like a very, very short delay and the odd pop or click but in the main we are able to practice our songs quite successfully. To get some idea of the impact of distance on latency I arranged a Jamulus session with friend and studio owner Bob Bickerton in New Zealand (10am here, 9pm there). Bob had no problems setting up the Jamulus client or connecting to my private server. However his latency was of the order of 3-400 ms. I don’t know if you’ve ever tried talking with your voice sounding in your headphones only delayed by one third of a second but it’s next to impossible. So then we tried connecting to a public server that was geographically almost exactly midway between us (in Japan). Here we both had latency of getting on for 200 ms. Conversation was just possible but playing music wouldn’t have been so we didn’t try. One slightly strange effect we noticed was that any changes we made to the mix were also delayed by latency. Hence on the high latency servers changes were delayed in a manner quite disorientating until we realised what was going on. This is due to the fact that the Personal Mix faders affect the mix at the server rather than at the client end.

Interestingly, a couple of times while we were connected other people connected and then disconnected in a few seconds. Clearly people connect to public servers and then if what they hear isn’t what they’re looking for they drop out quickly. This sounds like good etiquette.

So playing sessions with friends the other side of the planet isn’t here – yet.

Conclusions

Jamulus strikes me as a well thought out tool for making music across the internet but the great beast Latency is not thereby totally defeated and there is a definite element of luck in whether it works out for you. Having said that, if you can put your hands on the hardware necessary then do give it a go.

I have not covered all the settings available for tweaking (see the Jamulus documentation for more information on that), it’s hedged around with significant requirements and geographical restrictions but with a little bit of luck and a following wind you can play music in real time with other musicians across the internet.

Jamulus cost: free

Download Jamulus here:   https://sourceforge.net/projects/llcon/

Find Jamulus documentation here: https://github.com/corrados/jamulus/blob/master/src/res/homepage/manual.md


Status of this Document

Document published: 7 Oct 2021

About the Author

Chris Timson has been a longsword and rapper sword dancer with East Saxon Sword, a musician with Mr Wilkins’ Shilling clog morris and nowadays a member of the close harmony folk group Eagle Alley. He also leads English music sessions in Bath and Bradford on Avon and has a recording studio – Mr Punch’s Studio.

Licence for this Document

This document was originally published in Sound on Sound, June 2020.


Nov 06
4:00 pm - 5:30 pm
Talk - "Considering Morris Dance Costumes as English National Dress" - Chloe Middleton-Metcalfe (LIVE on Zoom)
Nov 07
11:00 am - 3:30 pm
Workshop - Whitby Toesday Hornpipe Clog Routine for Beginners & Intermediates - Melanie Barber (LIVE on Zoom)
Nov 14
5:00 pm - 6:30 pm
Talk - "A History of Mumming" - Stephen Rowley (LIVE on Zoom)
Dec 04
4:00 pm - 5:30 pm
Talk - "Coconut Dancing – more than just a Lancashire tradition” - Peter Bearon (LIVE on Zoom)
Dec 11
4:00 pm - 5:30 pm
Talk - "Morris Dolls in the Museum of British Folklore" - Simon Costin (LIVE on Zoom)
Dec 12
4:00 pm - 5:30 pm
Talk - "Straw Bear - 40 Years of Straw & String" - Brian Kell (LIVE on Zoom)
Apr 09
10:00 am - 5:00 pm
Joint Morris Organisations' Day of Dance 2022
Sep 24
All day
Morris Federation Day of Dance and AGM 2022

Don't miss out

Get The Morris Federation's News

Subscribe for news about The Morris Federation and morris related activities. Available for all.