angelofraietta
Posts: 3
Joined: Mon Jul 16, 2018 1:34 am

Difference between GPIO_GEN and GPIO

Mon Aug 13, 2018 1:09 am

Greetings

What is the difference between GPIO_GEN outputs and GPIO outputs

EG, if I look at image
https://myelectronicslab.com/raspberry- ... ck-pinout/
Eg, GPIO2 is on pin3, but GPIO_GEN2 is the same as GPIO27 on pin13

What is the purpose of the different names and what are the limitations / features of the difference.

Thanks

wildfire
Posts: 396
Joined: Sat Sep 03, 2016 10:39 am
Location: Dundee, Scotland

Re: Difference between GPIO_GEN and GPIO

Mon Aug 13, 2018 2:51 am

angelofraietta wrote:
Mon Aug 13, 2018 1:09 am

What is the purpose of the different names
Perhaps to add clarification, though as you discovered it only adds confusion.
and what are the limitations / features of the difference.
No difference and limitations are the same.
Scotty never said "I canae give her any more Captain, She'll blow".
B'Elanna Torres however did say "Get the cheese to the sickbay" :?:

User avatar
Burngate
Posts: 5441
Joined: Thu Sep 29, 2011 4:34 pm
Location: Berkshire UK
Contact: Website

Re: Difference between GPIO_GEN and GPIO

Mon Aug 13, 2018 8:44 am

The origin of your confusion is basically historical

Deep in the dark and distant past, the designers of the first Pi were trying to make things simple for a first-time user.
So they arranged for several busses to be broken out to a 26-way connector - an I2C bus, an SPI bus, and a UART - and, because there were extra pins available, also brought out seven more general-purpose signals and named them GEN0 to GEN6. Nice and straight forward, with the internal translation hidden from the user.

But they also produced a schematic for the Pi, which revealed that all those busses and those seven signals came from a 32-way interface, and they each had a number from 0 to 31, unrelated to what they were called.
What's more, everyone asked "Please sir, may I have More?"

So they got More - 11 more, on a larger 40-way connector.

Two of them are still "hidden" - pins 27 & 28 (GPIO0 & GPIO1, configured as an I2C bus using ALT 0) are called ID_SD and ID_SC, and it's Forbidden To Use Them For Anything.

But the underlying numbering is still available, and all of GPIO0 to GPIO27 can be used however you like (28 to 31 aren't broken out, and there's another bank, GPIOs 32 to 53, that carry things like SD card access. There's also a GPIO expander that allows even more wierd things to happen)
Most of them have built-in alternative functions, ALT 0 to ALT 5, which is how they created those original busses. But they're still just general-purpose IO at heart.

Return to “General discussion”

Who is online

Users browsing this forum: No registered users and 41 guests