diff --git a/ARES/a b/ARES/a index fe5c695..040c0cf 100644 --- a/ARES/a +++ b/ARES/a @@ -41,7 +41,7 @@ #define ARES // version that OS components will report: -#define ARES_VERSION "0.5.0" +#define ARES_VERSION "0.5.1" #define ARES_VERSION_TAGS "beta 3" // copyright year for the OS: @@ -314,6 +314,10 @@ string E_PROGRAM_NUMBER = "!!"; // The warning event triggers whenever a warning is issued by a daemon. This is meant only to be monitored by the _display program. Ideally this would be a notify message, but using an event hook fails gracefully if a warning is generated before _display is registered with the kernel. Specified as 11 , e.g. "11 2 6" displays 'RADIATION DANGER' in slot 2; see interface.consts.h.lsl for list. #define EVENT_WARNING 0x00b +// The "working" events aren't meant to be hooked by any programs, but rather used as a reliable way to tell the scheduler daemon itself when to show the working badge. They are called as "16 ", and "17 ", respectively. The on the begin and end must match, and will be visible to the user. Convenience macros are defined in scheduler.h.lsl. +#define EVENT_WORKING_BEGIN 0x010 +#define EVENT_WORKING_END 0x011 + /* MODE DEFINITIONS diff --git a/ARES/api/scheduler.h.lsl b/ARES/api/scheduler.h.lsl index bcc25a8..f9205ef 100644 --- a/ARES/api/scheduler.h.lsl +++ b/ARES/api/scheduler.h.lsl @@ -48,10 +48,14 @@ #define query_hooks() kernel(SIGNAL_QUERY_HOOKS, "") #define hook_events(...) kernel(SIGNAL_HOOK_EVENT, PROGRAM_NAME + "," + concat(__VA_ARGS__, ",")) #define unhook_events(...) kernel(SIGNAL_UNHOOK_EVENT, PROGRAM_NAME + "," + concat(__VA_ARGS__, ",")) + #define begin_working(_reason) kernel(SIGNAL_TRIGGER_EVENT, (string)EVENT_WORKING_BEGIN + " " + (_reason)) + #define end_working(_reason) kernel(SIGNAL_TRIGGER_EVENT, (string)EVENT_WORKING_END + " " + (_reason)) #else #define query_hooks() tell(DAEMON, C_SCHEDULER, E_SIGNAL_QUERY_HOOKS + PROGRAM_NAME) #define hook_events(...) tell(DAEMON, C_SCHEDULER, E_SIGNAL_HOOK_EVENT + PROGRAM_NAME + "," + concat(__VA_ARGS__, ",")) #define unhook_events(...) tell(DAEMON, C_SCHEDULER, E_SIGNAL_UNHOOK_EVENT + PROGRAM_NAME + "," + concat(__VA_ARGS__, ",")) + #define begin_working(_reason) tell(DAEMON, C_SCHEDULER, E_SIGNAL_TRIGGER_EVENT + (string)EVENT_WORKING_BEGIN + " " + (_reason)) + #define end_working(_reason) tell(DAEMON, C_SCHEDULER, E_SIGNAL_TRIGGER_EVENT + (string)EVENT_WORKING_END + " " + (_reason)) #endif // create a timer (interval must be an integer) diff --git a/protocols/phase protocol.txt b/protocols/phase protocol.txt index edd5dad..dfebf96 100644 --- a/protocols/phase protocol.txt +++ b/protocols/phase protocol.txt @@ -96,6 +96,8 @@ MESSAGES