Mapping of G pins and P pin on Exp. Board v3



  • The Exp. Board v3 spec sheet shows GPIO mapping, which I suspect is wrong. The board itself shows G mapping.... Where on earth is the mapping between the P pins and the G pins?? If i used WiPy Spec sheet there is a mapping between ESP32 GPIO and P pins...Nothiing about G pins though. How are you supposed to know where the P pins are on Exp Board v3 ??
    Thx



  • @mci For coding the content of the pins.csv file is effective, because that file is used for mapping the Pxx and Gxx numbers to the GPIO port numbers,



  • @robert-hh My board has G18 on the silkscreen and no G17 - I realise it doesn't align with the docs, but I was assuming the docs (which don't show the actual silkscreen) failed to align with the hardware. It may only be certain batches of the expansion board v3 that have this mismatch though...



  • @mci Thanks. Some copy & paste errors. But I do not agree about P10/G17. That matches my Board and the code based mapping table e.g. here: https://github.com/pycom/pycom-micropython-sigfox/blob/Dev/esp32/boards/WIPY/pins.csv

    P-Number G-Number GPIO
    P0 G2 GPIO3
    P1 G1 GPIO1
    P2 G23 GPIO0
    P3 G24 GPIO4
    P4 G11 GPIO15
    P5 G12 GPIO5
    P6 G13 GPIO27
    P7 G14 GPIO19
    P8 G15 GPIO2
    P9 G16 GPIO12
    P10 G17 GPIO13
    P11 G22 GPIO22
    P12 G28 GPIO21
    P13 G5 GPIO36
    P14 G4 GPIO37
    P15 G0 GPIO38
    P16 G3 GPIO39
    P17 G31 GPIO35
    P18 G30 GPIO34
    P19 G6 GPIO32
    P20 G7 GPIO33
    P21 G8 GPIO26
    P22 G9 GPIO25
    P23 G10 GPIO14

    P.S.: I do not know why I made the table by hand, when it existed (and I knew it before) in the code base.



  • @robert-hh A few corrections to the table:
    P1=G1=GPIO1
    P10=G18=GPIO13
    P19=G6=GPIO32
    P21=G8=GPIO26
    P23=G10=GPIO14



  • @trojanc I'm not from Pycom, so no reason to excuse. The G-Numbers are printed on the expansion boards. And the mapping between P-, G- and GPIO numbers is the same for all PyCom devices.
    I prefer to use the P-Numbers, because it is easy to count along the edges. They resemble the Pin numbers of DIL packages. The G-Numbers are kind of 'historic' from the times before PyCom. For the old WiPy1 device, the G-Numbers were identical to the GPIO numbers. But that device is not on sale any more, and PyCom never sold them. So it was kind of nonsense to carry over the G-Numbers to new expansion boards.



  • @robert-hh
    Thank you, this is usefull (though still painful)

    Can someone from Pycom please update the documentation with the proper images so that we don't need mapping tables like this... I'd contribute an update if there is source files for the image I can edit... The P-number and GPIO would be handy ;)

    For the others wonder how to read the table:
    The P-number is the real number you can use (e.g.

    pin = Pin('P10')
    

    G-Number is the incorrect number as displayed on the Expansion board documentation.
    GPIO is the GPIO number of the actual device (not the incorrect GPIO on docs)

    (Sorry @robert-hh if you are from Pycom, the forum doesn't make it obvious who are offical members...)



  • @trojanc Just an attempt for a mapping, created from existing documentation:

    P-Number G-Number GPIO
    P0 G2 GPIO3
    P1 G2 GPIO1
    P2 G23 GPIO0
    P3 G24 GPIO4
    P4 G11 GPIO15
    P5 G12 GPIO5
    P6 G13 GPIO27
    P7 G14 GPIO19
    P8 G15 GPIO2
    P9 G16 GPIO12
    P10 G17 GPIO13
    P11 G22 GPIO22
    P12 G28 GPIO21
    P13 G5 GPIO36
    P14 G4 GPIO37
    P15 G0 GPIO38
    P16 G3 GPIO39
    P17 G31 GPIO35
    P18 G30 GPIO34
    P19 G5 GPIO32
    P20 G7 GPIO33
    P21 G8 GPIO25
    P22 G9 GPIO25
    P23 G10 GPIO4


  • @dan said in Mapping of G pins and P pin on Exp. Board v3:

    @ldbm This is a known issue, we're working on a revised pinout sheet. You can follow the WiPy's pinout sheet instead of the expansion board's.

    Hi @dan is there a place where we can get the updated docs with proper port mappings for the V3 expansion board?
    The docs here https://docs.pycom.io/datasheets/boards/expansion3/ still have GPIO Pins that doesn't help anything for new boards like Lopy4, and the attached PDF https://docs.pycom.io/gitbook/assets/expansion3-pinout.pdf contains even more confusing information. I has 1M voltage divider instead of the 115k/56k as the documentation page, and the PDF has a photograph that seems to be missing the labels.



  • Thx @robert-hh !



  • @ldbm You have to match G and P numbers by the position. But Pycom could add a mapping table to the documentation. The Pinout of the Development modules show both the Pxx numbers and the GPIO numbers. The Pinout of the expansion board 2 and the printing on the board itself show the G numbers. These are the GPIO numbers of the WiPy1 module, which is out of sale. And for expansion board 3, these are not relevant any more, since the socket does not fit. So Pycom could drop the G numbers alltogether.
    And yes, the Pinout in the Docs for the expansion board is wrong. It tells GPIOxx instead of Gxx.



  • Hi @dan , that 's what we did but we could not match the ESP32 GPIO with the G number on the board. An older google search on Exp Board v2 instead showed some mapping P pin / G Pin that seem to work for finding UART 1 in this case, but generally speaking how do you match P and G pins ?



  • @ldbm This is a known issue, we're working on a revised pinout sheet. You can follow the WiPy's pinout sheet instead of the expansion board's.



Pycom on Twitter