I'm trying to control some LED's (pins 2,3,4) with a temperature sensor. In the setup I do a calibration step to set the baseline temperature. When that's done, the LED at pin 5 is turned on.
Before I added the LED at pin 5, I already had some issues with the values I get from the sensor and this was fixed by the second answer of this post. I didn't have the capacitor and resistor with the same values as suggested, but it worked out fine.
After adding the LED at pin 5, I noticed that when the LED turned on, my sensor value jumped up a little.
Why does this happen and how can I fix this?
EDIT
Thanks for the answers, I tried a few of them, but they didn't work. I'm not sure if I did them correctly. I found this post and realized that the arduino board has multiple grounds. I got rid of the capacitor and the 10k resistor since they seem to do no effect. There's just a little jump after I turn on the LED at pin 5, but it's less.