Skip to content

Portenta H7: Pin Table - How complete should it be? Compatible with MBED version? #68

Closed
@KurtE

Description

@KurtE

@pillo79 @facchinm @mjs513 and all:

We are starting to play with the Portenta H7. I have one of the H7 and one of the H7 lite processors and a breakout board and a Hat Carrier.
Starting to go through some of the basic testing. Earlier when I played with it using MBED, I added pages to my GIGA pin out excel document:
https://github.com/KurtE/Arduino_GIGA-stuff/blob/main/Documents/Arduino_GIGA_R1_pins.xlsx
Which still needs to be cleaned up.

It looks like the current state of the pin table in the overlay is pretty limited:

		digital-pin-gpios = <&gpioh 15 GPIO_ACTIVE_LOW>,
				    <&gpiok 1 GPIO_ACTIVE_LOW>,
				    <&gpioj 11 GPIO_ACTIVE_LOW>,
				    <&gpiog 7 GPIO_ACTIVE_LOW>,
				    <&gpioc 7 GPIO_ACTIVE_LOW>,
				    <&gpioc 6 GPIO_ACTIVE_LOW>,
				    <&gpioa 8 GPIO_ACTIVE_LOW>,
				    <&gpioi 0 GPIO_ACTIVE_LOW>,
				    <&gpioc 3 GPIO_ACTIVE_LOW>,
				    <&gpioi 1 GPIO_ACTIVE_LOW>,
				    <&gpioc 2 GPIO_ACTIVE_LOW>,
				    <&gpioh 8 GPIO_ACTIVE_LOW>,
				    <&gpioh 7 GPIO_ACTIVE_LOW>,
				    <&gpioa 10 GPIO_ACTIVE_LOW>,
				    <&gpioa 9 GPIO_ACTIVE_LOW>,
					<&gpiok 5 GPIO_ACTIVE_LOW>;	// LEDR

Which does align with the MBED version for D0-D14, however LEDR on MBED is something like pin 23 and here currently pin 15.
On MBED the table looks like:

PinDescription g_APinDescription[] = {
  // D0 - D7
  { PH_15,        NULL, NULL, NULL },    // D0
  { PK_1,         NULL, NULL, NULL },    // D1
  { PJ_11,        NULL, NULL, NULL },    // D2
  { PG_7,         NULL, NULL, NULL },    // D3
  { PC_7,         NULL, NULL, NULL },    // D4
  { PC_6,         NULL, NULL, NULL },    // D5
  { PA_8,         NULL, NULL, NULL },    // D6
  { PI_0,         NULL, NULL, NULL },    // D7

  // D8 - D14
  { PC_3,         NULL, NULL, NULL },    // D8
  { PI_1,         NULL, NULL, NULL },    // D9
  { PC_2,         NULL, NULL, NULL },    // D10
  { PH_8,         NULL, NULL, NULL },    // D11
  { PH_7,         NULL, NULL, NULL },    // D12
  { PA_10,        NULL, NULL, NULL },    // D13
  { PA_9,         NULL, NULL, NULL },    // D14

  // A0 - A6
  { PA_0C,        NULL, NULL, NULL },    // A0    ADC2_INP0
  { PA_1C,        NULL, NULL, NULL },    // A1    ADC2_INP1
  { PC_2C,        NULL, NULL, NULL },    // A2    ADC3_INP0
  { PC_3C,        NULL, NULL, NULL },    // A3    ADC3_INP1
  { PC_2_ALT0,    NULL, NULL, NULL },    // A4    ADC1_INP12
  { PC_3_ALT0,    NULL, NULL, NULL },    // A5    ADC1_INP13
  { PA_4,         NULL, NULL, NULL },    // A6    ADC1_INP18
  { PA_6,         NULL, NULL, NULL },    // A7    ADC1_INP7

  // LEDS
  { PK_5,         NULL, NULL, NULL },    // LEDR
  { PK_6,         NULL, NULL, NULL },    // LEDG
  { PK_7,         NULL, NULL, NULL },    // LEDB

  { PA_0,         NULL, NULL, NULL },
  { PA_1,         NULL, NULL, NULL },
  { PA_2,         NULL, NULL, NULL },
  { PA_3,         NULL, NULL, NULL },
  { PA_4,         NULL, NULL, NULL },
  { PA_5,         NULL, NULL, NULL },
  { PA_6,         NULL, NULL, NULL },
  { PA_7,         NULL, NULL, NULL },
  { PA_8,         NULL, NULL, NULL },
  { PA_9,         NULL, NULL, NULL },
  { PA_10,        NULL, NULL, NULL },
  { PA_11,        NULL, NULL, NULL },
  { PA_12,        NULL, NULL, NULL },
  { PA_13,        NULL, NULL, NULL },
  { PA_14,        NULL, NULL, NULL },
  { PA_15,        NULL, NULL, NULL },
  { PB_0,         NULL, NULL, NULL },
...
  { PK_5,         NULL, NULL, NULL },
  { PK_6,         NULL, NULL, NULL },
  { PK_7,         NULL, NULL, NULL },
};

Where you have pins PA_0-15, PB_0-15... PJ_0-15, PK_0-7

Which obviously some of these pins point to other pins with the same underlying hardware pin...
Some probably do not connect up to anything.  
If I print out number of digital pins and count of pins I see:

NUM_DIGITAL_PINS: 22
PINS_COUNT: 194

So main questions include:
a) Should the pin out match the MBED version?
b) My assumption is that all of the pins that could be used for digital stuff that are exported through the connectors should have a pin number assigned to them. For example you have several of the UARTS defined which is great, but I would also expect that for those uarts that a sketch does not utilize, I could use the RX and TX and on some of them RTS and CTS pins, as normal IO pins.

Thoughts?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions