mirror of
https://github.com/meshtastic/firmware.git
synced 2025-04-23 17:13:38 +00:00
fix build errors
This commit is contained in:
parent
91986db1b0
commit
0d19f766e8
@ -21,6 +21,8 @@
|
||||
SPIClass SDHandler = SPIClass(HSPI);
|
||||
#elif defined(SDCARD_USE_VSPI)
|
||||
SPIClass SDHandler = SPIClass(VSPI);
|
||||
#else
|
||||
#define SDHandler SPI
|
||||
#endif
|
||||
#elif defined(ARCH_NRF52)
|
||||
#if defined(SDCARD_USE_SPI1)
|
||||
@ -34,31 +36,6 @@ SPIClass SDHandler = SPIClass(VSPI);
|
||||
#endif
|
||||
#endif // HAS_SDCARD
|
||||
|
||||
|
||||
#if defined(ARCH_STM32WL)
|
||||
|
||||
uint16_t OSFS::startOfEEPROM = 1;
|
||||
uint16_t OSFS::endOfEEPROM = 2048;
|
||||
|
||||
// 3) How do I read from the medium?
|
||||
void OSFS::readNBytes(uint16_t address, unsigned int num, byte *output)
|
||||
{
|
||||
for (uint16_t i = address; i < address + num; i++) {
|
||||
*output = EEPROM.read(i);
|
||||
output++;
|
||||
}
|
||||
}
|
||||
|
||||
// 4) How to I write to the medium?
|
||||
void OSFS::writeNBytes(uint16_t address, unsigned int num, const byte *input)
|
||||
{
|
||||
for (uint16_t i = address; i < address + num; i++) {
|
||||
EEPROM.update(i, *input);
|
||||
input++;
|
||||
}
|
||||
}
|
||||
#endif // ARCH_STM32WL
|
||||
|
||||
/**
|
||||
* @brief Copies a file from one location to another.
|
||||
*
|
||||
|
@ -61,8 +61,10 @@ class XModemAdapter
|
||||
|
||||
uint16_t packetno = 0;
|
||||
|
||||
#if defined(ARCH_NRF52) || defined(ARCH_STM32WL)
|
||||
#if defined(ARCH_NRF52)
|
||||
Adafruit_LittleFS_Namespace::File file = Adafruit_LittleFS_Namespace::File(FSCom);
|
||||
#elif defined(ARCH_STM32WL)
|
||||
File file = File(FSCom);
|
||||
#else
|
||||
File file;
|
||||
#endif
|
||||
|
@ -48,7 +48,6 @@
|
||||
#undef GPS_RX_PIN
|
||||
#undef GPS_TX_PIN
|
||||
|
||||
|
||||
// #define HAS_SDCARD 1 // causes hang if defined
|
||||
#define SDCARD_USE_HSPI
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user