Update transmit.py print elapsed time for camera image

fc-8
Alan Johnston 10 months ago committed by GitHub
parent 27c3fc7fa1
commit 3abb631f53
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -3,7 +3,7 @@
import RPi.GPIO as GPIO import RPi.GPIO as GPIO
from RPi.GPIO import output from RPi.GPIO import output
#import subprocess #import subprocess
#import time import time
from time import sleep from time import sleep
#import os #import os
import sys import sys
@ -825,6 +825,7 @@ if __name__ == "__main__":
# image_present = False # image_present = False
# if (image_present == False): # if (image_present == False):
start = time.perf_counter()
camera_photo() camera_photo()
## system("raspistill -o /home/pi/CubeSatSim/camera_out.jpg -w 320 -h 256") # > /dev/null 2>&1") ## system("raspistill -o /home/pi/CubeSatSim/camera_out.jpg -w 320 -h 256") # > /dev/null 2>&1")
## print("Photo taken") ## print("Photo taken")
@ -832,6 +833,8 @@ if __name__ == "__main__":
print("image_id: " + str(image_id) + "\n") print("image_id: " + str(image_id) + "\n")
image_id = ( image_id + 1 ) % 256 image_id = ( image_id + 1 ) % 256
print("new image_id: " + str(image_id) + "\n") print("new image_id: " + str(image_id) + "\n")
print("Elapsed time: ")
print(time.perf_counter() - start)
sleep(0.5) sleep(0.5)
# else: # else:
sleep(0.6) sleep(0.6)

Loading…
Cancel
Save

Powered by TurnKey Linux.