diff --git a/data b/data index 653a39d..266a99b 160000 --- a/data +++ b/data @@ -1 +1 @@ -Subproject commit 653a39d0a339bcf3ac3365eacd2e5e8136ecf4c6 +Subproject commit 266a99be96189bea92e0ef593f930bb92d3b5b20 diff --git a/src/lib/defaults.hpp b/src/lib/defaults.hpp index ada5531..11df69a 100644 --- a/src/lib/defaults.hpp +++ b/src/lib/defaults.hpp @@ -70,3 +70,4 @@ #define DEFAULT_ACTIVE_CURRENCIES "USD,EUR,JPY" #define DEFAULT_GIT_RELEASE_URL "https://git.btclock.dev/api/v1/repos/btclock/btclock_v3/releases/latest" +#define DEFAULT_VERTICAL_DESC true diff --git a/src/lib/epd.cpp b/src/lib/epd.cpp index 1c04725..986b9cc 100644 --- a/src/lib/epd.cpp +++ b/src/lib/epd.cpp @@ -373,7 +373,11 @@ extern "C" void updateDisplay(void *pvParameters) noexcept void splitText(const uint dispNum, const String &top, const String &bottom, bool partial) { - displays[dispNum].setRotation(2); + if(preferences.getBool("verticalDesc", DEFAULT_VERTICAL_DESC) && dispNum == 0) { + displays[dispNum].setRotation(1); + } else { + displays[dispNum].setRotation(2); + } displays[dispNum].setFont(&FONT_SMALL); displays[dispNum].setTextColor(getFgColor()); diff --git a/src/lib/webserver.cpp b/src/lib/webserver.cpp index b901379..11b9024 100644 --- a/src/lib/webserver.cpp +++ b/src/lib/webserver.cpp @@ -549,6 +549,7 @@ void onApiSettingsPatch(AsyncWebServerRequest *request, JsonVariant &json) "mowMode", "suffixShareDot", "flOffWhenDark", "flAlwaysOn", "flDisable", "flFlashOnUpd", "mempoolSecure", "useNostr", "bitaxeEnabled", + "verticalDesc", "nostrZapNotify", "stagingSource", "httpAuthEnabled"}; for (String setting : boolSettings) @@ -689,6 +690,8 @@ void onApiSettingsGet(AsyncWebServerRequest *request) root["suffixPrice"] = preferences.getBool("suffixPrice", DEFAULT_SUFFIX_PRICE); root["disableLeds"] = preferences.getBool("disableLeds", DEFAULT_DISABLE_LEDS); root["mowMode"] = preferences.getBool("mowMode", DEFAULT_MOW_MODE); + root["verticalDesc"] = preferences.getBool("verticalDesc", DEFAULT_VERTICAL_DESC); + root["suffixShareDot"] = preferences.getBool("suffixShareDot", DEFAULT_SUFFIX_SHARE_DOT); root["hostnamePrefix"] = preferences.getString("hostnamePrefix", DEFAULT_HOSTNAME_PREFIX);