Skip to content

Commit

Permalink
Prepare BSP for Internal Flash filesystem (#316)
Browse files Browse the repository at this point in the history
* update upload tool for adafruit_proxlighttrinkey_m0 to bossac18

* fake SPI Interface so we could compile with SdFat
  • Loading branch information
hathach authored Jan 12, 2022
1 parent 90b4d35 commit 525980e
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
2 changes: 1 addition & 1 deletion boards.txt
Original file line number Diff line number Diff line change
Expand Up @@ -581,7 +581,7 @@ adafruit_proxlighttrinkey_m0.vid.1=0x239A
adafruit_proxlighttrinkey_m0.pid.1=0x0103
adafruit_proxlighttrinkey_m0.vid.1=0x239A
adafruit_proxlighttrinkey_m0.pid.1=0x8104
adafruit_proxlighttrinkey_m0.upload.tool=bossac
adafruit_proxlighttrinkey_m0.upload.tool=bossac18
adafruit_proxlighttrinkey_m0.upload.protocol=sam-ba
adafruit_proxlighttrinkey_m0.upload.maximum_size=262144
adafruit_proxlighttrinkey_m0.upload.offset=0x2000
Expand Down
2 changes: 1 addition & 1 deletion variants/proxlighttrinkey_m0/variant.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ const PinDescription g_APinDescription[]=
// Interrupt D6
{ PORTA, 0, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 },

// USB pins
// USB pins D7, D8, D9
{ PORTA, 28, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB Host enable
{ PORTA, 24, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM
{ PORTA, 25, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP
Expand Down
15 changes: 14 additions & 1 deletion variants/proxlighttrinkey_m0/variant.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,21 @@ static const uint8_t A2 = PIN_A2;

/*
* SPI Interfaces
* Fake SPI Interface just so we can compile
*/
#define SPI_INTERFACES_COUNT 0
#define SPI_INTERFACES_COUNT 1

#define PIN_SPI_MISO PIN_A0
#define PIN_SPI_MOSI PIN_A0
#define PIN_SPI_SCK PIN_A0
#define PERIPH_SPI sercom0
#define PAD_SPI_TX SPI_PAD_0_SCK_1
#define PAD_SPI_RX SERCOM_RX_PAD_0

static const uint8_t SS = PIN_A0;
static const uint8_t MOSI = PIN_SPI_MOSI;
static const uint8_t MISO = PIN_SPI_MISO;
static const uint8_t SCK = PIN_SPI_SCK;

/*
* Wire Interfaces
Expand Down

0 comments on commit 525980e

Please sign in to comment.