Sync iphone / ipod with Ubuntu 10.10 maverick meerkat

If you have Ubuntu and would ilke to sync your iphone without ITunes there is a solution from imobiledevice. Go ahead and run the code below and it will install all the packages necessary for you to be able to sync your iphone with Rhythmbox.
First run this:
$ sudo add-apt-repository ppa:pmcenery/ppa
$ sudo apt-get update
$ sudo apt-get upgrade

then run this:
$ sudo apt-get install gvfs gvfs-backends gvfs-bin gvfs-fuse libgvfscommon0 ifuse libgpod-dev libgpod-common libimobiledevice-utils libimobiledevice1 python-imobiledevice libplist++1 libplist-utils python-plist libusb-1.0-0 libusb-1.0-0-dev libusbmuxd1 usbmuxd nautilus-ideviceinfo

I had to reboot my computer before the changes took effect and I could sync successfully.
Some of you have gotten the error about not being able to mount their iphone – DBus error org.freedesktop.DBus.Error.NoReply: Message did not receive a reply (timeout by message bus). This is due to the new 4.2.1 firmware that Apple pushed out to the iPhone. Just make sure that the imobiledevice library that you install is 1.0.4 or later because that is the one that has support for it. If you followed the correct steps above you should have the newest version and everything should work right.

You can use Rhythmbox or gtkpod to sync your music to your Ipod/Iphone.

Stream audio to web with pulseaudio in Ubuntu 10.10

The other day I wanted to stream my new KORG Electribe MX online so that one of my friends could hear me play around with it. I looked everywhere for a solution but all the solutions out there seem to want to use Jack control which is low latency sound driver that a lot of people use for better sound quality. I just wanted to stream pulseaudio to the web because Ubuntu comes with pulseaudio installed and setup by default so it would be easiest for me. I figured out how to do it and just wanted to share it with all of you guys. I setup my Line in to stream on the web but any one of your sound devices can be used for these. You can even do multiple ones if you want to.

Here are the packages you will need for this. You can install these packages directly through the Ubuntu package manager so anyone can use these to set up and stream their sound. You do not have to be an expert.

These are the commands you have to run to install the required pacakges:
$ sudo apt-get install icecast2
$ sudo apt-get install gstreamer-tools
$ sudo apt-get install padevchooser
$ sudo apt-get install paman
$ sudo apt-get install pavucontrol

Icecast is the streaming server, gstreamer we use to stream to our icecast server and the last 3 packages are just interfaces to the pulseaudio soundcard which we will use to make our life easier.

Once you have these items installed you will have to edit the icecast2 configuration file which is at /etc/icecast2/icecast.xml and make sure you change the passwords under the section. Search in the file for them there is a lot of documentation in the file for that.
If you would like to change the port this server is running on go ahead and scroll down in this file and change it under . By default the port is 8000.

Once you do that you can start the icecast2 server by typing this command in the terminal:
$ /etc/init.d/icecast2 start
Congratulations you have a working streaming server!!! But we are not done. You need to stream something to it or it will just be sitting there doing nothing. How do we do this? This is a little more complicated but we do it using gstreamer. Gstreamer allows us to connect to this icecast2 server and forward any audio device we want.

Here is the command:
gst-launch pulsesrc device=alsa_input.pci-0000_00_10.1.analog-stereo ! audioconvert ! vorbisenc ! oggmux ! shout2send mount=/stream.ogg port=8000 password=password ip=localhost

I saved this into a script that i run anytime i want to stream my lineout. This command creates a recording device in the pulseaudio which takes whatever is in the linein and streams it to the icecast2 server.

Lets look at this command.
This specifies what device I want to stream to the web. In my case this is my linein device. This information is coming from the PulseAudio Manager. You can open this by typing in paman at command prompt. On the devices tab you will see all your device names there. If you look at the description on the right, one of them will say Loopback to Internal Audio Analog Stereo.

This is the stream path where your audio device will be streaming. If you leave it to stream.ogg, your stream address will be http://youraddress:8000/stream.ogg
This is the port where your icecast2 server is running on. If you changed that port from the default of 8000 you have to change it here also. If you have a different port the link to the streaming server will be http://youraddress:yourport
This is the password you setup in your icecast2 server. This is how you authenticate to the stream server.
This is the ip address for your stream server. If you are running it on the same machine as gstreamer then you can leave it to localhost.

And that is all folks!! If you have any questions about this post them below in a comment. I will answer them. It took me a while to get this going since a lot of people use different solutions including VLC and jack audio. I just wanted to keep it simple.

If you need to setup your line in which is not turned on by default in Ubuntu look at my article on setting up line in here.

KORG Electribe MX-1SD

Music is something that everyone has in their life. Music can make us happy when we are sad and bring out emotions and happy memories. Everyone has a favorite genre of music. Mine is electronic. I like to listen to all kinds of electronic music and I feel like theres a different kind for every kind of mood.
A couple weeks ago I was invited to go hang out with my some friends at a music studio. There I met some new people including this one guy Danny who is a music producer – Torkom. He created some music for us while we were hanging out. And I am seriously saying he was creating it there and then on the spot. How was he doing this? With a Korg EMX1 Electribe MX Music Production Station. I was amazed by this device as I never saw one of these before. What interested me was the fact that he could change the song and turn it into whatever he wanted at his whim. I wanted one instantly! I am trying to learn piano currently anyway so I thought this would be a fun addition. I bought one. It is a lot of fun to play with and you can make any kind of music and sounds that you want. I just started going through the users manual which I have been told is the best way to start learning it. What is great about it is that I can just plugin my headphones in the headphone port and play around with it anyway I want because nobody else has to hear it but me. I bought the Sennheiser HD555 Professional Headphones which are the best price to performance you can get. At a later time I will post more info as i get better at this. I will write about what made it easier for me to grasp it and explains of the more complicated things. Until then here are some pictures of it.

Ubuntu 10 pulseaudio line in pass through

Like some of you guys I just got rid of Windows 7 and installed Ubuntu. How do people choose from the multitude of distributions that are out there? Coming to a new operating system requires a lot of help and support with simple problems that have not been encountered in Windows. Ubuntu stands out when it comes to these because of their vast amount of support forums out there as well as the simple package manager ‘apt-get’ which allows you to install pretty much anything you can think of. The vast community keeps this package manager full with the latest software they can so that the end user can easily install it. If you do have questions when it comes to your install, Google is the universal place to search for answers.

Now lets get to the issue. I have an Korg Electribe MX which i wanted to plug in to my line in plug on my computer. What this allows me to do is play the sound from it through my computer into my headphones. This way  I do not have to switch my headphones back and fourth between my computer and this synthesizer. It seems though that Ubuntu 10 cannot do this out of the box since it is using the pulseaudio server. There is an option for this though.

First I recommend you install PulseAudio Volume control.
$ sudo apt-get install pavucontrol
This will give you access to your sound device volumes and settings. This is where you will be making your change.

PulseAudio does not allow the user to control their line in by default. For this to work you will have to install the loopback module. You can enable the loopback module directly by running the following command in your terminal:
$ pactl load-module module-loopback

To make the module automatically load in the future use the following command:
$ sudo sh -c ' echo "load-module module-loopback" >> /etc/pulse/ '

This will add the required information to your configuration files so that next time you start your computer the module will load again automatically.

Once you have this, open up the PulseAudio Volume Control and under the Recording tab you will be able to choose where you would like the output from line-in to go. Pick internal audio and you will now have sound coming from whatever you plug into it. Make sure that under the Configuration tab, the Internal Audio interface is set to Analog Stereo Duplex or something thats Duplex so it recognizes the line in as a device.
I noticed that the quality of the sound coming from my Korg Electribe is not as great as when I am plugged in directly to it. The convenience outweighs the sound quality right now. If there are any questions post your question in the comment section below.