Moved .ino to .hpp - fixed dup include and faulty declaration

This commit is contained in:
Ano-sys
2025-08-10 15:39:04 +02:00
parent cd30c25956
commit 76f96e4245
2 changed files with 4 additions and 3 deletions
+1 -1
View File
@@ -5,7 +5,7 @@
#include <Adafruit_SSD1306.h> #include <Adafruit_SSD1306.h>
#include <TinyGPS++.h> #include <TinyGPS++.h>
#include "SDCardHelper.ino" #include "SDCardHelper.hpp"
// LORA Settings // LORA Settings
#define SYNC_WORD 0xCE #define SYNC_WORD 0xCE
@@ -1,3 +1,4 @@
#pragma once
#include <SPI.h> #include <SPI.h>
#include <SD.h> #include <SD.h>
@@ -13,7 +14,7 @@ private:
File _stream; File _stream;
String _filename; String _filename;
bool _available = false; bool _available = false;
SPIClass _spi(HSPI); SPIClass _spi;
String getNewFilename() { String getNewFilename() {
static unsigned long i = 0; static unsigned long i = 0;
@@ -25,7 +26,7 @@ private:
} }
public: public:
SDHelper(uint8_t csPin, FileAccessMode fam, String filename = "") : _cs(csPin), _fam(fam) { SDHelper(uint8_t csPin, FileAccessMode fam, String filename = "") : _cs(csPin), _fam(fam), _spi(HSPI){
_spi.begin(14, 2, 15, 13); _spi.begin(14, 2, 15, 13);
if(!SD.begin(_cs, _spi)){ if(!SD.begin(_cs, _spi)){
_available = false; _available = false;