using arduino yun with AD595 to measure temperature


i powering ad595 5v on board , getting negative reading serial. print following code reference problem or have got gnd messed ? have realised problem simple math error , have learned not take other peoples code red , bit of thinking myself (my bad!) trying replace multimeter mobile phone , read high temperatures typically 300-700 'c can characterize "home brew" tandoor looking @ app builder program "blynk" thought's ? need learn how adjust decimal point , how use serial. print etc..,etc. project earn helper  serious tandoori chicken !!

code: [select]
[code]

const int temppin1 = 3;
void setup() {

serial.begin (9600);
// put setup code here, run once:

}

void loop() {
  float temperature =((getvoltage(temppin1) - 0.5) * 100l);
    
  serial.print (temperature);
  
  serial.print (" temp ('c) :");
  

  delay (300);
}

float getvoltage (int pin)

{
 return (analogread (pin) * 0.004882814);
}

[/code]


any gratefully received



Arduino Forum > Using Arduino > Sensors > using arduino yun with AD595 to measure temperature


arduino

Comments