Skip to Content
ExamplesThermocouple Demo

Thermocouple Demo

Code

MAX6675 thermocouple(THERMO_SCK_PIN, THERMO_CS_PIN, THERMO_SO_PIN); float tempC = thermocouple.readCelsius(); int64_t tempX100 = (int64_t)(tempC * 100.0f); Instruction ix; ix.setProgram(programId); ix.addKey(authorityPub, true, true); ix.addKey(dataAccountPda, false, true); ix.writeBytes(RECORD_DATA_DISCRIMINATOR, 8); ix.writeI64LE(tempX100);
Last updated on