'CU50'에 해당되는 글 2건

  1. 2018.08.06 Hardware | MAX31865 + PT100 온도센서 조합 2
  2. 2018.07.31 Hardware | MAX31855 + K-type 온도센서 조합 2

Hardware | MAX31865 + PT100 온도센서 조합

|

1. MAX31865


K-Type 온도 센서를 arduino 와 연결하여 측정하는 MAX31855 은 아래 포스팅에서 가지고 놀아 봤습니다.


* Hardware | MAX31855 + K-type 온도센서 조합

http://chocoball.tistory.com/entry/Hardware-MAX31855-Ktype


그 외의 온도센서에 대해서는 아래 포스트들을 참고해보세요.


* Hardware | AM2322 Temperature & Humidity Sensor

http://chocoball.tistory.com/entry/Hardware-AM2322-Temperature-Humidity-Sensor


* Hardware | Arduino 비접촉 온도센서 GY-906 MLX90614

http://chocoball.tistory.com/entry/HardwareArduinoMLX90614


* Hardware | Arduino BMP280 고도/온도/기압 센서

http://chocoball.tistory.com/entry/HardwareArduinoBMP280


* Hardware | BME280 sensor

http://chocoball.tistory.com/entry/HardwareBME280


* Hardware | DS18B20 온도센서

http://chocoball.tistory.com/entry/Hardware-DS18B20-temperature-sensor


여기서 주의할 점은, MAX31865은 MAX31855와 제일 마지막 앞번의 digit 차이 입니다.

주문시 주의해야 합니다.


* MAX31865 : PT100 / PT1000 용

* MAX31855 : K-type 용





2. MAX31865 구입


AliExpress 에서 검색하면 아래의 링크가 가장 많이 구입한걸로 나옵니다.

바로 주문 넣습니다.


* MAX31865 SPI PT100/PT1000 RTD-to-Digital Converter Board Temperature Thermocouple Sensor Amplifier Module For Arduino 3.3V/5V

https://ko.aliexpress.com/item/MAX31865-PT100-PT1000-RTD-to-Digital-Converter-Board-Temperature-Thermocouple-Sensor-Amplifier-BModule-For-Arduino/32777498066.html







3. 도착


다른 센서들보다는 조금 높은 가격입니다.

그러나 업자는 항상 1 USD 미만으로 보내주십니다. :-)



포장은 일반적인 간단한 포장입니다.



Adafruit 제품과 거의 동일하게 만들었습니다.



Chip 을 확대해 봤습니다.

Taiwan 에서 생산된 M31865 라고 인쇄되어 있습니다.



Pin array 와 terminal 을 납땜해 줍니다.

Rref 의 저항은 431 = 430 ohm 입니다.





4. Thermocouple K-Type 구매하기


MAX31865 를 구입하면서, 거의 동시에 온도 센서도 주문에 넣습니다.


* Thermocouple K-Type Thermocouple Thermometer Probe WRNT-03 200mm*1000mm

https://ko.aliexpress.com/item/Thermocouple-K-Type-Thermocouple-Thermometer-Probe-WRNT-03-200mm-1000mm/32615649856.html



분명히 K-Type 이라고 적혀 있습니다.



Probe 형이라 길이가 깁니다. 포장도 큼지막 합니다.



뽁뽁이로 잘 쌓여서 도착했습니다.



음? CU50?



이미 MAX31855 글에서도 CU50 에 대해서 적었습니다.


MAX31865 / MAX31855 의 개념이 없었고, K-Type / PT100 / PT1000 개념도 없이 처음 질렀던 온도계 센서 입니다.

더욱 헷갈리게 된 것은, K-Type 이라고 주문한게 CU50 이 도착해, 처음 한동안은 뭐가 문제인지 몰랐습니다.


그 뒤에 센서 및 coverter chip 종류가 다르다는걸 알았죠.


* CU50 / WRNT-03 spec.

K1118591875.pdf



뭘 모르면 알때까지 삽질해야 하는 것은 인생의 진리 입니다.





5. PT100 구입하기


MAX31865 는 PT100 / PT1000 용 analog to digital converter 입니다.

PT1000 은 예민하면서 실험실용으로 사용되고 있어서, PT100 을 선택합니다.


* MYLB-0-400C PT100 Type 5mm x 50mm Temperature Controller Thermocouple Probe 2 Meters

https://ko.aliexpress.com/item/MYLB-0-400C-PT100-Type-5mm-x-50mm-Temperature-Controller-Thermocouple-Probe-2-Meters/32746546570.html




점점 진실에 접근하는 느낌이 듭니다.



도착.




포장 문제 없슴.

선은 3 wire 센서 이군요.



흠흠.



색이 다른 터미널끼리는 거의 100 ohm 의 차이를 보입니다.

이는 PT100 의 일반적인 현상이며, 더운 여름에 측정하다 보니 저항값이 조금 높습니다.


이 저항값의 변화를 가지고 온도를 측정하는 것입니다.



동일 선끼리는 거의 0 ohm 입니다.





6. Pinout / Layout


Pinout 에 대해서는 아래 Adafruit 의 링크를 참조해 보세요.


* Adafruit MAX31865 RTD PT100 or PT1000 Amplifier

https://learn.adafruit.com/adafruit-max31865-rtd-pt100-amplifier/pinouts


 MAX31865  | Arduino Micro
---------------------------
    Vin    |      3.3V
    GND    |      GND
    CLK    |      D13
    SDO    |      D12
    SDI    |      D11
    CS     |      D10
---------------------------


Layout 입니다.






7. sketch


레퍼런스 소스를 이용해서 기본적인 동작 확인에 들어갑니다.

우선 Library Manager 에서 max31865 를 검색해서 install 해줍니다.



인스톨이 완료되면, "File > Examples > Adafruit MAX31865 library > max31865" 을 선택하여 소스를 로딩합니다.



아래는 sketch 입니다.


/*************************************************** 
  This is a library for the Adafruit PT100/P1000 RTD Sensor w/MAX31865

  Designed specifically to work with the Adafruit RTD Sensor
  ----> https://www.adafruit.com/products/3328

  This sensor uses SPI to communicate, 4 pins are required to  
  interface
  Adafruit invests time and resources providing this open source code, 
  please support Adafruit and open-source hardware by purchasing 
  products from Adafruit!

  Written by Limor Fried/Ladyada for Adafruit Industries.  
  BSD license, all text above must be included in any redistribution
 ****************************************************/

#include 

// Use software SPI: CS, DI, DO, CLK
Adafruit_MAX31865 max = Adafruit_MAX31865(10, 11, 12, 13);
// use hardware SPI, just pass in the CS pin
//Adafruit_MAX31865 max = Adafruit_MAX31865(10);

// The value of the Rref resistor. Use 430.0 for PT100 and 4300.0 for PT1000
#define RREF      430.0
// The 'nominal' 0-degrees-C resistance of the sensor
// 100.0 for PT100, 1000.0 for PT1000
#define RNOMINAL  100.0

void setup() {
  Serial.begin(115200);
  Serial.println("Adafruit MAX31865 PT100 Sensor Test!");

  max.begin(MAX31865_3WIRE);  // set to 2WIRE or 4WIRE as necessary
}


void loop() {
  uint16_t rtd = max.readRTD();

  Serial.print("RTD value: "); Serial.println(rtd);
  float ratio = rtd;
  ratio /= 32768;
  Serial.print("Ratio = "); Serial.println(ratio,8);
  Serial.print("Resistance = "); Serial.println(RREF*ratio,8);
  Serial.print("Temperature = "); Serial.println(max.temperature(RNOMINAL, RREF));

  // Check and print any faults
  uint8_t fault = max.readFault();
  if (fault) {
    Serial.print("Fault 0x"); Serial.println(fault, HEX);
    if (fault & MAX31865_FAULT_HIGHTHRESH) {
      Serial.println("RTD High Threshold"); 
    }
    if (fault & MAX31865_FAULT_LOWTHRESH) {
      Serial.println("RTD Low Threshold"); 
    }
    if (fault & MAX31865_FAULT_REFINLOW) {
      Serial.println("REFIN- > 0.85 x Bias"); 
    }
    if (fault & MAX31865_FAULT_REFINHIGH) {
      Serial.println("REFIN- < 0.85 x Bias - FORCE- open"); 
    }
    if (fault & MAX31865_FAULT_RTDINLOW) {
      Serial.println("RTDIN- < 0.85 x Bias - FORCE- open"); 
    }
    if (fault & MAX31865_FAULT_OVUV) {
      Serial.println("Under/Over voltage"); 
    }
    max.clearFault();
  }
  Serial.println();
  delay(1000);
}


결과는 아래와 같습니다.



뭔가 많이 이상하군요... 뭐가 문제일까...





8. Jumper !!!


그렇습니다.

Adafruit 의 점퍼 설정을 대충 읽은 결과 입니다.



위의 글에 나와 있듯이, 미세하게 연결된 24 부분의 선을 잘라줘야 합니다.

시키는 대로 했으나 제대로 되지 않았습니다.


처음에는 CU50 으로 삽질하면서 2 wire 설정으로 납땜 했다가, 납 지워줬다가, 3 wire 설정으로 다시 납땜 했다가,

기판이 지저분해진 상태이고, 자주 인두로 지져서 기판 상태가 엉망으로 되면서 고장난게 분명하다는 결론에 도달했습니다.

(모두 합하면 10시간동안 삽질함)





9. 재구매


breakout 보드값이 비싸지만, 모든걸 다 해본 뒤라 새로운 converter 를 구입하기로 합니다.

이번에는 색이 다른것으로 구입합니다.


배송료 합하면 거의 6천원이군요... ㅠ.ㅠ


* 31865 MAX31865 RTD platinum resistance temperature detector module PT100 to PT1000

https://www.aliexpress.com/item/31865-MAX31865-RTD-platinum-resistance-temperature-detector-module-PT100-to-PT1000/32814557294.html



잘 도착했습니다. 얼른 시험해보고 싶습니다.



점퍼 사시의 간극이 커서 잘 납땜해야 합니다.



Rref 저항은 430 ohm 으로 동일하며, 2 4 사이에 미세하게 연결되어 있는것도 확인했습니다.

커터로 잘 그어서 절단해 줍니다.



두둥!

잘 연결하고 확인해 봅니다.



Aㅏ.....

그렇습니다. 여러 삽질을 하는 동안, 기존 breakout 기판이 고장난 것이었습니다.

그간 삽질하면서 학습한 내용을 토대로 잘 jumper 도 납땜하고, 자를껀 자르고 연결하니 한방에 성공합니다.



애증의 MAX31865 와 PT100 센서 입니다.



찬물 / 상온 물 / 뜨거운 물을 가지고 확인한 동영상 입니다.

calibration 이 필요해 보이지만, 그딴거는 나중에 기회되면 하겠습니다.

여기까지 오는것만 해도 힘들었습니다.



그래프화 시킨 그림입니다.

동작에 무리 없어 보입니다.





FIN


제가 가지고 있는 온도센서 및 converter breakout 보드는 다 확인해 봤네요.

CU50 만 빼고... 이놈은 어떻게 해야 할까요.


And

Hardware | MAX31855 + K-type 온도센서 조합

|

1. 또 온도센서야?


지금까지 시험해본 온도센서들 입니다. 5개나 있네요.


* Hardware | AM2322 Temperature & Humidity Sensor

http://chocoball.tistory.com/entry/Hardware-AM2322-Temperature-Humidity-Sensor


* Hardware | Arduino 비접촉 온도센서 GY-906 MLX90614

http://chocoball.tistory.com/entry/HardwareArduinoMLX90614


* Hardware | Arduino BMP280 고도/온도/기압 센서

http://chocoball.tistory.com/entry/HardwareArduinoBMP280


* Hardware | BME280 sensor

http://chocoball.tistory.com/entry/HardwareBME280


* Hardware | DS18B20 온도센서

http://chocoball.tistory.com/entry/Hardware-DS18B20-temperature-sensor



* Hardware | AM2322 Temperature & Humidity Sensor

http://chocoball.tistory.com/entry/Hardware-AM2322-Temperature-Humidity-Sensor


* Hardware | Arduino 비접촉 온도센서 GY-906 MLX90614

http://chocoball.tistory.com/entry/HardwareArduinoMLX90614


* Hardware | Arduino BMP280 고도/온도/기압 센서

- http://chocoball.tistory.com/entry/HardwareArduinoBMP280


* Hardware | BME280 sensor

- http://chocoball.tistory.com/entry/HardwareBME280



출처: http://chocoball.tistory.com/entry/Hardware-DS18B20-temperature-sensor [초코볼의 inside Tech]


* Hardware | AM2322 Temperature & Humidity Sensor

http://chocoball.tistory.com/entry/Hardware-AM2322-Temperature-Humidity-Sensor


* Hardware | Arduino 비접촉 온도센서 GY-906 MLX90614

http://chocoball.tistory.com/entry/HardwareArduinoMLX90614


* Hardware | Arduino BMP280 고도/온도/기압 센서

- http://chocoball.tistory.com/entry/HardwareArduinoBMP280


* Hardware | BME280 sensor

- http://chocoball.tistory.com/entry/HardwareBME280



출처: http://chocoball.tistory.com/entry/Hardware-DS18B20-temperature-sensor [초코볼의 inside Tech]

* Hardware | AM2322 Temperature & Humidity Sensor

http://chocoball.tistory.com/entry/Hardware-AM2322-Temperature-Humidity-Sensor


* Hardware | Arduino 비접촉 온도센서 GY-906 MLX90614

http://chocoball.tistory.com/entry/HardwareArduinoMLX90614


* Hardware | Arduino BMP280 고도/온도/기압 센서

- http://chocoball.tistory.com/entry/HardwareArduinoBMP280


* Hardware | BME280 sensor

- http://chocoball.tistory.com/entry/HardwareBME280



출처: http://chocoball.tistory.com/entry/Hardware-DS18B20-temperature-sensor [초코볼의 inside Tech]


* Hardware | AM2322 Temperature & Humidity Sensor

http://chocoball.tistory.com/entry/Hardware-AM2322-Temperature-Humidity-Sensor


* Hardware | Arduino 비접촉 온도센서 GY-906 MLX90614

http://chocoball.tistory.com/entry/HardwareArduinoMLX90614


* Hardware | Arduino BMP280 고도/온도/기압 센서

- http://chocoball.tistory.com/entry/HardwareArduinoBMP280


* Hardware | BME280 sensor

- http://chocoball.tistory.com/entry/HardwareBME280



출처: http://chocoball.tistory.com/entry/Hardware-DS18B20-temperature-sensor [초코볼의 inside Tech]

네 그렇습니다.

온도 센서에는 기존에 확인했던 위의 센서들 말고, 준비하고 있는게 아래 3가지가 있습니다.


- K-type

- PT100 / PT100

- Cu50


이 포스트에서는 K-Type 에 대해 알아보려 합니다.





2. K-type


이번에는 K-type 온도센서 이므로, 해당의 제품을 구매합니다.


* Thermocouple K-Type Thermocouple Thermometer Probe WRNT-03 200mm*1000mm

https://www.aliexpress.com/item/Thermocouple-K-Type-Thermocouple-Thermometer-Probe-WRNT-03-200mm-1000mm/32615649856.html



일반적으로 Thermocouple K-type 은 선이 두가닥인데, 도착한 놈은 세가닥 입니다.

거기에 더해서 "Cu50" 이라는 라벨도 붙어 있습니다...


분명 난, K-Type 을 보고 주문한건데 말입니다.

사양서도 확인해 보면 WRNT-03 이라서 Probe type 의 thermocouple 이라고 생각했습니다만, 도착한건 그냥 Cu50 인듯 합니다..



세가닥 단자들 사이는 55 Ohm / 0 Ohm 의 차이를 보입니다.

100 Ohm 정도면 PT100 인데, 55 Ohm 이면 좀 애매하네요.



확실히 잘 사용되지 않는 Cu50 이 맞는 듯 합니다.

이놈은 이놈 나름대로 사용될 수 있는 방법을 찾아봐야겠습니다.



음?

테스터기로 측정하고 있을 때 눈에 들어오는 테스터용 온도 probe !!!



위 사진의 오른쪽 다발로 보이는 것이 테스터용 온도 센서 입니다.



혹시나? 하고 메뉴얼을 찾아 보니 "K-type" 이라고 적혀 있네요!



우연히 K-Type 온도센서를 구할 수 있게 되었습니다.

역시 K-Type 은 단자가 2개인게 확실합니다.





3. MAX31855


보통 온도 센서들은 아날로그 값으로 표현하므로, digital 로 변환해주는 converter 가 필요합니다.

K-Type 온도센서용으로는 MAX31855 라고 하는군요.


Arduino 용 K-Type 모듈인 MAX31855 를 구입합니다.


* MAX31855 MAX6675 SPI Type K Thermocouple Temperature Sensor Board Module For Arduino

https://ko.aliexpress.com/item/MAX31855-K-Type-Thermocouple-Breakout-Board-Temperature-200C-to-1350-Celsius-for-Arduino/32746337946.html



아래는 도착 사진 입니다.



친절하게 알아서 사용하라는 중국 생산자의 배려 입니다.



기록을 위해 뒷면도 찰칵.






4. sketch


Arduino IDE 에서 Library Manger 를 열고 max 라는 키워드로 검색하면, MAX31855 가 나옵니다.

인스톨 하세요.



패키지 인스톨 후, "File > Examples > Adafruit MAX31855 library > serialthermocouple" 을 선택합니다.



Sketch 는 다음과 같아요.


/*************************************************** 
  This is an example for the Adafruit Thermocouple Sensor w/MAX31855K

  Designed specifically to work with the Adafruit Thermocouple Sensor
  ----> https://www.adafruit.com/products/269

  These displays use SPI to communicate, 3 pins are required to  
  interface
  Adafruit invests time and resources providing this open source code, 
  please support Adafruit and open-source hardware by purchasing 
  products from Adafruit!

  Written by Limor Fried/Ladyada for Adafruit Industries.  
  BSD license, all text above must be included in any redistribution
 ****************************************************/

#include "SPI.h"
#include "Adafruit_MAX31855.h"

// Default connection is using software SPI, but comment and uncomment one of
// the two examples below to switch between software SPI and hardware SPI:

// Example creating a thermocouple instance with software SPI on any three
// digital IO pins.
#define MAXDO   3
#define MAXCS   4
#define MAXCLK  5

// initialize the Thermocouple
Adafruit_MAX31855 thermocouple(MAXCLK, MAXCS, MAXDO);

// Example creating a thermocouple instance with hardware SPI
// on a given CS pin.
//#define MAXCS   10
//Adafruit_MAX31855 thermocouple(MAXCS);

void setup() {
  while (!Serial); // wait for Serial on Leonardo/Zero, etc
  
  Serial.begin(9600);
  
  Serial.println("MAX31855 test");
  // wait for MAX chip to stabilize
  delay(500);
}

void loop() {
  // basic readout test, just print the current temp
   Serial.print("Internal Temp = ");
   Serial.println(thermocouple.readInternal());

   double c = thermocouple.readCelsius();
   if (isnan(c)) {
     Serial.println("Something wrong with thermocouple!");
   } else {
     Serial.print("C = "); 
     Serial.println(c);
   }
   //Serial.print("F = ");
   //Serial.println(thermocouple.readFarenheit());
 
   delay(1000);
}



음? 정상적으로 동작하지 않는군요.

혹시 몰라 MAX31855 의 전 버전인 MAX6675 라이브러리를 설치하고 sketch 를 실행시켜 봅니다.



음... 안되는군요.

뭐가 문제일까요?





5. 중국 공장의 나쁜 버릇


폭풍 검색을 해도 문제를 해결한 케이스를 볼 수 없다가,

우연히 Youtube 의 댓글에서 힌트를 찾았습니다.


MAX6675 와 MAX31855 breakout 보드의 차이점은 1번과 2번 pin 이 연결되어 있느냐 없느냐의 차이라고 합니다.



제가 구입한 MAX31855 breakout 보드의 1번과 2번을 보니 붙어 있네요.



위는 MAX6675 의 breakout board 의 layout 입니다.

1번과 2번이 연결되어 있네요.



MAX31855 의 breakout board 의 1번 / 2번 pin 은 서로 붙어있지 않습니다.



Adafruit 의 정식 판매용 MAX31855 breakout board 도 1번 / 2번 pin 도 떨어져 있습니다.



위의 사진은 중국 AliExpress 제품의 소개 사진입니다.

Chip 은 MAX31855 지만, breakout board 는 전압 regulator 도 없는 MAX6675 용 breakout board 와 비슷합니다.


즉, 중국 업자들은 기존 MAX6675 breakout board 에,

스펙이 비슷한 MAX31855 chip 을 얹은게 아닌가 하는게 internet 친구들의 예상입니다.


MAX31855 는 minus 온도까지 측정할 수 있는 등 upgrade 되었으나,

MAX6675 breakout board 를 사용하면서 기능 확장도 안되고, pinout spec. 에 맞지 않게 된거죠.


쉽게 말하면,

upgrade 제품이니까 맞겠지 하고 MAX6675 breakout board 에 MAX31855 를 얹으면서 정상작동하지 않는 것이였습니다.

(이거 팔아도 되는거야? 구매한 다른사람들은 어떻게 사용한거지?)



결국 위의 사진처럼 1번/2번 pin 사이의 연결을 완전히 긁어 내어 단락시키니 정상 작동하였습니다.

아놔....





6. K-Type +/- 단자 사이에 capacitor


해결점을 찾아서 정상 작동까지는 왔으나,

값이 널을 뛰어 안정적으로 측정하지 못했습니다.



위에서 보듯이 많은 사람들이 단자에 capacitor 를 사용했더랬습니다.


* Hardware | AliExpress 에서 Ceramic Condenser 를 구입해 보자

http://chocoball.tistory.com/entry/Hardware-AliExpress-Ceramic-Condenser-buying


뭘 하려면 여러가지가 구비되어야 하는군요.

다행이 ceramic capacitor (condenser) 가 있었습니다.



사용된 것은 10nF = 0.01uF 입니다.



Capacitor 를 연결하고서야 안정적으로 값을 확인할 수 있었습니다.





7. Pinout / Layout


Pinout 은 다음과 같습니다.


 MAX31855  | Arduino Micro
---------------------------
    Vin    |      5V
    GND    |      GND
    DO     |      D3
    CS     |      D4
    CLK    |      D5
---------------------------



구성도는 다음과 같습니다.



실제 사진입니다.






8. 결과


이제서야 제대로 측정이 되었습니다.

chip 자체적으로 Internal Temp 를 측정 가능한게 신시합니다.



여름 저녁이라 거실 실내 온도가 31도군요.

올해는 더워도 너무 덥습니다. 1994년도 5월에 입대하고 기초훈련 받던 때가 생각나네요.

그때도 이만큼 더웠던것 같습니다. 유격훈련 한번 하고 나면 동기들이 탈진해서 쓰러지곤 했더랬습니다.


우리 기수, 다른 중대 훈련병 중에 행군중 탈진으로 죽은 전우가 있어,

저의 다음 기수부터는 행군을 생략했다는 이야기를 들었습니다.

저의 행군 중에도, 옆에서 쓰러진 동기는 흰자위를 보이며 땅바닥에서 경련을 일으킬 정도로 극한의 날씨였습니다.



위는 K-type thermocouple 에 라이터 불로 온도를 높혔을 때를 동영상으로 찍어 봤습니다.



EXCEL 의 그래프 작업으로 internal / sensor 의 온도변화를 그래프로 표현해 봤습니다.

흠흠, 잘 변화를 감지했군요.





FIN


제대로 함정을 밟았지만, 잘 헤쳐나온것 같습니다.

Breakout board 는 되도록 reference (Adafruit / Sparkfun) 과 잘 비교해 본 다음, 문제가 없어보이면 구입하는게 좋을것 같습니다.


And
prev | 1 | next