Example #1
0
def run(sleep=100, max_iterations=100):
    while True:
        try:
            SERVER.service(delay=sleep/1000.0, max_iterations=max_iterations)
            TIMERS.service()
        except KeyboardInterrupt:
            log.info('Received shutdown command from keyboard')
            break
        except Exception:
            log.exception('exception encountered')
Example #2
0
def run(command, delay=.01, loop=0):
    ''' helper function: loop through SERVER/TIMER until command.is_done is True '''

    while not command.is_done:
        SERVER.service(delay=delay, max_iterations=loop)
        TIMERS.service()
Example #3
0
def run(command, delay=.01, loop=0):
    ''' helper function: loop through SERVER/TIMER until command.is_done is True '''

    while not command.is_done:
        SERVER.service(delay=delay, max_iterations=loop)
        TIMERS.service()
Example #4
0
def run(command, delay=.01, loop=0):
    """ service SERVER/TIMER until command.is_done is True """
    while not command.is_done:
        SERVER.service(delay=delay, max_iterations=loop)
        TIMERS.service()
Example #5
0
def run(command, delay=.01, loop=0):
    """ service SERVER/TIMER until command.is_done is True """
    while not command.is_done:
        SERVER.service(delay=delay, max_iterations=loop)
        TIMERS.service()