Piper

Pin numbering for Python on the Raspberry Pi header

I am trying to understand the numbering system for the GPIO pins on the rPi header.

One is the sequential numbering systems used in the piper play programming. It numbers pins from 1-20, then 21-40 on the two rows of pins, as shown in the Electronics tab of the editor.

Another is the alternating numbering, that runs right to left, with the even numbers closest to you as piper sits in his box. There is a diagram in Pi GPIO pin numbering . This was confusing as the topic said that this the system that the piper uses.

Another is the GPIO# system where the pins are named, but are not in any order on the header. I’ve read that this is hardware independent, so you can change chips(rPi 2 to rPi 3) and you program still works.

I spent several days trying to figure out pin numbers when I started using the Piper Play program. I finally saw the Electronics tab(moral of the story: Look at EVERYTHING)

Now I am wondering, if I try to write some python programs, which pin names/numbers should I be using, and what libraries are provided with Python.

Thanks for your help.

See my statement in your other thread. If you are writting Python programs use the standard numbering, but the pin number does NOT match the GPIO number, for example GPIO2 is Pin number 3 (not the current PiperCode numbering but the standard numbering)
The standard numbering is the same on all Pi’s Pi 2, Pi 3 Pi zero w, etc. There were some Pi’s made a long time ago (in computer years) that only had 26 pins.