Schedules
Creating a ScheduleΒΆ
A Drupal content has several properties concerning its use in the Digital Signage module:
- Priority
- Critical Flag
- Count
- Complexity
Based on theses Properties, we have to create a Schedule, which can be used for different Digital Signage vendors, like signageOS or ScreenFood. So this has to be quite generic.
A possible solution is to provide:
- a weight for the priority
- the critical flag is special and makes the priority obsolete
- a duration offset for complexity (and maybe for the critical flag as well), because complex content should be displayed longer
For example:
| Complexity | Offset in seconds |
|---|---|
| is Complex | X3 |
| is Critical | X2 |
For instance, the default duration is 5 seconds, a complex content will be displayed 15 seconds.
| Prio | Weight |
|---|---|
| High | 50 |
| Medium | 30 |
| Low | 20 |
The weight and the duration offset are implementation details and can be changed (see diagram below).
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 | |
A default implementation can be done as follows:
| node | is Critical | priority | is Complex | count | weight | offset |
|---|---|---|---|---|---|---|
| 1 | no | medium | no | infinite | 30 | |
| 2 | yes | obsolete | no | infinite | none | |
| 3 | no | low | yes | 10 | 20 | 5 |
| 4 | no | high | yes | infinite | 50 |
So we have a distribution of:
- Node 1: 30%
- Node 2: special, comes in first place
- Node 3: 20%
- Node 4: 50%
Based on this, we can create a sequence. The count property is handled by the specific device. We later request a report from that device to determine how ofter the node was displayed. So we can adjust the count property.