@SR61, glad you got it working for you...
With the card I posted it is always fun to figure out what subset of the information to post. Example this is from another tab in the same excel document, for thos pins:
Code:
SD Pins - Cable connector(T4 34-39)
42 SD_B0_03 2.15 Serial5(8) RTS SPI2(1) MISO PWM1_B1 IO-07 DATA1
43 SD_B0_02 3.14 Serial5(8) CTS SPI2(1) MOSI PWM1_A1 IO-06 DATA0
44 SD_B0_01 3.13 Wire1(3) SDA SPI2(1) CS0 PWM1_B0 IO-05 CLK
45 SD_B0_00 3.12 Wire1(3) SCL SPI2(1) SCK PWM1_A0 IO-04 CMD
46 SD_B0_05 3.17 Serial5(8) RX FLEXSPI B_DQS PWM1_B2 IO-09 DATA3
47 SD_B0_04 3.16 Serial5(8) TX FLEXSPI B_SSO_B PWM1_A2 IO-08 DATA2
Bottom Memory Connectors
48 EMC_24 4:24 Serial8(5) RX FLEXSPI2_A_SS0_B PWM1_B0
49 EMC_27 4:27 Serial8(5) RTS FLEXSPI2_A_DATA01, SPI2(1) SCK PWM1_A2 1:13
50 EMC_28 4:28 Serial8(5) CTS FLEXSPI2_A_DATA02, SPI2(1) MOSI PWM1_B2 1:14
51 EMC_22 4:22 Wire1(3) SCL FLEXSPI2_A_SS1_B PWM3_B3, QT2_3
52 EMC_26 4:26 Serial1(6) RX FLEXSPI2_A_DATA00 PWM1_B1 1:12
53 EMC_25 4:25 Serial1(6) TX FLEXSPI2_A_SCLK PWM1_A1
54 EMC_29 4:29 Serial1(6) RTS FLEXSPI2_A_DATA03, SPI2(1) MISO PWM3_A0 1:15
The fun thing here is there are two completely different SPI systems involved on these pins.
That is These pins are setup to use FLexSPI subsystem: Chapter 26 of the IMXRT1060RM.pdf file. Which after reading it a few times, I think I need to read it several more times before it makes total sense. So in the above these pins are setup to use FlexSPI2 object and you see all of these pins have roles in the FlexSPI2. As you mentioned pin 51 can be configured for FLEXSPI2_A_SS1_B which is a form of chip select...
Note @Paul added code into the core files (startup.c) which automatically tries to configure these pins into SPI2 and detect if there is a PSRAM installed and is then part of the addressable memory space.
But in addition, if you are not using it to have a PSRAM or Flash each of these pins can be configured for other things including what most of us think of as SPI which is the LPSPI subsystem, which is what I am showing in the Card view.. That is it is using the underlying object LPSPI1 which in the SPI library is the SPI2 object. In the above table you will also see that the pins in the SDCard can also be configured as SPI2 pins....
If you want even more of the gory details, you can look at the first couple of pins mentioned:
like Pin 51 is internally EMC_22, if you look for EMC_22 in the IOMUXC_ chapter (10), you will find at about page 448, the register:
IOMUXC_SW_MUX_CTL_PAD_GPIO_EMC_22
Code:
MUX Mode Select Field.
Select one of iomux modes to be used for pad: GPIO_EMC_22.
000 ALT0 — Select mux mode: ALT0 mux port: SEMC_BA1 of instance: semc
001 ALT1 — Select mux mode: ALT1 mux port: FLEXPWM3_PWMB03 of instance: flexpwm3
010 ALT2 — Select mux mode: ALT2 mux port: LPI2C3_SCL of instance: lpi2c3
011 ALT3 — Select mux mode: ALT3 mux port: ENET_TDATA00 of instance: enet
100 ALT4 — Select mux mode: ALT4 mux port: QTIMER2_TIMER3 of instance: qtimer2
101 ALT5 — Select mux mode: ALT5 mux port: GPIO4_IO22 of instance: gpio4
1000 ALT8 — Select mux mode: ALT8 mux port: FLEXSPI2_A_SS1_B of instance: flexspi2
So for FlexSPI2 you configure the pin into ALT8... And there are not LPSPI functions on this pin.
But if you look at pins 49 which is EMC_27 - IOMUXC_SW_MUX_CTL_PAD_GPIO_EMC_27 (P453)
Code:
000 ALT0 — Select mux mode: ALT0 mux port: SEMC_CKE of instance: semc
001 ALT1 — Select mux mode: ALT1 mux port: FLEXPWM1_PWMA02 of instance: flexpwm1
010 ALT2 — Select mux mode: ALT2 mux port: LPUART5_RTS_B of instance: lpuart5
011 ALT3 — Select mux mode: ALT3 mux port: LPSPI1_SCK of instance: lpspi1
100 ALT4 — Select mux mode: ALT4 mux port: FLEXIO1_FLEXIO13 of instance: flexio1
101 ALT5 — Select mux mode: ALT5 mux port: GPIO4_IO27 of instance: gpio4
1000 ALT8 — Select mux mode: ALT8 mux port: FLEXSPI2_A_DATA01 of instance: flexspi2
Again you will see ALT8 sets up for FlexSPI2, and in this case ALT3 sets it up as SCK for LPSPI1...
Again sorry if this is too much information, but thought it be helpful to some to see where this data comes from.
Also let me know if you do find errors in my tables and the like as I have found a few just a few days ago with the PWM markings.