Announcement

Collapse
No announcement yet.

Web page builder for Homeseer 3 & Homeseer 4

Collapse
This topic is closed.
X
This is a sticky topic.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Originally posted by jon00 View Post
    Have you tried the deviceimage tag?
    Hi jon,

    yes i did, that works... but i don't prefer that because it doesnt line out at all.. and its almost impossible to line up everything.. have a lot of devices.
    Preferred -> Jon's Plugins, Pushover, Phlocation, Easy-trigger,
    Rfxcom, Blade Plugins, Pushbullet, homekit, Malosa Scripts




    HS3Pro 4.1.14.0 on windows 10 enterprise X64 on hp quadcore laptop 8 GB.

    Comment


      Hi Jon. Wow am I late to the HS3 upgrade party. I am on schedule though as I have been a fairly late adopter through the years. I love this plugin.

      I read through doco provided, this 18 page thread and even the jump to the HS2 plugin with respect to resizing device images. Does the HS3 version of this plugin have the ability to use a completely different image for the device as we could in the HS2 version?

      There were many ways to do this... all lower case for the word device and then having the replacement image in the HTML/Image folder.
      Another method was to add [/images/homeseer/device2.gif] or [*/images/weather/] to the end of the device parameter.

      Comment


        You just need to construct this yourself by using the [Image] and [devicetext] tags (page 29/30 in the docs)

        Example:

        Column1Section1-1Middle=[image,/images/Homeseer/ui/caution-green.png,64,64,1] [devicetext,77]
        Jon

        Comment


          Thank you for the fast response Jon, but if I am not mistaken... the example you gave me would simply show the same image regardless of the device text or the device value. I was hoping the feature we had available in the HS2 version of this plugin still exhisted where a different replacement image could be displayed based on the device text.

          Maybe this is not possible with the way HS3 handles the image for device values now. Huge bummer if not.


          More like page 12 of the old HS2 Plugin...

          With DeviceAlt, you can also optionally change the image that is shown on the page. To do this, just add square
          brackets with the path (starting from the html folder) to the image i.e.
          Column1Section1-1Right=DeviceAltY14 [/images/homeseer/unknown.gif]
          This will change the default image for Y14 with unknown.gif (found in the html/images/Homeseer folder)
          New V.2.10.1
          Homeseer also uses a trick to use the text within a device to display the icon with the same name. This is used by
          some plugins.
          For example, if the text shown in a Homeseer device is 'Low', it will check for an icon called low.gif in the html
          directory and try and display that (if no icon is defined another way).
          You can use the DeviceAlt Command to display icons using this arrangement. This can be done by using the syntax:
          Column1Section1-1Right=DeviceAltY14[*]
          With this example, if the virtual device for temperature is showing 55, the page will attempt to display the image 55.gi
          located in the html folder. Should the temperature change to 57, the icon displayed would be 57.gif etc.
          You can optionally set the path to where the icons are located using the syntax:
          Column1Section1-1Right=DeviceAltY14 [*/images/weather/]
          With this example, if the virtual device for humidity is showing 68, the page will attempt to show an image 68.gif
          located in the html/images/weather folder.

          Comment


            I will hopefully get to work on this some more over the next week. Based on some additional experimenting it looks like I will just need to come up with a different approach to still make good use of this plugin. I relied heavily on alternative images for device states. Different images based on whether I was feeding a tablet or mobil phone or desktop pc. Different ini files for each environment. I think my work around is to come up with square replacement images that will scale across all environments and assign them to the device. HS built in gui will shrink to 32x32 and I can control the size of the image in your plugin with the resize/ replace tag mentioned in the HS2 plugin version thread. I will give that a go.

            Comment


              Apologies but you did not make that clear with your first post. Yes,things did change with HS3. Device graphics and text are linked to its device value known as status text & graphics pairs. This can be setup under each device or automatically by a plugin. An example is shown below where the speaker volume icon will change depending on its value.. Therefore there is no need to set this up in web page builder as the process is seamless.

              Click image for larger version

Name:	2019-12-07_09-27-29.png
Views:	406
Size:	229.7 KB
ID:	1345008

              Jon

              Comment


                Now that I have been working with HS3 for a few weeks and getting back into the groove. I am still very much gateful that you have created this plugin/script set for us to utilize. I would not be nearly as statisfied with HS software without this. I have used HS Touch and other plugins in the past, but once you get past the learning curve this is so configurable that I have no need for any other interface for daily interaction through my phone or tablets around the home. I plan to share some of my screens when I get them finished. I am still sorting out the images I want to represent various devices. Going back and forth between static and animated.

                A couple issues I ran into and wanted to post in case others run into this.

                Documentation:
                Page 19 concerning using JSON Commands with a button. The example has an extra space and is missing an equal sign for value, which is important.
                JSON1=/JSON?request=controldevicebyvalue&ref=123&value=100

                Using JSONRefresh I was occasionally observing the refresh of the page completing prior to the value of the device actually changing. It could be my slow hardware as I am running an atom processor for my HS server. I think the refresh code could use a little longer delay to account for this. I created my own work around that I will share below.

                I added the following to delay the refresh after a button push, which adds 750 milliseconds delay before doing refresh.

                Bodydata=<script type='text/javascript'> function mysleep() {var waitUntil = new Date().getTime() + 750; while(new Date().getTime() < waitUntil) true;} </script>

                Then after each JSONRefresh usage I added the following "replace":

                Column1Section2-6Middle=[button,ARM,JSONRefresh1,,Button9] {replace,"; refresh","; mysleep(); refresh"}

                Thank you again for the time and dedication you shared with this community.

                Comment


                  Many thanks.

                  I'm sure the script had a setting for the button refresh time so I checked! It does but it never made the documentation

                  Under [Settings] you can add:

                  ButtonRefreshTime=XXX where XXX is in milliseconds. Currently it is set to 250 internally.

                  I'll also add that to the docs and update the JSON string.

                  I would be interested in your screenshots once you have completed them.
                  Jon

                  Comment


                    Embed question.
                    I am trying to go over the top and embed:
                    https://embed.windy.com/embed2.html?...&radarRange=-1

                    Direct Iframe does not work neither does image or embed tags.
                    Is there a way to do this, or am I out of luck?

                    Comment


                      Web browsers do not now allow iframes to display anything if they are on a different domain. You may be able to take a snapshot of the page (I have a utility that may work) but I cannot see a easy way of showing live animation. There may be a utility to record video from the web page which could then be converted to an animated gif.
                      Jon

                      Comment


                        Thank you Im going to go look up that utility. I thought Iframes worked as long as it didn't try to read outside its domain?

                        Comment


                          Originally posted by Stubborn View Post
                          Thank you Im going to go look up that utility. I thought Iframes worked as long as it didn't try to read outside its domain?
                          Indeed. Windy.com is a different domain. For webpage builder that means you can now only display iframes showing pages served from Homeseer.
                          Jon

                          Comment


                            I cant get the button to work. I can put the json command in the url and it works, but when I hit the button it doesnt do anything, feel like I am missing something easy, but cant find it.

                            Column1Section1-7Middle=[button,Garage Lights on,JSON3] [button,Close Garage,JSON4] [button,JSON 3,JSON3]
                            ===========================================
                            JSON3=/JSON?request=controldevicebyvalue&ref=1040&value=255
                            JSON4=/JSON?request=controldevicebyvalue&ref=1040&value=0
                            JSON5=/JSON?request=controldevicebyvalue&ref=51&value=2
                            JSONRefresh1=/JSON?request=controldevicebyvalue&ref=51&value=1 refresh&host=*:*

                            Comment


                              Have you enabled JSON in Homeseer?

                              If you have, turn it off in the settings and then back on again. This should ensure the flag is set correctly in settings.ini
                              Jon

                              Comment


                                I did try that, will try again, I can copy the command to the url bar and it works.

                                Comment

                                Working...
                                X