迪文科技T5UIC2串口屏开发与特点解析

需积分: 20 3 下载量 151 浏览量 更新于2024-08-05 收藏 219KB PDF 举报
"T5UIC2是迪文科技推出的一款针对低端GUI应用设计的低功耗、低成本、精简版串口指令屏UI软件。它适用于多种尺寸的迪文屏硬件型号,支持丰富的图片存储、音乐播放、用户数据库以及SD卡配置等功能。此外,T5UIC2还具备自动电阻触摸屏校正、基本绘图操作和多种UI元素显示等特性。" 本文将详细介绍迪文科技的T5UIC2软件平台及其主要特点和串口指令集。 1. T5UIC2软件平台概述 T5UIC2是基于T5CPU设计的,专为低端图形用户界面应用而打造。该软件平台提供了128MB Flash内存,其中96MB用于存储图片,32MB用于存储字库,能容纳不同分辨率下的大量图片。同时,它支持32kHz 16bit WAV格式的音乐播放,并在启动时自动播放预设的音乐段落。此外,它拥有64KB的用户数据库,具有10万次的写入寿命。 2. 硬件支持 T5UIC2支持多种尺寸的迪文屏,包括2.8英寸至12.1英寸的屏幕,分辨率从240x320到800x600不等,部分型号具有IPS显示技术。每种型号的屏幕都与T5UIC2软件平台兼容,提供一致的操作体验。 3. 功能特性 - 图片存储:根据分辨率的不同,可存储的图片数量有所不同,最高可达94张。 - 音乐播放:内置音乐播放功能,最大可存储16MB的音乐文件。 - 用户数据库:提供64KB的用户数据存储空间,适用于存储用户设置或应用程序数据。 - SD/SDHC接口:通过SD卡进行软件下载和配置,方便更新和管理。 - 绘图操作:支持基础的绘图命令,如置点、连线和区域填充。 - UI显示:支持文本、图标、图片和二维码等多种UI元素的显示,丰富了人机交互。 - 触摸屏校正:自动识别和校正电阻触摸屏的误差,提高用户体验。 4. 串口指令集 T5UIC2通过串口指令集进行控制和通信,包括但不限于文本显示、图像处理、触控操作等指令,这些指令是开发者实现具体功能的基础。 T5UIC2软件平台的这些特性使得它成为一种高效且灵活的解决方案,适用于各种工业、商业和消费电子产品的HMI(人机界面)设计。开发者可以通过熟悉其串口指令集,轻松地创建和定制用户界面,实现与硬件的无缝交互。同时,其低功耗和低成本的设计也使其在能源效率和成本效益方面具有竞争优势。

使用QTimer对象代替QBasicTimer对象,修改程序class MyWindow(QWidget): def init(self): super().init() self.thread_list = [] self.color_photo_dir = os.path.join(os.getcwd(), "color_photos") self.depth_photo_dir = os.path.join(os.getcwd(), "depth_photos") self.image_thread = None self.saved_color_photos = 0 # 定义 saved_color_photos 属性 self.saved_depth_photos = 0 # 定义 saved_depth_photos 属性 self.init_ui() def init_ui(self): self.ui = uic.loadUi("C:/Users/wyt/Desktop/D405界面/intelrealsense1.ui") self.open_btn = self.ui.pushButton self.color_image_chose_btn = self.ui.pushButton_3 self.depth_image_chose_btn = self.ui.pushButton_4 self.open_btn.clicked.connect(self.open) self.color_image_chose_btn.clicked.connect(lambda: self.chose_dir(self.ui.lineEdit, "color")) self.depth_image_chose_btn.clicked.connect(lambda: self.chose_dir(self.ui.lineEdit_2, "depth")) def open(self): self.profile = self.pipeline.start(self.config) self.is_camera_opened = True self.label.setText('相机已打开') self.label.setStyleSheet('color:green') self.open_btn.setEnabled(False) self.close_btn.setEnabled(True) self.image_thread = ImageThread(self.pipeline, self.color_label, self.depth_label, self.interval, self.color_photo_dir, self.depth_photo_dir, self._dgl) self.image_thread.saved_color_photos_signal.connect(self.update_saved_color_photos_label) self.image_thread.saved_depth_photos_signal.connect(self.update_saved_depth_photos_label) self.image_thread.start() def chose_dir(self, line_edit, button_type): my_thread = MyThread(line_edit, button_type) my_thread.finished_signal.connect(self.update_line_edit) self.thread_list.append(my_thread) my_thread.start()

2023-05-26 上传

程序运行提示QBasicTimer::stop: Failed. Possibly trying to stop from a different thread,修改程序class MyWindow(QWidget): def init(self): super().init() self.thread_list = [] self.color_photo_dir = os.path.join(os.getcwd(), "color_photos") self.depth_photo_dir = os.path.join(os.getcwd(), "depth_photos") self.image_thread = None self.saved_color_photos = 0 # 定义 saved_color_photos 属性 self.saved_depth_photos = 0 # 定义 saved_depth_photos 属性 self.init_ui() def init_ui(self): self.ui = uic.loadUi("C:/Users/wyt/Desktop/D405界面/intelrealsense1.ui") self.open_btn = self.ui.pushButton self.color_image_chose_btn = self.ui.pushButton_3 self.depth_image_chose_btn = self.ui.pushButton_4 self.open_btn.clicked.connect(self.open) self.color_image_chose_btn.clicked.connect(lambda: self.chose_dir(self.ui.lineEdit, "color")) self.depth_image_chose_btn.clicked.connect(lambda: self.chose_dir(self.ui.lineEdit_2, "depth")) def open(self): self.profile = self.pipeline.start(self.config) self.is_camera_opened = True self.label.setText('相机已打开') self.label.setStyleSheet('color:green') self.open_btn.setEnabled(False) self.close_btn.setEnabled(True) self.image_thread = ImageThread(self.pipeline, self.color_label, self.depth_label, self.interval, self.color_photo_dir, self.depth_photo_dir, self._dgl) self.image_thread.saved_color_photos_signal.connect(self.update_saved_color_photos_label) self.image_thread.saved_depth_photos_signal.connect(self.update_saved_depth_photos_label) self.image_thread.start() def chose_dir(self, line_edit, button_type): my_thread = MyThread(line_edit, button_type) my_thread.finished_signal.connect(self.update_line_edit) self.thread_list.append(my_thread) my_thread.start()

2023-05-26 上传