def METHOD_NAME(self):
    '''called on idle'''
    if self.sock is None and self.listen_sock is None:
        return
    if self.sock is None:
        try:
            conn_sock, addr = self.listen_sock.accept()
        except Exception as e:
            if e.errno not in [ errno.EAGAIN, errno.EWOULDBLOCK ]:
                print("ucenter listen fail")
                self.stop_listener()
                return
            return
        self.sock = conn_sock
        self.sock.setblocking(False)
        print("ucenter connection from %s" % str(addr))
    now = time.time()
    try:
        pkt = self.sock.recv(1000)
    except socket.error as e:
        if e.errno not in [ errno.EAGAIN, errno.EWOULDBLOCK ]:
            print("ucenter connection closed")
            self.sock.close()
            self.sock = None
            return
        # send empty packet if idle
        pkt = ''
    if len(pkt) == 0 and now - self.last_write < self.ucenter_settings.delay:
        return
    self.write(pkt)