Hello, I'm controlling 12V LED strip using a tmp36 temperature sensor. The idea is: when it gets too hot -> turn the LEDs off or vice versa.
I've found a very helpful youtube video, based on which I setup the whole thing like this:
Only in my case instead of the little lamp I've got an LED strip and instead of a motion sensor I've got a temperature sensor.
Now everything is fine when I run it without the 12V power source - tmp36 is pretty stable and accurate, but as soon as I plug that 12V power source, the temperature sensor becomes unstable. Among a couple correct ones it starts reporting random incorrect values, even negative ones. I alleviated the issue a little bit by using 2 different grounds on my Arduino uno - one for the temp sensor and one for everything else. It helped, but it's still not perfect.
Does anyone know what is happening here and how do I fix it?