After a check run down the road, noticed the original temp guage reading a bit high.
A check with the multi and a temp probe showed that the temp was fine, just a bit out on the guage.
This has a bi-metal type regulator for the guage voltages which I replaced many moons ago but made the stuff up of positioning it in a rather hard to access place.
Well, set and forget, so should be no problem but during the above refit, must have bumped the settings.
To save all the ripping out again, decided on a 128 x 32 Oled and DS18B20 temp sensor in the dash where the air-con button used to live. RAC never ever worked properly and was abandoned yonks ago.
Anyhow, couple of pics of the yet to be completed and fitted guage, code etc.
Code: Select all
/*128x32 Oled temp guage Celica 1_November 2020
*/
#include <Arduino.h>
#include <U8g2lib.h>
#include <Wire.h>
#define ONE_WIRE_BUS 2 // Data wire is plugged into pin 2 on the Arduino
#include <DallasTemperature.h>
OneWire oneWire(ONE_WIRE_BUS); // Setup a oneWire instance to communicate with any OneWire devices
DallasTemperature sensors (&oneWire); // Pass our oneWire reference to Dallas Temperature.
U8G2_SSD1306_128X32_UNIVISION_F_HW_I2C u8g2(U8G2_R0);
void setup() {
u8g2.begin();
sensors.begin();
}
void loop() {
sensors.requestTemperatures();
u8g2.clearBuffer(); // clear the internal memory
u8g2.setFont(u8g2_font_logisoso32_tf); // choose a suitable font
u8g2.setCursor (0, 32);
//comment out whichever of the following for degrees Celcuis or Fahrenheit
//u8g2.print (sensors.getTempCByIndex(0),1); //
u8g2.print(sensors.getTempFByIndex(0),1);
u8g2.setCursor(100, 38);
u8g2.print((char)176); //degrees symbol
u8g2.setCursor(110, 32);
u8g2.print("F");
u8g2.sendBuffer(); // transfer internal memory to the display
delay(200);
}