How to be a linux DJ on a short notice

I was given a very short notice (~48 hours) to become a DJ for a party. Here I am writing a blog post about how to do it the night before. Since I am a linux user, I had to find a way to do this on linux.

Considering how busy I am with my doctoral work and research, I had to find some quick solutions. Fortunately, the machinery to do this sort of stuff already exists and I wrote some notes about it. Sharing it to all of you here.

Getting the playlist

I need to first download my spotify playlist. Going to use spotDL

https://github.com/spotDL/spotify-downloader

Did the following in ~/useful_scripts

git clone https://github.com/spotDL/spotify-downloader

Wrong move!

Should have done

python3 -m pip  install spotdl

Then, it could be run by the following command for example

python3 -m spotdl --version

Then

cd ~/Downloads
mkdir dj_songs && cd dj_songs
python3 -m spotdl [[my_spotify_playlist_url]]]

Alrighty! Quite an impressive script. Some of the lookups failed though, but I hope that will not be such a big problem.

But I wanted better sound quality than this. Let’s think about it a bit later

Using mixxx

I just did a

sudo apt install mixxx

on my Ubuntu and I had it with me.

It’s on. Asked me to configure audio devices and asked for a library. I think I figured it out.

It’s so confusing! There are so many knobs and buttons. This is exactly the nightmare I was afraid of. After fidling with it a bit, I think I figured it out though.

The way to do it is to first right-click a song in the library, load it into Deck 1 and play it. Take the central knob all the way to the left. While that song is playing, load up another one on the right. Play it, switch the slider to the left and then while the second is playing you pause the first one.

It’s basically a game of juggling. It’s a good idea to sort your songs by BPM (beats per minute) and increase the BPM thoughout the DJ performance. Keep the fast paced songs in the end. While switching songs, it seems more natural to transition to songs of roughly the same BPM.

The interface has the nice feature that it doesn’t let you load a track into a deck that’s already playing. But make sure to check which deck is being played before pausing the deck!

Using youtube premium for better sound quality

As it says in the docs, you need a cookie.txt file. For this, you can use the Firefox extenstion available

https://addons.mozilla.org/en-US/firefox/addon/cookies-txt/

You can login to your youtube-premium account and get 256kbps bitrate instead of 128kbps.

Conclusion

So this is it, in a nutshell! I’ll write a bit more when the party ends.

Edit:

So the party went well. One drawback was that I could not add songs on the fly. Some people requested Pathaan songs and I really didn’t have a system that could put songs on demand.

I’m sure that could also have been done on the fly with some nifty terminal scripts. I’ll be prepared for this if I’m a DJ again.