pokud to připojím k UNO ,bezproblémů funguje a v serial monitor zobrazí teploty (i s napájením na 3,3V ) pokud tentosamý zkušební program použiji pro různé desky Nodemcu (ESP8266) tak v lepším případě místo teploty "non" případně 0 C (viz.obr),ale většinou to na sériovém monitoru jen nesmyslné znaky (po nahrání jiných programů do nodemcu funguje normálně) .Jinak kompilace do Nodemcu proběhne vpořádku.
Už se s tím trápím měsíc...Tak mooc děkuji,za jakoukoliv radu.
Kód: Vybrat vše
// this example is public domain. enjoy! https://learn.adafruit.com/thermocouple/
#include "max6675.h"
int thermoDO = 4;
int thermoCS = 3;
int thermoCLK = 2;
MAX6675 thermocouple(thermoCLK, thermoCS, thermoDO);
void setup() {
Serial.begin(9600);
Serial.println("MAX6675 test");
// wait for MAX chip to stabilize
delay(500);
}
void loop() {
// basic readout test, just print the current temp
Serial.print("C = ");
Serial.println(thermocouple.readCelsius());
Serial.print("F = ");
Serial.println(thermocouple.readFahrenheit());
// For the MAX6675 to update, you must delay AT LEAST 250ms between reads!
delay(1000);
}