Appearance
traits/brightness_sensor.proto
Table of Contents
traits/brightness_sensor.proto
AmbientBrightness
AmbientBrightness records the light level measured by a device.
Field | Type | Label | Description |
---|---|---|---|
brightness_lux | float | Brightness measured in LUX |
AmbientBrightnessSupport
AmbientBrightnessSupport describes the capabilities of devices implementing this trait
Field | Type | Label | Description |
---|---|---|---|
resource_support | smartcore.types.ResourceSupport | How a named device supports read/pull apis | |
brightness_lux | smartcore.types.FloatBounds | The range of values the device is capable of reporting. |
DescribeAmbientBrightnessRequest
Field | Type | Label | Description |
---|---|---|---|
name | string | The name of the device |
GetAmbientBrightnessRequest
Field | Type | Label | Description |
---|---|---|---|
name | string | The name for the device. | |
read_mask | google.protobuf.FieldMask | The state fields to fetch |
PullAmbientBrightnessRequest
Field | Type | Label | Description |
---|---|---|---|
name | string | The name for the device. | |
read_mask | google.protobuf.FieldMask | The state fields to fetch | |
updates_only | bool | When true the device will only send changes to the resource value. The default behaviour is to send the current value immediately followed by any updates as they happen. |
PullAmbientBrightnessResponse
Field | Type | Label | Description |
---|---|---|---|
changes | PullAmbientBrightnessResponse.Change | repeated |
PullAmbientBrightnessResponse.Change
Field | Type | Label | Description |
---|---|---|---|
name | string | The name for the device that changed | |
ambient_brightness | AmbientBrightness | ||
change_time | google.protobuf.Timestamp | when the change occurred |
BrightnessSensorApi
BrightnessSensorApi reports on the measured ambient brightness for a space.
Method Name | Request Type | Response Type | Description |
---|---|---|---|
GetAmbientBrightness | GetAmbientBrightnessRequest | AmbientBrightness | GetAmbientBrightness returns the current brightness level as measured by the device. |
PullAmbientBrightness | PullAmbientBrightnessRequest | PullAmbientBrightnessResponse stream | PullAmbientBrightness returns a stream of brightness changes as the device measures them. |
BrightnessSensorInfo
Describes the capabilities of a specific named device with respect to this trait.
Method Name | Request Type | Response Type | Description |
---|---|---|---|
DescribeAmbientBrightness | DescribeAmbientBrightnessRequest | AmbientBrightnessSupport | Get information about how a named device implements AmbientBrightness measurements |