def test(self):
    self.write_message('scheduled!')
tornado.ioloop.IOLoop.instance().add_timeout(datetime.timedelta(seconds=5),
    self.test)
python Tornado websockets how to send message every X seconds?