So the New Raspberry Pi 2 Model B was released this week. I managed to get hold of one on the Monday and then spent the whole evening playing around with it.
It is true that the pinouts are identical to the Model B+ and A+ but this doesn't mean that in these first few day of release getting the GPIO running is plane sailing.
My first port of call was Python and RPi.GPIO so opened Python tapped in
import RPi.GPIO as GPIO
and was greeted with this message.
This could pose a problem. Thinking that a small update is probably required I decided that an
sudo apt-get install python-rpi.gpio
was in order to make sure I was up with the latest version.
Here's The SolutionDownload the new version from Source Forge with:
wget http://sourceforge.net/projects/raspberry-gpio-python/files/raspbian-wheezy/python-rpi.gpio_0.5.9-1_armhf.deband install it using:
sudo dpkg -i python-rpi.gpio_0.5.9-1_armhf.deb
This should bring you joy.
Hope this helps anyone wanting to get the GPIO running.