I'm testing a data pipeline and need to simulate sensor readings (CPU %, temperature) without real hardware. My first attempt used random.uniform(). But it looks like noise.
cpu = random.uniform(0, 100)
It jumps all over the range every reading. It goes from 8%, then 94%, then 3%.
But real sensors drift slowly and stay near a baseline. When I chart this, it's just static, and it's useless for testing anomaly detection because there's no normal pattern to deviate from.
Is there a way to generate values that drift smoothly and stay in a believable range, while still having some natural variation?
Also, if i start to simulate multiple devices, how do I stop them all moving in lockstep?