doc: fix issues in sensort.rst

- Paths to samples (one level up, BMP280 -> BME280)
- Type names (macro -> struct sensor_value)

Change-Id: I9e3e8e4dd7f7b1c55789ab4b9d621e75176e6d88
Signed-off-by: Inaky Perez-Gonzalez <inaky.perez-gonzalez@intel.com>
This commit is contained in:
Inaky Perez-Gonzalez 2016-06-13 12:28:02 -07:00 committed by Anas Nashif
commit 4bcb874e95

View file

@ -53,21 +53,21 @@ the corresponding :literal:`_ANY` channel type and a buffer of 3
of channels between reads and efficiency of communication by issuing a of channels between reads and efficiency of communication by issuing a
single transaction on the underlying bus. single transaction on the underlying bus.
Below is an example illustrating the usage of the BMP280 sensor, which Below is an example illustrating the usage of the BME280 sensor, which
measures ambient temperature and atmospheric pressure. Note that measures ambient temperature and atmospheric pressure. Note that
:c:func:`sensor_sample_fetch` is only called once, as it reads and :c:func:`sensor_sample_fetch` is only called once, as it reads and
compensates data for both channels. compensates data for both channels.
.. literalinclude:: ../../../samples/sensor/bmp280/src/main.c .. literalinclude:: ../../samples/sensor/bme280/src/main.c
:language: c :language: c
:lines: 31- :lines: 31-
:linenos: :linenos:
The example assumes that the returned values have type The example assumes that the returned values have type :c:type:`struct
:c:macro:`SENSOR_TYPE_INT_PLUS_MICRO`, which is the case for BMP280. A real sensor_value`, which is the case for BME280. A real application
application supporting multiple sensors should inspect the :c:data:`type` supporting multiple sensors should inspect the :c:data:`type` field of
field of the :c:data:`temp` and :c:data:`press` values and use the other the :c:data:`temp` and :c:data:`press` values and use the other fields
fields of the structure accordingly. of the structure accordingly.
Configuration and Attributes Configuration and Attributes
**************************** ****************************
@ -118,7 +118,7 @@ interest of saving power. Since the application has direct access to the
kernel config symbols, no trigger is registered when triggering was disabled kernel config symbols, no trigger is registered when triggering was disabled
by the driver's configuration. by the driver's configuration.
.. literalinclude:: ../../../samples/sensor/mcp9808/src/main.c .. literalinclude:: ../../samples/sensor/mcp9808/src/main.c
:language: c :language: c
:lines: 31- :lines: 31-
:linenos: :linenos: