Vishwanatha Subbanna | a1e70a7 | 2016-11-12 16:00:00 +0530 | [diff] [blame] | 1 | description: > |
| 2 | Interface to control physical LED. |
| 3 | |
| 4 | properties: |
| 5 | - name: State |
| 6 | type: enum[self.Action] |
Vishwanatha Subbanna | d9751fa | 2016-11-29 11:30:54 +0530 | [diff] [blame] | 7 | default: 'Off' |
Vishwanatha Subbanna | a1e70a7 | 2016-11-12 16:00:00 +0530 | [diff] [blame] | 8 | description: > |
| 9 | Current State of the LED. |
| 10 | |
| 11 | - name: DutyOn |
| 12 | type: byte |
| 13 | default: 50 |
| 14 | description: > |
| 15 | Percentage time the LED needs to be ON while blinking. |
| 16 | |
| 17 | - name: Color |
| 18 | type: enum[self.Palette] |
| 19 | default: Unknown |
| 20 | description: > |
| 21 | Color that the LED can emit. |
| 22 | |
Vishwanatha Subbanna | 47af1f7 | 2016-12-13 21:33:05 +0530 | [diff] [blame] | 23 | - name: Period |
| 24 | type: uint16 |
| 25 | default: 1000 |
| 26 | description: > |
| 27 | LED blink period expressed as milliseconds per on/off cycle. |
| 28 | |
Vishwanatha Subbanna | a1e70a7 | 2016-11-12 16:00:00 +0530 | [diff] [blame] | 29 | enumerations: |
| 30 | - name: Action |
| 31 | description: > |
| 32 | Possible states a LED can be in. |
| 33 | values: |
Vishwanatha Subbanna | d9751fa | 2016-11-29 11:30:54 +0530 | [diff] [blame] | 34 | - name: 'Off' |
Vishwanatha Subbanna | a1e70a7 | 2016-11-12 16:00:00 +0530 | [diff] [blame] | 35 | description: > |
| 36 | LED is in OFF state |
Vishwanatha Subbanna | d9751fa | 2016-11-29 11:30:54 +0530 | [diff] [blame] | 37 | - name: 'On' |
Vishwanatha Subbanna | a1e70a7 | 2016-11-12 16:00:00 +0530 | [diff] [blame] | 38 | description: > |
| 39 | LED is in solid ON state |
Vishwanatha Subbanna | d9751fa | 2016-11-29 11:30:54 +0530 | [diff] [blame] | 40 | - name: 'Blink' |
Vishwanatha Subbanna | a1e70a7 | 2016-11-12 16:00:00 +0530 | [diff] [blame] | 41 | description: > |
| 42 | LED is blinking |
| 43 | |
| 44 | - name: Palette |
| 45 | description: > |
| 46 | Possible colors that the LED can emit. |
| 47 | values: |
| 48 | - name: Unknown |
| 49 | description: > |
| 50 | Color emitted by LED is unknown. |
| 51 | - name: Red |
| 52 | description: > |
| 53 | LED can emit Red color. |
| 54 | - name: Green |
| 55 | description: > |
| 56 | LED can emit Green color. |
| 57 | - name: Blue |
| 58 | description: > |
| 59 | LED can emit Blue color. |
| 60 | - name: Yellow |
| 61 | description: > |
| 62 | LED can emit Yellow color. |