1. Qiita
  2. 投稿
  3. fabo

温度センサー ADT7410をArduinoで制御する(I2C)

  • 2
    いいね
  • 0
    コメント
この記事は最終更新日から1年以上が経過しています。

ADT7410

Datasheet

Datasheet ADT7410

計測可能な値

種類 概要
温度 温度精度は±0.5℃。-40℃~+105℃(2.7V~3.6V)の範囲。-40℃~+105℃の範囲で計測可能。16ビットの値を取得可能。分解能は0.0078℃。

Slave address

Slave Address 0x48

Register map

Address Name Type Default 概要
0x00 TEMP_MSB R 00000000 温度 MSB
0x01 TEMP_LSB R 00000000 温度 LSB
0x02 STATUS R 00000000 ステータス
0x03 CONFIGURATION R/W 00000000 Configuration
0x04 THIGH_MSB R/W 00100000 THIGH MSB
0x05 THIGH_LSB R/W 00000000 THIGH LSB
0x06 TLOW_MSB R/W 00000101 TLOW MSB
0x07 TLOW_LSB R/W 00000000 TLOW LSB
0x08 TCRIT_MSB R/W 01001001 TCRIT MSB
0x09 TCRIT_LSB R/W 10000000 TCRIT LSB
0x0A THYST_MSB R/W 00000101 THYST setpoint
0x0B ID R/W 1100xxxx ID
0x2F RESET R/W 00000000 Software reset

Who_am_i_reh

ID 0x0B

ADT7410の場合、0xCXが返ってくる。

arduino
#define ADT7410_WHO_AM_I_REG 0x0B

#define ADT7410_DEVICE 0xC0

bool searchDevice()
{
  byte device = 0x00;
  readI2c(ADT7410_WHO_AM_I, 1, &device);

  if((device && ADT7410_DEVICE) == ADT7410_DEVICE){
      return true;
  } else{
      return false;
  }
}

Configuration

CONFIGURATION 0x03
Bit7 Bit6 Bit5 Bit4 Bit3 Bit2 Bit1 Bit0
Resolution Operation mode Operation mode INT/CT mode INT pin CT pin  Fault Fault

Fault

Bit1 Bit0 Fault
0 0 1 fault (default).
0 1 2 faults.
1 0 3 faults.
1 1 4 faults.

CT pin

polarity This bit selects the output polarity of the CT pin.

  • 0 active low
  • 1 active high

INT pin

polarity This bit selects the output polarity of the INT pin.

  • 0 active low.
  • 1 active high.

INT/CT mode

This bit selects between comparator mode and interrupt mode.

  • 0 interrupt mode
  • 1 comparator mode

Operation mode

These two bits set the operational mode for the ADT7410.

Bit6 Bit5 操作
0 0 continuous conversion (default)
0 1 one shot. Conversion time is typically 240 ms.
1 0 1 SPS mode. Conversion time is typically 60 ms.
1 1 shutdown.

Resolution

This bit sets up the resolution of the ADC when converting.

  • 0 = 13-bit resolution. Sign bit + 12 bits gives a temperature resolution of 0.0625°C.
  • 1 = 16-bit resolution. Sign bit + 15 bits gives a temperature resolution of 0.0078°C