from time import sleep import kuukar.kuukar_nextion as kuukar_nextion class lcd: def __init__(self) -> None: self.nextion = kuukar_nextion.nextion() sleep(1) self.nextion.send_command("page home") def play_video(self,filename: str) -> None: self.nextion.send_command("page video_player") self.nextion.send_command("video.path=\"sd0/"+filename+".video\"") self.nextion.send_command("video.en=1") def pause_video(self) -> None: self.nextion.send_command("video.en=2") def resume_video(self) -> None: self.nextion.send_command("video.en=1") def stop_video(self) -> None: self.nextion.send_command("video.en=0") self.nextion.send_command("page home")