Premise [download] JQM

Motorola Premise
Does this rely on any other modules? On a clean install it immediately errors when trying to access a non-existent DefaultSite.
 
OK. I was reading that and had mistakenly thought that the posted version had the fix. Although I installed this on a test system, so upgrades do not really matter, what will the normal upgrade path be for new releases?
 
Please add a couple lines in the global script to circumvent WeatherUnderground:
 
Code:
		'V2.2 cl - comment out if you don't have the WeatherUnderground module active

+++		Count = Schema.Modules.GetObjectsByTypeAndPropertyValue(Schema.System.Module.Path, "Name", "WeatherUnderground", false).Count
+++		if (Count > 0) then

		for each oChild in home.GetObjectsByType(Schema.Modules.WeatherUnderground.Classes.CurrentConditions, true)
		sTemp =  (round(ochild.cctemperature)) & "°"
		sSum = ochild.ccsummary	
		sIcon = "<img width=32 height=32 SRC=""/sys/" & ochild.objectID & "!Image"">" 
		next
---		on error  goto 0 'Why is this here?
+++		end if
 
Also wondering why the UI would spin for a long time whenever anything is selected, but never actually do anything. Am I missing basic plugins? This is a test installation with the generic Apartment setup. See attachment.
 

Attachments

  • Capture.PNG
    Capture.PNG
    289.3 KB · Views: 13
Now that I am actually looking at that loop, it would appear to be trying to obtain the most current item:
 
set colCurrentConditions = home.GetObjectsByType(Modules.WeatherUnderground.Classes.CurrentConditions.Path, true)
Count = colCurrentConditions.Count
if (Count > 0) then
    Count = Count - 1
    sTemp = (round(colCurrentConditions(Count).cctemperature)) & "°"
    sSum = colCurrentConditions(Count).ccsummary
    sIcon = "<img width=32 height=32 SRC=""/sys/" & colCurrentConditions(Count).objectID & "!Image"">"
end if
 
I know nothing about the WeatherUnderground module, so if there is only one of these objects, then ignore this post.
 
chucklyons said:
The next release (and most likely my last given the pms and emails I have gotten) does not require mbWeatherUnderground...good luck to whomever is next.
 
Sorry to hear that, I thought you were making some good progress. I plan on getting back into the game, but I am not going to be updating the code as much as you have.
 
If you would like, once you release the final code, I can add it to github.  Then anybody that wants to fix or add to the project they can.  That would take the pressure off you and allow you to work on the stuff that is specific to your setup.  Who would have thought the little project that I started would have been used by anybody.  I have been thinking about some of the issues, especially the polling stuff.  I have a small setup with 3 devices, so polling isn't problem at the moment, but I can see where it can get out of hand.
 
Let me know your thoughts.
 
So I followed the instruction for the installation, and so therefore already have the PNG's in the web\images directory. This contains the Home, Apartment, etc. PNG's from the jqm installation.
 
What specifically happens is that the very first time I access http://localhost/jq the browser just sits waiting forever with a blank page. If I eventually refresh it then paints that top level view. If I select an item in that top level it waits forever using the spinner in the UI. Refreshing that page then displays that item that had previously been drilled into. So some times I am able to drill down to a new level as long as I hit Refresh on the browser. At no time are PNG's displayed.
 
Hope this helps.
 
Chuck,
 
Is the jqm 2.2 the latest version or do you have some cool experimental version?  I have installed Premise on my machine and I have my wifi thermostats installed. After I figure out how to get Premise to use my wifi thermostats, I will be ready to ease back into the jqm stuff :)
 
The weather could use polling as you only need to check every 30 minutes or so. The polling overhead is from the controls. They were set to 1 second so I could show real-time changes. Still not bad as they are only used on the device page.

The status page is the one that would have the most overhead, it requires separate calls back to the server for each device, but maybe we could change the polling interval on the status page.

It has been a long time since I looked at the Premise source code, but hopefully we can figure something out.

I do have a question, how do you get AB to work with newer versions of IE? I am going to add my thermostats, but I want to make it work with both AB and MB.
 
Welcome back!  Just enable the compatibility view for the AB page and this issue will go away.
 
w84no1 said:
I do have a question, how do you get AB to work with newer versions of IE? I am going to add my thermostats, but I want to make it work with both AB and MB.
 
I have JQM installed and I am working on getting my wifi thermostat working.  I do have some ideas about formating the screens for tablets, more to come.
 
I download and install JQM over my existing configuration… and got smashed all automation browser interface. After investigation and installation from scratch I was discover interesting thing – if you use blank setup without any house or apartment model – all automation browser interface was smashed! But if you start with house model from wizard -  all ok!
 
5rdOlfb.jpg
 
Kudos to Chuck, W84no1, and all others involved in creating JQM. Looks great!
 
I installed it on a test server and it displays all (well, most) of the items in the Apartment model. Unfortunately, I must've goofed somewhere because nothing actually works. If I turn on a light in the browser, no matching action occurs in Builder. If I turn on a light in Builder, nothing is updated in the browser. As a sanity check, http://localhost/ip works fine.
 
 
nj71Eqd.jpg

 
Can anyone shed light on what could be causing it to fail?
 
FWIW, I tested it with Edge and Internet Explorer 11 on Win10. I assume JQM is browser agnostic? I've been experimenting with openHAB and it requires a webkit-based browser.
https://community.openhab.org/t/openhab-crashes-non-webkit-browsers-normal/10006
 
 
123 said:
FWIW, I tested it with Edge and Internet Explorer 11 on Win10. I assume JQM is browser agnostic? I've been experimenting with openHAB and it requires a webkit-based browser.
https://community.openhab.org/t/openhab-crashes-non-webkit-browsers-normal/10006
 
If there is one thing I've learned about the programming scene that exploded since the smartphone revolution is that the term "Open" holds as much value for software as the words "Homeopathic", "Craft Beer" or "Natural".  WebKit though open source is no standard, rather a shortcut for software companies to build browsers that mostly support HTML5.  To complicate things, because WebKit is open source, companies like Google have created their own forks, including additional proprietary an non-standard elements.  So for anyone to say, "we support webkit only," is a bit silly as it begs the question "which webkit?.. WebKit, KHTML, Blink, Webkit2?"  
 
AFAIK, JQM is basic javascript and CSS, core elements of the HTML5 standard.  Both CSS and JavaScript were around before HTML5 of course, so JQM is likely backwards compatible with a lot of browsers & devices.  
 
I will never understand why developers are always so quick to hop on the proprietary chain -- surely a simple, responsive and portable/widely compatible UI is more important than integrating cpu & memory hogging animations, backgrounds, transitions and the like.  
 
Back
Top