I am using a Pi 3 Model B and a Sensehat. I am using the following command:

sudo watch -n 0.1 python sensors.py

My program runs fine and the command works, However I have one issue.

Even though I use -n 0.1 the program does not "refresh" every 1/10 of a second. It seems to only refresh at an interval of 1 second and cannot refresh any faster regardless of what I type.

Is this because the Sensehat sensors refresh at an interval of 1 second or is there any way to force the watch command to refresh more frequently?

1 Answer 1


Try the command watch -n 0.1 date +%N to see that watch can update 10 times per second.

It only updates the current time once a second.

Are you sure your script runs that fast?

What does time python sensors.py report for one run?

  • This is what I get: real 0m0.978s user 0m0.780s sys 0m0.090s
    – Marco
    May 27, 2017 at 2:06
  • 1
    @Marco So your script takes just under a second to run. You can't get updates faster unless you speed your script up.
    – joan
    May 27, 2017 at 3:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.