menu_data.py 文件源码

python
阅读 23 收藏 0 点赞 0 评论 0

项目:fingerpi 作者: zafartahirov 项目源码 文件源码
def Blink(self, *args, **kwargs):
        if not self.open:
            raise NotOpenError('Please, open the port first!')
        screen = args[0]
        y, x = screen.getmaxyx()
        screen.border(0)
        screen.addstr(0, 1, 'Press any button to stop...'[:x-2], curses.A_STANDOUT)

        t = RepeatingTimer(0.5, self.CmosLed, screen)
        t.start()

        screen.refresh()
        inp = screen.getch()
        if inp:
            t.cancel()
            self.CmosLed(led = False)
            self._led = False

        return ['', None]

    ####################################################################
    ## All (other) commands:
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号