From 3abb631f5349c4d7596eb924beddbacb5f578093 Mon Sep 17 00:00:00 2001 From: Alan Johnston Date: Tue, 11 Feb 2025 09:27:48 -0500 Subject: [PATCH] Update transmit.py print elapsed time for camera image --- transmit.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/transmit.py b/transmit.py index 720f87f6..26f85ad4 100644 --- a/transmit.py +++ b/transmit.py @@ -3,7 +3,7 @@ import RPi.GPIO as GPIO from RPi.GPIO import output #import subprocess -#import time +import time from time import sleep #import os import sys @@ -825,6 +825,7 @@ if __name__ == "__main__": # image_present = False # if (image_present == False): + start = time.perf_counter() camera_photo() ## system("raspistill -o /home/pi/CubeSatSim/camera_out.jpg -w 320 -h 256") # > /dev/null 2>&1") ## print("Photo taken") @@ -832,6 +833,8 @@ if __name__ == "__main__": print("image_id: " + str(image_id) + "\n") image_id = ( image_id + 1 ) % 256 print("new image_id: " + str(image_id) + "\n") + print("Elapsed time: ") + print(time.perf_counter() - start) sleep(0.5) # else: sleep(0.6)