Aller au contenu

Support Gea


Steven

Messages recommandés

Pepite,

Donc j'ai essayé de trouver la ligne d'erreur, j'ai dà» décalé quelque peut les lignes mais l'erreur provient de la ligne de code suivante :

elseif (type(id) == "table" and GEA.match(string.lower(id[1]), "global|global.")) then

Je n'y comprends rien, car je n'ai rien modifié qui pourrait générer un telle erreur!

Ensuite mon GEA est toute les 1min redémarré par WatchDog, bordel de bordel  :-(

[DEBUG] 11:33:18: line 1323: bad argument #1 to 'lower' (string expected, got boolean)

Bon, sujet clos, j'ai trouvé

En voulant essayé de gérer mes alertes sur le passage d'heure d'été / Hiver, j'ai entouré le déclencheur true, d'accolade !
Le bordel!

 

Merci encore de ma voir lu, désolé du dérangement.

Je ne sais toujours pas pour l'instant m'envoyer une alerte quand je change de l'été à  l'hiver le jour J et non chaque jour que je fais le test.

Enfin pas grave, cela ne va pas m'empêcher de dormir.  :-)

Lien vers le commentaire
Partager sur d’autres sites

J'avais pas vu que tu avais trouvé le soucis  ;) Bien joué.

 

Ton GEA est propre ça fait plaisir à  voir.

 

 

As-tu essayer cela :

GEA.add({"Global","HEURE_ETE_HIVER","HIVER"}, 30, "Passage à  l'heure d'été, penser à  avancer d'une heure", {{"Global","HEURE_ETE_HIVER","ETE"},{"DST"},{"Time", "05:00", "05:01"}})
GEA.add({"Global","HEURE_ETE_HIVER","ETE"}, 30, "Passage à  l'heure d'hiver, penser à  reculer d'une heure", {{"Global","HEURE_ETE_HIVER","HIVER"},{"NOTDST"},{"Time", "05:00", "05:01"}}) 
Lien vers le commentaire
Partager sur d’autres sites

 

J'avais pas vu que tu avais trouvé le soucis  ;) Bien joué.

 

Ton GEA est propre ça fait plaisir à  voir.

 

 

As-tu essayer cela :

GEA.add({"Global","HEURE_ETE_HIVER","HIVER"}, 30, "Passage à  l'heure d'été, penser à  avancer d'une heure", {{"Global","HEURE_ETE_HIVER","ETE"},{"DST"},{"Time", "05:00", "05:01"}})
GEA.add({"Global","HEURE_ETE_HIVER","ETE"}, 30, "Passage à  l'heure d'hiver, penser à  reculer d'une heure", {{"Global","HEURE_ETE_HIVER","HIVER"},{"NOTDST"},{"Time", "05:00", "05:01"}}) 

 

Je vais essayer.  :-)

 

 

 

=================================

Ca marche comme je veux, cool

Merci bcp

Yes

Aller je vais aller prendre le soleil, après un repas, plancha dehors un premier novembre

trop de la balle

Lien vers le commentaire
Partager sur d’autres sites

j'ai un gros probleme enfin pas très gros ;)

GEA.add({"Dead", id["LPDECO"]}, 30, "defaut #time#", {{"Repeat"}})

Si je débranche le FGD je ne reçois pas la notification DEFAUT, il faut que je cliquer sur on (allumer la lampe)  pour recevoir la notification 30s après.

Lien vers le commentaire
Partager sur d’autres sites

Super @kioneoranga,

 

Finalement, tu utilises quel code pour tes alertes de changement d'heures ?

 

Oui, ca sent la pale copie de ma part hihihi

 

@971jmd,

 

Il existe déjà  un VD "Jour chomé", t'embetes pas ;-)

 

Pepite

Tout simplement le code conseillé par Steven

 	 -- ### ETE / HIVER ##
     GEA.add({"Global","HEURE_ETE_HIVER","HIVER"}, 30, "Passage à  l'heure d'été, penser à  avancer d'une heure", {{"Global","HEURE_ETE_HIVER","ETE"},{"DST"},{"Time", "05:00", "05:01"},{"Portable", id["TELEPHONE_ERIC"]},{"Portable", id["TELEPHONE_MANUELA"]}})
     GEA.add({"Global","HEURE_ETE_HIVER","ETE"}, 30, "Passage à  l'heure d'hiver, penser à  reculer d'une heure", {{"Global","HEURE_ETE_HIVER","HIVER"},{"NOTDST"},{"Time", "05:00", "05:01"},{"Portable", id["TELEPHONE_ERIC"]},{"Portable", id["TELEPHONE_MANUELA"]}}) 
  • Upvote 1
Lien vers le commentaire
Partager sur d’autres sites

Bonjour,

Je veux envoyer des données via un périphérique virtuel à  ThingSpeak avec l'intervalle de 15 minutes.

J'utilise le code suivant. Cela fonctionne, mais y at-il une meilleure façon de le faire?

 

/Stefan

 



GEA.add(true, 15*60, "", {{"Repeat"}, {"Time","00:01","23:59"},{"VirtualDevice", id["NBThingSpeak"], "1"}})

Lien vers le commentaire
Partager sur d’autres sites

Bonjour,

Im trying to achieve some automatic lighting based on 2 variables, home / away and light / dark.

 

I have some questions how to make this work, first how should i combine the variables, like this:

 

  local HomeDark = {"Global", "PresentState", "Home"}, {"Global", "LuxHome", "0"}
  local HomeLight = {"Global", "PresentState", "Home"}, {"Global", "LuxHome", "2"}
  local AwayDark = {"Global", "PresentState", "Away"}, {"Global", "LuxHome", "0"}
  local AwayLight = {"Global", "PresentState", "Away"}, {"Global", "LuxHome", "2"}
 
or is this possible? :  
  
  local Home = {"Global", "PresentState", "Home"}
  local Away = {"Global", "PresentState", "Away"}
  local Light = {"Global", "LuxHome", "2"}
  local Dark = {"Global", "LuxHome", "0"} 
   
  local HomeDark = {Home}, {Dark}
  local HomeLight = {Home}, {Light} 
Lien vers le commentaire
Partager sur d’autres sites

Bonjour,

Ma première ligne fonctionne très bien, mais je veux seulement qu'elle soit active si la variable globale "heater_se" est "On"

Quel est le bon code pour cela?

Merci d'avance,

Stefan


GEA.add(true, 3*60, "", {{"Repeat"}, {"VirtualDevice", id["Energy"], "1"}})


GEA.add({"Global", "heater_se", On}, 3*60, "", {{"Repeat"}, {"VirtualDevice", id["Energy"]}, "1"}})
Lien vers le commentaire
Partager sur d’autres sites

@pepite

thank you for the quick answer

 

will the following be the right code then?

 

  GEA.add(HomeLight, 1, "", {
    {"turnOff", 482}, --worktop
    {"turnOff", 621}, --small light kitchen
    {"turnOff", 17}, --fire place
    {"turnOff", 619}, --small light living
    {"turnOff", 695}, --living main
    { "VirtualDevice", 666, 1}, --Iris HUE off
    {"Repeat"}
  })
Lien vers le commentaire
Partager sur d’autres sites

Hello @seriksson,

 

It's OK as you write it.

you don't need "Repeat" i think

 

Hi @pepite,

 

I got the following error

[DEBUG] 12:26:31: line 234: ')' expected near '}'

For this line

GEA.add({"Global", "heater_se", On}, 3*60, "", {{"Repeat"}, {"VirtualDevice", id["Energy"]}, "1"}})
Lien vers le commentaire
Partager sur d’autres sites

okay, thanks for the help so far

but when I use the code below, and I change the lux variable once (from dark to light), my lights keep going off and on and off and on

i didn't mean to built a disco, what am I doing wrong?

 

  GEA.add(HomeLight, 1, "", {
    {"turnOff", 482}, --worktop
    {"turnOff", 621}, --small light kitchen
    {"turnOff", 17}, --fire place
    {"turnOff", 619}, --small light living
    {"turnOff", 695}, --living main
    { "VirtualDevice", 666, 1}, --Iris HUE off
    {"Repeat"}

  })

 

  GEA.add(HomeDark, 1, "", {
    {"turnOn", 482}, --worktop
    {"turnOn", 621}, --small light kitchen
    {"turnOn", 17}, --fire place
    {"turnOn", 619}, --small light living
    {"turnOn", 695}, --living main
    { "VirtualDevice", 666, 2}, --Iris HUE off
    {"Repeat"}

  })

Lien vers le commentaire
Partager sur d’autres sites

 

Bonjour,

Im trying to achieve some automatic lighting based on 2 variables, home / away and light / dark.

 

I have some questions how to make this work, first how should i combine the variables, like this:

 

  local HomeDark = {"Global", "PresentState", "Home"}, {"Global", "LuxHome", "0"}
  local HomeLight = {"Global", "PresentState", "Home"}, {"Global", "LuxHome", "2"}
  local AwayDark = {"Global", "PresentState", "Away"}, {"Global", "LuxHome", "0"}
  local AwayLight = {"Global", "PresentState", "Away"}, {"Global", "LuxHome", "2"}
 
or is this possible? :  
  
  local Home = {"Global", "PresentState", "Home"}
  local Away = {"Global", "PresentState", "Away"}
  local Light = {"Global", "LuxHome", "2"}
  local Dark = {"Global", "LuxHome", "0"} 
   
  local HomeDark = {Home}, {Dark}
  local HomeLight = {Home}, {Light} 

 

 

Both are the same. I prefere the second option.

 

but you should write like this (watch the brackets at the last 2 lines)

  local Home = {"Global", "PresentState", "Home"}
  local Away = {"Global", "PresentState", "Away"}
  local Light = {"Global", "LuxHome", "2"}
  local Dark = {"Global", "LuxHome", "0"} 
   
  local HomeDark = {Home, Dark}
  local HomeLight = {Home, Light} 

With this modification, in GEA, you will have  to write

GEA.add( HomeDark , ...)

It is up to you but becarefull with brackets.

  • Upvote 1
Lien vers le commentaire
Partager sur d’autres sites

All, thank you for teaching me the basics, however Im not able to make it operational.

I now have the following made

 

  local Home = {"Global", "PresentState", "Home"}
  local Light = {"Global", "LuxHome", "2"}
  local Dark = {"Global", "LuxHome", "0"}
  local HomeLight = {Home, Light}
  local HomeDark = {Home, Dark}
 
 
  GEA.add( HomeDark, 1, "", {
    {"turnOn", 558}
})
 
  
  GEA.add( HomeLight, 1, "", {
    {"turnOff", 558}
})
  
and I get the following debug
[DEBUG] 16:39:06: [ PresentState=Home ] Run : checking (ID: 1) [turnOn,558] [if..]
[DEBUG] 16:39:06: [ PresentState=Home ] Check : starting checking (ID: 1) [turnOn,558] [if..]
[DEBUG] 16:39:06: [ PresentState=Home ] Check : checking dates (ID: 1) [turnOn,558] [if..]
[DEBUG] 16:39:06: [ PresentState=Home ] isActivated : activation checking (ID: 1) [turnOn,558] [if..]
[DEBUG] 16:39:06: [ PresentState=Home ] isActivated : type : global variable (ID: 1) [turnOn,558] [if..]
[DEBUG] 16:39:06: isActivated : 'if' checking
[DEBUG] 16:39:06: isActivated : type : global variable
[DEBUG] 16:39:06: isActivated : activated
[DEBUG] 16:39:06: [ PresentState=Home ] isActivated : activated (ID: 1) [turnOn,558] [if..]
[DEBUG] 16:39:06: [ PresentState=Home ] Run : checking (ID: 2) [turnOff,558] [if..]
[DEBUG] 16:39:06: [ PresentState=Home ] Check : starting checking (ID: 2) [turnOff,558] [if..]
[DEBUG] 16:39:06: [ PresentState=Home ] Check : checking dates (ID: 2) [turnOff,558] [if..]
[DEBUG] 16:39:06: [ PresentState=Home ] isActivated : activation checking (ID: 2) [turnOff,558] [if..]
[DEBUG] 16:39:06: [ PresentState=Home ] isActivated : type : global variable (ID: 2) [turnOff,558] [if..]
[DEBUG] 16:39:06: isActivated : 'if' checking
[DEBUG] 16:39:06: isActivated : type : global variable
[DEBUG] 16:39:06: !CANCEL! isActivated: desactivated
[DEBUG] 16:39:06: [ PresentState=Home ] !CANCEL! isActivated: 'if' stop the check (ID: 2) [turnOff,558] [if..]
[DEBUG] 16:39:06: [ PresentState=Home ] !CANCEL! isActivated: desactivated (ID: 2) [turnOff,558] [if..]
Lien vers le commentaire
Partager sur d’autres sites

Can you please send me your full script at steven.piccand@gmail.com I will have a look. I need yours because we may not have the same version.

 

And just explain me in the mail how your global variables are changed (or not ;) ) so I will be able to test it correctly.

  • Upvote 1
Lien vers le commentaire
Partager sur d’autres sites

Bonjour,

 

Je cherche à  modifier le temps déclenchement d'une tâche GEA en fonction d'une variable numérique.

Avez-vous une astuce ou est ce que ce n'est pas faisable :o ?

Ex: 
ma_variable_numerique = 1

GEA.add(true , {ma_variable_numerique}*60, "test", {{"Repeat"}})

Déclenchement toutes les minutes

Merci d'avance

Lien vers le commentaire
Partager sur d’autres sites

×
×
  • Créer...