amateurasu wrote:Wow. I had the same problem. Altering the code to use 27 instead of 21 worked, but man... I hope there was a good reason for changing the GPIOs between revisions and throwing this kind of monkey wrench into coding for RPi.
The foundation had a good reason for it - it's all to do with the new camera module AIUI. Note also that the I2C pins have changed - if you used them for GPIO: 0 & 1 are now 2 & 3.
My solution is to use wiringPi (but would say that as I wrote it
as the pin numbers I chose stay constant between Pi board revisions.
But no one solution seems to be ideal though - it's just something that we need to be aware of and work round.