MAX31865 Problems

General project help for Adafruit customers

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
User avatar
gzmarisa
 
Posts: 11
Joined: Sat Jan 20, 2018 10:25 am

MAX31865 Problems

Post by gzmarisa »

I have a MAX31865 amplifier and I am trying to get temperature readings using a 3 wire pt100 temperature sensor. This is hooked up to an Arduino Uno. I am using the example code provided

Code: Select all

/*************************************************** 
  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 <Adafruit_MAX31865.h>

// 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!
#define RREF 430.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(100, 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);
}
I also attached a picture of the set up.

I am unable to get any readings from the amplifier, with an RTD value of zero. This does not change whether the PT 100 is plugged in or not, and I am not getting any error messages, simply no reading.

I have double check all soldering points for good connections, replaced all wires, used different breadboards, tested resistance on 24 3 trace cut to verify that cut is good, used several different amplifiers, verified that the PT100 was reading the correct resistance for room temp, and tried both 5v and 3.3v.

I had proper readings before but struggled when adding more amplifiers and temperature sensors to the circuit, but now nothing works.

Any help would be greatly appreciated, been trying to troubleshoot this for 2+ weeks with little success.
Attachments
IMG_4475 2.JPG
IMG_4475 2.JPG (175.94 KiB) Viewed 4146 times

User avatar
gzmarisa
 
Posts: 11
Joined: Sat Jan 20, 2018 10:25 am

Re: MAX31865 Problems

Post by gzmarisa »

Also here is my results:
RTD value: 0
Ratio = 0.00000000
Resistance = 0.00000000
Temperature = -242.02

User avatar
adafruit_support_mike
 
Posts: 67454
Joined: Thu Feb 11, 2010 2:51 pm

Re: MAX31865 Problems

Post by adafruit_support_mike »

A couple of solder joints look pinched-in at the bottom, which often means the solder isn't making good contact with the PCB pad.

Take a look at our soldering tutorial, give each joint a dab of flux, and reheat them. You want a smooth cone that covers the whole pad and sweeps up to the pin.

https://learn.adafruit.com/adafruit-gui ... -soldering

User avatar
gzmarisa
 
Posts: 11
Joined: Sat Jan 20, 2018 10:25 am

Re: MAX31865 Problems

Post by gzmarisa »

I redid my solder joints and got the same result. I even brought out one of the spares my lab, redid the entire amplifier and it has and I get the same results as below. Any other troubleshooting ideas? I occasionally get a COMP 3 busy error on my Arduino is the only other thing going on that I can note.

Results:
RTD value: 0
Ratio = 0.00000000
Resistance = 0.00000000
Temperature = -242.02

Thanks!
Attachments
newsetup.jpg
newsetup.jpg (140.44 KiB) Viewed 4110 times

User avatar
adafruit_support_mike
 
Posts: 67454
Joined: Thu Feb 11, 2010 2:51 pm

Re: MAX31865 Problems

Post by adafruit_support_mike »

Hmm.. as a sanity check, measure the resistance between the screw heads on the RTD+ and RTD- terminal blocks. Let's make sure the resistance is really 100 ohms at that point.

User avatar
gzmarisa
 
Posts: 11
Joined: Sat Jan 20, 2018 10:25 am

Re: MAX31865 Problems

Post by gzmarisa »

I measured the resistance and got 109 ohms.

User avatar
gzmarisa
 
Posts: 11
Joined: Sat Jan 20, 2018 10:25 am

Re: MAX31865 Problems

Post by gzmarisa »

I figured out the solution. The jumper wires I used were cheap so didn't matter if I switched them. Once I switched to the Adafruit spool wire I got a reading of 24 degrees. Moral of the story is... BUY GOOD WIRE.

User avatar
adafruit_support_mike
 
Posts: 67454
Joined: Thu Feb 11, 2010 2:51 pm

Re: MAX31865 Problems

Post by adafruit_support_mike »

Glad to hear you got it working.

Jumpers can be silent trouble-makers. That's one of the places where an oscilloscope or logic analyzer comes in handy.. being able to see what the signals are doing at each end of a wire makes it as lot easier to locate problems.

User avatar
Phateeh
 
Posts: 5
Joined: Mon Jul 08, 2019 6:56 am

Re: MAX31865 Problems

Post by Phateeh »

I am at the same situation. I am using pt100 RTDs with arduino and getting nothing (sometimes random numbers). I tried nearly everything. I put some resistances replacing pt100s but didn't work. Are you sure it's because jumper wires? How can a jumper wire cause an error like this?

RTD value: 0
Ratio = 0.00000000
Resistance = 0.00000000
Temperature = -242.02

User avatar
adafruit_support_mike
 
Posts: 67454
Joined: Thu Feb 11, 2010 2:51 pm

Re: MAX31865 Problems

Post by adafruit_support_mike »

Among other things, jumpers can break inside the insulation, so what looks like a normal connection is really an open circuit.

User avatar
rohimo
 
Posts: 2
Joined: Wed Jul 17, 2019 10:09 am

Re: MAX31865 Problems

Post by rohimo »

gzmarisa wrote:I figured out the solution. The jumper wires I used were cheap so didn't matter if I switched them. Once I switched to the Adafruit spool wire I got a reading of 24 degrees. Moral of the story is... BUY GOOD WIRE.
can please send link of the wire you used?
Still not fully convinced how can jumper wire cause "Zero reading", some error could have been sensible...

User avatar
rohimo
 
Posts: 2
Joined: Wed Jul 17, 2019 10:09 am

Re: MAX31865 Problems

Post by rohimo »

I got over 20 pcs of MAX31865 boards lying in my drawer, so far only 3 worked and all other showing reading as follows:
RTD value: 0
Ratio = 0.00000000
Resistance = 0.00000000
Temperature = -242.02

I tried all technically possible Solutions to the boards, even used best quality jumper wires.....
but nothing worked.... and finally found the root of the issue in SPI communication.....

3 nos. of MAX31865 boards which are working are responding in SPI but others not working.
We can clearly see SDO line on logic analyzer screenshot ... so issue is really a internal bug of MAX31865 board and i am switching to other solutions....
Attachments
Logic Analyzer screenshot of faulty 17 nos. of  MAX31865  boards
Logic Analyzer screenshot of faulty 17 nos. of MAX31865 boards
LA fault with uno.jpg (65.29 KiB) Viewed 3191 times
Logic Analyzer screenshot of 3 nos. of working MAX31865  boards
Logic Analyzer screenshot of 3 nos. of working MAX31865 boards
LA ok reading.jpg (62.67 KiB) Viewed 3191 times

User avatar
clertem
 
Posts: 11
Joined: Sat Feb 11, 2017 4:47 am

Re: MAX31865 Problems

Post by clertem »

So what @Adafruit suggest as a solution ? They sell dodgy boards and we should all be content ?

User avatar
zener
 
Posts: 4567
Joined: Sat Feb 21, 2009 2:38 am

Re: MAX31865 Problems

Post by zener »

I have seen no evidence of a trend of dodgy boards. What gives you that idea? Do you have a problem with a product? If so what problem do you have?

User avatar
clertem
 
Posts: 11
Joined: Sat Feb 11, 2017 4:47 am

Re: MAX31865 Problems

Post by clertem »

...the previous post...

Locked
Please be positive and constructive with your questions and comments.

Return to “General Project help”