[raspberry-vi] Re: GPIO Pin-outs

  • From: "Jonathan Horniblow (Talking Newspaper Services)" <jonathan@xxxxxxxxxxxxxxxxxxxxxxxx>
  • To: raspberry-vi@xxxxxxxxxxxxx
  • Date: Sat, 16 Mar 2013 20:53:13 +0000

In addition to Michael's excellent reference, it might be worth noting
that the python RPi.GPIO library can use "real" pin numbering rather
than the ridiculous, confusing and potentially damaging BCM numbering
where you need to keep referring to a lookup table.

https://code.google.com/p/raspberry-gpio-python/

There are versions for python 3 and 2, but it should be as easy as:

sudo apt-get update
sudo apt-get install python-dev python-rpi.gpio

and then in your python script

import RPi.GPIO as GPIO
GPIO.setmode(GPIO.BOARD)
GPIO.setup(12, GPIO.OUT, initial=GPIO.HIGH)

And you'll have a HIGH on pin 12. Actual real physical pin 12 that you
can feel along to, not some bizarre alternative you need to lookup on
a table.

It's as easy as that - it can also do edge detection, input detection
and all sorts. Read the docs.

While I'm here, I don't know how accessible is it, but the Adafruit
WebIDE rocks! Anyone tried it?
http://learn.adafruit.com/webide/overview


On Sat, Mar 16, 2013 at 8:31 PM, Michael A. Ray <mike.ray@xxxxxxxxxxxxxx> wrote:
>
>
> Hello list,
>
> I did say I wasn't going to do this specifically and that I wasn't going
> to duplicate content to be found on the Foundation web-site or elinux.
>
> But after a frustrating search for the data, and after finding several
> conflicting entries, and the usual frustration associated with finding
> numerous posts that say stuff like 'look at this diagram', I have put a
> page on our wiki that details the pin-outs of the Raspi GPIO bus:
>
> http://www.raspberryvi.org/wiki/doku.php/gpio
>
> Please note the bit on the page that says it aint my fault if you blow
> up your Raspi, or your house.
>
> I have checked and double and triple checked the entries in the two
> tables and they are, as far as I can find, correct.  I even checked
> against a posting from the Foundation forums from one of the RPI team in
> response to my appeal for help.
>
> Every time I type 'the Foundation' I get  a mental image of Darth Vader
> clutching a Raspi.  I need to get out more.
>
> Mike
>
>
>
> --
> Michael A. Ray
>
> Analyst/Programmer
> Witley, Surrey, South-east UK
>
> github username: cromarty
> raspberrypi.org username: cromarty
> Ham Radio Call-sign: G4XBF, licensed since 1982
>
> 'Entia non sunt multiplicanda praeter necessitatem' - Ockham's razor
>
>
> Raspberry VI:
> http://www.raspberryvi.org/
> NVDA, the best free screen-reader in the world:
> http://www.nvda-project.org/
>
>
>
>
> ===========================================================
> The raspberry-vi mailing list
> Archives: //www.freelists.org/archives/raspberry-vi
> Administrative contact: <mike.ray@xxxxxxxxxxxxxx>
> -----------------------------------------------------------
> Raspberry Pi and the Raspberry Pi logo are trademarks of the Raspberry Pi 
> Foundation.
>
> This list is not affiliated to the Raspberry Pi Foundation and the views and 
> attitudes expressed by the subscribers to this list do not reflect those of 
> the Foundation.
>
> Mike Ray, list creator, January 2013
>
=========================================================== 
The raspberry-vi mailing list 
Archives: //www.freelists.org/archives/raspberry-vi
Administrative contact: <mike.ray@xxxxxxxxxxxxxx>
-----------------------------------------------------------
Raspberry Pi and the Raspberry Pi logo are trademarks of the Raspberry Pi 
Foundation.

This list is not affiliated to the Raspberry Pi Foundation and the views and 
attitudes expressed by the subscribers to this list do not reflect those of the 
Foundation.

Mike Ray, list creator, January 2013

Other related posts: