@@ -218,6 +218,7 @@ void common_hal_busio_spi_construct(busio_spi_obj_t *self,
218218 gpio_set_pin_pull_mode (clock -> number , GPIO_PULL_OFF );
219219 gpio_set_pin_function (clock -> number , clock_pinmux );
220220 claim_pin (clock );
221+ hri_port_set_PINCFG_DRVSTR_bit (PORT , (enum gpio_port )GPIO_PORT (clock -> number ), GPIO_PIN (clock -> number ));
221222 self -> clock_pin = clock -> number ;
222223
223224 if (mosi_none ) {
@@ -228,6 +229,7 @@ void common_hal_busio_spi_construct(busio_spi_obj_t *self,
228229 gpio_set_pin_function (mosi -> number , mosi_pinmux );
229230 self -> MOSI_pin = mosi -> number ;
230231 claim_pin (mosi );
232+ hri_port_set_PINCFG_DRVSTR_bit (PORT , (enum gpio_port )GPIO_PORT (mosi -> number ), GPIO_PIN (mosi -> number ));
231233 }
232234
233235 if (miso_none ) {
@@ -238,6 +240,7 @@ void common_hal_busio_spi_construct(busio_spi_obj_t *self,
238240 gpio_set_pin_function (miso -> number , miso_pinmux );
239241 self -> MISO_pin = miso -> number ;
240242 claim_pin (miso );
243+ hri_port_set_PINCFG_DRVSTR_bit (PORT , (enum gpio_port )GPIO_PORT (miso -> number ), GPIO_PIN (miso -> number ));
241244 }
242245
243246 if (slave_mode ) {
@@ -246,6 +249,7 @@ void common_hal_busio_spi_construct(busio_spi_obj_t *self,
246249 gpio_set_pin_function (ss -> number , ss_pinmux );
247250 self -> SS_pin = ss -> number ;
248251 claim_pin (ss );
252+ hri_port_set_PINCFG_DRVSTR_bit (PORT , (enum gpio_port )GPIO_PORT (ss -> number ), GPIO_PIN (ss -> number ));
249253 }
250254
251255 self -> running_dma .failure = 1 ; // not started
0 commit comments