GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — NightShift/looper_webcams.py at master · LowellObservatory/NightShift Expand file tree/ Copy pathlooper_webcams.pyMore file actions 65 lines (50 loc) · 2.22 KB / Copy pathlooper_webcams.pyFile metadata and controls65 lines (50 loc) · 2.22 KB 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 # -*- coding: utf-8 -*- # # This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this # file, You can obtain one at http://mozilla.org/MPL/2.0/. # # Created on 24 Oct 2018 # # @author: rhamilton from __future__ import division, print_function, absolute_import import time from ligmos.utils import logs, files, classes, confparsers from nightshift.webcam import grab_cams as cams def main(): """ """ # Switch to file-based logging since docker logs -f is mysteriously failing lfile = './outputs/logs/camLooper.log' cfile = './config/webcams.conf' pfile = './config/passwords.conf' confclass = classes.Webcam # Need to pass getList = False otherwise it'll try to generate a list # of files found in that directory and return it to you. files.checkOutDir('./outputs/logs/', getList=False) # If abort was True, this'll probably blow up...? logs.setup_logging(logName=lfile, nLogs=5) # Read the webcam config file and parse it accordingly. # Will return an OrderedDict of enabled webcams IF enableCheck is True oncams, _ = confparsers.parseConfig(cfile, confclass, passfile=pfile, searchCommon=False, enableCheck=True) # Before we start, check the ALL the image output directories. # Only checking the enabled ones, but could check allcams if desired. for cam in oncams: curcam = oncams[cam] # Test the output location to make sure it exists location = curcam.odir files.checkOutDir(location, getList=False) # Just run it for ever and ever and ever and ever and ever and ever while True: # failimg = None just uses the default one: # resources/images/percy_txt.jpg # Note: Archive locations will be created automatically in here cams.grabSet(oncams, failimg=None, makeMini=True, cullArchive=True) print("Done Grabbing Images!") print("Sleeping for 60 seconds...") time.sleep(60.) if __name__ == "__main__": main() |
| You are visitor 01402792 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |