Part 1
요약·해설
HS300x alias, fixture_i2c_hs300x와 11줄 측정 출력을 보존합니다.
Sensors
Up to 10
Alias
dht0 ··· dht9
Fixture
I2C HS300x
Part 2
접을 수 있는 영어 원문 전체
영어 원문 전체 펼치기
원문 SHA-256
871E58871258180AE4BD4BB028C8A908758A414CAE9D7E919AE92430998AE4AE
.. _dht_polling:
Generic Digital Humidity Temperature sensor polling sample
##########################################################
Overview
********
This sample application demonstrates how to use digital humidity temperature
sensors.
Building and Running
********************
This sample supports up to 10 humidity/temperature sensors. Each sensor needs to
be aliased as ``dhtN`` where ``N`` goes from ``0`` to ``9``. For example:
.. code-block:: devicetree
/ {
aliases {
dht0 = &hs300x;
};
};
Make sure the aliases are in devicetree.
It also requires a correct fixture setup when the sensor is present.
For the correct execution of that sample in twister, add into boards's
map-file next fixture settings::
- fixture: fixture_i2c_hs300x
Then build and run with:
.. zephyr-app-commands::
:zephyr-app: samples/sensor/dht_polling
:board: <board to use>
:goals: build flash
:compact:
Sample Output
=============
.. code-block:: console
hs300x@44: temp is 25.31 °C humidity is 30.39 %RH
hs300x@44: temp is 25.51 °C humidity is 30.44 %RH
hs300x@44: temp is 25.51 °C humidity is 30.37 %RH
hs300x@44: temp is 25.51 °C humidity is 30.39 %RH
hs300x@44: temp is 25.31 °C humidity is 30.37 %RH
hs300x@44: temp is 25.31 °C humidity is 30.35 %RH
hs300x@44: temp is 25.51 °C humidity is 30.37 %RH
hs300x@44: temp is 25.51 °C humidity is 30.37 %RH
hs300x@44: temp is 25.51 °C humidity is 30.39 %RH
hs300x@44: temp is 25.51 °C humidity is 30.44 %RH
hs300x@44: temp is 25.51 °C humidity is 30.53 %RH
Part 3
한국어 전문 번역
개요
이 sample application은 digital humidity·temperature sensor를 사용하는 방법을 보여 줍니다.
빌드 및 실행
이 sample은 humidity·temperature sensor를 최대 10개까지 지원합니다. 각 sensor에는 dhtN 형식의 alias가 필요하며, N에는 0부터 9까지의 번호가 들어갑니다. 예:
/ {
aliases {
dht0 = &hs300x;
};
};
Alias가 Devicetree에 정의되어 있는지 확인합니다.
Sensor가 실제로 연결된 경우에는 올바른 fixture setup도 필요합니다. Twister에서 이 sample을 정상 실행하려면 board map file에 다음 fixture setting을 추가합니다.
- fixture: fixture_i2c_hs300x
그런 다음 다음 명령으로 build하고 실행합니다.
west build -b <board to use> samples/sensor/dht_polling
west flash
출력 예
hs300x@44: temp is 25.31 °C humidity is 30.39 %RH
hs300x@44: temp is 25.51 °C humidity is 30.44 %RH
hs300x@44: temp is 25.51 °C humidity is 30.37 %RH
hs300x@44: temp is 25.51 °C humidity is 30.39 %RH
hs300x@44: temp is 25.31 °C humidity is 30.37 %RH
hs300x@44: temp is 25.31 °C humidity is 30.35 %RH
hs300x@44: temp is 25.51 °C humidity is 30.37 %RH
hs300x@44: temp is 25.51 °C humidity is 30.37 %RH
hs300x@44: temp is 25.51 °C humidity is 30.39 %RH
hs300x@44: temp is 25.51 °C humidity is 30.44 %RH
hs300x@44: temp is 25.51 °C humidity is 30.53 %RH
Source
출처
영어 원문에는 문단, 문서 지시문, 표, 코드, 코드 심벌, 경로를 그대로 보존했습니다.