技术领域technical field
本发明实施例涉及通信技术,尤其涉及数据传输方法、装置、终端以及存储介质。Embodiments of the present invention relate to communication technologies, and in particular, to a data transmission method, device, terminal, and storage medium.
背景技术Background technique
目前,很多智能终端上设置有触摸功能的触摸设备,由此简便、方便、自然的实现了人机交互,进而也扩大了具有触摸功能的智能终端的应用领域。图1A是现有技术中智能终端上触摸设备与其他组件的结构连接示意图,目前,触摸设备与智能终端的其他组件具有如图1A所示的连接结构。At present, many smart terminals are equipped with touch devices with touch functions, thereby realizing human-computer interaction simply, conveniently and naturally, and further expanding the application fields of smart terminals with touch functions. FIG. 1A is a schematic diagram of the structural connection between the touch device and other components on the smart terminal in the prior art. Currently, the touch device and other components of the smart terminal have a connection structure as shown in FIG. 1A .
参见图1A,智能终端中的控制芯片通过第一USB(Universal Serial Bus,通用串行总线)接口11与触摸设备直接相连,并通过第二USB接口12结合USB切换器13与智能终端上设置的主设备模块相连,其中,主设备模块可以是个人计算机PC设备模块、安卓设备Android模块或者外接设备模块,智能终端可以通过所设置的不同主设备模块来体现不同的功能。基于上述连接结构,可实现触摸设备智能终端主设备模块的数据交互。一般地,触摸设备与控制芯片通过连接第一USB接口11连接后,数据交互时所遵循的通信协议A由触摸设备生产厂商自定义形成;而控制芯片与智能终端的主设备模块数据交互时所遵循的通信协议B由智能终端生产厂商自定义形成。1A, the control chip in the smart terminal is directly connected to the touch device through the first USB (Universal Serial Bus, Universal Serial Bus) interface 11, and through the second USB interface 12 combined with the USB switch 13 and the smart terminal set The main equipment modules are connected, wherein the main equipment module can be a personal computer PC equipment module, an Android device Android module or an external equipment module, and the intelligent terminal can reflect different functions through different main equipment modules set. Based on the above connection structure, the data interaction of the main device module of the smart terminal of the touch device can be realized. Generally, after the touch device and the control chip are connected through the first USB interface 11, the communication protocol A followed during data interaction is defined by the touch device manufacturer; The communication protocol B followed is defined by the smart terminal manufacturer.
在对智能终端的开发和使用的过程中需要对设置其上的触摸设备进行固件升级,以提高触摸设备与智能终端中其他模块之间的兼容性,进而提升智能终端的使用体验度。现有技术中,对触摸设备固件升级时,需要将存放在主设备模块中的固件升级包发送给触摸设备,但由于上述连接结构中各设备的数据交互采用不同的协议,主设备模块无法准确的向触摸设备传输固件升级包。针对上述问题,技术人员提出下述改进方法:1)一种是采用软件开发的方式保证数据传输的准确性,但该种方式需要对触摸设备与控制芯片之间遵循的通信协议A进行详细的解析并且需要编写大量的代码实现逻辑对遵循不同通信协议的数据进行传输,以实现对触摸设备的二次开发进而实现对触摸设备的固件升级,增加了开发人员的开发维护难度;2)图1B是现有技术中改进后便于触摸设备进行固件升级的结构连接示意图,采用图1B中修改硬件框架的方式统一化固件升级时的传输协议,但该种方式需要在触摸设备与控制芯片之间添加额外第二USB切换器14,将触摸设备与存储触摸设备固件升级包的PC模块、Android模块或者外接设备模块直接相连,额外增添了硬件使用成本。During the development and use of the smart terminal, it is necessary to upgrade the firmware of the touch device installed on it, so as to improve the compatibility between the touch device and other modules in the smart terminal, thereby improving the user experience of the smart terminal. In the prior art, when upgrading the firmware of the touch device, the firmware upgrade package stored in the main device module needs to be sent to the touch device, but because the data interaction of each device in the above connection structure uses different protocols, the main device module cannot accurately Transfer the firmware upgrade package to the touch device. In response to the above problems, the technicians proposed the following improvement methods: 1) One is to use software development to ensure the accuracy of data transmission, but this method requires detailed communication protocol A followed between the touch device and the control chip To analyze and write a lot of codes to implement logic to transmit data following different communication protocols, so as to realize the secondary development of touch devices and then upgrade the firmware of touch devices, which increases the difficulty of development and maintenance for developers; 2) Figure 1B It is a schematic diagram of the structural connection of the improved firmware upgrade of the touch device in the prior art. The method of modifying the hardware framework in Figure 1B is adopted to unify the transmission protocol during firmware upgrade, but this method needs to be added between the touch device and the control chip. The additional second USB switch 14 directly connects the touch device to the PC module, the Android module or the external device module storing the firmware upgrade package of the touch device, which increases the cost of hardware usage.
发明内容Contents of the invention
本发明实施例提供了数据传输方法、装置、终端以及存储介质,以无需进行复杂的软件开发或修改硬件框架的情况下即可实现对触摸设备的固件升级,减少开发人员的开发维护难度,节约智能终端的硬件使用成本。The embodiment of the present invention provides a data transmission method, device, terminal, and storage medium, so that the firmware upgrade of the touch device can be realized without complex software development or modification of the hardware framework, reducing the development and maintenance difficulty of developers, saving The hardware usage cost of the smart terminal.
第一方面,本发明实施例提供了数据传输方法,该方法包括:In a first aspect, an embodiment of the present invention provides a data transmission method, the method comprising:
主设备模块监听到控制芯片中监听端口的端口值发生改变后,获取对应于所述控制芯片的当前通用串行接口USB描述符;After the main device module monitors that the port value of the monitoring port in the control chip changes, it obtains the current universal serial interface USB descriptor corresponding to the control chip;
所述主设备模块根据所述当前USB描述符,确定与所述控制芯片通信的芯片通信端口,并基于所述芯片通信端口向所述控制芯片发送固件升级包;The main device module determines a chip communication port communicating with the control chip according to the current USB descriptor, and sends a firmware upgrade package to the control chip based on the chip communication port;
所述控制芯片向与所述芯片通信端口对应的触摸设备通信端口转送所述固件升级包,以使所述触摸设备基于所述固件升级包进行固件升级。The control chip forwards the firmware upgrade package to the touch device communication port corresponding to the chip communication port, so that the touch device performs firmware upgrade based on the firmware upgrade package.
第二方面,本发明实施例还提供了数据传输装置,该装置包括:In the second aspect, the embodiment of the present invention also provides a data transmission device, which includes:
获取模块,用于在主设备模块监听到控制芯片中监听端口的端口值发生改变后,获取对应于所述控制芯片的当前通用串行接口USB描述符;The obtaining module is used to obtain the current universal serial interface USB descriptor corresponding to the control chip after the master device module monitors that the port value of the monitoring port in the control chip changes;
发送模块,用于根据所述当前USB描述符,确定与所述控制芯片通信的芯片通信端口,并基于所述芯片通信端口向所述控制芯片发送固件升级包;A sending module, configured to determine a chip communication port communicating with the control chip according to the current USB descriptor, and send a firmware upgrade package to the control chip based on the chip communication port;
转送模块,用于向与所述芯片通信端口对应的触摸设备通信端口转送所述固件升级包,以使所述触摸设备基于所述固件升级包进行固件升级。The transfer module is configured to transfer the firmware upgrade package to the touch device communication port corresponding to the chip communication port, so that the touch device performs firmware upgrade based on the firmware upgrade package.
第三方面,本发明实施例还提供了一种终端,该终端包括输入装置,还包括:In a third aspect, an embodiment of the present invention further provides a terminal, the terminal includes an input device, and further includes:
一个或多个处理器;one or more processors;
存储装置,用于存储一个或多个程序;storage means for storing one or more programs;
所述一个或多个程序被所述一个或多个处理器执行,使得所述一个或多个处理器实现本发明实施例提供的数据传输方法。The one or more programs are executed by the one or more processors, so that the one or more processors implement the data transmission method provided by the embodiment of the present invention.
第四方面,本发明实施例还提供了一种计算机可读存储介质,其上存储有计算机程序,该程序被处理器执行时实现本发明实施例提供的数据传输方法。In a fourth aspect, the embodiment of the present invention also provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, the data transmission method provided in the embodiment of the present invention is implemented.
本发明实施例通过主设备模块监听到控制芯片中监听端口的端口值发生改变后,获取对应于所述控制芯片的当前通用串行接口USB描述符;根据所述当前USB描述符,确定与所述控制芯片通信的芯片通信端口,并基于所述芯片通信端口向所述控制芯片发送固件升级包;控制芯片向与所述芯片通信端口对应的触摸设备通信端口转送所述固件升级包,以使所述触摸设备基于所述固件升级包进行固件升级,采用上述技术方案解决了在传输触摸设备的固件升级包的过程中,各个设备的数据交互采用的协议不同导致主设备模块无法准确向触摸设备传输固件升级包的技术问题,实现了无需进行复杂的软件开发或修改硬件框架的情况下主设备模块能够准确的向触摸设备传输固件升级包,从而在保证触摸设备能够有效进行固件升级的情况下,减少开发人员的开发维护难度,节约智能终端的硬件使用成本。In the embodiment of the present invention, after the port value of the monitoring port in the control chip is monitored by the main device module, the current universal serial interface USB descriptor corresponding to the control chip is obtained; The chip communication port of the control chip communication, and send a firmware upgrade package to the control chip based on the chip communication port; the control chip forwards the firmware upgrade package to the touch device communication port corresponding to the chip communication port, so that The touch device performs firmware upgrade based on the firmware upgrade package, and the above-mentioned technical solution solves the problem that in the process of transmitting the firmware upgrade package of the touch device, the data interaction protocol of each device is different, so that the main device module cannot accurately report to the touch device. The technical problem of transmitting the firmware upgrade package has realized that the main device module can accurately transmit the firmware upgrade package to the touch device without complex software development or modification of the hardware framework, so that the touch device can effectively upgrade the firmware. , reduce the development and maintenance difficulty of developers, and save the hardware cost of smart terminals.
附图说明Description of drawings
图1A是现有技术中智能终端上触摸设备与其他组件的结构连接示意图;FIG. 1A is a schematic diagram of the structural connection between a touch device and other components on a smart terminal in the prior art;
图1B是现有技术中改进后便于触摸设备进行固件升级的结构连接示意图;FIG. 1B is a schematic diagram of structural connections for firmware upgrades of touch devices after improvements in the prior art;
图2是本发明实施例一中的数据传输方法的流程示意图;FIG. 2 is a schematic flowchart of a data transmission method in Embodiment 1 of the present invention;
图3是本发明实施例二中的数据传输方法的流程示意图;FIG. 3 is a schematic flowchart of a data transmission method in Embodiment 2 of the present invention;
图4是本发明实施例三中的数据传输装置的结构示意图;4 is a schematic structural diagram of a data transmission device in Embodiment 3 of the present invention;
图5是本发明实施例四中的终端的结构示意图。FIG. 5 is a schematic structural diagram of a terminal in Embodiment 4 of the present invention.
具体实施方式Detailed ways
下面结合附图和实施例对本发明作进一步的详细说明。可以理解的是,此处所描述的具体实施例仅仅用于解释本发明,而非对本发明的限定。另外还需要说明的是,为了便于描述,附图中仅示出了与本发明相关的部分而非全部结构。The present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described here are only used to explain the present invention, but not to limit the present invention. In addition, it should be noted that, for the convenience of description, only some structures related to the present invention are shown in the drawings but not all structures.
实施例一Embodiment one
图2为本发明实施例一提供的数据传输方法的流程图,本实施例可适用于采用智能终端中的主设备模块中存储的固件升级包对智能终端中的触摸设备进行固件升级的情况,该方法可以由数据传输装置来执行,该装置由软件和/或硬件来实现,并配置在智能终端上。如图2所示的数据传输方法,具体包括:FIG. 2 is a flow chart of the data transmission method provided by Embodiment 1 of the present invention. This embodiment is applicable to the situation where the firmware upgrade package of the touch device in the smart terminal is upgraded by using the firmware upgrade package stored in the main device module in the smart terminal. The method can be executed by a data transmission device, which is realized by software and/or hardware and configured on an intelligent terminal. The data transmission method shown in Figure 2 specifically includes:
S101、主设备模块监听到控制芯片中监听端口的端口值发生改变后,获取对应于所述控制芯片的当前USB描述符。S101. After detecting that the port value of the monitoring port in the control chip changes, the main device module obtains the current USB descriptor corresponding to the control chip.
基于本实施例提供的数据传输方法用于触摸设备的固件升级时,无需改变触摸设备与智能终端中其他组件的连接结构,由此可认为,触摸设备与智能终端中其他组件的连接结构仍如图1A所示,控制芯片与触摸设备之间通过USB接口1物理连接。在本实施例中,可将控制芯片作为USB主从结构中的主机,触摸设备作为USB主从结构中的设备,当控制芯片与触摸设备在首次进行连接时,控制芯片会枚举触摸设备的USB描述符并存储在控制芯片中。When the data transmission method provided by this embodiment is used to upgrade the firmware of the touch device, there is no need to change the connection structure between the touch device and other components in the smart terminal, so it can be considered that the connection structure between the touch device and other components in the smart terminal is still as follows As shown in FIG. 1A , the control chip and the touch device are physically connected through a USB interface 1 . In this embodiment, the control chip can be used as the host in the USB master-slave structure, and the touch device can be used as a device in the USB master-slave structure. When the control chip and the touch device are connected for the first time, the control chip will enumerate the touch device. USB descriptor and stored in the control chip.
此外,控制芯片与主设备模块之间通过第二USB接口12以及USB切换器13进行物理连接,其中USB切换器13作为一个多通道的选择开关,通过控制芯片的控制连接主设备模块中的任一模块。本实施例可将主设备模块作为USB主从结构中的主机,控制芯片作为USB主从结构的设备。In addition, the control chip and the main device module are physically connected through the second USB interface 12 and the USB switcher 13, wherein the USB switcher 13 is used as a multi-channel selection switch, and is connected to any of the main device modules through the control of the control chip. a module. In this embodiment, the main device module can be used as the host in the USB master-slave structure, and the control chip can be used as a device in the USB master-slave structure.
可以理解的是,主设备模块与控制芯片首次连接后会默认获取控制芯片自身的USB描述符,但后续主设备模块仍可以主动监听控制芯片上的监听端口的端口值,来判定该监听端口的端口值是否发生变化,并在监听端口的端口值发生变化时,主设备模块获取控制芯片中与监听端口相对应设定存储空间中的数据信息,本实施例中主设备模块基于该数据信息可以直接或间接的获取控制芯片的当前USB描述符,其中,该当前USB描述为相当于控制芯片中存储的触摸设备的USB描述符。It is understandable that after the first connection between the main device module and the control chip, the USB descriptor of the control chip itself will be obtained by default, but the subsequent main device module can still actively monitor the port value of the monitoring port on the control chip to determine the value of the monitoring port. Whether the port value changes, and when the port value of the monitoring port changes, the main equipment module obtains the data information in the storage space corresponding to the monitoring port in the control chip. In this embodiment, the main equipment module can be based on the data information Acquire the current USB descriptor of the control chip directly or indirectly, wherein the current USB description is equivalent to the USB descriptor of the touch device stored in the control chip.
S102、所述主设备模块根据所述当前USB描述符,确定与所述控制芯片通信的芯片通信端口,并基于所述芯片通信端口向所述控制芯片发送固件升级包。S102. The main device module determines a chip communication port communicating with the control chip according to the current USB descriptor, and sends a firmware upgrade package to the control chip based on the chip communication port.
在该步骤中,主设备模块中存储有触摸设备供应商提供的触摸设备的固件升级包,用以对触摸设备进行固件升级。所述芯片通信端口具体可理解为主设备模块向控制芯片进行固件升级包传输时需要依据的通信端口,该芯片通信端口具体可基于主设备模块获得的当前USB描述符确定。由于当前USB描述符实际为触摸设备的USB描述符,所以控制芯片此时可看作一个虚拟的触摸设备被动接收主设备模块发送的固件升级包。In this step, the firmware upgrade package of the touch device provided by the touch device supplier is stored in the main device module, so as to upgrade the firmware of the touch device. The chip communication port can specifically be understood as the communication port that needs to be used when the main device module transmits the firmware upgrade package to the control chip, and the chip communication port can be specifically determined based on the current USB descriptor obtained by the main device module. Since the current USB descriptor is actually the USB descriptor of the touch device, the control chip can now be regarded as a virtual touch device to passively receive the firmware upgrade package sent by the main device module.
具体地,主设备模块枚举控制芯片中存储的触摸设备的USB描述符中至少包括标准描述符、HID(Human Interface Devices,人机接口设备)设备描述符以及HID报告描述符。其中,标准描述符包括对触摸设备的各配置信息进行描述的配置描述符、各配置信息中包含的各个接口对应的接口描述符、各接口中包含的各个端口对应的端口描述符,通过标准描述符中的端口描述符,主设备模块确定向控制芯片传输固件升级包的芯片通信端口。Specifically, the USB descriptor of the touch device stored in the main device module enumeration control chip includes at least a standard descriptor, a HID (Human Interface Devices, human interface device) device descriptor and a HID report descriptor. Wherein, the standard descriptor includes a configuration descriptor describing each configuration information of the touch device, an interface descriptor corresponding to each interface included in each configuration information, and a port descriptor corresponding to each port included in each interface. The port descriptor in the descriptor, the main device module determines the chip communication port for transmitting the firmware upgrade package to the control chip.
S103、所述控制芯片向与所述芯片通信端口对应的触摸设备通信端口转送所述固件升级包,以使所述触摸设备基于所述固件升级包进行固件升级。S103. The control chip forwards the firmware upgrade package to the touch device communication port corresponding to the chip communication port, so that the touch device performs firmware upgrade based on the firmware upgrade package.
在本实施例中,由于主设备模块所获取的当前USB描述符具体可看做触摸设备的USB描述符,因此,主设备模块根据当前USB描述符确定的芯片通信端口实质上相当于触摸设备直接与主设备模块采用USB接口的方式进行物理连接时,被动接收主设备模块发送数据所需的通信端口,在该种情况下,控制芯片相当于主设备模块与触摸设备之间的一个虚拟的触摸设备,此时,控制芯片自身无需对接收的固件升级包进行任何处理,就可通过触摸设备通信端口向触摸设备转送该固件升级包,以使触摸设备能够基于该固件升级包进行固件升级,其中,该触摸设备通信端口实质上与芯片通信端口相同,但具体设置在触摸设备上,与设置在控制芯片上的芯片通信端口一同构成了进行固件升级包传输的数据传输通道。In this embodiment, since the current USB descriptor obtained by the main device module can be specifically regarded as the USB descriptor of the touch device, the chip communication port determined by the main device module according to the current USB descriptor is essentially equivalent to the touch device directly When the main equipment module is physically connected with the USB interface, the communication port required to passively receive the data sent by the main equipment module, in this case, the control chip is equivalent to a virtual touch between the main equipment module and the touch device device, at this time, the control chip itself does not need to perform any processing on the received firmware upgrade package, and can transfer the firmware upgrade package to the touch device through the communication port of the touch device, so that the touch device can perform firmware upgrade based on the firmware upgrade package, wherein , the touch device communication port is substantially the same as the chip communication port, but it is specifically set on the touch device, and together with the chip communication port set on the control chip, constitutes a data transmission channel for firmware upgrade package transmission.
本发明实施例通过主设备模块监听到控制芯片中监听端口的端口值发生改变后,获取对应于所述控制芯片的当前通用串行接口USB描述符;根据所述当前USB描述符,确定与所述控制芯片通信的芯片通信端口,并基于所述芯片通信端口向所述控制芯片发送固件升级包;控制芯片向与所述芯片通信端口对应的触摸设备通信端口转送所述固件升级包,以使所述触摸设备基于所述固件升级包进行固件升级,采用上述技术方案解决了在传输触摸设备的固件升级包的过程中,各个设备的数据交互采用的协议不同导致主设备模块无法准确向触摸设备传输固件升级包的技术问题,实现了无需进行复杂的软件开发或修改硬件框架的情况下主设备模块能够准确的向触摸设备传输固件升级包,从而在保证触摸设备能够有效进行固件升级的情况下,减少开发人员的开发维护难度,节约智能终端的硬件使用成本。In the embodiment of the present invention, after the port value of the monitoring port in the control chip is monitored by the main device module, the current universal serial interface USB descriptor corresponding to the control chip is obtained; The chip communication port of the control chip communication, and send a firmware upgrade package to the control chip based on the chip communication port; the control chip forwards the firmware upgrade package to the touch device communication port corresponding to the chip communication port, so that The touch device performs firmware upgrade based on the firmware upgrade package, and the above-mentioned technical solution solves the problem that in the process of transmitting the firmware upgrade package of the touch device, the data interaction protocol of each device is different, so that the main device module cannot accurately report to the touch device. The technical problem of transmitting the firmware upgrade package has realized that the main device module can accurately transmit the firmware upgrade package to the touch device without complex software development or modification of the hardware framework, so that the touch device can effectively upgrade the firmware. , reduce the development and maintenance difficulty of developers, and save the hardware cost of smart terminals.
实施例二Embodiment two
图3为本发明实施例二提供的数据传输方法的流程示意图,本实施例在上述各实施例的技术方案的基础场,优选是将“所述主设备模块根据所述当前USB描述符,确定与所述控制芯片通信的芯片通信端口,并基于所述芯片通信端口向所述控制芯片发送固件升级包”进一步细化为“所述主设备模块根据所述标准描述符,确定向所述控制芯片传输所述固件升级包所需的芯片通信端口;所述主设备模块选取所述HID报告描述符中与目标报告标识码对应的报告描述符,作为传输所述固件升级包所依照的目标数据传输格式;当所述HID设备描述符中的设备标识符与所述触摸设备的标准标识符相匹配时,所述主设备模块依照所述目标数据传输格式向所述芯片通信端口传输所述固件升级包”。Fig. 3 is a schematic flow chart of the data transmission method provided by Embodiment 2 of the present invention. In this embodiment, in the basic field of the technical solutions of the above-mentioned embodiments, it is preferred that "the main device module determines according to the current USB descriptor A chip communication port communicating with the control chip, and sending a firmware upgrade package to the control chip based on the chip communication port" is further refined into "the main device module determines to send a firmware upgrade package to the control chip according to the standard descriptor. The chip communication port required for the chip to transmit the firmware upgrade package; the main device module selects the report descriptor corresponding to the target report identification code in the HID report descriptor as the target data according to which the firmware upgrade package is transmitted Transmission format: when the device identifier in the HID device descriptor matches the standard identifier of the touch device, the main device module transmits the firmware to the chip communication port according to the target data transmission format upgrade package".
进一步地,本发明实施例的技术方案还追加了“所述控制芯片接收到触发生成的固件升级指令时,更新设定存储空间中保存的通信控制信息,并调整所述设备存储空间所对应监听端口的端口值”的技术方案,以进一步描述控制芯片的监听端口的端口值发生变化的操作。Further, the technical solution of the embodiment of the present invention also adds that "when the control chip receives the trigger-generated firmware upgrade instruction, update the communication control information stored in the setting storage space, and adjust the monitoring corresponding to the device storage space." port value of the port” to further describe the operation of changing the port value of the monitoring port of the control chip.
进一步地,本发明实施例的技术方案将“获取对应于所述控制芯片的当前USB描述符”进一步细化为“向所述控制芯片发送复位请求,并接收到所述控制芯片反馈的外部中断信号后,向所述控制芯片发送设备信息获取指令;获取所述控制芯片基于设备信息获取指令反馈的所述当前USB描述符”。Further, the technical solution of the embodiment of the present invention further refines "obtaining the current USB descriptor corresponding to the control chip" into "sending a reset request to the control chip and receiving an external interrupt fed back by the control chip After receiving the signal, send a device information acquisition instruction to the control chip; acquire the current USB descriptor fed back by the control chip based on the device information acquisition instruction.
如图3所示的数据传输方法,包括以下步骤:The data transmission method as shown in Figure 3 comprises the following steps:
S201、控制芯片接收到触发生成的固件升级指令时,更新设定存储空间中保存的通信控制信息,并调整所述设备存储空间所对应监听端口的端口值。S201. When the control chip receives a trigger-generated firmware upgrade instruction, update the communication control information stored in the setting storage space, and adjust the port value of the monitoring port corresponding to the device storage space.
在该步骤中,控制芯片会接收到由于用户的触发操作而形成的对触摸设备进行固件升级的固件升级指令。在控制芯片接收到该固件升级指令后,更新设定存储空间中保存的通信控制信息,同时调整该设备存储空间所对应的监听端口的端口值。其中,设定存储空间用于存储通信控制信息,并且主设备模块通过该设定存储空间来直接或者间接获取控制芯片中的当前USB描述符。In this step, the control chip will receive a firmware upgrade instruction for upgrading the firmware of the touch device formed due to a user's trigger operation. After the control chip receives the firmware upgrade instruction, it updates the communication control information stored in the setting storage space, and at the same time adjusts the port value of the listening port corresponding to the storage space of the device. Wherein, the set storage space is used to store the communication control information, and the main device module obtains the current USB descriptor in the control chip directly or indirectly through the set storage space.
需要说明的是,控制芯片通信控制信息确定控制芯片中与该设备存储空间相对应监听端口的端口值变化。而主设备模块通过监听控制芯片中与该设备存储空间相对应的监听端口的端口值来确定控制芯片中的通信控制信息是否发生了变化。也就是说,如果设定存储空间中保存的通信控制信息发生了变化,那么相应的,控制芯片中与该设备存储空间相对应的监听端口的端口值也会发生变化,此时主设备模块将会以控制芯片的设备存储空间所对应的监听端口的端口值,作为后续获取控制芯片中的当前USB描述符的依据。其中,设定存储空间中存储的通信控制信息可以是控制芯片中存储的以控制芯片为USB主从结构中的主机相对应的USB主从结构中的各设备的USB描述符;还可以是存储各USB描述符的本地存储地址。It should be noted that the communication control information of the control chip determines the port value change of the monitoring port corresponding to the storage space of the device in the control chip. The main device module determines whether the communication control information in the control chip has changed by monitoring the port value of the monitoring port corresponding to the storage space of the device in the control chip. That is to say, if the communication control information saved in the setting storage space changes, correspondingly, the port value of the monitoring port corresponding to the storage space of the device in the control chip will also change, and at this time the main device module will The port value of the monitoring port corresponding to the device storage space of the control chip will be used as the basis for subsequent acquisition of the current USB descriptor in the control chip. Wherein, the communication control information stored in the setting storage space can be the USB descriptor of each device in the USB master-slave structure corresponding to the host computer in the USB master-slave structure stored in the control chip; The local storage address of each USB descriptor.
进一步地,通过获取控制芯片中所存储USB描述符的USB描述符序列表中包含的各USB描述符中的设备标识信息;当设定存储空间中存储的通信控制信息为USB描述符时,从各所述设备标识信息中查找与设定标识信息相匹配的目标设备标识信息,并将包含所述目标设备标识信息的目标USB描述符作为通信控制信息更新到所述设定存储空间中;或者,当设定存储空间中存储的通信控制信息为USB描述符的本地存储地址时,将包含所述目标设备标识信息的目标USB描述符的本地存储地址作为通信控制信息更新到所述设定存储空间中。Further, by obtaining the device identification information in each USB descriptor contained in the USB descriptor sequence table of the USB descriptor stored in the control chip; when the communication control information stored in the storage space is set as the USB descriptor, from Searching for target device identification information matching the set identification information in each of the device identification information, and updating the target USB descriptor containing the target device identification information into the set storage space as communication control information; or , when setting the communication control information stored in the storage space as the local storage address of the USB descriptor, updating the local storage address of the target USB descriptor containing the target device identification information as the communication control information to the setting storage in space.
示例性地,假设以控制芯片作为USB主从结构的主机时,与控制芯片相对应的设备为触摸设备、其他设备1、其他设备3、…、其他设备n,那么相应的在控制芯片中可以理解为存在一个包含触摸设备的USB描述符、n个其他设备的USB描述符以及控制芯片自身的USB描述符形成的USB描述符序列表。该列表中每个USB描述符均包含一个设备标识信息;当控制芯片接收到固件升级指令后,需要从USB描述符序列表中包含的各个设备标识信息中查找与设定标识信息(也即触摸设备标识信息)相对应的设备标识信息作为目标设备标识信息,并将包含该目标设备标识信息的目标USB描述符作为通信控制信息更新到设定存储空间中;或者将存储该目标USB描述符的本地存储地址作为通信控制信息更新到设定存储空间中。Exemplarily, assuming that when the control chip is used as the host of the USB master-slave structure, the devices corresponding to the control chip are touch devices, other devices 1, other devices 3, ..., other devices n, then correspondingly in the control chip can be It is understood that there is a USB descriptor sequence table formed by including the USB descriptor of the touch device, the USB descriptors of n other devices, and the USB descriptor of the control chip itself. Each USB descriptor in the list contains a device identification information; when the control chip receives the firmware upgrade instruction, it needs to search and set the identification information from each device identification information contained in the USB descriptor sequence list (that is, touch device identification information) corresponding device identification information as the target device identification information, and update the target USB descriptor containing the target device identification information in the setting storage space as communication control information; or store the target USB descriptor The local storage address is updated in the setting storage space as communication control information.
进一步地,所述固件升级指令为:用户通过所述触摸设备的触摸界面触摸而产生的第一升级指令;或者,用户对所述主设备模块中升级控制开关键的触发而产生的第二升级指令;或者,所述控制芯片代码逻辑实现中的模式切换标识符的标识值为升级标识值时对应产生的第三升级指令。Further, the firmware upgrade instruction is: a first upgrade instruction generated by the user touching the touch interface of the touch device; or a second upgrade instruction generated by the user triggering the upgrade control switch key in the main device module instruction; or, the third upgrade instruction correspondingly generated when the identification value of the mode switching identifier in the code logic implementation of the control chip is an upgrade identification value.
S202、主设备模块监听到控制芯片中监听端口的端口值发生改变后,向所述控制芯片发送复位请求,并接收到所述控制芯片反馈的外部中断信号后,向所述控制芯片发送设备信息获取指令。S202. After the main device module detects that the port value of the monitoring port in the control chip has changed, it sends a reset request to the control chip, and after receiving an external interrupt signal fed back by the control chip, sends device information to the control chip Get instructions.
S203、获取所述控制芯片基于设备信息获取指令反馈的所述当前USB描述符;其中,所述当前USB描述符通过所述通信控制信息确定。S203. Acquire the current USB descriptor fed back by the control chip based on the device information acquisition instruction; wherein the current USB descriptor is determined through the communication control information.
在S202和S203中,主设备模块监听到控制芯片中监听端口的端口值发生变化后,向控制芯片发送复位请求。在控制芯片接收到该复位请求后,控制芯片会向主设备模块反馈外部中断信号。当主设备模块接收到该外部中断信号后,向控制芯片发送用于获取控制芯片的USB描述符的设备信息获取指令。In S202 and S203, the main device module sends a reset request to the control chip after detecting that the port value of the monitoring port in the control chip changes. After the control chip receives the reset request, the control chip will feed back an external interrupt signal to the main device module. After receiving the external interrupt signal, the main device module sends a device information acquisition instruction for acquiring the USB descriptor of the control chip to the control chip.
在控制芯片接收到该设备信息获取指令后,主设备模块会通过获取设备存储空间中的通信控制信息,当通信控制信息为USB描述符时,将该USB描述符(也即目标USB描述符)作为当前USB描述符;当通信控制信息为USB描述符的本地存储地址时,获取该本地存储地址中存储的USB描述符(也即目标USB描述符)作为当前USB描述符。After the control chip receives the device information acquisition instruction, the main device module will obtain the communication control information in the device storage space. When the communication control information is a USB descriptor, the USB descriptor (that is, the target USB descriptor) As the current USB descriptor; when the communication control information is the local storage address of the USB descriptor, obtain the USB descriptor (that is, the target USB descriptor) stored in the local storage address as the current USB descriptor.
需要说明的是,其中当前USB描述符至少包括:标准描述符、人机接口设备HID报告描述符以及HID设备描述符。It should be noted that the current USB descriptor includes at least: a standard descriptor, a human interface device HID report descriptor and a HID device descriptor.
S204、所述主设备模块根据所述标准描述符,确定向所述控制芯片传输所述固件升级包所需的芯片通信端口。S204. The main device module determines a chip communication port required for transmitting the firmware upgrade package to the control chip according to the standard descriptor.
在标准描述符中存储有与触摸设备相对应的配置描述符、各配置信息中包含的各个接口对应的接口描述符、各接口中包含的各个端口对应的端口描述符,通过标准描述符中的端口描述符,主设备模块确定向控制芯片传输固件升级包的芯片通信端口。The configuration descriptor corresponding to the touch device, the interface descriptor corresponding to each interface included in each configuration information, and the port descriptor corresponding to each port included in each interface are stored in the standard descriptor. The port descriptor, the main device module determines the chip communication port for transmitting the firmware upgrade package to the control chip.
S205、所述主设备模块选取所述HID报告描述符中与目标报告标识码对应的报告描述符,作为传输所述固件升级包所依照的目标数据传输格式。S205. The main device module selects the report descriptor corresponding to the target report identification code in the HID report descriptor as the target data transmission format according to which the firmware upgrade package is transmitted.
在HID报告描述符中会包含多种不同功能操作对应的报告描述符,主设备模块通过查找HID报告描述符中包含的报告标识码与目标报告标识码相对应的报告描述符,以确定向控制芯片传输固件升级包时所依照的数据传输格式。The HID report descriptor will contain a variety of report descriptors corresponding to different functional operations. The main device module will determine the report descriptor corresponding to the report identification code contained in the HID report descriptor and the target report identification code. The data transmission format used by the chip to transmit the firmware upgrade package.
S206、判断HID设备描述符中的设备标识符与所述触摸设备的标准标识符是否相匹配;如果是,则执行S207。S206. Determine whether the device identifier in the HID device descriptor matches the standard identifier of the touch device; if yes, execute S207.
在HID设备描述符中包含有标识该设备类型的设备标识符。当HID设备描述符中的设备标识符与触摸设备的标准标识符相同时,则确定当前USB描述符为触摸设备的USB描述符,此时控制芯片可以作为一个虚拟的触摸设备接收主控设备传输的固件升级包。The device identifier that identifies the device type is included in the HID device descriptor. When the device identifier in the HID device descriptor is the same as the standard identifier of the touch device, it is determined that the current USB descriptor is the USB descriptor of the touch device. At this time, the control chip can receive the transmission from the master device as a virtual touch device. firmware upgrade package.
S207、主设备模块依照所述目标数据传输格式向所述芯片通信端口传输所述固件升级包。S207. The master device module transmits the firmware upgrade package to the chip communication port according to the target data transmission format.
S208、所述控制芯片向与所述芯片通信端口对应的触摸设备通信端口转送所述固件升级包,以使所述触摸设备基于所述固件升级包进行固件升级。S208. The control chip forwards the firmware upgrade package to the touch device communication port corresponding to the chip communication port, so that the touch device performs firmware upgrade based on the firmware upgrade package.
本发明实施例进一步细化了主设备模块获取控制芯片中当前USB描述符以及向控制芯片发送固件升级包的操作,并追加控制芯片的监听端口的端口值发生变化的操作,进一步完善了数据传输方法的技术方案,解决了在传输触摸设备的固件升级包的过程中,各个设备的数据交互采用的协议不同导致主设备模块无法准确向触摸设备传输固件升级包的技术问题,实现了无需进行复杂的软件开发或修改硬件框架的情况下主设备模块能够准确的向触摸设备传输固件升级包,从而在保证触摸设备能够有效进行固件升级的情况下,减少开发人员的开发维护难度,节约智能终端的硬件使用成本。The embodiment of the present invention further refines the operation of the main device module obtaining the current USB descriptor in the control chip and sending the firmware upgrade package to the control chip, and adds the operation of changing the port value of the monitoring port of the control chip, further improving data transmission The technical solution of the method solves the technical problem that the main device module cannot accurately transmit the firmware upgrade package to the touch device due to the different protocols adopted by the data interaction of each device in the process of transmitting the firmware upgrade package of the touch device, and realizes that no complicated process is required. In the case of software development or modification of the hardware framework, the main device module can accurately transmit the firmware upgrade package to the touch device, so as to ensure that the touch device can effectively upgrade the firmware, reduce the difficulty of development and maintenance for developers, and save the cost of smart terminals Hardware usage costs.
实施例三Embodiment Three
图4为本发明实施例三提供的数据传输装置的结构示意图,本实施例可适用于采用智能终端中的主设备模块中存储的固件升级包对智能终端中的触摸设备进行固件升级的情况,该装置包括:获取模块301,发送模块302以及转送模块303。FIG. 4 is a schematic structural diagram of a data transmission device provided by Embodiment 3 of the present invention. This embodiment is applicable to the case where the firmware upgrade package of the touch device in the smart terminal is upgraded by using the firmware upgrade package stored in the main device module in the smart terminal. The device includes: an acquiring module 301 , a sending module 302 and a forwarding module 303 .
其中,获取模块301,用于在主设备模块监听到控制芯片中监听端口的端口值发生改变后,获取对应于所述控制芯片的当前通用串行接口USB描述符;Wherein, the obtaining module 301 is used to obtain the current universal serial interface USB descriptor corresponding to the control chip after the master device module detects that the port value of the monitoring port in the control chip has changed;
发送模块302,用于根据所述当前USB描述符,确定与所述控制芯片通信的芯片通信端口,并基于所述芯片通信端口向所述控制芯片发送固件升级包;A sending module 302, configured to determine a chip communication port communicating with the control chip according to the current USB descriptor, and send a firmware upgrade package to the control chip based on the chip communication port;
转送模块303,用于向与所述芯片通信端口对应的触摸设备通信端口转送所述固件升级包,以使所述触摸设备基于所述固件升级包进行固件升级。The forwarding module 303 is configured to forward the firmware upgrade package to the touch device communication port corresponding to the chip communication port, so that the touch device performs firmware upgrade based on the firmware upgrade package.
本发明实施例通过主设备模块监听到控制芯片中监听端口的端口值发生改变后,获取模块301获取对应于所述控制芯片的当前USB描述符;发送模块302根据当前USB描述符,确定与控制芯片通信的芯片通信端口,并基于所述芯片通信端口向所述控制芯片发送固件升级包;转送模块303向与芯片通信端口对应的触摸设备通信端口转送固件升级包,以使所述触摸设备基于所述固件升级包进行固件升级。采用上述技术方案解决了在传输触摸设备的固件升级包的过程中,各个设备的数据交互采用的协议不同导致主设备模块无法准确向触摸设备传输固件升级包的技术问题,实现了无需进行复杂的软件开发或修改硬件框架的情况下主设备模块能够准确的向触摸设备传输固件升级包,从而在保证触摸设备能够有效进行固件升级的情况下,减少开发人员的开发维护难度,节约智能终端的硬件使用成本。In the embodiment of the present invention, after the port value of the monitoring port in the control chip is monitored by the main device module, the acquisition module 301 acquires the current USB descriptor corresponding to the control chip; the sending module 302 determines and controls the USB descriptor according to the current USB descriptor. The chip communication port of the chip communication, and send the firmware upgrade package to the control chip based on the chip communication port; the transfer module 303 forwards the firmware upgrade package to the touch device communication port corresponding to the chip communication port, so that the touch device is based on The firmware upgrade package performs firmware upgrade. The above-mentioned technical solution solves the technical problem that the main device module cannot accurately transmit the firmware upgrade package to the touch device due to the different protocols adopted for the data interaction of each device in the process of transmitting the firmware upgrade package of the touch device, and realizes the need for complicated procedures. In the case of software development or modification of the hardware framework, the main device module can accurately transmit the firmware upgrade package to the touch device, so as to ensure that the touch device can effectively upgrade the firmware, reduce the development and maintenance difficulty of developers, and save the hardware of smart terminals The cost.
进一步地,所述当前USB描述符包括:标准描述符、人机接口设备HID报告描述符以及HID设备描述符;Further, the current USB descriptor includes: a standard descriptor, a human-machine interface device HID report descriptor and a HID device descriptor;
相应的,所述发送模块302,包括:Correspondingly, the sending module 302 includes:
确定单元,用于根据所述标准描述符,确定向所述控制芯片传输所述固件升级包所需的芯片通信端口;A determining unit, configured to determine a chip communication port required for transmitting the firmware upgrade package to the control chip according to the standard descriptor;
选取单元,用于选取所述HID报告描述符中与目标报告标识码对应的报告描述符,作为传输所述固件升级包所依照的目标数据传输格式;The selection unit is used to select the report descriptor corresponding to the target report identification code in the HID report descriptor as the target data transmission format according to which the firmware upgrade package is transmitted;
发送单元,用于当所述HID设备描述符中的设备标识符与所述触摸设备的标准标识符相匹配时,依照所述目标数据传输格式向所述芯片通信端口传输所述固件升级包。A sending unit, configured to transmit the firmware upgrade package to the chip communication port according to the target data transmission format when the device identifier in the HID device descriptor matches the standard identifier of the touch device.
进一步地,该装置,还包括:Further, the device also includes:
调整模块,用于在所述控制芯片接收到触发生成的固件升级指令时,更新设定存储空间中保存的通信控制信息,并调整所述设备存储空间所对应监听端口的端口值。The adjustment module is configured to update the communication control information stored in the setting storage space and adjust the port value of the listening port corresponding to the device storage space when the control chip receives a firmware upgrade instruction generated by triggering.
进一步地,所述调整模块,包括:Further, the adjustment module includes:
第一获取单元,用于获取所述控制芯片中所存储USB描述符序列表中各USB描述符的设备标识信息;A first acquiring unit, configured to acquire the device identification information of each USB descriptor in the USB descriptor sequence table stored in the control chip;
更新单元,用于从各所述设备标识信息中查找与设定标识信息相匹配的目标设备标识信息,并将包含所述目标设备标识信息的目标USB描述符作为通信控制信息更新到所述设定存储空间中;或者,An update unit, configured to search for target device identification information that matches the set identification information from each of the device identification information, and update the target USB descriptor containing the target device identification information to the device as communication control information. in a given storage space; or,
将包含所述目标设备标识信息的目标USB描述符的本地存储地址作为通信控制信息更新到所述设定存储空间中。The local storage address of the target USB descriptor containing the target device identification information is updated into the set storage space as the communication control information.
进一步地,该装置中,所述固件升级指令为:Further, in this device, the firmware upgrade instruction is:
用户通过所述触摸设备的触摸界面触摸而产生的第一升级指令;或者,A first upgrade instruction generated by the user touching the touch interface of the touch device; or,
用户对所述主设备模块中升级控制开关键的触发而产生的第二升级指令;或者,A second upgrade instruction generated by the user triggering the upgrade control switch key in the main equipment module; or,
所述控制芯片代码逻辑实现中的模式切换标识符的标识值为升级标识值时对应产生的第三升级指令。The third upgrade instruction correspondingly generated when the identification value of the mode switching identifier in the code logic implementation of the control chip is an upgrade identification value.
进一步地,所述获取模块301,包括:Further, the acquisition module 301 includes:
发送单元,用于向所述控制芯片发送复位请求,并接收到所述控制芯片反馈的外部中断信号后,向所述控制芯片发送设备信息获取指令;A sending unit, configured to send a reset request to the control chip, and send a device information acquisition instruction to the control chip after receiving an external interrupt signal fed back by the control chip;
第二获取单元,用于获取所述控制芯片基于设备信息获取指令反馈的所述当前USB描述符;a second acquiring unit, configured to acquire the current USB descriptor fed back by the control chip based on a device information acquisition instruction;
其中,所述当前USB描述符通过所述通信控制信息确定Wherein, the current USB descriptor is determined through the communication control information
上述数据传输装置可执行本发明任意实施例所提供数据传输方法,具备执行数据传输方法相应的功能模块和有益效果。The above-mentioned data transmission device can execute the data transmission method provided by any embodiment of the present invention, and has corresponding functional modules and beneficial effects for executing the data transmission method.
可以理解的是,针对图1A中的具备触摸设备的智能终端的结构示意图,获取模块301可配置于主设备模块中;发送模块302可配置于主设备模块中;转送模块303可配置于控制芯片中;调整模块可配置于控制芯片中。It can be understood that, for the schematic structural diagram of an intelligent terminal equipped with a touch device in FIG. 1A , the acquisition module 301 can be configured in the main device module; the sending module 302 can be configured in the main device module; the transfer module 303 can be configured in the control chip Medium; the adjustment module can be configured in the control chip.
实施例四Embodiment four
图5为本发明实施例四提供的一种终端的结构示意图,如图5所示,本发明实施例四提供的终端,包括:输入装置401、处理器402以及存储装置403。其中,输入装置401用于接收触摸设备供应商的固件升级包。该终端中的处理器可以是一个或多个。图5中以一个处理器402为例,所述终端中的输入装置401可以通过总线或其他方式处理器402以及存储装置403相连,且处理器402和存储装置403也通过总线或其他方式连接,图5中以通过总线连接为例。FIG. 5 is a schematic structural diagram of a terminal provided in Embodiment 4 of the present invention. As shown in FIG. 5 , the terminal provided in Embodiment 4 of the present invention includes: an input device 401 , a processor 402 and a storage device 403 . Wherein, the input device 401 is used for receiving a firmware upgrade package from a touch device supplier. There may be one or more processors in the terminal. In FIG. 5, a processor 402 is taken as an example. The input device 401 in the terminal can be connected to the processor 402 and the storage device 403 through a bus or other methods, and the processor 402 and the storage device 403 are also connected through a bus or other methods. In Fig. 5, the bus connection is taken as an example.
在本实施例中,终端中的处理器402可以监听控制芯片中监听端口的端口值是否发生变化;还可以获取控制芯片中的当前USB描述符;还可以根据当前USB描述符确定控制芯片的芯片通信端口;还可以基于芯片通信端口向控制芯片发送固件升级包。In this embodiment, the processor 402 in the terminal can monitor whether the port value of the monitoring port in the control chip changes; it can also obtain the current USB descriptor in the control chip; it can also determine the chip number of the control chip according to the current USB descriptor. Communication port; it is also possible to send a firmware upgrade package to the control chip based on the chip communication port.
该终端中的存储装置403作为一种计算机可读存储介质,可用于存储一个或多个程序,所述程序可以是软件程序、计算机可执行程序以及模块,如本发明实施例中数据传输方法对应的程序指令/模块(例如,附图4所示的数据传输装置中的模块,包括:获取模块301,发送模块302以及转送模块303)。处理器402通过运行存储在存储装置403中的软件程序、指令以及模块,从而执行终端的各种功能应用以及数据处理,即实现上述方法实施例中数据传输方法。The storage device 403 in the terminal, as a computer-readable storage medium, can be used to store one or more programs, and the programs can be software programs, computer-executable programs, and modules, such as the corresponding data transmission method in the embodiment of the present invention program instructions/modules (for example, modules in the data transmission device shown in FIG. 4 , including: acquiring module 301, sending module 302 and forwarding module 303). The processor 402 executes various functional applications and data processing of the terminal by running software programs, instructions and modules stored in the storage device 403 , that is, implements the data transmission method in the above method embodiments.
存储装置403可包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序;存储数据区可存储根据设备的使用所创建的数据等(如上述实施例中的固件升级包、各USB描述符、USB描述符序列表、目标报告标识码以及标准标识符等)。此外,存储装置403可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他非易失性固态存储器件。在一些实例中,存储装置403可进一步包括相对于处理器402远程设置的存储器,这些远程存储器可以通过网络连接至设备。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。The storage device 403 may include a program storage area and a data storage area, wherein the program storage area may store an operating system and an application program required by at least one function; the data storage area may store data created according to the use of the device, etc. The firmware upgrade package in the example, each USB descriptor, USB descriptor sequence list, target report identification code and standard identifier, etc.). In addition, the storage device 403 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid-state storage devices. In some examples, the storage device 403 may further include memories that are remotely located relative to the processor 402, and these remote memories may be connected to the device through a network. Examples of the aforementioned networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
此外,本发明实施例还提供一种计算机可读存储介质,其上存储有计算机程序,该程序被数据传输装置执行时实现本发明实施例一或实施例二提供的数据传输方法,该方法包括:主设备模块监听到控制芯片中监听端口的端口值发生改变后,获取对应于所述控制芯片的当前通用串行接口USB描述符;所述主设备模块根据所述当前USB描述符,确定与所述控制芯片通信的芯片通信端口,并基于所述芯片通信端口向所述控制芯片发送固件升级包;所述控制芯片向与所述芯片通信端口对应的触摸设备通信端口转送所述固件升级包,以使所述触摸设备基于所述固件升级包进行固件升级。In addition, an embodiment of the present invention also provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a data transmission device, the data transmission method provided in Embodiment 1 or Embodiment 2 of the present invention is implemented. The method includes : After the main equipment module detects that the port value of the monitoring port in the control chip changes, it obtains the current universal serial interface USB descriptor corresponding to the control chip; the main equipment module determines the corresponding USB descriptor according to the current USB descriptor. The chip communication port of the control chip communication, and send a firmware upgrade package to the control chip based on the chip communication port; the control chip forwards the firmware upgrade package to the touch device communication port corresponding to the chip communication port , so that the touch device performs firmware upgrade based on the firmware upgrade package.
通过以上关于实施方式的描述,所属领域的技术人员可以清楚地了解到,本发明可借助软件及必需的通用硬件来实现,当然也可以通过硬件实现,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品可以存储在计算机可读存储介质中,如计算机的软盘、只读存储器(Read-Only Memory,ROM)、随机存取存储器(RandomAccess Memory,RAM)、闪存(FLASH)、硬盘或光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本发明各个实施例所述的方法。Through the above description about the implementation mode, those skilled in the art can clearly understand that the present invention can be realized by means of software and necessary general-purpose hardware, and of course it can also be realized by hardware, but in many cases the former is a better implementation mode . Based on this understanding, the essence of the technical solution of the present invention or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as a floppy disk of a computer , read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), flash memory (FLASH), hard disk or optical disc, etc., including several instructions to make a computer device (which can be a personal computer, A server, or a network device, etc.) executes the methods described in various embodiments of the present invention.
注意,上述仅为本发明的较佳实施例及所运用技术原理。本领域技术人员会理解,本发明不限于这里所述的特定实施例,对本领域技术人员来说能够进行各种明显的变化、重新调整和替代而不会脱离本发明的保护范围。因此,虽然通过以上实施例对本发明进行了较为详细的说明,但是本发明不仅仅限于以上实施例,在不脱离本发明构思的情况下,还可以包括更多其他等效实施例,而本发明的范围由所附的权利要求范围决定。Note that the above are only preferred embodiments of the present invention and applied technical principles. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and that various obvious changes, readjustments and substitutions can be made by those skilled in the art without departing from the protection scope of the present invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the above embodiments, and can also include more other equivalent embodiments without departing from the concept of the present invention, and the present invention The scope is determined by the scope of the appended claims.
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201810203509.4ACN108366131B (en) | 2018-03-13 | 2018-03-13 | Data transmission method, device, terminal and storage medium |
| PCT/CN2018/118087WO2019174307A1 (en) | 2018-03-13 | 2018-11-29 | Data transmission method and apparatus, terminal and storage medium |
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201810203509.4ACN108366131B (en) | 2018-03-13 | 2018-03-13 | Data transmission method, device, terminal and storage medium |
| Publication Number | Publication Date |
|---|---|
| CN108366131Atrue CN108366131A (en) | 2018-08-03 |
| CN108366131B CN108366131B (en) | 2020-10-02 |
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN201810203509.4AActiveCN108366131B (en) | 2018-03-13 | 2018-03-13 | Data transmission method, device, terminal and storage medium |
| Country | Link |
|---|---|
| CN (1) | CN108366131B (en) |
| WO (1) | WO2019174307A1 (en) |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2019174307A1 (en)* | 2018-03-13 | 2019-09-19 | 广州视源电子科技股份有限公司 | Data transmission method and apparatus, terminal and storage medium |
| CN111221009A (en)* | 2018-11-23 | 2020-06-02 | 青岛海信移动通信技术股份有限公司 | Switching method of positioning chip, mobile terminal and computer storage medium |
| CN114153368A (en)* | 2021-12-07 | 2022-03-08 | Oppo广东移动通信有限公司 | Application control method and system |
| CN114185609A (en)* | 2021-11-04 | 2022-03-15 | 深圳市德明利技术股份有限公司 | Method and device for processing equipment configuration information, storage medium and processor |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN102033770A (en)* | 2010-12-17 | 2011-04-27 | 中兴通讯股份有限公司 | Touch screen firmware upgrading method and device for mobile terminal |
| CN102646048A (en)* | 2012-05-03 | 2012-08-22 | 中兴通讯股份有限公司 | Method for upgrading firmware of touch screen of mobile terminal and device |
| CN102750155A (en)* | 2011-04-19 | 2012-10-24 | 鸿富锦精密工业(深圳)有限公司 | Control board for updating firmware as well as firmware updating system and method |
| CN103577213A (en)* | 2012-08-09 | 2014-02-12 | 深圳市中兴移动通信有限公司 | Method for upgrading touch screen firmware of intelligent terminal |
| CN105094880A (en)* | 2014-05-23 | 2015-11-25 | 中兴通讯股份有限公司 | USB driving method, computer and compound equipment |
| CN106168863A (en)* | 2015-05-19 | 2016-11-30 | 义隆电子股份有限公司 | Computer device with touch control chip and updating method of touch control chip |
| CN106502743A (en)* | 2016-11-01 | 2017-03-15 | 捷开通讯(深圳)有限公司 | The upgrade method of the touch-screen firmware of electronic equipment and update device, electronic equipment |
| CN107368219A (en)* | 2017-07-12 | 2017-11-21 | 广州视源电子科技股份有限公司 | Touch response method, chip and intelligent device |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| KR20130087747A (en)* | 2012-01-30 | 2013-08-07 | 삼성전자주식회사 | Display apparatus, upgrade apparatus, display system including the same and the control method thereof |
| CN105718281B (en)* | 2015-07-29 | 2019-04-12 | 中科创达软件科技(深圳)有限公司 | A kind of touch screen firmware upgrade method and device |
| CN108366131B (en)* | 2018-03-13 | 2020-10-02 | 广州视源电子科技股份有限公司 | Data transmission method, device, terminal and storage medium |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN102033770A (en)* | 2010-12-17 | 2011-04-27 | 中兴通讯股份有限公司 | Touch screen firmware upgrading method and device for mobile terminal |
| WO2012079301A1 (en)* | 2010-12-17 | 2012-06-21 | 中兴通讯股份有限公司 | Method and device for upgrading touch screen firmware of mobile terminal |
| CN102750155A (en)* | 2011-04-19 | 2012-10-24 | 鸿富锦精密工业(深圳)有限公司 | Control board for updating firmware as well as firmware updating system and method |
| CN102646048A (en)* | 2012-05-03 | 2012-08-22 | 中兴通讯股份有限公司 | Method for upgrading firmware of touch screen of mobile terminal and device |
| CN103577213A (en)* | 2012-08-09 | 2014-02-12 | 深圳市中兴移动通信有限公司 | Method for upgrading touch screen firmware of intelligent terminal |
| CN105094880A (en)* | 2014-05-23 | 2015-11-25 | 中兴通讯股份有限公司 | USB driving method, computer and compound equipment |
| CN106168863A (en)* | 2015-05-19 | 2016-11-30 | 义隆电子股份有限公司 | Computer device with touch control chip and updating method of touch control chip |
| CN106502743A (en)* | 2016-11-01 | 2017-03-15 | 捷开通讯(深圳)有限公司 | The upgrade method of the touch-screen firmware of electronic equipment and update device, electronic equipment |
| CN107368219A (en)* | 2017-07-12 | 2017-11-21 | 广州视源电子科技股份有限公司 | Touch response method, chip and intelligent device |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2019174307A1 (en)* | 2018-03-13 | 2019-09-19 | 广州视源电子科技股份有限公司 | Data transmission method and apparatus, terminal and storage medium |
| CN111221009A (en)* | 2018-11-23 | 2020-06-02 | 青岛海信移动通信技术股份有限公司 | Switching method of positioning chip, mobile terminal and computer storage medium |
| CN111221009B (en)* | 2018-11-23 | 2023-10-13 | 青岛海信移动通信技术有限公司 | Switching method of positioning chip, mobile terminal and computer storage medium |
| CN114185609A (en)* | 2021-11-04 | 2022-03-15 | 深圳市德明利技术股份有限公司 | Method and device for processing equipment configuration information, storage medium and processor |
| CN114153368A (en)* | 2021-12-07 | 2022-03-08 | Oppo广东移动通信有限公司 | Application control method and system |
| Publication number | Publication date |
|---|---|
| CN108366131B (en) | 2020-10-02 |
| WO2019174307A1 (en) | 2019-09-19 |
| Publication | Publication Date | Title |
|---|---|---|
| CN108366131B (en) | Data transmission method, device, terminal and storage medium | |
| CN103412769B (en) | External card parameter configuration, equipment and system | |
| JP7562661B2 (en) | Software upgrade method, apparatus and system | |
| US8650332B2 (en) | Method for switching working mode, USB device, and host device | |
| CN111203874A (en) | Robot control method, device, electronic device and storage medium | |
| EP2840455A1 (en) | Method, apparatus and system for intelligently controlling device, and plug-and-play device | |
| US20100023602A1 (en) | Method and apparatus for updating information on an embedded system | |
| US12120759B2 (en) | Data transmission method, data transmission apparatus, and electronic device | |
| WO2019024754A1 (en) | Page loading method, device, and system | |
| JP7547636B2 (en) | Parameter configuration method, device, and system | |
| CN103383669A (en) | Method for identifying universal serial bus host, and electronic device thereof | |
| US12206261B2 (en) | Control method, electronic device, and writing interaction device | |
| CN108199931A (en) | A kind of household electric appliance control method and system | |
| EP3188446B1 (en) | Remote resource access method and switching device | |
| WO2021018208A1 (en) | Firmware upgrade method and apparatus, electronic device, and storage medium | |
| CN106416196A (en) | Mobile terminal, power adapter and upgrading method thereof | |
| CN115080091A (en) | Method and system for upgrading MCU firmware on line by satellite communication equipment | |
| CN111930678A (en) | Data transmission method and device, electronic equipment and storage medium | |
| WO2018003841A1 (en) | Serial communication method and sensor controller | |
| CN110995462B (en) | Cloud host function expansion method, system, equipment and computer storage medium | |
| WO2025118547A1 (en) | Interaction data transmission method, system and apparatus, storage medium and electronic device | |
| CN101998691B (en) | Method, system and device for data transmission | |
| CN117369896A (en) | Information acquisition system and method | |
| WO2025025382A1 (en) | Method and apparatus for controlling peripheral device of head unit, and vehicle, system and storage medium | |
| WO2024037376A1 (en) | Service management method and apparatus, device and readable storage medium |
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant |