Alternate UI to UI7

Fantastic - thats a lot easier!

Your improvements also are wonderful! This is the UI that Vera should have created!

Still making progress. a little breakthrough today, I am able to offer a UI to modify LUA startup code and use the not so well documented api ModifyUserData “http://wiki.micasaverde.com/index.php/ModifyUserData”.

tested on UI5 and UI7 and with complex code & characters, so I think it is reliable.

Be careful with that call … A mistake there can brick Vera requiring someone (like support) to rollback to a previous user_data state.
You need to be very defensive about the DATA you pass to this call.

@RichardTSchaefer
Yes indeed, it seems a powerful api but quite dangerous. for now little risk with what I do with it.

I reworked scene display and prepare for next efforts ( scene details display & editor … ). files & PDF with screen shot here : http://code.mios.com/trac/mios_ipx800/changeset/195/trunk?old_path=%2F&format=zip

Now scene editor in progress. I have , not yet a scene editor, but at least a scene “decoder”. cf screen. what a messy piece of code … and some inconsistencies accross device types. Hard to make bug free code when things are changing in the underlying data ( sometime a name, sometime not, sometime a argumentlist, sometime not etc … )

files: http://code.mios.com/trac/mios_ipx800/changeset/195/trunk?old_path=%2F&format=zip inside the ALTUI folder.

Top banana !!

Looks very clean and fresh, well done, awesome work.

QQ:

  1. Are you anticipating any issues with this and the current role out of 7.0.4 firmware ?
  2. What are you plans for the future of this long term ? Is it an experiment for now, or would be prepared to commit to development long term and even charge for it ? (like RTS)

You’ve got my support for the future.

[quote=“dmckenna, post:26, topic:185570”]Top banana !!

Looks very clean and fresh, well done, awesome work.

QQ:

  1. Are you anticipating any issues with this and the current role out of 7.0.4 firmware ?
  2. What are you plans for the future of this long term ? Is it an experiment for now, or would be prepared to commit to development long term and even charge for it ? (like RTS)

You’ve got my support for the future.[/quote]

I will fix eventual issues for 7.0.4 firmware, hopefully not too dependent on it.

I have a day job so cannot really commit or make a business at it but I want to continue this long term and want to welcome other developpers to help me, I do not think to charge for it, maybe volunteeer donation via paypal at best. But eventually if MCV listen it could be that they want to take / license it and use it instead of UI7 … we can dream :slight_smile:

otherwise it will remain an alternative UI and I ll welcome others to help / contribute given few rules.

  • full responsive design ( bootstrap grid system )
  • few js framework : bootstrap jquery jqueryui is enough, maybe one more for a graphic lib
  • putting as little strain on the back-end server ( the vera box ) as possible, all/most is client based, one page, even using CDN to download minified js framework instead of vera
  • seperation of HTML & code via CSS
  • some simple naming convention for CSS classes etc…
  • do not rely on complex JSON files but offer ability for developper of plugin to code in JS to display his plugin . for instance one goal as to seperate dashboard and scene editor ( decision which I believe is at the root of many UI7 mess and UI5 to some extent ) each device is displayed using a pure javascript callback so developper would be quite free to do fancy things in the dashboards. we could also have a different display mode to display devices with more space ( at the click of a button ) and still let the developper do the plugin display. and the scene editor and the custom panel with drag and drop to position some device exactly how you want and then save the “page” etc …
  • looking for somebody to code the MMS authentication and encapsulate the page into a “PhoneGap” shell and produce directrly a native mobile application for it , thus directly reusing html5 and js code. right now it works great ( local access ) on iphone4s & ipad for instance

the more I do the more I find to do :slight_smile: :slight_smile: the scene editor proves to be hard…

amg0

Looks like a solid plan, thanks again for taking the time to develop an alternative future to the clunky UI that Vera have imposed on us, I really, really look forward to seeing this develop with the input of this community at large.


Some feedback on v0.21
*) VERY fast, uncluttered. Scales up/down well on different browsers - UI5 style feel running on UI7 backend
*) It’s picking up devices which are (probably) hidden in the native UI7 - something called “_sensor” of which I’m showing around 50 of them in one room, all unknown to me
*) Am assuming that devices with a status showing of “todo” are exactly that - ones that you’ll get around to doing in the future ? Would you like a list of what they are ?
*) Both ‘Variables’ and ‘Actions’ pull down on any device does not do anything (no error, no fails, no UI popup) - is this enabled yet ?

[quote=“dmckenna, post:28, topic:185570”]amg0

Looks like a solid plan, thanks again for taking the time to develop an alternative future to the clunky UI that Vera have imposed on us, I really, really look forward to seeing this develop with the input of this community at large.


Some feedback on v0.21
*) VERY fast, uncluttered. Scales up/down well on different browsers - UI5 style feel running on UI7 backend
*) It’s picking up devices which are (probably) hidden in the native UI7 - something called “_sensor” of which I’m showing around 50 of them in one room, all unknown to me
*) Am assuming that devices with a status showing of “todo” are exactly that - ones that you’ll get around to doing in the future ? Would you like a list of what they are ?
*) Both ‘Variables’ and ‘Actions’ pull down on any device does not do anything (no error, no fails, no UI popup) - is this enabled yet ?[/quote]

yes i need to filter out hidden device, at the same time it is interesting and useful to see them so maybe a user option

yes please tell me where you see a “todo”

variable & action as well as scene detail should be visible. see screen shots in the document http://code.mios.com/trac/mios_ipx800/browser/trunk/AltUI/doc.docx

and maybe reapply latest version http://code.mios.com/trac/mios_ipx800/changeset/195/trunk?old_path=%2F&format=zip

after install: remember to “refresh browser cache”

Hi,

Just stumbling across what may be a memory issue (I have reloaded, and cleared cache too). This may be related to the pull down menus not appearing at all.

Selecting ALL under Devices only displays first 27 devices, then blanks for the remainder. Furthermore when I select some rooms, these are also blank. BUT after a restart, these then show devices and other rooms then become blank. The pull down menus do not work.

Here’s a screenshot of the final few of the 27 (I’ve got over 100 devices expected).

[quote=“dmckenna, post:30, topic:185570”]Hi,

Just stumbling across what may be a memory issue (I have reloaded, and cleared cache too). This may be related to the pull down menus not appearing at all.

Selecting ALL under Devices only displays first 27 devices, then blanks for the remainder. Furthermore when I select some rooms, these are also blank. BUT after a restart, these then show devices and other rooms then become blank. The pull down menus do not work.

Here’s a screenshot of the final few of the 27 (I’ve got over 100 devices expected).[/quote]

no I think it is something else. must be a javascript crash. are you in chrome ? There are 2 things that could help me debug here:

a) can you open the javascript console and share the error shown here ?
b) can you open this url in your browser, capture the result and send it to me ?
http://<vera_ip>/port_3480/data_request?id=user_data2&output_format=json

Thank you

Hi, here’s the JSON, running Firefox 31.4

Jscript errors:
https://dmckenna.myknowhowcloud.com/Item/5f29ceaa268c486a991fc5fa0a16fae9

ReferenceError: Off is not defined J_ALTUI_utils.js line 544 > eval:1
GET http://192.168.0.24/cmh/skins/default/icons/Power_Meter.png [HTTP/1.1 404 Not Found 6ms]
ReferenceError: Off is not defined J_ALTUI_utils.js line 544 > eval:1
GET http://192.168.0.24/cmh/skins/default/icons/Power_Meter.png [HTTP/1.1 404 Not Found 12ms]
GET http://192.168.0.24/cmh/skins/default/img/devices/device_states/vcontainericon.png [HTTP/1.1 404 Not Found 11ms]
GET http://192.168.0.24/cmh/skins/default/icons/SceneController_0.png [HTTP/1.1 404 Not Found 11ms]

[quote=“dmckenna, post:32, topic:185570”]Hi, here’s the JSON, running Firefox 31.4

Jscript errors:
https://dmckenna.myknowhowcloud.com/Item/5f29ceaa268c486a991fc5fa0a16fae9

ReferenceError: Off is not defined J_ALTUI_utils.js line 544 > eval:1
GET http://192.168.0.24/cmh/skins/default/icons/Power_Meter.png [HTTP/1.1 404 Not Found 6ms]
ReferenceError: Off is not defined J_ALTUI_utils.js line 544 > eval:1
GET http://192.168.0.24/cmh/skins/default/icons/Power_Meter.png [HTTP/1.1 404 Not Found 12ms]
GET http://192.168.0.24/cmh/skins/default/img/devices/device_states/vcontainericon.png [HTTP/1.1 404 Not Found 11ms]
GET http://192.168.0.24/cmh/skins/default/icons/SceneController_0.png [HTTP/1.1 404 Not Found 11ms][/quote]

ok so it sounds we have an issue in the evaluation of condition for dynamic icons. it is a device type that I do not have. could you edit J_ALTUI_utils on line 544 and add these lines

	function _evaluateConditions(deviceid,conditions) {
		var bResult = false;
		var expressions=[];
		$.each(conditions, function(i,condition){
			var str = "({0}{1}{2})".format(
				condition.value, 
				condition.operator, 
				VeraBox.getStatus( deviceid, condition.service, condition.variable )
			);
			expressions.push(str);
		});
		var str = expressions.join(" && ");

//---------------
console.log("deviceid="+deviceid);
console.log(str);
//---------------

		var bResult = eval(str);
		return bResult;
	};

also try to find the deviceid and tell me which device type it is so I can check the device .JSON file
thx !

Will do - need to pop out first…stand by.

On example Device ID is 324 which is a StellaZ thermostat but I’ve now noticed that none of these StellaZ device types are appearing on any screen on ALTUI

D

[quote=“amg0, post:33, topic:185570”]also try to find the deviceid and tell me which device type it is so I can check the device .JSON file
thx ![/quote]

I think I have a fix. I have attached the fixed files here

Bingo - yes that’s fixed it - all devices appear now.

I’m still not getting the pull downs for Variables and Actions though - nothing coming up in the Javascript window. I’ve also tried Chrome instead of FF and the same result.

Let me know if you require anything else/debug etc.

Cheers

David

[quote=“dmckenna, post:36, topic:185570”]Bingo - yes that’s fixed it - all devices appear now.

I’m still not getting the pull downs for Variables and Actions though - nothing coming up in the Javascript window. I’ve also tried Chrome instead of FF and the same result.

Let me know if you require anything else/debug etc.

Cheers

David[/quote]

Thx same story , let s try the js console captured while you try to open variables / actions for a start.

[quote=“amg0, post:37, topic:185570”][quote=“dmckenna, post:36, topic:185570”]Bingo - yes that’s fixed it - all devices appear now.

I’m still not getting the pull downs for Variables and Actions though - nothing coming up in the Javascript window. I’ve also tried Chrome instead of FF and the same result.

Let me know if you require anything else/debug etc.

Cheers

David[/quote]

Thx same story , let s try the js console captured while you try to open variables / actions for a start.[/quote]

I found one potential caveat, here is a version to try and let me know. thx !
http://code.mios.com/svn_public/mios_ipx800/trunk/AltUI/J_ALTUI_utils.js
.

it is part of latest built. I could reproduce the issue for actions ( it was working for variables) on a test UI5 box with a dummy thermostat device ( I do not have one on my real UI7 box ) , then with this fix, it worked. it has to do with me using a file not yet received… the fun of async programming :slight_smile:

let me know if it fixes your issue

Hi,

I’ve uploaded that last .js file and unfortunately it’s not changed anything, the pull downs are still not functioning in either FF or Chrome. No errors either on the jscript console when selecting the pulldowns, however, the following are jscript errors when ‘ALL’ is selected:

TypeError: str is undefined J_ALTUI_utils.js:1219
GET http://192.168.0.20/cmh/skins/default/icons/Power_Meter.png [HTTP/1.1 404 Not Found 11ms]
GET http://192.168.0.20/cmh/skins/default/img/devices/device_states/vcontainericon.png [HTTP/1.1 404 Not Found 12ms]
GET http://192.168.0.20/cmh/skins/default/icons/SceneController_0.png [HTTP/1.1 404 Not Found 7ms]
GET http://192.168.0.20/cmh/skins/default/icons/intro.png [HTTP/1.1 404 Not Found 6ms

Need anything else ?

good.
it seems one of the device type is lacking a icon definition in the .JSON file. could be one of the built in VERA devices. let’s try this .JS file and look at the console for a message. I have put a default value for the icon and a console message to track this.
could you please try with this file ?