mirror of
https://github.com/meshtastic/firmware.git
synced 2025-09-04 10:38:57 +00:00
Compare commits
9 Commits
e5042015b1
...
fe091a7c75
Author | SHA1 | Date | |
---|---|---|---|
![]() |
fe091a7c75 | ||
![]() |
bd3cbfc1ad | ||
![]() |
fddc4e00ca | ||
![]() |
5f7eec5504 | ||
![]() |
6b94c297b9 | ||
![]() |
edeb25cab5 | ||
![]() |
44688e8363 | ||
![]() |
291643fa3b | ||
![]() |
ba7f23bb9b |
@ -9,14 +9,14 @@ plugins:
|
||||
lint:
|
||||
enabled:
|
||||
- checkov@3.2.467
|
||||
- renovate@41.88.0
|
||||
- renovate@41.90.1
|
||||
- prettier@3.6.2
|
||||
- trufflehog@3.90.5
|
||||
- yamllint@1.37.1
|
||||
- bandit@1.8.6
|
||||
- trivy@0.65.0
|
||||
- taplo@0.10.0
|
||||
- ruff@0.12.10
|
||||
- ruff@0.12.11
|
||||
- isort@6.0.1
|
||||
- markdownlint@0.45.0
|
||||
- oxipng@9.1.5
|
||||
|
@ -100,7 +100,6 @@ IF NOT "!FILENAME:update=!"=="!FILENAME!" (
|
||||
)
|
||||
|
||||
:skip-filename
|
||||
SET "ESPTOOL_BAUD=1200"
|
||||
|
||||
CALL :LOG_MESSAGE DEBUG "Determine the correct esptool command to use..."
|
||||
IF NOT "__%PYTHON%__"=="____" (
|
||||
@ -142,7 +141,7 @@ CALL :LOG_MESSAGE INFO "Using esptool baud: !ESPTOOL_BAUD!."
|
||||
|
||||
IF %BPS_RESET% EQU 1 (
|
||||
@REM Attempt to change mode via 1200bps Reset.
|
||||
CALL :RUN_ESPTOOL !ESPTOOL_BAUD! --after no_reset read_flash_status
|
||||
CALL :RUN_ESPTOOL 1200 --after no_reset read_flash_status
|
||||
GOTO eof
|
||||
)
|
||||
|
||||
|
@ -87,6 +87,9 @@
|
||||
</screenshots>
|
||||
|
||||
<releases>
|
||||
<release version="2.7.8" date="2025-08-30">
|
||||
<url type="details">https://github.com/meshtastic/firmware/releases?q=tag%3Av2.7.8</url>
|
||||
</release>
|
||||
<release version="2.7.7" date="2025-08-28">
|
||||
<url type="details">https://github.com/meshtastic/firmware/releases?q=tag%3Av2.7.7</url>
|
||||
</release>
|
||||
|
7
debian/changelog
vendored
7
debian/changelog
vendored
@ -1,4 +1,4 @@
|
||||
meshtasticd (2.7.7.0) UNRELEASED; urgency=medium
|
||||
meshtasticd (2.7.8.0) UNRELEASED; urgency=medium
|
||||
|
||||
[ Austin Lane ]
|
||||
* Initial packaging
|
||||
@ -41,4 +41,7 @@ meshtasticd (2.7.7.0) UNRELEASED; urgency=medium
|
||||
* GitHub Actions Automatic version bump
|
||||
* GitHub Actions Automatic version bump
|
||||
|
||||
-- Ubuntu <github-actions[bot]@users.noreply.github.com> Thu, 28 Aug 2025 10:33:25 +0000
|
||||
[ ]
|
||||
* GitHub Actions Automatic version bump
|
||||
|
||||
-- <github-actions[bot]@users.noreply.github.com> Sat, 30 Aug 2025 00:26:04 +0000
|
||||
|
@ -128,6 +128,7 @@ RAK9154Sensor rak9154Sensor;
|
||||
#ifdef HAS_PPM
|
||||
// note: XPOWERS_CHIP_XXX must be defined in variant.h
|
||||
#include <XPowersLib.h>
|
||||
XPowersPPM *PPM = NULL;
|
||||
#endif
|
||||
|
||||
#ifdef HAS_BQ27220
|
||||
@ -681,7 +682,7 @@ bool Power::setup()
|
||||
found = true;
|
||||
} else if (lipoChargerInit()) {
|
||||
found = true;
|
||||
} else if (meshSolarInit()) {
|
||||
} else if (meshSolarInit()) {
|
||||
found = true;
|
||||
} else if (analogInit()) {
|
||||
found = true;
|
||||
@ -745,7 +746,11 @@ void Power::shutdown()
|
||||
|
||||
#if HAS_SCREEN
|
||||
if (screen) {
|
||||
#ifdef T_DECK_PRO
|
||||
screen->showSimpleBanner("Device is powered off.\nConnect USB to start!", 0); // T-Deck Pro has no power button
|
||||
#else
|
||||
screen->showSimpleBanner("Shutting Down...", 0); // stays on screen
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
#if !defined(ARCH_STM32WL)
|
||||
@ -763,7 +768,7 @@ void Power::shutdown()
|
||||
#ifdef PIN_LED3
|
||||
ledOff(PIN_LED3);
|
||||
#endif
|
||||
doDeepSleep(DELAY_FOREVER, false, true);
|
||||
doDeepSleep(DELAY_FOREVER, true, true);
|
||||
#elif defined(ARCH_PORTDUINO)
|
||||
exit(EXIT_SUCCESS);
|
||||
#else
|
||||
@ -1320,7 +1325,6 @@ bool Power::lipoInit()
|
||||
class LipoCharger : public HasBatteryLevel
|
||||
{
|
||||
private:
|
||||
XPowersPPM *ppm = nullptr;
|
||||
BQ27220 *bq = nullptr;
|
||||
|
||||
public:
|
||||
@ -1329,41 +1333,41 @@ class LipoCharger : public HasBatteryLevel
|
||||
*/
|
||||
bool runOnce()
|
||||
{
|
||||
if (ppm == nullptr) {
|
||||
ppm = new XPowersPPM;
|
||||
bool result = ppm->init(Wire, I2C_SDA, I2C_SCL, BQ25896_ADDR);
|
||||
if (PPM == nullptr) {
|
||||
PPM = new XPowersPPM;
|
||||
bool result = PPM->init(Wire, I2C_SDA, I2C_SCL, BQ25896_ADDR);
|
||||
if (result) {
|
||||
LOG_INFO("PPM BQ25896 init succeeded");
|
||||
// Set the minimum operating voltage. Below this voltage, the PPM will protect
|
||||
// ppm->setSysPowerDownVoltage(3100);
|
||||
// PPM->setSysPowerDownVoltage(3100);
|
||||
|
||||
// Set input current limit, default is 500mA
|
||||
// ppm->setInputCurrentLimit(800);
|
||||
// PPM->setInputCurrentLimit(800);
|
||||
|
||||
// Disable current limit pin
|
||||
// ppm->disableCurrentLimitPin();
|
||||
// PPM->disableCurrentLimitPin();
|
||||
|
||||
// Set the charging target voltage, Range:3840 ~ 4608mV ,step:16 mV
|
||||
ppm->setChargeTargetVoltage(4288);
|
||||
PPM->setChargeTargetVoltage(4288);
|
||||
|
||||
// Set the precharge current , Range: 64mA ~ 1024mA ,step:64mA
|
||||
// ppm->setPrechargeCurr(64);
|
||||
// PPM->setPrechargeCurr(64);
|
||||
|
||||
// The premise is that limit pin is disabled, or it will
|
||||
// only follow the maximum charging current set by limit pin.
|
||||
// Set the charging current , Range:0~5056mA ,step:64mA
|
||||
ppm->setChargerConstantCurr(1024);
|
||||
PPM->setChargerConstantCurr(1024);
|
||||
|
||||
// To obtain voltage data, the ADC must be enabled first
|
||||
ppm->enableMeasure();
|
||||
PPM->enableMeasure();
|
||||
|
||||
// Turn on charging function
|
||||
// If there is no battery connected, do not turn on the charging function
|
||||
ppm->enableCharge();
|
||||
PPM->enableCharge();
|
||||
} else {
|
||||
LOG_WARN("PPM BQ25896 init failed");
|
||||
delete ppm;
|
||||
ppm = nullptr;
|
||||
delete PPM;
|
||||
PPM = nullptr;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@ -1404,23 +1408,23 @@ class LipoCharger : public HasBatteryLevel
|
||||
/**
|
||||
* return true if there is a battery installed in this unit
|
||||
*/
|
||||
virtual bool isBatteryConnect() override { return ppm->getBattVoltage() > 0; }
|
||||
virtual bool isBatteryConnect() override { return PPM->getBattVoltage() > 0; }
|
||||
|
||||
/**
|
||||
* return true if there is an external power source detected
|
||||
*/
|
||||
virtual bool isVbusIn() override { return ppm->getVbusVoltage() > 0; }
|
||||
virtual bool isVbusIn() override { return PPM->getVbusVoltage() > 0; }
|
||||
|
||||
/**
|
||||
* return true if the battery is currently charging
|
||||
*/
|
||||
virtual bool isCharging() override
|
||||
{
|
||||
bool isCharging = ppm->isCharging();
|
||||
bool isCharging = PPM->isCharging();
|
||||
if (isCharging) {
|
||||
LOG_DEBUG("BQ27220 time to full charge: %d min", bq->getTimeToFull());
|
||||
} else {
|
||||
if (!ppm->isVbusIn()) {
|
||||
if (!PPM->isVbusIn()) {
|
||||
LOG_DEBUG("BQ27220 time to empty: %d min (%d mAh)", bq->getTimeToEmpty(), bq->getRemainingCapacity());
|
||||
}
|
||||
}
|
||||
@ -1453,8 +1457,6 @@ bool Power::lipoChargerInit()
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
#ifdef HELTEC_MESH_SOLAR
|
||||
#include "meshSolarApp.h"
|
||||
|
||||
@ -1492,7 +1494,7 @@ class meshSolarBatteryLevel : public HasBatteryLevel
|
||||
/**
|
||||
* return true if there is an external power source detected
|
||||
*/
|
||||
virtual bool isVbusIn() override { return meshSolarIsVbusIn();}
|
||||
virtual bool isVbusIn() override { return meshSolarIsVbusIn(); }
|
||||
|
||||
/**
|
||||
* return true if the battery is currently charging
|
||||
|
@ -26,10 +26,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#include <Arduino.h>
|
||||
|
||||
#ifdef RV3028_RTC
|
||||
#if __has_include("Melopero_RV3028.h")
|
||||
#include "Melopero_RV3028.h"
|
||||
#endif
|
||||
#ifdef PCF8563_RTC
|
||||
#if __has_include("pcf8563.h")
|
||||
#include "pcf8563.h"
|
||||
#endif
|
||||
|
||||
|
@ -55,9 +55,9 @@ RTCSetResult readFromRTC()
|
||||
|
||||
LOG_DEBUG("Read RTC time from RV3028 getTime as %02d-%02d-%02d %02d:%02d:%02d (%ld)", t.tm_year + 1900, t.tm_mon + 1,
|
||||
t.tm_mday, t.tm_hour, t.tm_min, t.tm_sec, printableEpoch);
|
||||
timeStartMsec = now;
|
||||
zeroOffsetSecs = tv.tv_sec;
|
||||
if (currentQuality == RTCQualityNone) {
|
||||
timeStartMsec = now;
|
||||
zeroOffsetSecs = tv.tv_sec;
|
||||
currentQuality = RTCQualityDevice;
|
||||
}
|
||||
return RTCSetResultSuccess;
|
||||
@ -94,9 +94,9 @@ RTCSetResult readFromRTC()
|
||||
|
||||
LOG_DEBUG("Read RTC time from PCF8563 getDateTime as %02d-%02d-%02d %02d:%02d:%02d (%ld)", t.tm_year + 1900, t.tm_mon + 1,
|
||||
t.tm_mday, t.tm_hour, t.tm_min, t.tm_sec, printableEpoch);
|
||||
timeStartMsec = now;
|
||||
zeroOffsetSecs = tv.tv_sec;
|
||||
if (currentQuality == RTCQualityNone) {
|
||||
timeStartMsec = now;
|
||||
zeroOffsetSecs = tv.tv_sec;
|
||||
currentQuality = RTCQualityDevice;
|
||||
}
|
||||
return RTCSetResultSuccess;
|
||||
|
@ -431,6 +431,8 @@ class LGFX : public lgfx::LGFX_Device
|
||||
#if HAS_TOUCHSCREEN
|
||||
#if defined(T_WATCH_S3) || defined(ELECROW)
|
||||
lgfx::Touch_FT5x06 _touch_instance;
|
||||
#elif defined(TOUCH_CS)
|
||||
lgfx::Touch_XPT2046 _touch_instance;
|
||||
#else
|
||||
lgfx::Touch_GT911 _touch_instance;
|
||||
#endif
|
||||
@ -494,8 +496,17 @@ class LGFX : public lgfx::LGFX_Device
|
||||
#endif
|
||||
cfg.dummy_read_bits = 1; // Number of bits for dummy read before non-pixel data read
|
||||
cfg.readable = true; // Set to true if data can be read
|
||||
#ifndef TFT_INVERSION_OFF
|
||||
cfg.invert = true; // Set to true if the light/darkness of the panel is reversed
|
||||
#else
|
||||
cfg.invert = false;
|
||||
#endif
|
||||
|
||||
#if !defined(TFT_RGB_ORDER) || (TFT_RGB_ORDER == TFT_BGR)
|
||||
cfg.rgb_order = false; // Set to true if the panel's red and blue are swapped
|
||||
#else
|
||||
cfg.rgb_order = true;
|
||||
#endif
|
||||
cfg.dlen_16bit =
|
||||
false; // Set to true for panels that transmit data length in 16-bit units with 16-bit parallel or SPI
|
||||
cfg.bus_shared = true; // If the bus is shared with the SD card, set to true (bus control with drawJpgFile etc.)
|
||||
@ -522,6 +533,7 @@ class LGFX : public lgfx::LGFX_Device
|
||||
#endif
|
||||
|
||||
#if HAS_TOUCHSCREEN
|
||||
#if !defined(TOUCH_CS)
|
||||
// Configure settings for touch screen control.
|
||||
{
|
||||
auto cfg = _touch_instance.config();
|
||||
@ -554,6 +566,30 @@ class LGFX : public lgfx::LGFX_Device
|
||||
_touch_instance.config(cfg);
|
||||
_panel_instance.setTouch(&_touch_instance);
|
||||
}
|
||||
#else // if defined(TOUCH_CS)
|
||||
{
|
||||
// Configure settings for touch control.
|
||||
auto touch_cfg = _touch_instance.config();
|
||||
|
||||
touch_cfg.x_min = TFT_TOUCH_X_MIN;
|
||||
touch_cfg.x_max = TFT_TOUCH_X_MAX;
|
||||
touch_cfg.y_min = TFT_TOUCH_Y_MIN;
|
||||
touch_cfg.y_max = TFT_TOUCH_Y_MAX;
|
||||
touch_cfg.pin_int = -1;
|
||||
touch_cfg.bus_shared = true;
|
||||
touch_cfg.offset_rotation = TFT_TOUCH_OFFSET_ROTATION;
|
||||
// SPI configuration
|
||||
touch_cfg.spi_host = ST7789_SPI_HOST;
|
||||
touch_cfg.freq = SPI_TOUCH_FREQUENCY;
|
||||
touch_cfg.pin_sclk = ST7789_SCK;
|
||||
touch_cfg.pin_mosi = ST7789_SDA;
|
||||
touch_cfg.pin_miso = ST7789_MISO;
|
||||
touch_cfg.pin_cs = TOUCH_CS;
|
||||
|
||||
_touch_instance.config(touch_cfg);
|
||||
_panel_instance.setTouch(&_touch_instance);
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
||||
setPanel(&_panel_instance); // Sets the panel to use.
|
||||
|
@ -419,7 +419,7 @@ void setup()
|
||||
struct timeval tv;
|
||||
tv.tv_sec = time(NULL);
|
||||
tv.tv_usec = 0;
|
||||
perhapsSetRTC(RTCQualityNTP, &tv);
|
||||
perhapsSetRTC(RTCQualityDevice, &tv);
|
||||
#endif
|
||||
|
||||
powerMonInit();
|
||||
|
@ -32,6 +32,16 @@ esp_sleep_source_t wakeCause; // the reason we booted this time
|
||||
#endif
|
||||
#include "Throttle.h"
|
||||
|
||||
#ifdef USE_XL9555
|
||||
#include "ExtensionIOXL9555.hpp"
|
||||
extern ExtensionIOXL9555 io;
|
||||
#endif
|
||||
|
||||
#ifdef HAS_PPM
|
||||
#include <XPowersLib.h>
|
||||
extern XPowersPPM *PPM;
|
||||
#endif
|
||||
|
||||
#ifndef INCLUDE_vTaskSuspend
|
||||
#define INCLUDE_vTaskSuspend 0
|
||||
#endif
|
||||
@ -297,6 +307,14 @@ void doDeepSleep(uint32_t msecToWake, bool skipPreflight = false, bool skipSaveN
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef HAS_PPM
|
||||
if (PPM) {
|
||||
LOG_INFO("PMM shutdown");
|
||||
console->flush();
|
||||
PPM->shutdown();
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef HAS_PMU
|
||||
if (pmu_found && PMU) {
|
||||
// Obsolete comment: from back when we we used to receive lora packets while CPU was in deep sleep.
|
||||
@ -412,6 +430,16 @@ esp_sleep_wakeup_cause_t doLightSleep(uint64_t sleepMsec) // FIXME, use a more r
|
||||
if (pmu_found)
|
||||
gpio_wakeup_enable((gpio_num_t)PMU_IRQ, GPIO_INTR_LOW_LEVEL); // pmu irq
|
||||
#endif
|
||||
|
||||
#ifdef T_LORA_PAGER
|
||||
LOG_DEBUG("power down XL9555 io");
|
||||
io.digitalWrite(EXPANDS_DRV_EN, LOW);
|
||||
io.digitalWrite(EXPANDS_AMP_EN, LOW);
|
||||
io.digitalWrite(EXPANDS_KB_EN, LOW);
|
||||
io.digitalWrite(EXPANDS_SD_EN, LOW);
|
||||
io.digitalWrite(EXPANDS_GPIO_EN, LOW);
|
||||
#endif
|
||||
|
||||
auto res = esp_sleep_enable_gpio_wakeup();
|
||||
if (res != ESP_OK) {
|
||||
LOG_ERROR("esp_sleep_enable_gpio_wakeup result %d", res);
|
||||
@ -452,6 +480,14 @@ esp_sleep_wakeup_cause_t doLightSleep(uint64_t sleepMsec) // FIXME, use a more r
|
||||
gpio_wakeup_disable((gpio_num_t)RF95_IRQ);
|
||||
}
|
||||
#endif
|
||||
#ifdef T_LORA_PAGER
|
||||
LOG_DEBUG("power up XL9555 io");
|
||||
io.digitalWrite(EXPANDS_DRV_EN, HIGH);
|
||||
io.digitalWrite(EXPANDS_AMP_EN, HIGH);
|
||||
io.digitalWrite(EXPANDS_KB_EN, HIGH);
|
||||
io.digitalWrite(EXPANDS_SD_EN, HIGH);
|
||||
io.digitalWrite(EXPANDS_GPIO_EN, HIGH);
|
||||
#endif
|
||||
|
||||
esp_sleep_wakeup_cause_t cause = esp_sleep_get_wakeup_cause();
|
||||
notifyLightSleepEnd.notifyObservers(cause); // Button interrupts are reattached here
|
||||
|
@ -3,7 +3,10 @@ extends = portduino_base
|
||||
build_flags = ${portduino_base.build_flags} -I variants/native/portduino
|
||||
-I /usr/include
|
||||
board = cross_platform
|
||||
lib_deps = ${portduino_base.lib_deps}
|
||||
lib_deps =
|
||||
${portduino_base.lib_deps}
|
||||
melopero/Melopero RV3028@^1.1.0
|
||||
|
||||
build_src_filter = ${portduino_base.build_src_filter}
|
||||
|
||||
[env:native]
|
||||
|
@ -4,4 +4,7 @@
|
||||
#define CANNED_MESSAGE_MODULE_ENABLE 1
|
||||
#define HAS_GPS 1
|
||||
#define MAX_RX_TOPHONE settingsMap[maxtophone]
|
||||
#define MAX_NUM_NODES settingsMap[maxnodes]
|
||||
#define MAX_NUM_NODES settingsMap[maxnodes]
|
||||
|
||||
// RAK12002 RTC Module
|
||||
#define RV3028_RTC (uint8_t)0b1010010
|
@ -208,7 +208,7 @@ No longer populated on PCB
|
||||
#undef AREF_VOLTAGE
|
||||
#define AREF_VOLTAGE 3.0
|
||||
#define VBAT_AR_INTERNAL AR_INTERNAL_3_0
|
||||
#define ADC_MULTIPLIER (4.90F)
|
||||
#define ADC_MULTIPLIER (4.99F)
|
||||
|
||||
#define HAS_RTC 0
|
||||
#ifdef __cplusplus
|
||||
|
@ -1,4 +1,4 @@
|
||||
[VERSION]
|
||||
major = 2
|
||||
minor = 7
|
||||
build = 7
|
||||
build = 8
|
||||
|
Loading…
Reference in New Issue
Block a user