Skip to content

Commit f2e405b

Browse files
committed
Add defines for QSPI pins
1 parent eaeb1e6 commit f2e405b

File tree

3 files changed

+24
-6
lines changed

3 files changed

+24
-6
lines changed

Diff for: libraries/WiFi/examples/PortentaWiFiFirmwareUpdater/PortentaWiFiFirmwareUpdater.ino

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#error Update the WiFi firmware by uploading the sketch to the M7 core instead of the M4 core.
99
#endif
1010

11-
QSPIFBlockDevice root(PD_11, PD_12, PF_7, PD_13, PF_10, PG_6, QSPIF_POLARITY_MODE_1, 40000000);
11+
QSPIFBlockDevice root(QSPI_SO0, QSPI_SO1, QSPI_SO2, QSPI_SO3, QSPI_SCK, QSPI_CS, QSPIF_POLARITY_MODE_1, 40000000);
1212
mbed::MBRBlockDevice wifi_data(&root, 1);
1313
mbed::MBRBlockDevice ota_data(&root, 2);
1414
mbed::FATFileSystem wifi_data_fs("wlan");
@@ -106,4 +106,4 @@ void setup() {
106106

107107
void loop() {
108108

109-
}
109+
}

Diff for: variants/NICLA_VISION/pins_arduino.h

+14-4
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,14 @@ static const uint8_t MOSI = PIN_SPI_MOSI;
8787
static const uint8_t MISO = PIN_SPI_MISO;
8888
static const uint8_t SCK = PIN_SPI_SCK;
8989

90+
// QSPI
91+
#define QSPI_SO0 PD_11
92+
#define QSPI_SO1 PF_9
93+
#define QSPI_SO2 PE_2
94+
#define QSPI_SO3 PD_13
95+
#define QSPI_SCK PF_10
96+
#define QSPI_CS PG_6
97+
9098
// Wire
9199
#define PIN_WIRE_SDA (11u)
92100
#define PIN_WIRE_SCL (12u)
@@ -116,10 +124,12 @@ void _ontouch1200bps_();
116124
#define I2C_SDA (digitalPinToPinName(PIN_WIRE_SDA))
117125
#define I2C_SCL (digitalPinToPinName(PIN_WIRE_SCL))
118126

119-
//#define I2C_SDA_INTERNAL (PB_7)
120-
//#define I2C_SCL_INTERNAL (PB_6)
121-
#define I2C_SDA1 (13u)
122-
#define I2C_SCL1 (14u)
127+
#define I2C_SDA_INTERNAL (PF_0)
128+
#define I2C_SCL_INTERNAL (PF_1)
129+
#define I2C_SDA1 I2C_SDA_INTERNAL
130+
#define I2C_SCL1 I2C_SCL_INTERNAL
131+
//#define I2C_SDA1 (13u)
132+
//#define I2C_SCL1 (14u)
123133

124134
#define I2C_SDA3 (18u)
125135
#define I2C_SCL3 (19u)

Diff for: variants/PORTENTA_H7_M7/pins_arduino.h

+8
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,14 @@ static const uint8_t MOSI = PIN_SPI_MOSI;
9595
static const uint8_t MISO = PIN_SPI_MISO;
9696
static const uint8_t SCK = PIN_SPI_SCK;
9797

98+
// QSPI
99+
#define QSPI_SO0 PD_11
100+
#define QSPI_SO1 PD_12
101+
#define QSPI_SO2 PF_7
102+
#define QSPI_SO3 PD_13
103+
#define QSPI_SCK PF_10
104+
#define QSPI_CS PG_6
105+
98106
// Wire
99107
#define PIN_WIRE_SDA (11u)
100108
#define PIN_WIRE_SCL (12u)

0 commit comments

Comments
 (0)