title: Can only upload the first image each time my camera takes a picture
body: <p>I've setup my RPi, motion detector and camera to capture an image whenever motion is detected. Each time an image is captured, I'd like to automatically upload that image to Google Drive (and delete it from my RPi). </p>
  
  <p>Everything seems to be working with one exception - my script captures and uploads the first image to Google Drive with no problems but then it continues to upload that same image and only that image each time the camera is subsequently triggered. The subsequent images are being captured and stored on my RPi properly, just not uploaded to Google Drive. </p>
  
  <p>I'm only a couple weeks into coding so please have mercy on me (and sincere thanks for any help). Relevant bits below:</p>
  
  <pre><code>class MotionUploader:
      def __init__(self, config_file_path):
          config = ConfigParser.ConfigParser()
          config.read(config_file_path)
  
  def upload_snapshot(self, snapshot_file_path):
          """Upload a snapshot to the specified folder. Remove duplicates."""
          folder_id = self._get_folder_id(self.snapshot_folder)
          file_name = os.path.basename(snapshot_file_path)
          media = MediaFileUpload(snapshot_file_path, mimetype='image/jpeg')
          self.drive_service.files().insert(media_body=media, body={'title':file_name, 'parents':[{u'id': folder_id}]}).execute()          
  
  
  while True:
     i=GPIO.input(11)
     if i==0:    #When output from motion sensor is LOW
        print "All quiet... too quiet...",i
        GPIO.output(3, 0) #Turn OFF LED
        time.sleep(3)
     elif i==1:     #When output from motion sensor is HIGH
        print "!Achtung!",i
        GPIO.output(3, 1) #Turn ON LED
        now = datetime.datetime.now().strftime("%m_%d_%Y_%H_%M_%S")  
        camera.rotation = 180
        camera.start_preview()
        camera.capture("/home/pi/motion-uploader/Photos/"+ now + ".jpg")
        cfg_path = sys.argv[1]
        vid_path = sys.argv[2]  
        MotionUploader(cfg_path).upload_snapshot(vid_path)        
        camera.stop_preview()
        time.sleep(3)
  </code></pre>