Multiple Sensor Issues

I have a Nano running multiple analog sensors, all on the 5v pin. Two are thermistors, both of which are working as expected. I added a pressure sensor, and when I was testing it on a separate Nano, it worked and the results were inline with what I expected. I correlated the raw values to PSI and then copied the code to the other Nano with the other sensors and now the pressure sensor is all over the place and the values are substantially higher than they should be. The thermosisters have 10k resistors across the + pin, could that be affecting the reading of the pressure sensor?

Code attached if anyone wants to see if there’s an issue there. I’m a hack, so I won’t be offended if anyone has some offers on how to clean things up lol:

#include <VL53L0X.h>
#include <Wire.h>
#include <math.h>

// Define each bit of a byte to control one relay.
#define B_PUMP 0
#define B_LIGHT 1
#define B_BLOWER 2
#define B_INTAKE 3
#define B_RETURN 4
#define B_CLEANER 5
#define B_HEATER 6
#define B_UNUSED7 7

// Define pins for each relay.
#define P_PUMP 11
#define P_LIGHT 10
#define P_BLOWER 9
#define P_INTAKE 8
#define P_RETURN 7
#define P_CLEANER 6
#define P_HEATER 5
#define P_UNUSED7 4

// Define water and air temperature pins
#define P_H2O PIN_A0
#define P_AIR PIN_A1
#define P_PSI PIN_A3
#define P_VL1 12
#define P_VL2 13

VL53L0X sensor;
#define LONG_RANGE
/* Uncomment ONE of these two lines to get
 - higher speed at the cost of lower accuracy OR
 - higher accuracy at the cost of lower speed
//#define HIGH_SPEED

int rawValue; // A/D readings
float pressure; // final pressure

void setup() {
  // Set mode of pins used to toggle relays.
  pinMode(P_PUMP, OUTPUT);
  pinMode(P_LIGHT, OUTPUT);
  pinMode(P_BLOWER, OUTPUT);
  pinMode(P_INTAKE, OUTPUT);
  pinMode(P_RETURN, OUTPUT);
  pinMode(P_HEATER, OUTPUT);
  pinMode(P_UNUSED7, OUTPUT);

  // Set mode of pins used to read temperatures.
  pinMode(P_H2O, INPUT);
  pinMode(P_AIR, INPUT);
  pinMode(P_PSI, INPUT);
  pinMode(P_VL1, INPUT);
  pinMode(P_VL2, INPUT);

  // Default state is all devices off.
  digitalWrite(P_PUMP, HIGH);
  digitalWrite(P_LIGHT, HIGH);
  digitalWrite(P_BLOWER, HIGH);
  digitalWrite(P_INTAKE, HIGH);
  digitalWrite(P_RETURN, HIGH);
  digitalWrite(P_CLEANER, HIGH);
  digitalWrite(P_HEATER, HIGH);
  digitalWrite(P_UNUSED7, HIGH);
 // Start serial connection.


  #if defined LONG_RANGE
  // lower the return signal rate limit (default is 0.25 MCPS)
  // increase laser pulse periods (defaults are 14 and 10 PCLKs)
  sensor.setVcselPulsePeriod(VL53L0X::VcselPeriodPreRange, 18);
  sensor.setVcselPulsePeriod(VL53L0X::VcselPeriodFinalRange, 14);

#if defined HIGH_SPEED
  // reduce timing budget to 20 ms (default is about 33 ms)
#elif defined HIGH_ACCURACY
  // increase timing budget to 200 ms


#define NUMSAMPLES 10
#define SERIESRESISTOR 10000
#define BCOEFFICIENT 3950

int8_t getTemp(int p) {
	uint8_t i;
	float average;
	uint16_t samples[NUMSAMPLES];
	// take N samples in a row, with a slight delay
	for (i=0; i< NUMSAMPLES; i++) {
		samples[i] = analogRead(p);
	// average all the samples out
	average = 0;
	for (i=0; i< NUMSAMPLES; i++) {
		average += samples[i];
	average /= NUMSAMPLES;
	// convert the value to resistance
	average = 1023 / average - 1;
	average = SERIESRESISTOR / average;
	float steinhart;
	steinhart = average / THERMISTORNOMINAL;     // (R/Ro)
	steinhart = log(steinhart);                  // ln(R/Ro)
	steinhart /= BCOEFFICIENT;                   // 1/B * ln(R/Ro)
	steinhart += 1.0 / (TEMPERATURENOMINAL + 273.15); // + (1/To)
	steinhart = 1.0 / steinhart;                 // Invert
	steinhart -= 273.15;                         // convert to C	
	steinhart = steinhart*1.8 + 32.0;            // convert to F
	return (int8_t)steinhart;                   // truncate to integer value


void loop() {
   // Read water temp and air temp in turn and write status
	// of each to serial port.
	int8_t val;

	val = getTemp(P_H2O);

	val = getTemp(P_AIR);


  if (sensor.timeoutOccurred()) { Serial.print(" TIMEOUT"); }


/////////// PSI Sensor//////////
  rawValue = analogRead(A3);
  pressure = (rawValue / 7.9) - 11.942; //sort of calculated using scatter plot on Excel, but more manual
  Serial.print("PSI:");Serial.println(pressure, 0); // zero decimal places

void serialEvent()
       char ch =;
       // The input is expected to set the bit to turn on the relay,
       // but the relays are active LOW, so invert and then handle.
       ch = ~ch;
       digitalWrite(P_PUMP, bitRead(ch, B_PUMP));
       digitalWrite(P_LIGHT, bitRead(ch, B_LIGHT));
       digitalWrite(P_BLOWER, bitRead(ch, B_BLOWER));
       digitalWrite(P_INTAKE, bitRead(ch, B_INTAKE));
       digitalWrite(P_RETURN, bitRead(ch, B_RETURN));
       digitalWrite(P_CLEANER, bitRead(ch, B_CLEANER));
       digitalWrite(P_HEATER, bitRead(ch, B_HEATER));
       digitalWrite(P_UNUSED7, bitRead(ch, B_UNUSED7));

As you failed to provide a wiring diagram I simply expect the worst case that you did just wire the pressure sensor to the Nano and that one is running on USB power. Measure the voltage between the GND and the 5V pin on both Nanos. I guess that you get a slight difference. Most probably that difference can explain the higher values you get on the second Nano but that's a guess too as you also failed to tell use how much the values are to high.

Is that pressure sensor output absolute or ratiometric?

Typically if all sensors are ratiometric you'll be fine, but its important to keep any high currents on separate
wires back to the Arduino. A few 10k thermistors shouldn't be an issue for this though.

With a ratiometric sensor the same ADC counts will be returned if the 5V droops, because the ADC uses
it as a reference and is really just measuring a voltage ratio. For instance this means you could use 3 AA
batteries as a power source (4.5V) without any change in readings.

I'd check your wiring is solid, measure the resistance across the wiring (when powered down)
using a multimeter.