Page 58 of 66
Re: NEW frontpage.html - request comments
Posted: Tuesday 03 January 2017 17:00
by denisj
barbaar wrote:...
However, I would like to adjust the frontpage so it will be full screen on my tablet (1920x1200). I cannot get this to work.
I also want to change the screen res. in order to run on my tablet.
I think that in some place of code it take the max resolution of the screen and then it reduce it. ) (???)
Thanks
Denis
Re: NEW frontpage.html - request comments
Posted: Wednesday 04 January 2017 23:47
by peterjoosen
[/quote]
Hansbit wrote:I've updated the default frontpage.html page
Most important changes:
- The html is cleaned and structured. User settings are now only at end of script.
- All cells are numbered. If cell is not defined in user settings, the cell number appears on screen
- User can now easily set the label of the cell in the user settings (like 'Temperature Livingroom')
- User can now set optional alarm value. Of value of sensor above this value, the text will turn to RED.
- User can easily adjust the color of the text.
- If defined cell is a switch, the cell is clickable to switch that device.
Schermafbeelding 2014-12-29 om 14.11.16.png
How to install?
- copy attached frontpage.html to the Domoticz ditrectory (domoticz/www)
- Create a roomplan in Domoticz and add devices to that roomplan
- Adjust user settings in frontpage.html: the URL of your domoticz, the number of your roomplan and the devices to display
- If log-in for Domoticz is required, it best to add the IP of the device displaying the frontpage to the settings in Domiticz, so no login is required.
- Open in browser [your Domoticz IP]:8080/frontpage.html
Please send me your comments!
Hans
frontpage.html.tar.gz
Hello Hans,
I followed your instructions to get the frontpage online, but all cells stays empty (--) and also no names are filled in the cells.
-Created a roomplan in Domoticz
-Filled in the roomplan N° (user values)
-Filled in url (user values)
-Filled in a couple off switches (idx,....name of the switch etc...)
Any idea what causes this problem???
Thanks already
Peter
Re: NEW frontpage.html - request comments
Posted: Friday 06 January 2017 20:25
by albertvandam
Dear all,
With all the examples and code in this forum, I have managed to create a pretty good frontpage which runs on a wall mounted tablet. Thanks to Hansbit, G3rard and all others.
However I can't get to control my Dru Fireplace (Mertik G6R-HT4B) on the frontpage like it should. Directly from Domoticz it works fine.
Does someone have the right json commands to control the Mertik controller?
When I send json commands directly from the Chrome Address Bar, it doesn't work as aspected also.
For example:
http://192.168.4.250:8080/json.htm?type ... itchcmd=up
switches the fire place off!
Thanks in advance for any response.
Re: NEW frontpage.html - request comments
Posted: Friday 06 January 2017 21:03
by jompie
Hi,
you need to use Capitial letter "U", thus: Up and not up, as a command.
Re: NEW frontpage.html - request comments
Posted: Friday 06 January 2017 22:38
by albertvandam
Hi Jompie,
You were absolutely right!
Thanks a lot.
Re: NEW frontpage.html - request comments
Posted: Saturday 07 January 2017 1:42
by madrian
Guys, one question:
I can't get to work one Dummy switch. I have few of them, but this one is not working. It's just showing "Nan" and doesn't reagate to click.
Code: Select all
"AddjMulti" : 1.0,
"AddjMulti2" : 1.0,
"AddjValue" : 0.0,
"AddjValue2" : 0.0,
"BatteryLevel" : 255,
"CustomImage" : 15,
"Data" : "On",
"Description" : "",
"Favorite" : 1,
"HardwareID" : 2,
"HardwareName" : "Dummy",
"HardwareType" : "Dummy (Does nothing, use for virtual switches only)",
"HardwareTypeVal" : 15,
"HaveDimmer" : true,
"HaveGroupCmd" : true,
"HaveTimeout" : false,
"ID" : "00014060",
"Image" : "Heating",
"IsSubDevice" : false,
"LastUpdate" : "2017-01-06 15:00:01",
"Level" : 100,
"LevelInt" : 100,
"MaxDimLevel" : 100,
"Name" : "Heating",
"Notifications" : "false",
"PlanID" : "4",
"PlanIDs" : [ 4 ],
"Protected" : false,
"ShowNotifications" : true,
"SignalLevel" : "-",
"Status" : "On",
"StrParam1" : "",
"StrParam2" : "",
"SubType" : "Switch",
"SwitchType" : "On/Off",
"SwitchTypeVal" : 0,
"Timers" : "true",
"Type" : "Light/Switch",
"TypeImg" : "lightbulb",
"Unit" : 1,
"Used" : 1,
"UsedByCamera" : false,
"XOffset" : "0",
"YOffset" : "0",
"idx" : "17"
- Screen Shot 2017-01-07 at 02.45.29.png (35.64 KiB) Viewed 2857 times
- Screen Shot 2017-01-07 at 03.58.04.png (337.49 KiB) Viewed 2851 times
.js:
Code: Select all
['17', 'Status', 'cell6', 'Heating','0','0'],
If I turn on "lastseen is wanted" -> I can see the correct date.
What's wrong with this?
Re: NEW frontpage.html - request comments
Posted: Saturday 07 January 2017 9:23
by denisj
albertvandam wrote:Dear all,
With all the examples and code in this forum, I have managed to create a pretty good frontpage which runs on a wall mounted tablet.
Albert,
can you please upload your frontpage packet some wear in order to download it and take some sample please ?
Thanks in advance
Denis
Re: NEW frontpage.html - request comments
Posted: Saturday 07 January 2017 9:59
by ChrisPi
Hello,
Is ther anyone that can tel how to change mij inlogscreen? I just want to change the Domoticz into my name.
- Inlog screen
- Domoticz.JPG (19.42 KiB) Viewed 2829 times
Re: NEW frontpage.html - request comments
Posted: Saturday 07 January 2017 14:07
by ropske
hi ChrisPi,
i don't think you can change this, unless you change it in the sourcecode and rebuild it
Re: NEW frontpage.html - request comments
Posted: Saturday 07 January 2017 14:53
by madrian
I created similar dummy switch and replaced the not working switch with this. Now it works. Anyone knows what happened here?
Re: NEW frontpage.html - request comments
Posted: Saturday 07 January 2017 15:51
by ChrisPi
ropske wrote:hi ChrisPi,
i don't think you can change this, unless you change it in the sourcecode and rebuild it
Oké. Do you know where to find the sourcecode?
Re: NEW frontpage.html - request comments
Posted: Saturday 07 January 2017 15:57
by ropske
Re: NEW frontpage.html - request comments
Posted: Saturday 07 January 2017 16:22
by ChrisPi
Thanks for your comment. I just looked here but can you be more specific?
Re: NEW frontpage.html - request comments
Posted: Saturday 07 January 2017 16:29
by ropske
I also don't know in what part this is, sorry
Re: NEW frontpage.html - request comments
Posted: Sunday 08 January 2017 0:28
by markk
Has anyone incorporated their front page into a smart mirror?
https://www.youtube.com/watch?v=oLpwJAphU7Y
Re: NEW frontpage.html - request comments
Posted: Sunday 08 January 2017 16:33
by JuanUil
sorry wanted to delete this post
Re: NEW frontpage.html - request comments
Posted: Sunday 08 January 2017 16:50
by JuanUil
Do you know the problem?
Do we need to put the garbage, the green garbage or the paper container outside?
I have made a selectorswitch and a program to display what container needs to get out.
the LUA code:
Code: Select all
week = tonumber (os.date( "%V"))
dag = tostring(os.date("%a"));
status = tonumber(otherdevices_svalues['Afval'])
commandArray = {}
--print ('Dag= '..dag)
if (dag=='Fri' or dag=='Sat' ) then
weekend = false; weekdag = true
end
if (dag=='Mon' or dag=='Tue' or dag=='Wed' or dag=='Thu'or dag=='Sun') then
weekend = true ; weekdag = false
end
--Bepalen alleen grijs
if(week==2 or week==6 or week==10 or week==14 or week==18 or week==22 or week==26 or week==30 or week==34 or week==38) then
afval = true ; papier = false ; groen = false
end
--Bepalen grijs en papier
if (week==42 or week==46 or week==50) then
afval = true ; papier = true ; groen = false
end
--Bepalen alleen groen
if (week==1 or week==5 or week==9 or week==13 or week==17 or week==19 or
week==21 or week==23 or week==25 or week==27 or week==29 or week==31 or week==35 or week==39
or week==41 or week==43 or week==45 or week==47 or week==49 or week==51) then
afval = false ; papier = false ; groen = true
end
--Bepalen groen en papier
if (week==3 or week==7 or week==11 or week==15 or week==33 or week==37 ) then
afval = false ; papier = true ; groen = true
end
--Bepalen alleen papier
if (week==20 or week==24 or week==28) then
afval = false ; papier = true ; groen = false
end
-- Bepalen niets
if (week==4 or week==8 or week==12 or week==16 or week==32 or week==36 or week==40 or week==44 or week==48 or week==52) then
afval = false ; papier = false ; groen = false
end
if (not(afval) and not(papier) and not(groen) and status~=10) then
status=10
commandArray ['UpdateDevice']= '383|0|' .. status
end
if (afval and weekdag and status~=20)then
status=20
commandArray ['UpdateDevice']= '383|0|' .. status
end
if (afval and weekend and status~=10) then
status=10
commandArray ['UpdateDevice']= '383|0|' .. status
end
if (groen and weekdag and status~=30) then
status=30
commandArray ['UpdateDevice']= '383|0|' .. status
end
if (groen and weekend and status~=10) then
status=10
commandArray ['UpdateDevice']= '383|0|' .. status
end
if (papier and weekend and status~=40) then
status=40
commandArray ['UpdateDevice']= '383|0|' .. status
end
if (papier and weekdag and status~=10) then
status=10
commandArray ['UpdateDevice']= '383|0|' .. status
end
return commandArray
And the adjustment in frontpage.js
Code: Select all
// replace Afval met icoon
if (item.idx == idx_Afval){// && vdata == "grijs" ){
vdata = item['Level']; //get current level
if (vdata == '10'){}
vdata=new String(vdata).replace( "10", "<img src=icons/niets.png height=155px vspace=35> ");
if (vdata == '20'){}
vdata=new String(vdata).replace( "20", "<img src=icons/grijs.png height=155px vspace=20> ");
if (vdata == '30'){}
vdata=new String(vdata).replace( "30", "<img src=icons/groen.png height=155px vspace=20> ");
if (vdata == '40'){}
vdata=new String(vdata).replace( "40", "<img src=icons/papier.png height=155px vspace=35> ");
}
And of course some screenshots
enjoy
Jan
Re: NEW frontpage.html - request comments
Posted: Sunday 08 January 2017 22:23
by pvm
Somewhat different but possibly interesting :
I performed some tests with
https://magicmirror.builders
Nice mirror software with a lot of plugins. It shouldn't be too hard to incorporate domoticz information.
Re: NEW frontpage.html - request comments
Posted: Sunday 08 January 2017 23:25
by jhenrikb
Hi:)
How are you guys installing any frontpage to your Raspi Domoticz interface?
I have tried to Download this (among other frontpages) packages.
Unzip on computer
Edit config and or other file to correct IP adress, Port, User&Password etc.
Load all the files into www folder with a subfolder with filezilla
enter: http://ip:port/folder (with no success)
also tried "..folder/" and "..folder/index.htm" and "..index.htm/". Also with no success.
Do i need to do this differently?
Sincerely
John
Re: NEW frontpage.html - request comments
Posted: Monday 09 January 2017 18:17
by Trigun
albertvandam wrote:Dear all,
With all the examples and code in this forum, I have managed to create a pretty good frontpage which runs on a wall mounted tablet. Thanks to Hansbit, G3rard and all others.
However I can't get to control my Dru Fireplace (Mertik G6R-HT4B) on the frontpage like it should. Directly from Domoticz it works fine.
Does someone have the right json commands to control the Mertik controller?
When I send json commands directly from the Chrome Address Bar, it doesn't work as aspected also.
For example:
http://192.168.4.250:8080/json.htm?type ... itchcmd=up
switches the fire place off!
Thanks in advance for any response.
Hi Albertvandam,
first of all, you did a great job!
is there a chance you can post your frontpage files?
I would love to check it out and see how I can make it fit for my home.
thnx in advance!