diff --git a/README.md b/README.md index ffa329d40..c0432b66b 100644 --- a/README.md +++ b/README.md @@ -46,7 +46,7 @@ This project is still under development and adds following features: [Full documentation of OpenDTU-onBattery extensions can be found at the project's wiki](https://github.com/helgeerbe/OpenDTU-OnBattery/wiki). -For documentation of openDTU core functionality I refer to the original [repo](https://github.com/tbnobody/OpenDTU) and its [wiki](https://github.com/tbnobody/OpenDTU/wiki). +For documentation of openDTU core functionality I refer to the original [repo](https://github.com/tbnobody/OpenDTU) and its [documentation](https://tbnobody.github.io/OpenDTU-docs/). Please note that openDTU-onBattery may change significantly during its development. Bug reports, comments, feature requests and fixes are most welcome! diff --git a/docs/Display.md b/docs/Display.md index 154aa05ad..c914e4a8d 100644 --- a/docs/Display.md +++ b/docs/Display.md @@ -1,20 +1,3 @@ # Display integration -OpenDTU currently supports 3 types of displays (SSD1306, SH1106 and PCD8544). Currently only displays with a resolution of 128x64 pixel are supported. To activate a display you have to specify it's type and pin assignment either in the `platformio_override.ini` or in a device profile. Due to the fact that device profiles work with the pre-compiled binary the following documentation will only cover the device profile method. - -You can either create your own device profile as described [here](DeviceProfiles.md) or use some pre-defined. The pre-defined profiles can be found [here](DeviceProfiles/). You can simply open the json file with a text editor of your choice to view/edit the pin assignment. - -## Uploading Device Profiles - -Use the "Config Management" site to upload (Restore) the json file. Make sure to choose "Pin Mapping (pin_mapping.json)" in the combo box. After you click on restore the ESP will restart. At this point, the profile is not yet active. Please read the next chapter. -![Config Management](screenshots/14_ConfigManagement.png) - -## Selecting a Device Profile - -After you uploaded the device profile you can select the profile in the "Device Manager" view. After a click on "Save" the ESP will be restarted and the pin assignment is active. At this point the display should already show something. Please see the next chapter for display settings. -![Device Manager](screenshots/20_DeviceManager_Pin.png) - -## Display Settings - -Display settings can also be found in the "Device Manager". -![Device Manager Display](screenshots/21_DeviceManager_Display.png) \ No newline at end of file +This documentation will has been moved and can be found here: diff --git a/docs/UpgradePartition.md b/docs/UpgradePartition.md index f2cd8bf9a..782463f56 100644 --- a/docs/UpgradePartition.md +++ b/docs/UpgradePartition.md @@ -1,21 +1,3 @@ # Upgrade Partition -To be able to install further updates you have to update the partition table of the ESP32. Doing so will **erase** all configuration data. Over The Air update using the web interface is **NOT** possible! - -**So make sure you export a backup of your configuration files before continuing.** - -There are several possibilities to update the partition table: - -- Using Visual Studio Code or PlatformIO CLI - - If you have already used Visual Studio Code or the `platformio` command you can use it again to install the latest version. The partition table is upgraded automatically. - -- Any kind of flash interface - - If you like to use any kind of flash interface like `esptool.py`, Espressif Flash Download Tool, ESP_Flasher or esptool-js you have to make sure to upload the provided .factory.bin file. It is important to enter the correct target address. - - | Address | File | - | ---------| ---------------------- | - | 0x0 | opendtu-*.factory.bin | - -After upgrading the ESP32 will open the intergrated access point (AP) again. Just connect to it using the default password ("openDTU42"). If you are connected, just visit and enter the "Configuration Management". Recover the previously backuped config files. +This documentation will has been moved and can be found here: diff --git a/include/Display_Graphic.h b/include/Display_Graphic.h index 270ee81da..e49bf9f61 100644 --- a/include/Display_Graphic.h +++ b/include/Display_Graphic.h @@ -20,6 +20,7 @@ enum DisplayType_t { SSD1306, SH1106, SSD1309, + ST7567_GM12864I_59N, DisplayType_Max, }; diff --git a/src/Display_Graphic.cpp b/src/Display_Graphic.cpp index 7f5d94c37..12b2aa56e 100644 --- a/src/Display_Graphic.cpp +++ b/src/Display_Graphic.cpp @@ -13,6 +13,7 @@ std::map { DisplayType_t::SSD1306, [](uint8_t reset, uint8_t clock, uint8_t data, uint8_t cs) { return new U8G2_SSD1306_128X64_NONAME_F_HW_I2C(U8G2_R0, reset, clock, data); } }, { DisplayType_t::SH1106, [](uint8_t reset, uint8_t clock, uint8_t data, uint8_t cs) { return new U8G2_SH1106_128X64_NONAME_F_HW_I2C(U8G2_R0, reset, clock, data); } }, { DisplayType_t::SSD1309, [](uint8_t reset, uint8_t clock, uint8_t data, uint8_t cs) { return new U8G2_SSD1309_128X64_NONAME0_F_HW_I2C(U8G2_R0, reset, clock, data); } }, + { DisplayType_t::ST7567_GM12864I_59N, [](uint8_t reset, uint8_t clock, uint8_t data, uint8_t cs) { return new U8G2_ST7567_ENH_DG128064I_F_HW_I2C(U8G2_R0, reset, clock, data); } }, }; // Language defintion, respect order in languages[] and translation lists @@ -50,6 +51,9 @@ void DisplayGraphicClass::init(Scheduler& scheduler, const DisplayType_t type, c if (isValidDisplay()) { auto constructor = display_types[_display_type]; _display = constructor(reset, clk, data, cs); + if (_display_type == DisplayType_t::ST7567_GM12864I_59N) { + _display->setI2CAddress(0x3F << 1); + } _display->begin(); setContrast(DISPLAY_CONTRAST); setStatus(true); diff --git a/src/InverterSettings.cpp b/src/InverterSettings.cpp index cfc990cd1..04ec1e009 100644 --- a/src/InverterSettings.cpp +++ b/src/InverterSettings.cpp @@ -109,6 +109,7 @@ void InverterSettingsClass::init(Scheduler& scheduler) void InverterSettingsClass::settingsLoop() { const CONFIG_T& config = Configuration.get(); + const bool isDayPeriod = SunPosition.isDayPeriod(); for (uint8_t i = 0; i < INV_MAX_COUNT; i++) { auto const& inv_cfg = config.Inverter[i]; @@ -120,8 +121,8 @@ void InverterSettingsClass::settingsLoop() continue; } - inv->setEnablePolling(inv_cfg.Poll_Enable && (SunPosition.isDayPeriod() || inv_cfg.Poll_Enable_Night)); - inv->setEnableCommands(inv_cfg.Command_Enable && (SunPosition.isDayPeriod() || inv_cfg.Command_Enable_Night)); + inv->setEnablePolling(inv_cfg.Poll_Enable && (isDayPeriod || inv_cfg.Poll_Enable_Night)); + inv->setEnableCommands(inv_cfg.Command_Enable && (isDayPeriod || inv_cfg.Command_Enable_Night)); } } diff --git a/webapp/package.json b/webapp/package.json index ab152cd4e..ac787a8e1 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -14,7 +14,7 @@ "dependencies": { "@popperjs/core": "^2.11.8", "bootstrap": "^5.3.2", - "bootstrap-icons-vue": "^1.11.1", + "bootstrap-icons-vue": "^1.11.3", "mitt": "^3.0.1", "sortablejs": "^1.15.2", "spark-md5": "^3.0.2", @@ -24,10 +24,10 @@ }, "devDependencies": { "@intlify/unplugin-vue-i18n": "^2.0.0", - "@rushstack/eslint-patch": "^1.7.0", + "@rushstack/eslint-patch": "^1.7.2", "@tsconfig/node18": "^18.2.2", "@types/bootstrap": "^5.2.10", - "@types/node": "^20.11.5", + "@types/node": "^20.11.7", "@types/pulltorefreshjs": "^0.1.7", "@types/sortablejs": "^1.15.7", "@types/spark-md5": "^3.0.4", diff --git a/webapp/yarn.lock b/webapp/yarn.lock index 14f673bdd..f1d1b4b46 100644 --- a/webapp/yarn.lock +++ b/webapp/yarn.lock @@ -408,10 +408,10 @@ resolved "https://registry.yarnpkg.com/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.4.1.tgz#8311b77e6cce322865ba12ada8c3779369610d18" integrity sha512-eAhItDX9yQtZVM3yvXS/VR3qPqcnXvnLyx1pLXl4JzyNMBNO3KC986t/iAg2zcMzpAp9JSvxB5VZGnBiNoA98w== -"@rushstack/eslint-patch@^1.7.0": - version "1.7.0" - resolved "https://registry.yarnpkg.com/@rushstack/eslint-patch/-/eslint-patch-1.7.0.tgz#b5bc1e081428794f6a4d239707b359404be35ce2" - integrity sha512-Jh4t/593gxs0lJZ/z3NnasKlplXT2f+4y/LZYuaKZW5KAaiVFL/fThhs+17EbUd53jUVJ0QudYCBGbN/psvaqg== +"@rushstack/eslint-patch@^1.7.2": + version "1.7.2" + resolved "https://registry.yarnpkg.com/@rushstack/eslint-patch/-/eslint-patch-1.7.2.tgz#2d4260033e199b3032a08b41348ac10de21c47e9" + integrity sha512-RbhOOTCNoCrbfkRyoXODZp75MlpiHMgbE5MEBZAnnnLyQNgrigEj4p0lzsMDyc1zVsJDLrivB58tgg3emX0eEA== "@tsconfig/node18@^18.2.2": version "18.2.2" @@ -435,10 +435,10 @@ resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.12.tgz#d70faba7039d5fca54c83c7dbab41051d2b6f6cb" integrity sha512-Hr5Jfhc9eYOQNPYO5WLDq/n4jqijdHNlDXjuAQkkt+mWdQR+XJToOHrsD4cPaMXpn6KO7y2+wM8AZEs8VpBLVA== -"@types/node@^20.11.5": - version "20.11.5" - resolved "https://registry.yarnpkg.com/@types/node/-/node-20.11.5.tgz#be10c622ca7fcaa3cf226cf80166abc31389d86e" - integrity sha512-g557vgQjUUfN76MZAN/dt1z3dzcUsimuysco0KeluHgrPdJXkP/XdAURgyO2W9fZWHRtRBiVKzKn8vyOAwlG+w== +"@types/node@^20.11.7": + version "20.11.7" + resolved "https://registry.yarnpkg.com/@types/node/-/node-20.11.7.tgz#cb49aedd758c978c30806d0c38b520ed2a3df6e0" + integrity sha512-GPmeN1C3XAyV5uybAf4cMLWT9fDWcmQhZVtMFu7OR32WjrqGG+Wnk2V1d0bmtUyE/Zy1QJ9BxyiTih9z8Oks8A== dependencies: undici-types "~5.26.4" @@ -855,10 +855,10 @@ boolbase@^1.0.0: resolved "https://registry.yarnpkg.com/boolbase/-/boolbase-1.0.0.tgz#68dff5fbe60c51eb37725ea9e3ed310dcc1e776e" integrity sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww== -bootstrap-icons-vue@^1.11.1: - version "1.11.1" - resolved "https://registry.yarnpkg.com/bootstrap-icons-vue/-/bootstrap-icons-vue-1.11.1.tgz#6b0359e8f1a538b2a14e1ced5ba927391f7e3abe" - integrity sha512-vQELXxclY2LauUJ7OMXScv1j+mJS2K2h7NTgW7yDG954dI+SC2QHLKg+Mc7qmCDZ+3oMayeLqmFTDX0GBmdobA== +bootstrap-icons-vue@^1.11.3: + version "1.11.3" + resolved "https://registry.yarnpkg.com/bootstrap-icons-vue/-/bootstrap-icons-vue-1.11.3.tgz#717745c433b2043d6d1ec24260b9bbc9eea16c66" + integrity sha512-Xba1GTDYon8KYSDTKiiAtiyfk4clhdKQYvCQPMkE58+F5loVwEmh0Wi+ECCfowNc9SGwpoSLpSkvg7rhgZBttw== bootstrap@^5.3.2: version "5.3.2" diff --git a/webapp_dist/index.html.gz b/webapp_dist/index.html.gz index be84fc7db..3f62e3dc5 100644 Binary files a/webapp_dist/index.html.gz and b/webapp_dist/index.html.gz differ diff --git a/webapp_dist/js/app.js.gz b/webapp_dist/js/app.js.gz index cdb5bb647..8d177806b 100644 Binary files a/webapp_dist/js/app.js.gz and b/webapp_dist/js/app.js.gz differ diff --git a/webapp_dist/zones.json.gz b/webapp_dist/zones.json.gz index 02f82db68..6e5a69eae 100644 Binary files a/webapp_dist/zones.json.gz and b/webapp_dist/zones.json.gz differ