Skip to content

Commit 902e242

Browse files
committed
Revert "enable internal SPI intercepts. can brick USB"
This reverts commit 5b70fa0.
1 parent 5b70fa0 commit 902e242

4 files changed

Lines changed: 11 additions & 17 deletions

File tree

ports/stm32f4/boards/meowbit_v121/mpconfigboard.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
#define BOARD_NO_VBUS
4040

4141
// On-board flash
42-
#define SPI_FLASH_MOSI_PIN (&pin_PB15)
43-
#define SPI_FLASH_MISO_PIN (&pin_PB14)
44-
#define SPI_FLASH_SCK_PIN (&pin_PB13)
45-
#define SPI_FLASH_CS_PIN (&pin_PB01)
42+
// #define SPI_FLASH_MOSI_PIN (&pin_PB15)
43+
// #define SPI_FLASH_MISO_PIN (&pin_PB14)
44+
// #define SPI_FLASH_SCK_PIN (&pin_PB13)
45+
// #define SPI_FLASH_CS_PIN (&pin_PB01)

ports/stm32f4/boards/meowbit_v121/mpconfigboard.mk

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,19 @@ USB_PRODUCT = "Meowbit"
44
USB_MANUFACTURER = "Kittenbot"
55
USB_DEVICES = "CDC,MSC"
66

7-
SPI_FLASH_FILESYSTEM = 1
8-
EXTERNAL_FLASH_DEVICE_COUNT = 1
9-
EXTERNAL_FLASH_DEVICES = W25Q16JV_IQ
10-
LONGINT_IMPL = MPZ
7+
# SPI_FLASH_FILESYSTEM = 1
8+
# EXTERNAL_FLASH_DEVICE_COUNT = 1
9+
# EXTERNAL_FLASH_DEVICES = W25Q16JV_IQ
10+
# LONGINT_IMPL = MPZ
1111

12-
# INTERNAL_FLASH_FILESYSTEM = 1
13-
# LONGINT_IMPL = NONE
12+
INTERNAL_FLASH_FILESYSTEM = 1
13+
LONGINT_IMPL = NONE
1414

1515
MCU_SERIES = m4
1616
MCU_VARIANT = stm32f4
1717
MCU_SUB_VARIANT = stm32f401xe
1818
MCU_PACKAGE = 64
1919
CMSIS_MCU = STM32F401xE
20-
LD_FILE = boards/STM32F401.ld
20+
LD_FILE = boards/STM32F401_fs.ld
2121
TEXT0_ADDR = 0x08010000
2222
TEXT1_ADDR = 0x08020000

ports/stm32f4/boards/meowbit_v121/pins.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
#include "shared-bindings/board/__init__.h"
2-
#include "supervisor/spi_flash_api.h"
32

43
STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
54
{ MP_ROM_QSTR(MP_QSTR_LED_RED), MP_ROM_PTR(&pin_PB04) },
@@ -60,6 +59,5 @@ STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
6059
{ MP_ROM_QSTR(MP_QSTR_P0), MP_ROM_PTR(&pin_PA00) },
6160
{ MP_ROM_QSTR(MP_QSTR_P3), MP_ROM_PTR(&pin_PB00) },
6261

63-
{ MP_ROM_QSTR(MP_QSTR_INTERNAL_SPI), MP_ROM_PTR(&spi) },
6462
};
6563
MP_DEFINE_CONST_DICT(board_module_globals, board_module_globals_table);

supervisor/spi_flash_api.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,6 @@
3131

3232
#include "supervisor/shared/external_flash/devices.h"
3333

34-
#include "shared-bindings/busio/SPI.h"
35-
36-
extern busio_spi_obj_t spi; //Used to share SPI bus on some boards
37-
3834
// This API is implemented for both normal SPI peripherals and QSPI peripherals.
3935

4036
bool spi_flash_command(uint8_t command);

0 commit comments

Comments
 (0)