:orphan:

DS18B20BusConsumer
==================

**From:** `Analog Devices <https://www.analog.com/en/products/ds18b20.html>`_

**Class:** :py:class:`herosdevices.hardware.analog_devices.ds18b20.DS18B20BusConsumer`


**Driver Quality Index:** beta


DS18B20 temperature sensor, read from a shared OneWireBusMaster's cache instead of sysfs directly.

.. tab-set:: 


   .. tab-item:: Arguments
   
   
      Bold arguments are mandatory. For more information on the listed arguments refer to the class             documentation: :py:class:`herosdevices.hardware.analog_devices.ds18b20.DS18B20BusConsumer` If parameters appear in this             list but not in the class definition, please recursively check the linked base classes for the             definition of the parameter.
      
      
      .. list-table:: 
         :widths: 50 50 50 100
         :header-rows: 1
      
         * - Argument
           - Type
           - Default Value
           - Description
         * - **bus_master**
           - **<class 'herosdevices.core.bus.onewire.OneWireBusMaster'>**
           - 
           - the OneWireBusMaster (typically a RemoteHERO proxy to one) that polls the physical bus this device lives on.
         * - **device_id**
           - **<class 'str'>**
           - 
           - id of the onewire device as named by the w1 Linux kernel driver (e.g. "28-00000df6f834").
      

   .. tab-item:: Example JSON for BOSS
   
      The following JSON strings can be used to start a HERO device representation of             :py:class:`DS18B20BusConsumer <herosdevices.hardware.analog_devices.ds18b20.DS18B20BusConsumer>` using             `BOSS <https://boss-eb4966.gitlab.io/>`_.
      
      .. code-block:: json
      
         {
             "_id": "device_ds18b20_table_right",
             "classname": "herosdevices.hardware.analog_devices.DS18B20BusConsumer",
             "arguments": {
                 "bus_master": "$device_w1therm_bus",
                 "device_id": "28-00000e1e6004"
             },
             "datasource": {
                 "async": false,
                 "observables": {
                     "temperature": {
                         "conversion": "x / 1000",
                         "unit": "degC",
                         "boundaries": [
                             [
                                 21,
                                 22
                             ],
                             [
                                 20,
                                 24
                             ],
                             [
                                 15,
                                 30
                             ]
                         ]
                     }
                 },
                 "interval": 15
             }
         }
      .. note::
      
          This example contains a variable that     :external:ref:`references another HERO <json-remote-hero>` with ``$``.
      
      
      :sup:`from examples/analog_devices/ds18b20_bus.json` 
      
      
      .. code-block:: json
      
         {
             "_id": "my_DS18B20BusConsumer",
             "classname": "herosdevices.hardware.analog_devices.ds18b20.DS18B20BusConsumer",
             "arguments": {
                 "bus_master": "<class 'herosdevices.core.bus.onewire.OneWireBusMaster'>",
                 "device_id": "<class 'str'>"
             }
         }
      
      :sup:`generated from signature`
   .. tab-item:: Inheritance
   
   
      .. inheritance-diagram:: herosdevices.hardware.analog_devices.ds18b20.DS18B20BusConsumer
      
