Timeline Always Run for One Second
TurnipTruck
Posts: 1,485
This codes exists within a module. The timeline event always happens after one second regardless of the value of lTL1_10Sec
Hmmmm?
VOLATILE LONG lTL1_10Sec[1]={10000} TIMELINE_CREATE (1,lTL1_10Sec,1,TIMELINE_RELATIVE,TIMELINE_ONCE) TIMELINE_EVENT [1]
Hmmmm?
0
Comments
And the output when button 1 is pushed.
Just for grins and giggles, perhaps you can go ahead and make the variable VOLATILE LONG lTL1_10Sec[1]={10000} and array. and see how that behaves.
so,
VOLATILE LONG lTL1_10Sec[2]
lTL1_10Sec[1]=1
lTL1_10Sec[2]=10000
Then just don't do anything on the first timeline event.
See how that behaves...
Commenting out the variable definition results in a compiler error. Thus I know that there are no confused variables for the timeline time values.
Is it possible to post something that can be compiled? I filled in the blanks as best I could and I still don't see anything wrong with the timeline creation. It fires 10 seconds after the last push. What is your indication that it fires after 1 second no matter what?
If you don't want to post more code then I suggest putting in a SEND_STRING 0 whenever you start the timeline (or set the timeline timer back to 1) and do a SEND_STRING 0 when the timeline fires.
I wish I could be of more help but I don't have enough to go on.
Sorry about that. I didn't realize that you were trying to compile my code. It is from a long-winded module for a specific digital tv tuner. I'll try to post more later.
TimelineID's need to be Longs so maybe that's what is screwing things up.
BTW, I use that stacking of timelines all the time and have never yet had a probelm related to it. Works well for making waits related to UIs that can be tracked and managed seperately.
Thanks to all who had a look at the module for me!