Initial commit: LoRa APRS Beacon для T-Beam V1.2

- Статический маяк с координатами 67.369281N, 32.497063E
- Отправка каждые 10 минут + при включении
- APRS символ L в чёрном ромбике, позывной UA1ZBE-TS
- Дисплей SH1106 1.3 повёрнутый
- Мониторинг напряжения батареи в сообщении
- Кнопка для ручной отправки
- Частота 433.775 MHz, SF12, BW125

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
This commit is contained in:
ua1zbe
2026-04-04 20:59:12 +00:00
committed by UA1ZBE
commit b48f588921
9 changed files with 517 additions and 0 deletions

59
src/power_management.h Normal file
View File

@@ -0,0 +1,59 @@
#ifndef POWER_MANAGEMENT_H_
#define POWER_MANAGEMENT_H_
#include <Wire.h>
#include <XPowersLibInterface.hpp>
class PowerManagement {
public:
~PowerManagement() {
}
virtual bool begin(TwoWire &port) = 0;
virtual void activateLoRa() = 0;
virtual void deactivateLoRa() = 0;
virtual void activateGPS() = 0;
virtual void deactivateGPS() = 0;
virtual void activateOLED() = 0;
virtual void deactivateOLED() = 0;
virtual void activateMeasurement() = 0;
virtual void deactivateMeasurement() = 0;
virtual double getBatteryVoltage() = 0;
virtual bool isBatteryConnect() = 0;
virtual bool isCharging() = 0;
protected:
XPowersLibInterface *_pmu = 0;
};
class AXP2101 : public PowerManagement {
public:
AXP2101();
bool begin(TwoWire &port);
void activateLoRa();
void deactivateLoRa();
void activateGPS();
void deactivateGPS();
void activateOLED();
void deactivateOLED();
void activateMeasurement();
void deactivateMeasurement();
double getBatteryVoltage();
bool isBatteryConnect();
bool isCharging();
};
#endif