panotimer.swf
I wrote this timer plugin because the FPP timer seems to be very dependant on frame rate.
The method used in this timer, is to check the built-in hardware clock in your computer.
As a curiosity this clock is counting milliseconds since January 1, 1970, and the plugin
is reading this value five times a second. That, of course, doesn't make the plugin suited
for millisecond timings but rather from a second upwards. And keeping the checking rate low
helps keeping the CPU load on a low level.
There is no restriction on the number of delays that can be handled. They are all stored in
an array and checked five times a second. And as soon as "their time has come", the FPP-
command is executed and they are removed from the array.
You can use this timer in two different ways: 1. To get a simple fixed delay before a FPP command is issued. 2. To execute FPP commands repeatedly at certain intervals. This can be used as a countdown to an event, or for example to show a hotspot once every 2 minutes and then hide it again after 10 seconds.
Format:
external.panotimer.event=delay,timeout_command[,interval,repetitive_command] The last two parameters are only used for interval commands.Usage:
Just load the plugin in a layer in your FPP XML file:layer9 = files/panotimer.swf
To initiate a timer, you set the plugin event= with the delay and command parameters, for example:
external.panotimer.event=15000,global.showSpot20
To execute the example above with showing a hotspot every 2 minutes, you add the two extra parameters for interval and repetitive command:
external.panotimer.event=1200000,global.endFunc,120000,global.showSpot
NOTES:
Because FPP parses values assigned to external plugin parameters as if they were assignments with motion tweens, like:
[name]=[value],[time in milliseconds],[type of tween function],[done function name],[interrupt function name]
you cannot use commands like these when setting the plugin event parameter. We are using commas to separate our own parameters. This is a general rule, and not valid for just this plugin. To avoid problems, I would suggest always using the name of an FPP (global) function as FPP_command, and instead put your commands in that function. If you are executing a global function, don't forget to include the "global." prefix.