[arm-allstar] Scheduler reload interval (and how to use the scheduler)

David McGough kb4fxc at inttek.net
Wed Mar 9 05:18:49 EST 2016


Hi Barry,

Here is how I understand the basic scheduler operation.

First, you must add a definition in the rpt.conf node stanza defining the
scheduler stanza and a valid macro stanza. You also may need a functions
stanza, depending on what you're trying to do. These definitions only get
updated when the node is forced to restart--like stopping/starting
Asterisk or issuing a "rpt reload" from the Asterisk command prompt.

Once setup properly, the scheduler code in app_rpt.c will try to execute
every minute, looking (in a somewhat ugly, brute-force way!!) for jobs to
run. You can enable debugging, which will send messages to the Asterisk
console related to the scheduler (and many other operations, too). It's
probably best to initially try this debugging on a quiet, inactive
node...Or, you'll likely be overrun by the quantity of debug messages!  
To enable debug, run from the Asterisk console:

rpt debug level 7

...To turn back off:

rpt debug level 0



So, here is a working example, using the scheduler to send the current 
time of day to the defined node, once per minute. All this code is found 
in the rpt.conf file:

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

[1215]			; Example node number 1215
functions=funcs33	; Arbitrary names for stanzas...
macros=macros33
scheduler=sked33

[funcs33]	; Customized functions for node 1215
81=status,12    ; Time of Day (local only)

[macros33]	; Customized macros for node 1215
1234=*81#	; The number 1234 is arbitrary, 81 is defined in funcs33.

[sked33]	; Customized scheduler for node 1215
1234=* * * * *	; 1234 is defined as a macro. Run macro once a minute.

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;



Questions???


73, David KB4FXC





On Wed, 9 Mar 2016, Barry Buelow via arm-allstar wrote:

> 
> How/when does the [Schedule] stanza reload.  I've been making some 
changes and it appears the changes don't take effect immediately (or 
after an astres.sh).  Do they maybe reload hourly or ???
> Barry w0iy
> 
> 
> 



More information about the arm-allstar mailing list