Assignment code for Georgia Tech CS 3630, 2014
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add image-taking script

+28
+28
Assignment 6/working code 4-16 pre/takeImage.py
··· 1 + import time 2 + import System 3 + from Myro import * 4 + 5 + def takePhoto(): 6 + pic_fname = "pic-%d.jpg" % time.time() 7 + print('\tTaking picture:', pic_fname) 8 + picture = takePicture(); 9 + print('\tPicture taken!') 10 + logNow(log, 0,0,pic_fname); 11 + print('\tSaving picture...') 12 + savePicture(picture, pic_fname) 13 + print('\tPicture saved!') 14 + 15 + 16 + print('Connecting to Scribbler...') 17 + init("COM8") 18 + setIRPower(140) 19 + setForwardness(1) 20 + 21 + takePhoto() 22 + print('Photo taken!') 23 + 24 + log.close() 25 + 26 + print('Script finished!') 27 + 28 + System.Environment.Exit(0)