HomeGenie Forum
Automation Program Plugins and Wizard Scripting => APP Contributions => Topic started by: dani on December 30, 2014, 03:58:55 PM
-
You can find here new widgets.
Calendrier allows to program a calendar wich define the kind of the day :
- W : Week-end
- O : Working day (French:Ouvré)
- F : Free day (French:Férié)
- S : Special day as hollidays or other
Tables horaires allows to program different Hours schedule tables by step of 15 mns.
There are 10 tables for thermostats use, 6 tables for lights and switchs, 6 tables for shutters or dimmers.
4 states for thermostat : A (Stop) - H (No frost) - E (Eco) - C (Comfort)
2 states for light and switch : F (ofF) - O (On)
6 states for shutter and dimmer : 0 (0%) - 1 (20%) - 2 (40%)- 3 (60%)- 4 (60%)- 5 (100%)
The parameters generated are copied in general settings parameters by the hgx actually only at the starting of the scenario.
The parameters for the calendar are ;
Settings.Parameter("Calend.Year.0 ).Value for January
Settings.Parameter("Calend.Year.1 ).Value for Februaryy
.
.
Settings.Parameter("Calend.Year.11 ).Value for December
The parameters for Hours schedule are :
Settings.Parameter("Table.Therm.0").Value
Settings.Parameter("Table.Therm.1").Value.
.
Settings.Parameter("Table.Therm.9").Value
Settings.Parameter("Table.Light.0").Value
Settings.Parameter("Table.Light.1").Value.
.
Settings.Parameter("Table.Light.6").Value
Settings.Parameter("Table.Shutter.0").Value
Settings.Parameter("Table.Shutter.1").Value.
.
Settings.Parameter("Table.Shutter.6").Value
The .html and .json have to be in the folder html/pages/control/widgets/DaniMail/generic of HG UI.
I will provide some samples later on how to use those tables.
And I will see later for include local language in this contributions, but I am new in JS environment
Cheers
Dani
-
Here have some screenshots
Cheers
-
You can find here :
Calendrier Widget and Module with some adjustements
Tables horaires Widget and Module with some adjustments
And new Thermostat Widget and Module which implement a multi Virtual DevicesThermostat that use the Calendar and Hours Tables.
Only one thing, you have to adjust the Module number of Tables Horaires in thermostats.json Line 48, just replace 1009 by your module number, insteadof the tables are not display in the control popup in program mode.
48 : var moduleTH = HG.WebApp.Utility.GetModuleByDomainAddress('HomeAutomation.HomeGenie.Automation', '1009');
The files *.json, *.html and the folder locales have to be in html/pages/control/widgets/DaniMail/generic.
Let's me now if you have some requests
Cheers
Dani
-
Hi dani,
this is really a good work. We can include it as a System Application, so users won't have to change the program address in the source code.
Let me know when you feel it's ready to be included in default hg programs.
Cheers,
g.
-
Hi Gene,
I am Ok to include as a system application. I actually make some little modifications.
As to prevent the module that table as changed then the system parameter are updated without start and stop the module.
I think it will be ready tomorrow after some improve.
Cheers
Dani
-
Hi Gene,
Here you can find my first official version to join in your master
Only you have to modify :
At the line 60 of thermostats.json :
Replace 1018 with the new module number of Calendrier
At the line 63 of thermostats.json :
Replace 1009 with the new module number of Tables horaires
Let's me now if you have some requests or issues.
Cheers
Dani
-
Hi Gene,
I corrected a small issue when leave the group of a virtual Thermostat and come back.
If you use the ControlPopup and click severals Mode buttons without close the popup then we get after the first change mode more and more Events for one button press. It's increased all change mode from 1 events to 3, 9, 36 at the 4th change. Here you find the release.
The cause is that I don't include the events click'on' off all items the test if( !controlpopup ) perhaps you know the reason. I need to change only the room of end parenthesis in json code.
I have an other small issue in the Hour Tables in the same order when recall the control group of Tables Horaires.
The 2 selected hours box are not show. If I print in a log item the edit value of that two items are corrects after the initialisation by calling analyseclick : function().
Here You find the first patch.
-
Here you can find the release of the Contribution.
It comes with some corrections of little issues and some addons same if's now possible to change the number of Hour tables from the option popup of each thermostat ...
I am now working on some Virtual Lights and Shutter in accordance with the calendar and Hour tables.
Now for change the Number of Modules in Thermostats.json, it's in the lines 13 and 14 :
Replace 1000 your Number of Calendrier Module.
Replace 1001 your Number of Tables horaires Module.
-
You can find here :
Calendrier Widget and Module with some adjustements and small design changes
Tables horaires Widget and Module with some adjustments
Thermostat Widget and Module which implement a multi Virtual DevicesThermostat that use the calendar and Hours Tables.
Each Thermostat can controle 3 Areas (Switchs) like 3 independant elctric heaters
And new Eclairage Widget and Module which implement a multi Light Devices that use the calendar and Hours Tables.
Each Light Device can controle 4 Areas (Lights or Switchs)
Only something todo :
1 - you have to adjust the Module number of Calendrier in thermostats.js Line 13 and eclairages.js Line 11, just replace 1000 by your module number, instead of the tables are not display in the control popups in program mode.
2 - you have to adjust the Module number of Tables Horaires in thermostats.js Line 14 and eclairages.js Line 12, just replace 1001 by your module number, instead of the tables are not display in the control popups in program mode.
Carreful since the rev 458 of HG, the .json files are replace by .js
Let's me now if you have some requests.
Cheers
Dani
-
Hi Gene,
How does we do to merge xxxx-Program.hgx to the git project. And small notice too.
My calendar and Hours tables work fine.
I join also two Virtual projects in accordance with those parameters : A multiple Thermostats and multi lights that care of the calendar and hours tables.
We can include that in the general project when you agree
After that I hope some helps to add the other languages.
Cheers
Dani
-
Hi dani,
what do you mean with "small notice"? Can the description field of the program a good place for it?
To add a program to default HG programs proceed as follow:
- run HomeGenie from the IDE
- import/compile the program in the "Weather and Enviroment" automation group
- quit homegenie
- copy the HomeGenie/HomeGenie/bin/Debug/programs.xml over the BaseFiles/Common/programs.xml
- edit the BaseFiles programs.xml and change your program's address with an address > 500 with the next available number (let's say 510)
- copy the HomeGenie/HomeGenie/bin/Debug/programs/1000.dll (or whatever it was the dll) as BaseFiles/Common/programs/500.dll
- add the 500.dll to the HG Common project as well with the "copy to output directory" flag active as other programs dlls
- copy the new programs.xml and the new dll in the BaseFiles/Common/homegenie_factory_config.zip archive
I can add italian translation to your app.
Cheers,
g.
-
Thank's Gene,
I will follow your instructions.
See you
Dani
-
Hi,
here the english locale.
Best Regards,
AutoBob.
-
Hi AutoBob,
You can find following your module JeeNode with some modifications.
Cheers
Dani
-
Hi,
Thank you Dani.
Once I have all working, I will publish the code for HG, JeeLink & JeeNodes + Hardware Schema.
Best Regards,
AutoBob
-
This APP Contribution is now include in the Standard project.
Thank you Gene for spend times with me for that work.
Please inform us about issues you will find.
-
I looked at it when I installed r466. Very nice appearance!
-
Hi Dani,
I think you and Gene made a good work!
Thank for your app contribution, I appreciate the time table and new look of thermostat.
But I think something is wrong..
I set in automation the values, and restarted(see picture "automation")
then add the app and open the settings in control, the values are empty, are not saved by "automation setting" and if I change they can be different by the "automation setting""...
Some difference:
the app have new name "Basic Thermostat" in old release was "generic Thermostat"
and in dashboard the name is "Danimail 1"
Some advice?
Thank
Marco
-
You are right, because it's the domain Name we Have to change to Thermostat Habitually in the widget it's the domain name that is write in this place
That's because Gene change the domain name To HomeAutomation.DaniMail. We look for change that.
The problem of lost of parameter, because you have to give a name to the virtual thermostat. If not when the prog restart it's reset the value if you don't give a name to the ModuleSwitch.
Cheers
Dani
-
Dani,
Is it possible to make some modifications to the Enhanced Thermostats App.
- some of the error reports and notifications are in your language, please change them to English
- The thermostat app is for heating only, can you modify this for heating and cooling (airconditioning). The standard modes for these are Cooling - Fan Only - Heating ; each of these functions require a seperate relays/switch setting for control of the equipment.
Thanks.
Peter
-
Enterprised,
I will look at for translate, and for different relay instaed of the mode as you ask.
Cheers
Dani
-
Hi,
I want to try your APP now integrate in HG distribution, but it failed. I think a widget not existing.
I have in "configuration" :
* "automation" -> "scheduling" -> "timetable" activated.
* "group" -> with "timetable calendar" and "timetable"
But when i go in "control", nothing show-up ...
Any idea ?
Bye
-
Depending on what version of HG you are running, the app may be broken due to a change Gene made during refactoring. If you are running the most current stable version, that shouldn't be the issue.
-
Arf, I have the latest HG (r478) ???
-
Hmmm, not sure then. I saw the issue in R471'ish and it was fixed in the next version number. I'm not on r478 yet.
-
Hi Dani,
I want to understand how the plugin is working but i need small help to know what to fill in the empty boxes.
Thanks.
Kobi
-
In the empty box you have to put the numer of time table from 1 to 10, in accordance with the calendar.
Cheers
Dani
-
Dani,
Thanks it's working.
BR
Kobi.
-
Hello,
is a great job. I would like to link my app squeezebox radio.
http://www.homegenie.it/forum/index.php?topic=715.0 (http://www.homegenie.it/forum/index.php?topic=715.0)
My idea is this:
- if period in your timetable is active and a motion sensor is turn on --> play a radio in streaming.
How we can do? can you help me?
-
Hello Igor,
For use the timetable for your application, you can wtite A C# programme that use them. Or you can create a Virtual light module and the time table will send On/Off to your virtual module. At you to check the sensor state and send the command to your radio
Cheers
Dani
-
Hello,
;D I created the virtual device ;D (Thank you dani )
Now I create a timetable 1 with the period of the switch and setted the timetable on the widget of the switch... but it doesn t change status :'( Any advice for me?
I almost ready for my music started from a motion detector when I arrive at breakfast 8)
Thank you
-
For me it's work, the Virtual switch is on automatically from 12:20 as I ask in the timetable.
Don't forget to check Enable TimeTable Scheduling.
-
All the schedule works. Only your code crash but I don't have a reel squeezebox.
Try the code I join, you will see that the time table works Fine, Is the switch is on, you will get the message Switch is on every 10 secondes.
Check Your code I mask.
And why you create 2 switchs in the trigger code ?
-
Thank you dani,
I didn t see this reply :-[ I will use only the thread of squeezebox.
Now I check my code and test the timetable.
Thank you
-
Found,
the problem was the wrong timezone on raspberry. Correct with:
dpkg-reconfigure tzdata
-
Hi!
I'm very interested in Enhaced Thermostat, but I can't find it in my homegenie installation (1.1 r512). How can I get this enhaced thermostat?
Thanks!!
Nacho.-