From d9ad8e8d21986d3038df7353093af6d056e8e5ad Mon Sep 17 00:00:00 2001 From: Stephan <31169771+Blueforcer@users.noreply.github.com> Date: Tue, 12 Mar 2024 10:11:50 +0100 Subject: [PATCH] v0.95 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Rebranding AWTRIX Light to AWTRIX 3 - **Enhancements:** - Implemented median and mean filters for more accurate processing of raw data from LDR and BATT sensors. - Added Cyrillic support, limited to UPPERCASE letters. Issue #467 closed. 🇷🇺 - Introduced overlays for weather animations accessible via the /settings API or customapp/notifications. Available overlays: clear, snow, drizzle, rain, storm, thunder, frost. closes #454 - **Features:** - Added AP Mode timeout configuration via dev.json. ⏱️ - The hostname isnt the same as the MQTT prefix anymore. Instead you can set "hostname" in your dev.json. 🏠 - Supports SSIDs with 32 characters. 🔒 - Web port can now be changed via dev.json. 🌐 - Unified firmware versions for peripherals, allowing Ulanzi firmware to control DFPlayer and read temperature sensors and vice versa. Only port mapping differs. DFPlayer can be enabled in dev.json. 🔄 - **Bug Fixes:** - Resolved issue where using custom apps and sending text in colored fragments prevented reverting to a single color. Issue #464 closed. 🐛 - Fixed URL forwarding in the web interface. Issue #501 closed. 🔗 - **Miscellaneous:** - Added functionality to control the volume of the buzzer or DFPlayer via on-screen menu or settings API. 🔊 - Enabled reset button on the back of Ulanzi; holding it for 5 seconds initiates a full reset of the AWTRIX firmware. 🔧 --- .devcontainer/devcontainer.json | 2 +- .github/ISSUE_TEMPLATE/bug_report.md | 4 +- .github/ISSUE_TEMPLATE/feature_request.md | 2 +- Helper_Scripts/Awtrix_Clone.py | 2 +- Helper_Scripts/screenmirror.py | 2 +- README.md | 22 +- docs/README.md | 14 +- docs/Test_Flasher/firmware/manifest.json | 2 +- docs/Test_Flasher/index.html | 8 +- docs/_coverpage.md | 6 +- docs/api.md | 74 +- docs/apps.md | 12 +- docs/awtrix2_flasher/firmware/manifest.json | 2 +- docs/awtrix2_flasher/index.html | 8 +- docs/backup.html | 10 +- docs/dev.md | 9 +- docs/effects.md | 40 +- docs/faq.md | 14 +- docs/hardware.md | 2 +- docs/icons.md | 2 +- docs/index.html | 4 +- docs/onscreen.md | 2 +- docs/sounds.md | 4 +- docs/ulanzi_flasher/firmware/manifest.json | 2 +- docs/ulanzi_flasher/index.html | 8 +- lib/MedianFilterLib/.piopm | 1 + lib/MedianFilterLib/LICENSE | 201 +++ lib/MedianFilterLib/README.md | 109 ++ .../MedianFilterFloat/MedianFilterFloat.ino | 47 + .../MedianFilterInt/MedianFilterInt.ino | 47 + lib/MedianFilterLib/keywords.txt | 18 + lib/MedianFilterLib/library.properties | 9 + lib/MedianFilterLib/src/MedianFilterLib.h | 171 ++ lib/Melody Player/src/melody_player.cpp | 58 +- lib/Melody Player/src/melody_player.h | 45 +- lib/webserver/esp-fs-webserver.cpp | 25 +- lib/webserver/esp-fs-webserver.h | 2 +- lib/webserver/setup_htm.h | 1569 +++++++++-------- platformio.ini | 24 +- src/Apps.cpp | 7 +- src/Apps.h | 1 + src/AwtrixFont.h | 4 +- src/Dictionary.cpp | 2 +- src/DisplayManager.cpp | 49 +- src/GameManager.cpp | 4 +- src/Globals.cpp | 46 +- src/Globals.h | 15 +- src/MQTTManager.cpp | 6 +- src/MatrixDisplayUi.cpp | 55 +- src/MatrixDisplayUi.h | 2 +- src/MenuManager.cpp | 30 +- src/Overlays.cpp | 47 +- src/Overlays.h | 6 +- src/PeripheryManager.cpp | 263 +-- src/PeripheryManager.h | 6 +- src/ServerManager.cpp | 38 +- src/ServerManager.h | 2 +- src/UpdateManager.cpp | 6 +- src/effects.cpp | 176 +- src/effects.h | 15 + src/htmls.h | 4 +- src/main.cpp | 19 +- src/timer.h | 1 + 63 files changed, 2169 insertions(+), 1218 deletions(-) create mode 100644 lib/MedianFilterLib/.piopm create mode 100644 lib/MedianFilterLib/LICENSE create mode 100644 lib/MedianFilterLib/README.md create mode 100644 lib/MedianFilterLib/examples/MedianFilterFloat/MedianFilterFloat.ino create mode 100644 lib/MedianFilterLib/examples/MedianFilterInt/MedianFilterInt.ino create mode 100644 lib/MedianFilterLib/keywords.txt create mode 100644 lib/MedianFilterLib/library.properties create mode 100644 lib/MedianFilterLib/src/MedianFilterLib.h diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 704e51df..482cc6b0 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -1,7 +1,7 @@ // For format details, see https://aka.ms/devcontainer.json. For config options, see the // README at: https://github.com/devcontainers/templates/tree/main/src/cpp { - "name": "awtrix-light", + "name": "awtrix3", "build": { "dockerfile": "Dockerfile" } diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 142b2d25..0090eff9 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -6,7 +6,7 @@ labels: bug assignees: '' --- - + # Bug report @@ -18,7 +18,7 @@ Add a description of the bug. Detail the expected behaviour in contrast with the - Devices involved: - Model: Ulanzi Awtrix Smart Pixel Clock 2882 (TC001) - - AWTRIX-LIGHT version: [ eg. v0.45 ] + - awtrix3 version: [ eg. v0.45 ] ## To Reproduce diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index d9e7fe97..c02e07dd 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -6,7 +6,7 @@ labels: feature request assignees: '' --- - + # Feature Request diff --git a/Helper_Scripts/Awtrix_Clone.py b/Helper_Scripts/Awtrix_Clone.py index 42ad50db..f82b23d4 100644 --- a/Helper_Scripts/Awtrix_Clone.py +++ b/Helper_Scripts/Awtrix_Clone.py @@ -1,4 +1,4 @@ -#Clones the ICONS and MELODIES folder from one to another AWTRIX Light +#Clones the ICONS and MELODIES folder from one to another AWTRIX 3 import os import argparse diff --git a/Helper_Scripts/screenmirror.py b/Helper_Scripts/screenmirror.py index d54eb5fa..cc0011d3 100644 --- a/Helper_Scripts/screenmirror.py +++ b/Helper_Scripts/screenmirror.py @@ -80,6 +80,6 @@ def capture_image(self): # Hauptteil des Programms root = tk.Tk() root.resizable(False, False) -ip_address = simpledialog.askstring("AWTRIX LIGHT", "Please enter IP address:") +ip_address = simpledialog.askstring("AWTRIX 3", "Please enter IP address:") app = LedScreenApp(root, ip_address) root.mainloop() \ No newline at end of file diff --git a/README.md b/README.md index ed6062e4..24cdb705 100644 --- a/README.md +++ b/README.md @@ -11,13 +11,13 @@ ![Alt text](/logo.png?raw=true "Title")
-![GitHub all releases](https://img.shields.io/github/downloads/blueforcer/awtrix-light/total?style=flat-square) +![GitHub all releases](https://img.shields.io/github/downloads/blueforcer/awtrix3/total?style=flat-square) ![GitHub Sponsors](https://img.shields.io/github/sponsors/blueforcer?style=flat-square) ![Discord](https://img.shields.io/discord/546407049148366859?label=Discord&style=flat-square)
-**AWTRIX Light is an open‑source custom firmware for the [Ulanzi Smart Pixel clock TC001](https://www.ulanzi.com/products/ulanzi-pixel-smart-clock-2882?ref=28e02dxl) or as upgrade for the old AWTRIX 2 Mainboard and even self build matrix clock** +**AWTRIX 3 is an open‑source custom firmware for the [Ulanzi Smart Pixel clock TC001](https://www.ulanzi.com/products/ulanzi-pixel-smart-clock-2882?ref=28e02dxl) or as upgrade for the old AWTRIX 2 Mainboard and even self build matrix clock** **Note: This Firmware is only compatible with ESP32** @@ -29,11 +29,11 @@ Our discord community, with over 3000 people, are willing to help you! It is ready to use straight out of the box, with time, date, temperature, and humidity pages pre-installed. You don't need to do anything other than turning it on to start using these features. -However, for those with more advanced skills, the customization options available with customapps and mqtt commands allows you to take Awtrix Light to its full potential. +However, for those with more advanced skills, the customization options available with customapps and mqtt commands allows you to take AWTRIX 3 to its full potential. Just send all your customapps from your smarthome via MQTT or HTTP and update it in realtime. The powerful icon system brings your ideas to life and lets you enjoy a hassle-free experience. -Join the thousands of satisfied awtrix users who have already chosen Awtrix 2 and Awtrix Light and experience the difference today! +Join the thousands of satisfied awtrix users who have already chosen Awtrix 2 and AWTRIX 3 and experience the difference today! @@ -47,13 +47,13 @@ Take your Awtrix experience to the next level with the mobile app, tailored for - **Exclusive Icon Database:** Get unique icons only available for app users. - **Icon Creation & Sharing:** Design and share your icons with our community. -By purchasing the app, you're directly contributing to the future of Awtrix Light. Dive deep, explore more, and be a part of the innovation. +By purchasing the app, you're directly contributing to the future of AWTRIX 3. Dive deep, explore more, and be a part of the innovation. Support our journey and enhance your Awtrix experience. Your contribution matters. ✨ Get it on Google Play - + Get it on Google Play @@ -63,8 +63,8 @@ Support our journey and enhance your Awtrix experience. Your contribution matter -# AWTRIX Light flows -This is your go-to hub for sharing and discovering AWTRIX Light automations. Enhance your AWTRIX Light experience, exchange ideas, and get inspired. Let's bring our creative automations to life together! +# AWTRIX 3 flows +This is your go-to hub for sharing and discovering AWTRIX 3 automations. Enhance your AWTRIX 3 experience, exchange ideas, and get inspired. Let's bring our creative automations to life together! https://flows.blueforcer.de/ # Features @@ -89,7 +89,7 @@ https://flows.blueforcer.de/ # Getting Started Starting is easy as 1-2-3 -[with the documentation](https://blueforcer.github.io/awtrix-light/) +[with the documentation](https://blueforcer.github.io/awtrix3/) # Community Join the discord channel with over 3000 Users @@ -118,8 +118,8 @@ https://www.buymeacoffee.com/blueforcer https://www.paypal.me/blueforcer # Contributors - - + + # Disclaimer diff --git a/docs/README.md b/docs/README.md index 50d358a8..3547e6a6 100644 --- a/docs/README.md +++ b/docs/README.md @@ -1,18 +1,18 @@ -# AWTRIX-LIGHT +# awtrix3 !> This open-source software is not affiliated with or endorsed by the company Ulanzi in any way. Use of the software is at your own risk and discretion, and i assume no liability for any potential damages or issues that may arise from using the software. It is important to be aware that using this open-source software comes without direct support or guarantees from the company Ulanzi. -Awtrix Light is a custom firmware for the [Ulanzi Smart Pixel clock](https://www.ulanzi.com/products/ulanzi-pixel-smart-clock-2882?ref=28e02dxl) (Ref link). +AWTRIX 3 is a custom firmware for the [Ulanzi Smart Pixel clock](https://www.ulanzi.com/products/ulanzi-pixel-smart-clock-2882?ref=28e02dxl) (Ref link). It meant to be a companion for your smarthome like HomeAssistant, IOBroker, NodeRed and so on. Even if you don't have a Smarthome system, but would like to experiment, you are still welcome to join us. There are many users who are willing to help you! It is ready to use straight out of the box, with time, date, temperature, and humidity apps pre-installed. You don't need to do anything other than turning it on to start using these features. -During the development of Awtrix Light, usability and simplicity are my top priorities. My aim is to make it easy for non-tech-savvy users to benefit from Awtrix Light without any headaches or hours of scripting. -Awtrix Light is ready to use straight out of the box, without the need for a single line of code. -However, for those with more advanced skills, the customization options available with custom apps allow you to take Awtrix Light to its full potential. -With Awtrix Light, you can effortlessly bring your ideas to life and enjoy a hassle-free experience. -Join the thousands of satisfied awtrix users who have already chosen Awtrix 2 and Awtrix Light and experience the difference today! +During the development of AWTRIX 3, usability and simplicity are my top priorities. My aim is to make it easy for non-tech-savvy users to benefit from AWTRIX 3 without any headaches or hours of scripting. +AWTRIX 3 is ready to use straight out of the box, without the need for a single line of code. +However, for those with more advanced skills, the customization options available with custom apps allow you to take AWTRIX 3 to its full potential. +With AWTRIX 3, you can effortlessly bring your ideas to life and enjoy a hassle-free experience. +Join the thousands of satisfied awtrix users who have already chosen Awtrix 2 and AWTRIX 3 and experience the difference today! https://discord.gg/cyBCpdx ## Support diff --git a/docs/Test_Flasher/firmware/manifest.json b/docs/Test_Flasher/firmware/manifest.json index 4a1e63a0..8a203519 100644 --- a/docs/Test_Flasher/firmware/manifest.json +++ b/docs/Test_Flasher/firmware/manifest.json @@ -1,5 +1,5 @@ { - "name": "AWTRIX Light", + "name": "AWTRIX 3", "version": "0.81", "home_assistant_domain": "AwtrixLight", "funding_url": "https://blueforcer.de", diff --git a/docs/Test_Flasher/index.html b/docs/Test_Flasher/index.html index 8d65071a..7adb73a8 100644 --- a/docs/Test_Flasher/index.html +++ b/docs/Test_Flasher/index.html @@ -2,10 +2,10 @@ - AWTRIX LIGHT + AWTRIX 3 @@ -86,8 +86,8 @@

BACKUP YOUR FLASH!

-

AWTRIX Light Backup & Restore

+

AWTRIX 3 Backup & Restore

- This tool allows you to create a backup of your AWTRIX Light by downloading all its files into a ZIP + This tool allows you to create a backup of your AWTRIX 3 by downloading all its files into a ZIP archive. You can also restore a backup by uploading a ZIP archive.

@@ -100,7 +100,7 @@

} document.getElementById('backupButton').addEventListener('click', async function () { - const source_ip = prompt("Enter the AWTRIX Light IP address:"); + const source_ip = prompt("Enter the AWTRIX 3 IP address:"); let zip = new JSZip(); await getFilesFromDirectory(source_ip, '/', zip); @@ -126,7 +126,7 @@ }); document.getElementById('fileInput').addEventListener('change', async function () { - const target_ip = prompt("Enter the AWTRIX Light IP address:"); + const target_ip = prompt("Enter the AWTRIX 3 IP address:"); const file = this.files[0]; const zip = new JSZip(); diff --git a/docs/dev.md b/docs/dev.md index 73b549e1..ba420bd5 100644 --- a/docs/dev.md +++ b/docs/dev.md @@ -12,6 +12,8 @@ The JSON object has the following properties: | Key | Type | Description | Default | | --- | ---- | ----------- | ------- | +| `hostname` | string | Changes the hostname of your awtrix. This is used for App discovery, mDNS etc. | uniqeID | +| `ap_timeout` | integer | The timeout in seconds before AWTRIX switches to AP mode if the saved WLAN was not found. | 15 | | `bootsound` | string | Uses a custom melodie while booting | | | `matrix` | integer | Changes the matrix layout (0,1 or 2) | `0` | | `color_correction` | array of int | Sets the colorcorrection of the matrix | `[255,255,255]` | @@ -29,20 +31,19 @@ The JSON object has the following properties: | `min_battery` | integer | Calibrates the minimum battery measurement by the given raw value. You will get that from the stats api | `475` | | `max_battery` | integer | Calibrates the maximum battery measurement by the given raw value. You will get that from the stats api | `665` | | `ha_prefix` | string | Sets the prefix for Homassistant discovery | `homeassistant` | -| `background_effect` | string | Sets an [effect](https://blueforcer.github.io/awtrix-light/#/effects) as global background layer | - | +| `background_effect` | string | Sets an [effect](https://blueforcer.github.io/awtrix3/#/effects) as global background layer | - | | `stats_interval` | integer | Sets the interval in milliseconds when awtrix should send its stats to HA and MQTT | 10000 | | `debug_mode` | boolean | Enables serial debug outputs. | false | | `dfplayer` | boolean | Enables DFPLayer for Awtrix2_conversation builds. | false | | `button_callback` | string | http callback url for button presses. | - | -| `let_it_snow` | boolean | Let it snow as a global Overlay. | true for christmastime | | `new_year` | boolean | Displays fireworks and plays a jingle at newyear. | false | + #### Example: ```json { "temp_dec_places":1, "bootsound":true, - "hum_offset":-2, - "let_it_snow": true + "hum_offset":-2 } ``` \ No newline at end of file diff --git a/docs/effects.md b/docs/effects.md index 2348db08..e449bcad 100644 --- a/docs/effects.md +++ b/docs/effects.md @@ -1,6 +1,6 @@ # Effects -AWTRIX light can show effects wherever you want +AWTRIX 3 can show effects wherever you want - Notification and CustomApps. This will show the effect as the first layer, so you can still draw text over it. - Backgroundlayer. This will show the effect behind everything and in each app. You can add it via Hidden features. @@ -17,58 +17,58 @@ Its also accessible via HTTTP /api/effects BrickBreaker - + Checkerboard - + Fireworks - + PingPong - + Radar - + Ripple - + Snake - + TwinklingStars - + TheaterChase - + ColorWaves - + SwirlOut - + SwirlIn - + LookingEyes - + Matrix - + Pacifica - + Plasma - + PlasmaCloud - + MovingLine - + @@ -158,7 +158,7 @@ Remember, the colors you define in your palette serve as key points in the color # Artnet (DMX) -Awtrix light supports Artnet out of the box. +AWTRIX 3 supports Artnet out of the box. For [Jinx!](http://www.live-leds.de/) you can download this template. Just change the IP of both universes to your awtrix IP and you're ready to go. **For any Other Artnet controller:** diff --git a/docs/faq.md b/docs/faq.md index eee824b1..2750f4e0 100644 --- a/docs/faq.md +++ b/docs/faq.md @@ -4,7 +4,7 @@ Welcome to the FAQ section. Here, you'll find answers to some of the most common ### Table of Contents - [General Questions](#general-questions) - - [Can I run AWTRIX Light standalone?](#q-can-i-run-awtrix-light-standalone) + - [Can I run AWTRIX 3 standalone?](#q-can-i-run-awtrix3-standalone) - [Can I use different matrix sizes other than 8x32?](#q-can-i-use-different-matrix-sizes-other-than-8x32) - [Error while flashing my Ulanzi clock](#q-why-am-i-getting-an-error-while-flashing-my-ulanzi-clock-with-the-awtrix-web-flasher) - [Accidentally touched DoNotTouch.json](#q-what-should-i-do-if-i-accidentally-touched-the-donottouchjson-file-in-awtrix-web-file-manager) @@ -15,7 +15,7 @@ Welcome to the FAQ section. Here, you'll find answers to some of the most common ### General Questions -#### Q: Can I Run AWTRIX Light Standalone? +#### Q: Can I Run AWTRIX 3 Standalone? A: No, AWTRIX is designed as a companion for your smart home system. It displays information based on what you send through its API. #### Q: Can I Use Different Matrix Sizes Other Than 8x32? @@ -56,13 +56,13 @@ Reboot the device #### Q: I want to build my own AWTRIX, which firmware should I use? A: Please read the options you have specified below -#### Option 1: [Ulanzi TC001 and Custom Builds Flasher](https://blueforcer.github.io/awtrix-light/#/flasher?id=ulanzi-tc001-and-custom-builds-flasher) +#### Option 1: [Ulanzi TC001 and Custom Builds Flasher](https://blueforcer.github.io/awtrix3/#/flasher?id=ulanzi-tc001-and-custom-builds-flasher) - **Firmware Compatibility**: This firmware is compatible with both the Ulanzi TC001 and custom build AWTRIX devices using any ESP32-WROOM board, including the ESP32 D1 Mini. -- **Pinout Guide**: Ensure you follow the specific pinout for your custom build to function correctly with this firmware. The pinout guide is available at: [AWTRIX Light Hardware Guide](https://blueforcer.github.io/awtrix-light/#/hardware) +- **Pinout Guide**: Ensure you follow the specific pinout for your custom build to function correctly with this firmware. The pinout guide is available at: [AWTRIX 3 Hardware Guide](https://blueforcer.github.io/awtrix3/#/hardware) -#### Option 2: [Awtrix 2.0 Controller Upgrade (with ESP32 D1 Mini)](https://blueforcer.github.io/awtrix-light/#/flasher?id=awtrix-20-controller-upgrade-with-esp32-d1-mini) -- **Firmware Purpose**: This firmware is specifically designed for upgrading an old AWTRIX 2.0. The original AWTRIX 2.0 was built with a Wemos D1 mini (ESP8266), which is not supported by AWTRIX Light. +#### Option 2: [Awtrix 2.0 Controller Upgrade (with ESP32 D1 Mini)](https://blueforcer.github.io/awtrix3/#/flasher?id=awtrix-20-controller-upgrade-with-esp32-d1-mini) +- **Firmware Purpose**: This firmware is specifically designed for upgrading an old AWTRIX 2.0. The original AWTRIX 2.0 was built with a Wemos D1 mini (ESP8266), which is not supported by AWTRIX 3. - **Upgrade Requirements**: To upgrade, the ESP8266 needs to be replaced with an ESP32 D1 Mini. The ESP32 D1 Mini maintains the same form factor, allowing it to replace the older module on the motherboard directly. - **Pinout Compatibility**: The ESP32 D1 Mini uses the same pinout as the old AWTRIX 2.0. - **Build Information**: For more details about this build, visit: [AWTRIX 2.0 Build Information](https://awtrixdocs.blueforcer.de/#/en-en/awtrix_family?id=parts-list) @@ -71,7 +71,7 @@ A: Please read the options you have specified below A: The temperature sensor measures the temperature inside the case, which is not very useful for external temperature readings. The heat generated by internal components, such as the matrix (depending on the brightness and the number of LEDs turned on) and the battery, affects this measurement. -You can adjust the temperature and humidity offset settings in the `dev.json` file, which can be found at [AWTRIX Light Developer Settings](https://blueforcer.github.io/awtrix-light/#/dev). The configuration of these settings depends on your specific requirements. +You can adjust the temperature and humidity offset settings in the `dev.json` file, which can be found at [AWTRIX 3 Developer Settings](https://blueforcer.github.io/awtrix3/#/dev). The configuration of these settings depends on your specific requirements. Create a `dev.json` file in the root directory using the file manager with the content as shown below. diff --git a/docs/hardware.md b/docs/hardware.md index c9b13b4d..c5de21b7 100644 --- a/docs/hardware.md +++ b/docs/hardware.md @@ -1,6 +1,6 @@ # DIY Hardware -if you want to build your own AWTRIX Light, here are the pinout of the Ulanzi clock +if you want to build your own AWTRIX 3, here are the pinout of the Ulanzi clock |ESP32 PIN | GPIO | Usage or part | diff --git a/docs/icons.md b/docs/icons.md index af2fb8f3..1683b9df 100644 --- a/docs/icons.md +++ b/docs/icons.md @@ -1,6 +1,6 @@ # Icons -AWTRIX Light doesn't offer any cloud connection like AWTRIX 2.0. However, to use your favorite icon for a custom page or notification, you can use the integrated icon downloader in the web interface. +AWTRIX 3 doesn't offer any cloud connection like AWTRIX 2.0. However, to use your favorite icon for a custom page or notification, you can use the integrated icon downloader in the web interface.
diff --git a/docs/index.html b/docs/index.html index ef0664c8..25fa647b 100644 --- a/docs/index.html +++ b/docs/index.html @@ -3,7 +3,7 @@ - AWTRIX LIGHT + AWTRIX 3 @@ -20,7 +20,7 @@ coverpage: true, loadNavbar: true, mergeNavbar: true, - repo: 'https://github.com/Blueforcer/awtrix-light', + repo: 'https://github.com/Blueforcer/awtrix3', share: { reddit: true, linkedin: true, diff --git a/docs/onscreen.md b/docs/onscreen.md index 8205f0b1..267b5770 100644 --- a/docs/onscreen.md +++ b/docs/onscreen.md @@ -1,6 +1,6 @@ # Onscreen menu -AWTRIX Light provides a **onscreen menu** directly on your clock. +AWTRIX 3 provides a **onscreen menu** directly on your clock. Press and hold the middle button for 2 seconds to access the menu. Navigate through the items with the left and right buttons and choose the submenu with a push on the middle button. Hold down the middle button for 2s to exit the current menu and to save your setting. diff --git a/docs/sounds.md b/docs/sounds.md index 9e6feff0..9f27ebd4 100644 --- a/docs/sounds.md +++ b/docs/sounds.md @@ -8,8 +8,8 @@ With the Buzzer you can play monophone RTTTL melodies in two ways: **via API:** You can send the RTTTL string directly with your API request. See documentation for commands: -[Single sounds](https://blueforcer.github.io/awtrix-light/#/api?id=sound-playback) -[With your notification](https://blueforcer.github.io/awtrix-light/#/api?id=json-properties) +[Single sounds](https://blueforcer.github.io/awtrix3/#/api?id=sound-playback) +[With your notification](https://blueforcer.github.io/awtrix3/#/api?id=json-properties) **via file:** This method is to avoid long jsons beacuse the receive buffer is limited. diff --git a/docs/ulanzi_flasher/firmware/manifest.json b/docs/ulanzi_flasher/firmware/manifest.json index 6e79d58c..41d45df3 100644 --- a/docs/ulanzi_flasher/firmware/manifest.json +++ b/docs/ulanzi_flasher/firmware/manifest.json @@ -1,5 +1,5 @@ { - "name": "AWTRIX Light", + "name": "AWTRIX 3", "version": "0.94", "home_assistant_domain": "AwtrixLight", "funding_url": "https://blueforcer.de", diff --git a/docs/ulanzi_flasher/index.html b/docs/ulanzi_flasher/index.html index 2f0cf535..329d833f 100644 --- a/docs/ulanzi_flasher/index.html +++ b/docs/ulanzi_flasher/index.html @@ -2,10 +2,10 @@ - AWTRIX LIGHT + AWTRIX 3 @@ -86,8 +86,8 @@

Ulanzi Flasher

LiveView
+LiveView
)EOF"; static const char backup_html[] PROGMEM = R"EOF( - Backup & Restore

AWTRIX Light Backup & Restore


+ Backup & Restore

AWTRIX 3 Backup & Restore


)EOF"; static const char screenfull_html[] PROGMEM = R"EOF( diff --git a/src/main.cpp b/src/main.cpp index 5f14808a..b06fe4d9 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -13,7 +13,7 @@ *************************************************************************** * * - * AWTRIX Light, a custom firmware for the Ulanzi clock * + * AWTRIX 3, a custom firmware for the Ulanzi clock * * * * Copyright (C) 2023 Stephan Mühl aka Blueforcer * * * @@ -22,7 +22,7 @@ * 4.0 International License. * * * * More information: * - * https://github.com/Blueforcer/awtrix-light/blob/main/LICENSE.md * + * https://github.com/Blueforcer/awtrix3/blob/main/LICENSE.md * * * * This firmware is distributed in the hope that it will be useful, * * but WITHOUT ANY WARRANTY; without even the implied warranty of * @@ -74,15 +74,24 @@ void setup() ServerManager.setup(); if (ServerManager.isConnected) { + // timer_init(); DisplayManager.loadNativeApps(); DisplayManager.loadCustomApps(); UpdateManager.setup(); DisplayManager.startArtnet(); StopTask = true; float x = 4; - while (x >= -85) + String textForDisplay = "AWTRIX " + ServerManager.myIP.toString(); + + if (WEB_PORT != 80) + { + textForDisplay += ":" + String(WEB_PORT); + } + + int textLength = textForDisplay.length() * 4; + while (x >= -textLength) { - DisplayManager.HSVtext(x, 6, ("AWTRIX " + ServerManager.myIP.toString()).c_str(), true, 0); + DisplayManager.HSVtext(x, 6, textForDisplay.c_str(), true, 0); x -= 0.18; } if (MQTT_HOST != "") @@ -103,10 +112,10 @@ void setup() void loop() { + timer_tick(); ServerManager.tick(); DisplayManager.tick(); PeripheryManager.tick(); - timer_tick(); if (ServerManager.isConnected) { MQTTManager.tick(); diff --git a/src/timer.h b/src/timer.h index 49f49919..938f38a7 100644 --- a/src/timer.h +++ b/src/timer.h @@ -4,6 +4,7 @@ #include void timer_tick(); +void timer_init(); time_t timer_time(); struct tm *timer_localtime();