Teploměr

Ceiro
Příspěvky: 17
Registrován: 16 úno 2019, 08:30
Reputation: 0

Re: Teploměr

Příspěvek od Ceiro » 17 lis 2021, 13:49

I když teploměr odpojím anebo zapojím obráceně tak je to to samé

AstroMiK
Příspěvky: 592
Registrován: 08 pro 2017, 19:05
Reputation: 0

Re: Teploměr

Příspěvek od AstroMiK » 17 lis 2021, 13:53

... Tak dál už nevím.

Ceiro
Příspěvky: 17
Registrován: 16 úno 2019, 08:30
Reputation: 0

Re: Teploměr

Příspěvek od Ceiro » 20 lis 2021, 15:04

Tak menši pokrok, proměřil jsem voltmetrem a davalo to šťávu tal jsem to znovu napojil na UNO, nanovo zadal kód a fungovalo to. Když zadám kód s: Serial.print tak na seriovem monitoru se teploty zobrazí, když zadám kód s: M5.Lcd.print tak na displeji se zobrazuje nula
Nevěděl by prosím někdo něco poradit?
Screenshot_20211120-145904_Gallery.jpg
Screenshot_20211120-145910_Gallery.jpg

jankop
Příspěvky: 1029
Registrován: 06 zář 2017, 20:04
Reputation: 0
Bydliště: Brno
Kontaktovat uživatele:

Re: Teploměr

Příspěvek od jankop » 20 lis 2021, 15:14

Promiň, ale běž se vycpat s těma svýma fotkama obrazovky. Existuje několik způsobů, jak normálně prezentovat kód. Pokud nezvládneš ani Copy+ Paste, tak se raději do programování čehokoliv ani nepouštěj.

Ceiro
Příspěvky: 17
Registrován: 16 úno 2019, 08:30
Reputation: 0

Re: Teploměr

Příspěvek od Ceiro » 20 lis 2021, 15:30

omlouvám se, psal jsem přes mobil proto jsem to fotil

Ceiro
Příspěvky: 17
Registrován: 16 úno 2019, 08:30
Reputation: 0

Re: Teploměr

Příspěvek od Ceiro » 20 lis 2021, 15:31

Kód: Vybrat vše

// this example is public domain. enjoy!
// https://learn.adafruit.com/thermocouple/

#include "max6675.h"

int thermoDO = 19;
int thermoCS = 23;
int thermoCLK = 18;

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);
}

Ceiro
Příspěvky: 17
Registrován: 16 úno 2019, 08:30
Reputation: 0

Re: Teploměr

Příspěvek od Ceiro » 20 lis 2021, 15:32

Kód: Vybrat vše

#include <M5Stack.h>

// this example is public domain. enjoy!
// https://learn.adafruit.com/thermocouple/

#include "max6675.h"

int thermoDO = 19;
int thermoCS = 23;
int thermoCLK = 18;

MAX6675 thermocouple(thermoCLK, thermoCS, thermoDO);

void setup() {
  M5.begin(9600);

  M5.Lcd.println("MAX6675 test");
  // wait for MAX chip to stabilize
  delay(500);
}

void loop() {
  // basic readout test, just print the current temp
  
   M5.Lcd.print("C = "); 
   M5.Lcd.println(thermocouple.readCelsius());
   M5.Lcd.print("F = ");
   M5.Lcd.println(thermocouple.readFahrenheit());
 
   // For the MAX6675 to update, you must delay AT LEAST 250ms between reads!
   delay(1000);
}

jankop
Příspěvky: 1029
Registrován: 06 zář 2017, 20:04
Reputation: 0
Bydliště: Brno
Kontaktovat uživatele:

Re: Teploměr

Příspěvek od jankop » 20 lis 2021, 16:53

Zkus tohle

Kód: Vybrat vše

// this example is public domain. enjoy!
// https://learn.adafruit.com/thermocouple/
#include <M5Stack.h>
#include "max6675.h"

int thermoDO = 19;
int thermoCS = 23;
int thermoCLK = 18;

MAX6675 thermocouple(thermoCLK, thermoCS, thermoDO);

void setup() {
  M5.begin(9600);
  M5.Lcd.println("MAX6675 test");
}

void loop() {
  // basic readout test, just print the current temp
  delay(1000);
  M5.Lcd.print("C = ");
  M5.Lcd.println(thermocouple.readCelsius());
  delay(1000);
  M5.Lcd.print("F = ");
  M5.Lcd.println(thermocouple.readFahrenheit());
}

Ceiro
Příspěvky: 17
Registrován: 16 úno 2019, 08:30
Reputation: 0

Re: Teploměr

Příspěvek od Ceiro » 20 lis 2021, 17:16

stejný výsledek, na sériovém monitoru aktuální teplotu, na displeji nulu

Odpovědět

Kdo je online

Uživatelé prohlížející si toto fórum: Žádní registrovaní uživatelé a 10 hostů