SHT1x温湿度传感器

概述

瑞士Sensirion公司推出了SHT1x单片数字温湿度集成传感器。采用CMOS微加工专利技术(CMOSenstechnology),确保产品具有极高的可靠性和出色的长期稳定性。该传感器由1个电容式聚合体测湿元件和1个能隙式测温元件组成,并与1个14位A/D转换器以及1个2-wire数字接口在单芯片中无缝结合,使得该产品具有功耗低、反应快、抗干扰能力强等优点。 在对环境温度与湿度测量要求高的情况下使用,该产品具有极高的可靠性和出色的稳定性。与Arduino专用传感器扩展板结合使用,可以非常容易地实现与温度和与湿度感知相关的互动效果。

技术规格

应用范围

连接示意图

示例代码

在运行样例程序前,请先安装SHT1x 库文件到您的Arduino libraries文件夹下

//Arduino Sample Code for SHT1x Humidity and Temperature Sensor
//www.DFRobot.com
//Version 1.0

#include <SHT1x.h>

// Specify data and clock connections and instantiate SHT1x object
#define dataPin  10
#define clockPin 11
SHT1x sht1x(dataPin, clockPin);

void setup()
{
   Serial.begin(38400); // Open serial connection to report values to host
   Serial.println("Starting up");
}

void loop()
{
  float temp_c;
  float temp_f;
  float humidity;

  // Read values from the sensor
  temp_c = sht1x.readTemperatureC();
  temp_f = sht1x.readTemperatureF();
  humidity = sht1x.readHumidity();

  // Print the values to the serial port
  Serial.print("Temperature: ");
  Serial.print(temp_c, DEC);
  Serial.print("C / ");
  Serial.print(temp_f, DEC);
  Serial.print("F. Humidity: ");
  Serial.print(humidity);
  Serial.println("%");

  delay(2000);
}

相关文档

<File:nextredirectltr.png>购买 [SHT1x数字温湿度传感器(SKU: DFR0066)]

category: Product_Manual category: DFR_Series category: Sensors category:source category:Diagram