logo elektroda
logo elektroda
X
logo elektroda

OpenBeken Schedules Utility (addClockEvent UI generator) - work in progress

Eltaistos 1116 7
ADVERTISEMENT
  • #1 20976433
    Eltaistos
    Level 6  

    [postid:47ae092c1c]20975906[/postid:47ae092c]
    also, I wanted your opinion: I want to make a tool for the openbeken web app for generating addClockEvent command from a gui. But I think the trouble of making it embedded is not worth it. But instead, adding a new category on the website (https://openbekeniot.github.io/webapp/devicesList.html) is a better and simpler idea.

    Here is a picture of the web page I made and wanted to integrate:
    Schedule configuration form with selected days, time field, and command field.

    Feel free to tell me what you think.
  • ADVERTISEMENT
  • Helpful post
    #2 20976568
    p.kaczmarek2
    Moderator Smart Home
    That's a great addition. That's what I would have done, if I had a bit more time. I have still a queue of devices to reverse-engineer (@auntlydia sorry for delay!), and I barely managed to post TuyaMCU tutorial today:
    TuyaMCU flashing, setup and configuration guide - configure dpIDs for Home Assistant
    Your generator looks very good, please open a pull request. As I can see, it generates just a code snippet, right? If we had more time, maybe we could make it even more automatic someday, but it's still good.
    Btw, maybe along with command, generate a comment, something like:
    
    // trigger on sundays blahblah etc
    

    and put both in text field (multiline) with "Copy " button?
    Helpful post? Buy me a coffee.
  • ADVERTISEMENT
  • #3 20977209
    Eltaistos
    Level 6  

    Update on the utility tool,
    I have finalized the v2 of my schedule snippet generator ;)
    preview :
    Schedule Configurator interface with day selection and command generator options.

    I have taken into account your suggestion and use bootstrap the same manner has yours.
    I will soon make a merge request on your repo (https://github.com/openshwprojects/OpenBekenRESTDemo) I have already created the fork.
    And I will also open a new post ? But i don't know in which section to make it.

    ps : I was thinking maybe renaming it or making 2 repos, one for community utility script and one for demo ?
  • #4 20977420
    p.kaczmarek2
    Moderator Smart Home
    Wait, OpenBekenRESTDemo is a repository for custom per-device UI. The WebApp repo contains our template importer, on the other hand:
    https://openbekeniot.github.io/webapp/templateImporter.html

    I think your addon should be added to the Web App, not to the OpenBekenRESTDemo:
    https://github.com/OpenBekenIOT/webapp/tree/gh-pages
    Then we can link to it from within the Web App.
    The link would look something like that:
    https://openbekeniot.github.io/webapp/schedulesUtility.html

    PS: I think that comment should go first, then a code

    Once you have tool ready, you can post it in Smart Home Tutorials. For now, I have split the posts about WIP version.
    Helpful post? Buy me a coffee.
  • ADVERTISEMENT
  • #5 20992952
    Eltaistos
    Level 6  

    Hi,

    I'm currently having trouble to start the web app project do you know ways to starting on Linux using npm or other way but without using the simulator?
  • #6 20993046
    p.kaczmarek2
    Moderator Smart Home
    Clone the repository and use Visual Code with the "Run as local server" extension.

    Alternatively, use Python command:
    
    python -m http.server 7000
    

    in the web app dir.

    Then, once you have server running, you can either change the target IP in the web app index to your page, or you can change your OBK device web app link to your local server.
    Helpful post? Buy me a coffee.
  • ADVERTISEMENT
  • #7 21024314
    Eltaistos
    Level 6  

    Hello!

    Thank you very much for the tips because I was on the wrong path trying to run the full emulator. This is significantly easier for me to run. However, I don't quite understand how you run Vue.js without an npm server?
  • #8 21026759
    p.kaczmarek2
    Moderator Smart Home
    Any HTTP server will run our vue page correctly. Vue is a client-side scripting, it's interpreted by your browser. You can use any HTTP server for development, including:
    - Visual Code "run with live server" utility
    - Python HTTP server as shown in my previous post
    - Xampp/Apache server will also work good
    - GH pages (Github pages) hosting will also work well
    Long story short, any HTTP server will suffice for the development. Just make sure to either point your OBK device Web App url to your Web App hosted instance or change IP in the development HTML of the web app itself.

    Regarding OBK simulator:
    https://github.com/openshwprojects/obkSimulator
    I will be releasing early alpha version binaries on our "Smart Home Tutorials" section soon, maybe within a day or do, so please stay tuned.

    Let me know if you have any other questions, I will do my best to help.
    Helpful post? Buy me a coffee.

Topic summary

The discussion revolves around the development of a utility tool for the OpenBeken web app, specifically aimed at generating the addClockEvent command through a graphical user interface (GUI). The author proposes creating a new category on the OpenBeken website for this tool instead of embedding it directly into the app. Feedback from the community suggests that the tool is a valuable addition, with recommendations to include comments in the generated code snippets. The author has made progress on the tool, incorporating community suggestions and planning to submit a merge request. Additionally, there are discussions on how to run the web app project on Linux without using a simulator, with various methods provided for setting up a local server to facilitate development.
Summary generated by the language model.
ADVERTISEMENT