SK
Signal Kโ€ข2w ago
Matti Airas

Matti Airas - And here comes!I just released ...

And here comes! I just released SensESP v3.0.0-beta.4. This time I hope all essential and/or non-essential breaking changes have been made, honest! The latest release includes a lot of changes. Web UI configuration has been changed substantially. Previously, any objects that inherited from Configurable and that had a non-empty config_path were rendered as a config card. This approach mixed the embedded class implementation with presentation issues and made things like custom configuration schema more complex than necessary. In the latest version, Configurable has been replaced with a ConfigItem factory that needs to be called for every item you want on display. See for example the constant_sensor.cpp example for a practical example. Also, most of the internal pointer handling has been converted to smart pointers, improving memory safety and healing a long-time sore thumb. Use of smart pointers is also possible, but not mandatory, for user code. Some new tutorials might need to be written to cover the topic. Oh, and after a long last, there are at least a few unit tests. They haven't been added in CI yet - that requires setting up a remote runner - but can be run either from the VSCode PlatformIO menu or from the command line:
pio test -f system/test_offline --upload-port /dev/tty.usbserial-210 --test-port /dev/tty.usbserial-210 -vv
pio test -f system/test_offline --upload-port /dev/tty.usbserial-210 --test-port /dev/tty.usbserial-210 -vv
If you would be kind enough to test the new release and report any bugs, that would help me a lot! I would like to get the v3 release finally done! ๐Ÿ˜„
GitHub
SensESP/examples/constant_sensor.cpp at main ยท SignalK/SensESP
Universal Signal K sensor framework for the ESP32 platform - SignalK/SensESP
7 Replies
Matti Airas
Matti Airasโ€ข7d ago
... aaand now v3.0.0-beta.5 is out. Just some instrumentation improvements: data on the event loop operation is now shown on the web UI status page.
Unknown User
Unknown Userโ€ข4d ago
Message Not Public
Sign In & Join Server To View
Matti Airas
Matti Airasโ€ข4d ago
Constant sensors are completely unrelated; they were just used as an example. If you have a linear sensor:
c++
auto my_linear = new Linear(2.0, 1.1, "/My/Linear");
c++
auto my_linear = new Linear(2.0, 1.1, "/My/Linear");
and you want it to be visible in the config UI, you create a ConfigItem for it:
c++
ConfigItem(my_linear)
->set_title("My Linear Thingy");
c++
ConfigItem(my_linear)
->set_title("My Linear Thingy");
The created config item will be displayed as a config card similar to the one in the previous version.
Unknown User
Unknown Userโ€ข3d ago
Message Not Public
Sign In & Join Server To View
Matti Airas
Matti Airasโ€ข3d ago
Hmm, I got the same result... Fixing... That was some C++ template black magic that I struggled with earlier and thought I had already fixed. I suppose I had broken it again. I have now pushed a fix and created a new release. It should be published soon.
Unknown User
Unknown Userโ€ข3d ago
Message Not Public
Sign In & Join Server To View
Matti Airas
Matti Airasโ€ข3d ago
Excellent!
Want results from more Discord servers?
Add your server