caspia.gateway.services.sensors.temperature package

Submodules

caspia.gateway.services.sensors.temperature.analog module

class caspia.gateway.services.sensors.temperature.analog.AnalogTemperatureSensor(*args, **kwargs)[source]

Bases: caspia.gateway.services.base.GatewayService, caspia.meadow.services.sensors.temperature.TemperatureSensorBase

Initialize new service.

Parameters
  • name – Name of the service (or just its path)

  • include – What optional characteristics to include. Tuple of their names.

property all_observables
attach(connection)
property attached
auto_discovery = False
characteristic_cached_read(characteristic)
characteristic_cached_write(characteristic, value_and_meta)
async characteristic_read(characteristic, **kwargs)
characteristic_subscribe(characteristic, on_value, on_error=None)
async characteristic_write(characteristic, value, **kwargs)
characteristics = {'$metadata': <Characteristic <class 'caspia.meadow.services.base.ServiceMeta'>:$metadata>, 'temp': <Characteristic <class 'caspia.meadow.services.base.ServiceMeta'>:temp>}
configure()[source]
convert_from_raw(raw)[source]
convert_ratio_to_resistance(ratio)[source]
property dependant_components
detach()
get_node()
static get_subclass(stype, mixin=None)
property is_updated_periodically
load_definition(spec)

Update characteristics of this instance based on serialized specs.

Parameters

spec – Dict most likely going to be coming from meadow - from some gateway informing us about its services and their characteristics.

metadata
async notify(characteristic, value, if_changed=False, extra=None)
on(name, *args, **kwargs)
async on_component_event(component, event)[source]
optional = {}
async published()
serialize()

Return serialized version (most likely dict) if possible or None.

temp
async temp_read(**kwargs)[source]
type = 'temperature-sensor'

caspia.gateway.services.sensors.temperature.mcp980x module

class caspia.gateway.services.sensors.temperature.mcp980x.MCP980XTemperatureSensor(config, network, storage)[source]

Bases: caspia.gateway.services.base.GatewayService, caspia.meadow.services.sensors.temperature.TemperatureSensorBase

property all_observables
attach(connection)
property attached
auto_discovery = False
characteristic_cached_read(characteristic)
characteristic_cached_write(characteristic, value_and_meta)
async characteristic_read(characteristic, **kwargs)
characteristic_subscribe(characteristic, on_value, on_error=None)
async characteristic_write(characteristic, value, **kwargs)
characteristics = {'$metadata': <Characteristic <class 'caspia.meadow.services.base.ServiceMeta'>:$metadata>, 'temp': <Characteristic <class 'caspia.meadow.services.base.ServiceMeta'>:temp>}
configure()[source]
property dependant_components
detach()
get_node()
static get_subclass(stype, mixin=None)
property is_updated_periodically
load_definition(spec)

Update characteristics of this instance based on serialized specs.

Parameters

spec – Dict most likely going to be coming from meadow - from some gateway informing us about its services and their characteristics.

metadata
async notify(characteristic, value, if_changed=False, extra=None)
on(name, *args, **kwargs)
async on_component_event(component, event)[source]
optional = {}
async published()
serialize()

Return serialized version (most likely dict) if possible or None.

temp
async temp_read(**kwargs)[source]
type = 'temperature-sensor'

caspia.gateway.services.sensors.temperature.scd30 module

class caspia.gateway.services.sensors.temperature.scd30.SCD30TemperatureSensor(config, network, storage)[source]

Bases: caspia.gateway.services.base.GatewayService, caspia.meadow.services.sensors.temperature.TemperatureSensorBase

property all_observables
attach(connection)
property attached
auto_discovery = False
characteristic_cached_read(characteristic)
characteristic_cached_write(characteristic, value_and_meta)
async characteristic_read(characteristic, **kwargs)
characteristic_subscribe(characteristic, on_value, on_error=None)
async characteristic_write(characteristic, value, **kwargs)
characteristics = {'$metadata': <Characteristic <class 'caspia.meadow.services.base.ServiceMeta'>:$metadata>, 'temp': <Characteristic <class 'caspia.meadow.services.base.ServiceMeta'>:temp>}
configure()[source]
property dependant_components
detach()
get_node()
static get_subclass(stype, mixin=None)
property is_updated_periodically
load_definition(spec)

Update characteristics of this instance based on serialized specs.

Parameters

spec – Dict most likely going to be coming from meadow - from some gateway informing us about its services and their characteristics.

metadata
async notify(characteristic, value, if_changed=False, extra=None)
on(name, *args, **kwargs)
async on_component_event(component, event)[source]
optional = {}
async published()
serialize()

Return serialized version (most likely dict) if possible or None.

temp
async temp_read(**kwargs)[source]
type = 'temperature-sensor'

caspia.gateway.services.sensors.temperature.service module

class caspia.gateway.services.sensors.temperature.service.TemperatureSensor(config, network, storage)[source]

Bases: caspia.gateway.services.base.GatewayService, caspia.meadow.services.sensors.temperature.TemperatureSensorBase

property all_observables
attach(connection)
property attached
auto_discovery = True
characteristic_cached_read(characteristic)
characteristic_cached_write(characteristic, value_and_meta)
async characteristic_read(characteristic, **kwargs)
characteristic_subscribe(characteristic, on_value, on_error=None)
async characteristic_write(characteristic, value, **kwargs)
characteristics = {'$metadata': <Characteristic <class 'caspia.meadow.services.base.ServiceMeta'>:$metadata>, 'temp': <Characteristic <class 'caspia.meadow.services.base.ServiceMeta'>:temp>}
abstract configure()
abstract property dependant_components
detach()
get_node()
static get_subclass(stype, mixin=None)
load_definition(spec)

Update characteristics of this instance based on serialized specs.

Parameters

spec – Dict most likely going to be coming from meadow - from some gateway informing us about its services and their characteristics.

metadata
async notify(characteristic, value, if_changed=False, extra=None)
on(name, *args, **kwargs)
async on_component_event(component, event)
optional = {}
async published()
serialize()

Return serialized version (most likely dict) if possible or None.

temp
type = 'temperature-sensor'

caspia.gateway.services.sensors.temperature.sht2x module

class caspia.gateway.services.sensors.temperature.sht2x.SHT2XTemperatureSensor(config, network, storage)[source]

Bases: caspia.gateway.services.base.GatewayService, caspia.meadow.services.sensors.temperature.TemperatureSensorBase

property all_observables
attach(connection)
property attached
auto_discovery = False
characteristic_cached_read(characteristic)
characteristic_cached_write(characteristic, value_and_meta)
async characteristic_read(characteristic, **kwargs)
characteristic_subscribe(characteristic, on_value, on_error=None)
async characteristic_write(characteristic, value, **kwargs)
characteristics = {'$metadata': <Characteristic <class 'caspia.meadow.services.base.ServiceMeta'>:$metadata>, 'temp': <Characteristic <class 'caspia.meadow.services.base.ServiceMeta'>:temp>}
configure()[source]
property dependant_components
detach()
get_node()
static get_subclass(stype, mixin=None)
property is_updated_periodically
load_definition(spec)

Update characteristics of this instance based on serialized specs.

Parameters

spec – Dict most likely going to be coming from meadow - from some gateway informing us about its services and their characteristics.

metadata
async notify(characteristic, value, if_changed=False, extra=None)
on(name, *args, **kwargs)
async on_component_event(component, event)[source]
optional = {}
async published()
serialize()

Return serialized version (most likely dict) if possible or None.

temp
async temp_read(**kwargs)[source]
type = 'temperature-sensor'

Module contents