mirror of
https://github.com/meshtastic/firmware.git
synced 2025-06-09 14:42:05 +00:00
Fix exclude macros (#4233)
* fix MESHTASTIC_EXCLUDE_BLUETOOTH * fix HAS_SCREEN=0 * fix MESHTASTIC_EXCLUDE_GPS
This commit is contained in:
parent
c1df621711
commit
ae420dcd21
@ -173,6 +173,7 @@ void RedirectablePrint::log_to_syslog(const char *logLevel, const char *format,
|
|||||||
|
|
||||||
void RedirectablePrint::log_to_ble(const char *logLevel, const char *format, va_list arg)
|
void RedirectablePrint::log_to_ble(const char *logLevel, const char *format, va_list arg)
|
||||||
{
|
{
|
||||||
|
#if !MESHTASTIC_EXCLUDE_BLUETOOTH
|
||||||
if (config.bluetooth.device_logging_enabled && !pauseBluetoothLogging) {
|
if (config.bluetooth.device_logging_enabled && !pauseBluetoothLogging) {
|
||||||
bool isBleConnected = false;
|
bool isBleConnected = false;
|
||||||
#ifdef ARCH_ESP32
|
#ifdef ARCH_ESP32
|
||||||
@ -211,6 +212,11 @@ void RedirectablePrint::log_to_ble(const char *logLevel, const char *format, va_
|
|||||||
delete[] buffer;
|
delete[] buffer;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
(void)logLevel;
|
||||||
|
(void)format;
|
||||||
|
(void)arg;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
meshtastic_LogRecord_Level RedirectablePrint::getLogLevel(const char *logLevel)
|
meshtastic_LogRecord_Level RedirectablePrint::getLogLevel(const char *logLevel)
|
||||||
|
@ -22,6 +22,10 @@ class Screen
|
|||||||
void doDeepSleep() {}
|
void doDeepSleep() {}
|
||||||
void forceDisplay(bool forceUiUpdate = false) {}
|
void forceDisplay(bool forceUiUpdate = false) {}
|
||||||
void startFirmwareUpdateScreen() {}
|
void startFirmwareUpdateScreen() {}
|
||||||
|
void increaseBrightness() {}
|
||||||
|
void decreaseBrightness() {}
|
||||||
|
void setFunctionSymbal(std::string) {}
|
||||||
|
void removeFunctionSymbal(std::string) {}
|
||||||
void startAlert(const char *) {}
|
void startAlert(const char *) {}
|
||||||
void endAlert() {}
|
void endAlert() {}
|
||||||
};
|
};
|
||||||
|
@ -269,7 +269,7 @@ bool MeshService::trySendPosition(NodeNum dest, bool wantReplies)
|
|||||||
assert(node);
|
assert(node);
|
||||||
|
|
||||||
if (hasValidPosition(node)) {
|
if (hasValidPosition(node)) {
|
||||||
#if HAS_GPS
|
#if HAS_GPS && !MESHTASTIC_EXCLUDE_GPS
|
||||||
if (positionModule) {
|
if (positionModule) {
|
||||||
LOG_INFO("Sending position ping to 0x%x, wantReplies=%d, channel=%d\n", dest, wantReplies, node->channel);
|
LOG_INFO("Sending position ping to 0x%x, wantReplies=%d, channel=%d\n", dest, wantReplies, node->channel);
|
||||||
positionModule->sendOurPosition(dest, wantReplies, node->channel);
|
positionModule->sendOurPosition(dest, wantReplies, node->channel);
|
||||||
|
@ -232,9 +232,9 @@ bool AdminModule::handleReceivedProtobuf(const meshtastic_MeshPacket &mp, meshta
|
|||||||
#if !MESHTASTIC_EXCLUDE_GPS
|
#if !MESHTASTIC_EXCLUDE_GPS
|
||||||
if (gps != nullptr)
|
if (gps != nullptr)
|
||||||
gps->enable();
|
gps->enable();
|
||||||
#endif
|
|
||||||
// Send our new fixed position to the mesh for good measure
|
// Send our new fixed position to the mesh for good measure
|
||||||
positionModule->sendOurPosition();
|
positionModule->sendOurPosition();
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user