mirror of
https://github.com/meshtastic/firmware.git
synced 2025-02-26 22:33:24 +00:00
Merge branch 'master' of github.com:meshtastic/Meshtastic-device
This commit is contained in:
commit
eb6dd6b53d
@ -35,6 +35,7 @@ build_flags = -Wno-missing-field-initializers
|
||||
-Isrc -Isrc/mesh -Isrc/gps -Isrc/buzz -Wl,-Map,.pio/build/output.map
|
||||
-DUSE_THREAD_NAMES
|
||||
-DTINYGPS_OPTION_NO_CUSTOM_FIELDS
|
||||
-DPB_ENABLE_MALLOC=1
|
||||
|
||||
monitor_speed = 921600
|
||||
|
||||
@ -49,7 +50,7 @@ lib_deps =
|
||||
https://github.com/meshtastic/AXP202X_Library.git#8404abb6d4b486748636bc6ad72d2a47baaf5460
|
||||
Wire ; explicitly needed here because the AXP202 library forgets to add it
|
||||
SPI
|
||||
https://github.com/geeksville/ArduinoThread.git#72921ac222eed6f526ba1682023cee290d9aa1b3
|
||||
https://github.com/meshtastic/ArduinoThread.git#72921ac222eed6f526ba1682023cee290d9aa1b3
|
||||
PubSubClient
|
||||
nanopb/Nanopb@^0.4.6
|
||||
meshtastic/json11@^1.0.2
|
||||
|
@ -1,10 +1,6 @@
|
||||
#include "buzz.h"
|
||||
#include "configuration.h"
|
||||
|
||||
#ifdef NRF52_SERIES
|
||||
#include "variant.h"
|
||||
#endif
|
||||
|
||||
#ifndef PIN_BUZZER
|
||||
|
||||
// Noop methods for boards w/o buzzer
|
||||
|
@ -120,7 +120,7 @@ bool perhapsSetRTC(RTCQuality q, const struct timeval *tv)
|
||||
#endif
|
||||
|
||||
// nrf52 doesn't have a readable RTC (yet - software not written)
|
||||
#if defined(PORTDUINO) || !defined(NO_ESP32) || defined(RV3028_RTC)
|
||||
#if defined(PORTDUINO) || !defined(NO_ESP32) || defined(RV3028_RTC) || defined(PCF8563_RTC)
|
||||
readFromRTC();
|
||||
#endif
|
||||
|
||||
|
@ -20,6 +20,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
*/
|
||||
#include "configuration.h"
|
||||
#ifndef NO_SCREEN
|
||||
#include <OLEDDisplay.h>
|
||||
|
||||
#include "GPS.h"
|
||||
@ -1665,3 +1666,4 @@ int Screen::handleUIFrameEvent(const UIFrameEvent *event)
|
||||
}
|
||||
|
||||
} // namespace graphics
|
||||
#endif // NO_SCREEN
|
@ -1,6 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#ifdef NO_SCREEN
|
||||
#include "power.h"
|
||||
namespace graphics
|
||||
{
|
||||
// Noop class for boards without screen.
|
||||
@ -15,6 +16,8 @@ class Screen
|
||||
void adjustBrightness(){}
|
||||
void doDeepSleep() {}
|
||||
void forceDisplay() {}
|
||||
void startBluetoothPinScreen(uint32_t pin) {}
|
||||
void stopBluetoothPinScreen() {}
|
||||
};
|
||||
}
|
||||
|
||||
|
@ -440,7 +440,7 @@ uint32_t sinceLastSeen(const NodeInfo *n)
|
||||
return delta;
|
||||
}
|
||||
|
||||
#define NUM_ONLINE_SECS (60 & 60 * 2) // 2 hrs to consider someone offline
|
||||
#define NUM_ONLINE_SECS (60 * 60 * 2) // 2 hrs to consider someone offline
|
||||
|
||||
size_t NodeDB::getNumOnlineNodes()
|
||||
{
|
||||
|
@ -798,7 +798,9 @@ void handleBlinkLED(HTTPRequest *req, HTTPResponse *res)
|
||||
count = count - 1;
|
||||
}
|
||||
} else {
|
||||
#ifndef NO_SCREEN
|
||||
screen->blink();
|
||||
#endif
|
||||
}
|
||||
|
||||
Json jsonObjOuter = Json::object{{"status", "ok"}};
|
||||
|
@ -152,10 +152,11 @@ void createSSLCert()
|
||||
|
||||
yield();
|
||||
esp_task_wdt_reset();
|
||||
|
||||
#ifndef NO_SCREEN
|
||||
if (millis() / 1000 >= 3) {
|
||||
screen->setSSLFrames();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
runLoop = false;
|
||||
} else {
|
||||
|
@ -1,4 +1,5 @@
|
||||
#include "configuration.h"
|
||||
#ifndef NO_SCREEN
|
||||
#include "CannedMessageModule.h"
|
||||
#include "PowerFSM.h" // neede for button bypass
|
||||
#include "MeshService.h"
|
||||
@ -548,3 +549,4 @@ void CannedMessageModule::handleSetCannedMessageModulePart4(const char *from_msg
|
||||
this->saveProtoForModule();
|
||||
}
|
||||
}
|
||||
#endif
|
@ -1,4 +1,6 @@
|
||||
#pragma once
|
||||
#ifdef NO_SCREEN
|
||||
#else
|
||||
#include "ProtobufModule.h"
|
||||
#include "input/InputBroker.h"
|
||||
|
||||
@ -84,3 +86,4 @@ class CannedMessageModule :
|
||||
};
|
||||
|
||||
extern CannedMessageModule *cannedMessageModule;
|
||||
#endif
|
@ -47,7 +47,9 @@ void setupModules()
|
||||
cardKbI2cImpl->init();
|
||||
facesKbI2cImpl = new FacesKbI2cImpl();
|
||||
facesKbI2cImpl->init();
|
||||
#ifndef NO_SCREEN
|
||||
cannedMessageModule = new CannedMessageModule();
|
||||
#endif
|
||||
#ifndef PORTDUINO
|
||||
new DeviceTelemetryModule();
|
||||
new EnvironmentTelemetryModule();
|
||||
|
@ -15,7 +15,11 @@ class EnvironmentTelemetryModule : private concurrency::OSThread, public Protobu
|
||||
lastMeasurementPacket = nullptr;
|
||||
}
|
||||
virtual bool wantUIFrame() override;
|
||||
#ifdef NO_SCREEN
|
||||
void drawFrame(OLEDDisplay *display, OLEDDisplayUiState *state, int16_t x, int16_t y);
|
||||
#else
|
||||
virtual void drawFrame(OLEDDisplay *display, OLEDDisplayUiState *state, int16_t x, int16_t y) override;
|
||||
#endif
|
||||
|
||||
protected:
|
||||
/** Called to handle a particular incoming message
|
||||
|
@ -3,7 +3,7 @@
|
||||
#undef GPS_RX_PIN
|
||||
#undef GPS_TX_PIN
|
||||
#define GPS_RX_PIN 36
|
||||
#define GPS_TX_PIN 34
|
||||
#define GPS_TX_PIN 33
|
||||
|
||||
#ifndef USE_JTAG // gpio15 is TDO for JTAG, so no I2C on this board while doing jtag
|
||||
#define I2C_SDA 4 // I2C pins for this board
|
||||
@ -20,8 +20,8 @@
|
||||
#ifndef USE_JTAG
|
||||
#define LORA_RESET 14
|
||||
#endif
|
||||
#define LORA_DIO1 33 // Not really used
|
||||
#define LORA_DIO2 32 // Not really used
|
||||
#define LORA_DIO1 35 // Not really used
|
||||
#define LORA_DIO2 34 // Not really used
|
||||
|
||||
// ratio of voltage divider = 3.20 (R1=100k, R2=220k)
|
||||
#define ADC_MULTIPLIER 3.2
|
||||
|
@ -1,6 +1,6 @@
|
||||
; The Portduino based sim environment on top of any host OS, all hardware will be simulated
|
||||
[env:native]
|
||||
platform = https://github.com/geeksville/platform-native.git
|
||||
platform = https://github.com/meshtastic/platform-native.git
|
||||
src_filter =
|
||||
${env.src_filter}
|
||||
-<esp32/>
|
||||
@ -19,7 +19,7 @@ lib_deps =
|
||||
|
||||
; The Portduino based sim environment on top of a linux OS and touching linux hardware devices
|
||||
[env:linux]
|
||||
platform = https://github.com/geeksville/platform-native.git
|
||||
platform = https://github.com/meshtastic/platform-native.git
|
||||
src_filter =
|
||||
${env.src_filter}
|
||||
-<esp32/>
|
||||
@ -34,4 +34,4 @@ framework = arduino
|
||||
board = linux_hardware
|
||||
lib_deps =
|
||||
${arduino_base.lib_deps}
|
||||
rweather/Crypto
|
||||
rweather/Crypto
|
||||
|
@ -201,6 +201,9 @@ static const uint8_t SCK = PIN_SPI_SCK;
|
||||
// RAK12002 RTC Module
|
||||
#define RV3028_RTC (uint8_t) 0b1010010
|
||||
|
||||
// RAK18001 Buzzer in Slot C
|
||||
#define PIN_BUZZER 21 // IO3 is PWM2
|
||||
|
||||
// Battery
|
||||
// The battery sense is hooked to pin A0 (5)
|
||||
#define BATTERY_PIN PIN_A0
|
||||
|
Loading…
Reference in New Issue
Block a user