Nano with thermocouple, AD8495 and HC-06

Dear all

I am creating a equipement to measure the surface temp from a pavement, and air temp at the same time (in that moment I am using only 1 sensor for tests).

Equipement

  • arduino nano
  • 2x thermocouple amplifier AD8495
  • 1x Bluetooth module HC-06
  • 1x USB Voltage Converter Step Up Booster
  • 1x powerbank

A - The powerbank seems turns off after a few secounds and after google it, seems normal. I will apply the Booster directly to the batteryes and get from there power

B - The Bluetooth module woks fine with my phone

C - The problem seems to be the AD8495, I power it with 5V from arduino. And I power arduino throuth USB (~4.8V - 5V).
After calibrating thermocouple, powering it by laptop I get consistent readings. When changing power by phone or by powerbank the temperature reading change, for example 4.8v power gives about 40C degrees and 5V about 25C degrees.

How can I resolve it? I buy the AD8495 in aliexpress and seems it changes output reading with change od power it.
I need a thin sensor as thermocouple if not I could use a digital one.

#include <SoftwareSerial.h>

/*
   ReadAnalogVoltage
   Reads an analog input on pin 0 to 3, converts it to voltage, 
   and prints the result to the serial monitor.cpalha 04dez2017 and BT 28ago23
   */

// the setup routine runs once when you press reset:

SoftwareSerial B(10,11);    //10-RX,  11-TX


void setup() {
   // initialize serial communication at 9600 bits per second:
   Serial.begin(9600);
   B.begin(9600);
}

// the loop routine runs over and over again forever:

void loop() {
   // read the input on analog pin 0:
   int sensorValue0 = analogRead(A0);
    int sensorValue1 = analogRead(A1);
     int sensorValue2 = analogRead(A2);
      int sensorValue3 = analogRead(A3);
   
   
   
   // Convert the analog reading (which goes from 0 - 1023) to a voltage (0 - 5V):
   float voltage0 = sensorValue0 * (5.0 / 1023.0) * 192.53 - 256.78;// * 199.19 - 265.23;//calib out20, nova em 14mar23
  float voltage1 = sensorValue1 * (5.0 / 1023.0);
 float voltage2 = sensorValue2 * (5.0 / 1023.0);
float voltage3 = sensorValue3 * (5.0 / 1023.0); 
   
   
   
   // print out the value you read:

 Serial.println(voltage0, 2);
  B.print(voltage0, 2);
  B.print(" - ");
 B.println(voltage1, 2);
 //Serial.print(" ");
  //Serial.print(voltage1, 4);
  // Serial.print(" ");
  // Serial.print(voltage2, 4);
  //  Serial.print(" ");
   //erial.println(voltage3, 4);
   
   delay(1000);
}

Any suggestions?

Best regards
Carlos

When you are converting your sensor values to a voltage, you are assuming that the reference voltage is exactly 5.0V.

Don't blame the AD8495, it is due to the power supply voltage, and hence the reference voltage changing depending on how you power it.

You can get around this by using a different , stable analogReference().

1 Like

Hi John

Can you please explain it better about using analogReference()?
The arduino can regulate input voltage? Where I should input it? And if the voltage drops a litle for a 4.8 V arduino boost it for 5V?

EDIT: After reading a litle bit more, I could see that I can supply the TC amplifier with 3.3V, and use the ARef with 3.3V. My question is, I make a bridge between 3.3v power from arduino to Aref pin? And power the TC amplifier from 3.3V pin too?

Best
CPalha

An DS18B20 would be easier in that temp range.
Thermocouples are more for extreme temps.

I would power the thermocouple module (assuming you have an Adafruit module) from 5volt.
and change Aref of the (assuming classic ATmega328) Nano to 3.3volt.
Put this line in setup() , and upload, before you connect the Aref pin to the 3.3volt pin.
analogReference(EXTERNAL);
Forgetting to do that could fry the A/D converter.

A powerbank can be kept "alive" by switching on a 80-100mA load periodically for a few ms.
Leo..

The highest temperature ever recorded on Earth was 136 Fahrenheit (58 Celsius) in the Libyan desert. The coldest temperature ever measured was -126 Fahrenheit (-88 Celsius) at Vostok Station in Antarctica.

They produce a high level (5 mV/°C) output ...
https://www.analog.com/media/en/technical-documentation/data-sheets/ad8494_8495_8496_8497.pdf
So how will they deal with a temperature below 0C?

I'm not happy with your conversion. How will that line be evaluated? What are the magic numbers?
It would make a lot of sense to do the inital conversion to a voltage in mV, than apply a correction if needed.
It would also make a lot of sense to use a voltage reference for the ADC.
as explained here

Dear all

Thanks for the help.
You can see that arduino programming is not my sea....I change existing programms to my projects.

Thermocouple, because I work a lot with it, I can produce the sensors and I have very thin cables. Digital ones has a big metalic point and I think with this point touching the pavemente could not be so sensitive as the small point of the thermocouple.
But if you tell me DS18B20 will get the temps with better way (whould have more accurancy, but sensitiviy....) I would change for that. I make tests on roads and during a test, about 3 h I would like place on ground an arduino with a power bank a 2 temp sensors measuring and send data to my phone, instead doing it each 10 0r 15 min.

Best
cpalha

The breakout module looks like a good option.

It has an SPI interface so you dont need to do all that complicated conversion.

Thanks

In the google I foun an image how to connect it

But for 2 sensors will I have enought Digital inputs?

What is the difference between MAX31855 and MAX31856?

Best
CPalha

just connect them like this.

Thanks

In that time I am very confused, MAX31856 seems complicated many wires, DS18B20 seems easyer but less sensitive...
I will try still use the AD8495 but with Aref3.3V (I need to study how to do) and see if the power to arduino with changes (4.7 to 5V) the 3.3V still stable

Best
CPalha

? A DS18B20 to has a 10 to 50 times better resolution than a thermocouple.
Calibrated to 0.5C, with a 1/16th degree C readout. A thermocouple could be 5 degrees C off.

So you're using the bare chip, not a module. Aref voltage sets the temp range.
Schematic here.
Leo..

How will you cope with temperatures below 0C?

Hi Friends

Thanks for tips and help.

Here is my idea...

image

At beginning I am thinking on it, but it does no save data in phone
https://pt.aliexpress.com/item/33003419547.html

After that why not to do with an arduino?

Best
cpalha

Hi Friends

After using ARef (EXTERNAL) and connect the power to 3.3V and use 3.3V in code the readings are much better (+-1 ºC) with voltages between 4.7 to 5V in the usb power.

Best
cpalha

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.