I have a small problem with the TimerTask execution. I want to close my shutters at four o'clock in the morning.
First thing was that I added the objectdefinition:
<object id="ROLLAEDENZ" gad="0/1/8" init="persist">Rollaeden2</object>
Second step was the rule def.:
<rule id="ROLLDOWN">
<condition type="timer" trigger="true">
<at hour="3" min="59" wdays="1234567" exception="no" />
</condition>
<actionlist>
<action type="set-value" id="ROLLAEDENZ" value="1" />
</actionlist>
</rule>
Yesterday everthing worked, see the logfileentry:
2010-06-17 03:59:00 TimerManager: TimerTask execution. 1276739940
2010-06-17 03:59:00 Condition: TimerCondition evaluated as '1'
2010-06-17 03:59:00 Condition: TimerCondition evaluated as '0'
2010-06-17 03:59:00 PeriodicTask: Rescheduled at 2010-6-17 3:59:0 (1276826340)
2010-06-17 03:59:00 Action: Execute SetValueAction with value on
2010-06-17 03:59:00 KnxConnection: write(gad=264, buf, len=2): Send request
2010-06-17 03:59:00 FilePersistentStorage: Writing 'on' for object 'ROLLAEDENZ'
Write from 0.0.0 to 0/1/8: 01
Today, nothing happend:
Write from 1.2.2 to 3/1/1: 19 23
2010-06-18 03:59:00 TimerManager: TimerTask execution. 1276826340
2010-06-18 03:59:00 Condition: TimerCondition evaluated as '1'
2010-06-18 03:59:00 Condition: TimerCondition evaluated as '0'
2010-06-18 03:59:00 PeriodicTask: Rescheduled at 2010-6-18 3:59:0 (1276912740)
2010-06-18 03:59:00 Action: Execute SetValueAction with value on
Can someone point me in the right direction?
Thanks in advance!
René
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I just have the usual issue in mind: could you please check, that you have defined the object with the Force-flag (or nowadays the "stateless" flag?
Ie if you use the linknx 0.0.1.27 version:
<object id="ROLLAEDENZ" gad="0/1/8" flags="cwtuf" init="persist">Rollaeden2</object>
or if you use the sourcecode from the cvs:
<object id="ROLLAEDENZ" gad="0/1/8" flags="cwtus" init="persist">Rollaeden2</object>
Maybe someone pressed the down-button for your shutters just quickly, which was enough the let linknx think, that the shutters were already closed.
Otherwise:
What was the next entry on the log of the 18-6? was it also a "KnxConnection: write…?
Please check first, whether this is all ok - otherwise, come back :-)
(you can also check the EIBD-logfile, whether the gad was really send to the bus)
Best Regards, Jens
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
If it is currently still not working yet (and because the log shows, that the rule is triggered)
You cans also just try to trigger some other action like sending an email at this time. (to see, that the rule is working)
Furthermore: you use init="persist"
i.e. if you have defined in the <system> section something like:
<persistence type="file" path="/var/linknx/persist" logpath="/var/linknx/log"/>
then you should get a file like /var/linknx/persist/ROLLAEDENZ which always contains the last value. (check the timestamp of the file to see, when the last change was done.
Even better: If you furthermore create the object definition like
<object id="ROLLAEDENZ" gad="0/1/8" flags="cwtuf" init="persist" log="true">Rollaeden2</object>
then you will also get a logfile
/var/linknx/log/ROLLAEDENZ.log which contains a log of the changes of the "0/1/8" message with a timestamp.
(you should check this to see, whether linknx has write-permissions in the respective folders :)
Just another question: if you open the shutters "manually", which command is send? 0/1/8 or do send some other groupaddress?
Best Regards, Jens
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
it wasn't working yesterday, but today in the morning at 03:59 the telegram got sent and now everything is fine!
I meant that I defined two different objectnames and they did work only once, because of the "statelessflag". I use another address to control the shutter, the address 0/1/8 is only to close them in the morning.
Thanks again for your help!
Best Regards
René
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have also noticed this behaviour. For unknown reason sometimes the lamps which should be turned every night don't get turned on. I have checked all the respective flags. I did not narrow the problem down yet, and I am not 100% sure when such condition occures.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi Damago1,
I have just asked because some timers were deleted because of some sort of timer-stack-issue, when you used timer-task in some previous versions…But since you don't use it, that cannot be the cause.
In general, you should check the logfile after such a behaviour occured. You could especially check for "TimerTask skipped due to clock skew or heavy load.". I had once the problem, that especially some night-time timers were not executed correctly, because of a weird NTP-update issue after a DSL-re-connect…
In this case you will get some of these error-messages in the log.
…but the simplest cause could be, that you have just specified the wrong flags :-)
Best Regards, jens
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I have a small problem with the TimerTask execution. I want to close my shutters at four o'clock in the morning.
First thing was that I added the objectdefinition:
<object id="ROLLAEDENZ" gad="0/1/8" init="persist">Rollaeden2</object>
Second step was the rule def.:
<rule id="ROLLDOWN">
<condition type="timer" trigger="true">
<at hour="3" min="59" wdays="1234567" exception="no" />
</condition>
<actionlist>
<action type="set-value" id="ROLLAEDENZ" value="1" />
</actionlist>
</rule>
Yesterday everthing worked, see the logfileentry:
2010-06-17 03:59:00 TimerManager: TimerTask execution. 1276739940
2010-06-17 03:59:00 Condition: TimerCondition evaluated as '1'
2010-06-17 03:59:00 Condition: TimerCondition evaluated as '0'
2010-06-17 03:59:00 PeriodicTask: Rescheduled at 2010-6-17 3:59:0 (1276826340)
2010-06-17 03:59:00 Action: Execute SetValueAction with value on
2010-06-17 03:59:00 KnxConnection: write(gad=264, buf, len=2): Send request
2010-06-17 03:59:00 FilePersistentStorage: Writing 'on' for object 'ROLLAEDENZ'
Write from 0.0.0 to 0/1/8: 01
Today, nothing happend:
Write from 1.2.2 to 3/1/1: 19 23
2010-06-18 03:59:00 TimerManager: TimerTask execution. 1276826340
2010-06-18 03:59:00 Condition: TimerCondition evaluated as '1'
2010-06-18 03:59:00 Condition: TimerCondition evaluated as '0'
2010-06-18 03:59:00 PeriodicTask: Rescheduled at 2010-6-18 3:59:0 (1276912740)
2010-06-18 03:59:00 Action: Execute SetValueAction with value on
Can someone point me in the right direction?
Thanks in advance!
René
Hi René,
I just have the usual issue in mind: could you please check, that you have defined the object with the Force-flag (or nowadays the "stateless" flag?
Ie if you use the linknx 0.0.1.27 version:
<object id="ROLLAEDENZ" gad="0/1/8" flags="cwtuf" init="persist">Rollaeden2</object>
or if you use the sourcecode from the cvs:
<object id="ROLLAEDENZ" gad="0/1/8" flags="cwtus" init="persist">Rollaeden2</object>
Maybe someone pressed the down-button for your shutters just quickly, which was enough the let linknx think, that the shutters were already closed.
Otherwise:
What was the next entry on the log of the 18-6? was it also a "KnxConnection: write…?
Please check first, whether this is all ok - otherwise, come back :-)
(you can also check the EIBD-logfile, whether the gad was really send to the bus)
Best Regards, Jens
Hi Jens,
thanks for your help! I use the version 1.26 and didn't know that this feature is already enable in there.
I think it has something to do with the stateless flag, cause it works just once for every new definition for this issue!
Best Regards
René
Hi Rene,
sorry, I didn't got the last conclusion: is it working now, or not?
What do you mean with: "it works just once for every new definition for this issue"?
You can check the wiki for an explanation of the flags:
http://sourceforge.net/apps/mediawiki/linknx/index.php?title=Object_Definition_Syntax
If it is currently still not working yet (and because the log shows, that the rule is triggered)
You cans also just try to trigger some other action like sending an email at this time. (to see, that the rule is working)
Furthermore: you use init="persist"
i.e. if you have defined in the <system> section something like:
<persistence type="file" path="/var/linknx/persist" logpath="/var/linknx/log"/>
then you should get a file like /var/linknx/persist/ROLLAEDENZ which always contains the last value. (check the timestamp of the file to see, when the last change was done.
Even better: If you furthermore create the object definition like
<object id="ROLLAEDENZ" gad="0/1/8" flags="cwtuf" init="persist" log="true">Rollaeden2</object>
then you will also get a logfile
/var/linknx/log/ROLLAEDENZ.log which contains a log of the changes of the "0/1/8" message with a timestamp.
(you should check this to see, whether linknx has write-permissions in the respective folders :)
Just another question: if you open the shutters "manually", which command is send? 0/1/8 or do send some other groupaddress?
Best Regards, Jens
Hi Jens,
it wasn't working yesterday, but today in the morning at 03:59 the telegram got sent and now everything is fine!
I meant that I defined two different objectnames and they did work only once, because of the "statelessflag". I use another address to control the shutter, the address 0/1/8 is only to close them in the morning.
Thanks again for your help!
Best Regards
René
I have also noticed this behaviour. For unknown reason sometimes the lamps which should be turned every night don't get turned on. I have checked all the respective flags. I did not narrow the problem down yet, and I am not 100% sure when such condition occures.
Hi damago1,
quick question: Do you use anywere "time-counter" in your config? And if yes: which version of linknx do you use?
best Regards, Jens
I do not use time-counter yet. I am still using version 0.0.1.27 with
- LUA scripting support enabled
- Log4cpp logging enabled
Yours
Damago1
Hi Damago1,
I have just asked because some timers were deleted because of some sort of timer-stack-issue, when you used timer-task in some previous versions…But since you don't use it, that cannot be the cause.
In general, you should check the logfile after such a behaviour occured. You could especially check for "TimerTask skipped due to clock skew or heavy load.". I had once the problem, that especially some night-time timers were not executed correctly, because of a weird NTP-update issue after a DSL-re-connect…
In this case you will get some of these error-messages in the log.
…but the simplest cause could be, that you have just specified the wrong flags :-)
Best Regards, jens