Touch screen firmware loading method, device, electronic device and storage medium

By detecting the switching of the touch screen working mode and loading the corresponding touch screen firmware, the problem of too long loading time caused by excessive firmware files is solved, and the response speed of the touch screen is improved.

CN114286979BActive Publication Date: 2025-04-01SHENZHEN HEYTAP TECHNOLOGY CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN201980099751.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-11-18
Publication Date
2025-04-01
Estimated Expiration
2039-11-18

AI Technical Summary

Technical Problem

The excessively large touch screen firmware file takes a long time to load from the system memory to the touch screen memory, resulting in a reduced response speed of the touch screen.

Method used

By detecting whether the working mode of the touch screen has been switched, if the switching occurs, the touch screen firmware corresponding to the current working mode is obtained as the firmware to be loaded and loaded into the touch screen memory.

Benefits of technology

Reduces the firmware size loaded to the touch screen memory, increases the loading speed, and enhances the touch screen's response speed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114286979B_ABST
    Figure CN114286979B_ABST
Patent Text Reader

Abstract

The present application discloses a touch screen firmware loading method, device, electronic device and storage medium, and relates to the field of data processing technology. The method includes detecting whether the working mode of the touch screen is switched; if the working mode of the touch screen is switched, obtaining the touch screen firmware corresponding to the current working mode as the firmware to be loaded, wherein different working modes of the touch screen correspond to different touch screen firmware; loading the firmware to be loaded into the touch screen memory, thereby improving the speed of loading the touch screen firmware into the touch screen memory.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of electronic devices, and more specifically, to a touch screen firmware loading method, device, electronic device and storage medium. Background Art

[0002] With the development of technology, the functions of electronic devices are constantly enhanced, and the touch operations supported by the touch screen of electronic devices are becoming more and more complicated, so the firmware files of the touch screen are constantly increasing. When loading an oversized firmware file from the system memory to the touch screen memory, it will take a long time, which will reduce the response speed of the touch screen. Summary of the invention

[0003] In view of the above problems, the present application proposes a touch screen firmware loading method, device, electronic device and storage medium to improve the above problems.

[0004] In a first aspect, an embodiment of the present application provides a touch screen firmware loading method, the method comprising: detecting whether the working mode of the touch screen switches; if the working mode of the touch screen switches, obtaining the touch screen firmware corresponding to the current working mode as the firmware to be loaded, wherein different working modes of the touch screen correspond to different touch screen firmware; and loading the obtained firmware to be loaded into the touch screen memory.

[0005] In the second aspect, an embodiment of the present application provides a touch screen firmware loading device, which includes: a detection module, used to detect whether the working mode of the touch screen is switched; a firmware acquisition module, used to obtain the touch screen firmware corresponding to the current working mode as the firmware to be loaded if the working mode of the touch screen is switched, wherein different working modes of the touch screen correspond to different touch screen firmware; a loading module, used to load the firmware to be loaded into the touch screen memory.

[0006] In a third aspect, an embodiment of the present application provides an electronic device, including: one or more processors;

[0007] A system memory; a touch screen memory; and one or more programs, wherein the one or more programs are stored in the system memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute the above method.

[0008] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, in which a program code is stored. The program code can be called by a processor to execute the above method.

[0009] The touch screen firmware loading method, device, electronic device and storage medium provided in the embodiments of the present application load the touch screen firmware according to the current working mode of the touch screen. When the working mode of the touch screen is switched, only the touch screen firmware of the current working mode is loaded into the touch screen memory, thereby improving the speed of loading the touch screen firmware into the touch screen memory. BRIEF DESCRIPTION OF THE DRAWINGS

[0010] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.

[0011] Figure 1 A flow chart of a touch screen firmware loading method provided in an embodiment of the present application is shown.

[0012] Figure 2 A flowchart of a touch screen firmware loading method provided by another embodiment of the present application is shown.

[0013] Figure 3 A schematic diagram of a firmware file provided in an embodiment of the present application is shown.

[0014] Figure 4 Another schematic diagram of a firmware file provided in an embodiment of the present application is shown.

[0015] Figure 5 A flowchart of a touch screen firmware loading method provided by another embodiment of the present application is shown.

[0016] Figure 6 A functional module diagram of a touch screen firmware loading device provided in an embodiment of the present application is shown.

[0017] Figure 7 A structural block diagram of an electronic device provided in an embodiment of the present application is shown.

[0018] Figure 8 It is a storage unit of the embodiment of the present application for storing or carrying a program code for implementing the touch screen firmware loading method according to the embodiment of the present application. DETAILED DESCRIPTION

[0019] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application.

[0020] Firmware is the software that performs the most basic and lowest-level work of a system. It refers to the device "driver" stored inside the device. Through firmware, the operating system can implement the operation of a specific machine according to the standard device driver. For example, for the touch screen of an electronic device, the touch screen can be driven by loading firmware in the touch screen memory, so that various touch operations can be performed on the touch screen. The touch screen memory is the memory of the touch screen system, which is used to store data related to the touch screen operation.

[0021] The inventors have found that the touch screen of some electronic devices reacts slowly when the screen is turned on. For example, there is a significant time difference between the time when the screen of the electronic device actually turns on and the time when the user turns on the screen, which greatly affects the user experience.

[0022] After studying the problem of screen lag in some electronic devices, the inventor found that the electronic devices with screen lag are usually those whose touch screen storage does not have its own flash memory. For such electronic devices, the terminal system needs to load the firmware into the touch screen storage every time the screen is turned on. However, since the touch screen can support many functions, the firmware loaded into the touch screen storage is large, and the communication interface rate during the loading process is limited, the loading time process causes the touch screen to be delayed.

[0023] In order to solve this problem, the inventor further studied and found that the touch screen may have more than one working mode, for example, there may be a normal use mode for users, a test mode for developers to test the performance of the touch screen, a working mode corresponding to the screen on, and a working mode corresponding to the screen off. The touch screen firmware for different working modes is usually integrated together as a firmware file, which is large and takes too long to load. The touch screen of the electronic device actually uses different touch screen firmware in different working modes, that is, in one working mode, the loaded touch screen firmware file includes the touch screen firmware for all working modes.

[0024] Therefore, the inventors have proposed a touch screen firmware loading method according to an embodiment of the present application. Each time the working mode of the touch screen is switched, the touch screen firmware corresponding to the current working mode is loaded into the touch screen memory, thereby reducing the size of the firmware loaded into the touch screen memory and increasing the loading speed. The touch screen firmware loading method, device, electronic device and storage medium provided by the embodiment of the present application will be described in detail below through specific embodiments.

[0025] See also Figure 1 , shows a touch screen firmware loading method provided in an embodiment of the present application. The method can be applied to a central processor of an electronic device, and the embodiment of the present application is described by taking a mobile phone as an example. Specifically, the method includes:

[0026] Step S110: Detect whether the working mode of the touch screen is switched.

[0027] The touch screen has different responses to touch operations on the touch screen in different working modes, and is driven by different touch screen firmware. Therefore, it is possible to detect whether the working mode of the touch screen has been switched.

[0028] Step S120: if the working mode of the touch screen is switched, the touch screen firmware corresponding to the current working mode is obtained as the firmware to be loaded, wherein different working modes of the touch screen correspond to different touch screen firmware.

[0029] In the touch screen memory, the touch screen firmware of the working mode in operation is stored. When the working mode is switched, the touch screen firmware of the new working mode can be used to drive the touch screen. Therefore, after the working mode is switched, the touch screen firmware corresponding to the current working mode can be obtained, that is, the touch screen firmware of the switched working mode is obtained. In the embodiment of the present application, for the convenience of description, the touch screen firmware corresponding to the current working mode obtained is defined as the firmware to be loaded.

[0030] Step S130: loading the firmware to be loaded into the touch screen memory.

[0031] The touch screen firmware of the current working mode is loaded into the touch screen memory, and the touch screen is driven by the loaded touch screen firmware to respond to the touch operation in the current working mode.

[0032] In the embodiment of the present application, since only the touch screen firmware of the current working mode is loaded into the touch screen memory when the working mode is switched, there is no need to load the firmware file supporting all working modes of the touch screen into the touch screen memory, which reduces the loading time and improves the response speed of the touch screen.

[0033] Another embodiment of the present application provides a touch screen firmware loading method. In the touch screen firmware loading method of this embodiment, the firmware files corresponding to different working modes are obtained by splitting the firmware files. For details, see Figure 2 , the method comprising:

[0034] Step S210: split the firmware file to obtain touch screen firmware corresponding to different mode identifiers.

[0035] The electronic device can obtain a firmware file for driving the touch screen and store it in a system memory, wherein the firmware file includes firmware for driving all working modes of the touch screen, that is, all touch screen firmware corresponding to all working modes of the touch screen are stored in the system memory as a firmware file. The system memory is electrically connected to the central processor and is different from the touch screen memory.

[0036] The electronic device may obtain the firmware file from a server. For example, when the electronic device system is upgraded, the upgraded version of the firmware file for the touch screen driver is obtained from the server. The electronic device may also obtain the firmware file from other electronic devices.

[0037] After the electronic device obtains the firmware file, since the firmware file includes the touch screen firmware of each working mode, the firmware file can be split to obtain the touch screen firmware corresponding to each working mode.

[0038] In the embodiment of the present application, different working modes correspond to different mode identifiers, that is, the mode identifier corresponds to the working mode one by one, and the mode identifier corresponding to the working mode indicates the identity of the working mode. Therefore, after splitting the firmware, touch screen firmware corresponding to different mode identifiers can be obtained.

[0039] In an embodiment of the present application, data of touch screen firmware of the same working mode in a firmware file can be stored adjacently. The firmware file can be split by reading from the beginning of the firmware file and obtaining the size of the touch screen firmware currently read. During the reading process, it is detected whether the size of the read file is equal to the size of the touch screen firmware currently read.

[0040] If the currently read file is not equal to the size of the currently read touch screen firmware, continue to read the firmware file until the currently read file is equal to the size of the currently read touch screen firmware. If the currently read file is equal to the size of the currently read touch screen firmware, the currently read touch screen firmware can be split from the firmware file to obtain a split touch screen firmware. Continue to read the remaining firmware files until the firmware file is finished reading.

[0041] For example Figure 3 It represents a firmware file. In the firmware file, A and B are different working modes. Touch screen firmware A starts from a1 and ends at an, and touch screen firmware B starts from b1 and ends at bn. Read from the beginning of the firmware file, that is, read from a1. During the reading process, detect whether the read file size is equal to the size of touch screen firmware A. When an is read, it can be detected that the read file size is equal to the size of touch screen firmware A, then file A is split from the firmware file to obtain touch screen firmware A. Continue to read the remaining firmware files from b1, and when bn is read, it can be detected that the read file size is equal to the size of touch screen firmware B, then file B is split from the firmware file to obtain touch screen firmware B.

[0042] Optionally, in the first implementation, if the sizes of touch screen firmwares in different working modes are consistent, the size of the touch screen firmware in each working mode may be determined according to the firmware file size and the number of working modes.

[0043] Optionally, in the second embodiment, the sizes of the touch screen firmware of each working mode may be different. The size of the touch screen firmware can be stored in a related field at the beginning of each touch screen firmware in the firmware file, and then during the reading of the firmware file, it can be determined whether the read file size is equal to the size of the touch screen firmware being read.

[0044] Optionally, in a third implementation, the touch screen firmware of each working mode may have a unique firmware identifier, and a configuration file may be provided to store the correspondence between different firmware identifiers and the size of the touch screen firmware, and the data size corresponding to each firmware identifier is equal to the size of the touch screen firmware corresponding to the firmware identifier. In the firmware file, the firmware identifier of the touch screen firmware is stored in the relevant field at the beginning of each touch screen firmware, and the size of the touch screen firmware being read can be obtained based on the firmware identifier, so as to determine whether the read file is equal to the size of the touch screen firmware normally read.

[0045] In addition, in the embodiment of the present application, after splitting the firmware file, touch screen firmware corresponding to different mode identifiers can be obtained.

[0046] In one implementation, the touch screen firmware has different data in different working modes, and the firmware sizes of different touch screen firmware are different. Therefore, a corresponding relationship between the mode identifiers and the firmware sizes of different working modes can be set, and the firmware size corresponding to each mode identifier indicates the size of the touch screen firmware of the mode identifier. Therefore, the mode identifier corresponding to each touch screen firmware can be determined according to the corresponding relationship between the mode identifier and the firmware size, and the size of each split touch screen firmware.

[0047] In another embodiment, each of the split touch screen firmware includes a firmware identifier of the touch screen firmware. In addition, a configuration file that stores the correspondence between the firmware identifier and the mode identifier is stored. Therefore, the firmware identifier of each of the split touch screen firmware can be obtained, and the mode identifier corresponding to each touch screen firmware can be determined according to the correspondence between the firmware identifier and the mode identifier, thereby determining the touch screen firmware corresponding to each working mode.

[0048] In the embodiment of the present application, when the firmware file is updated, the new firmware file needs to be split again. Therefore, it is also possible to detect whether a new firmware file is obtained. If a new firmware file is obtained, the touch screen firmware corresponding to each mode identifier is re-determined according to the new firmware file.

[0049] In one implementation, when a new firmware file is obtained, the firmware file can be split again to obtain the split touch screen firmwares, and then the touch screen firmware corresponding to the mode identifier is updated. The specific implementation of this implementation can refer to the above embodiment, which will not be repeated here.

[0050] In another implementation manner, after the firmware file is updated, not all touch screen firmware may be updated, and therefore, only the updated touch screen firmware may be re-established with the corresponding relationship between the mode identifier.

[0051] Specifically, in this implementation, the update part in the new firmware file can be determined. The update part may belong to one touch screen firmware, or multiple touch screen firmwares, and the touch screen firmware corresponding to the update part can be separated from the new firmware file. The touch screen firmware corresponding to the update part is the touch screen firmware to which the update part belongs.

[0052] A unique correspondence between the split touch screen firmware and the mode identifier is then established, and the correspondence between the newly corresponding mode identifier and the old touch screen firmware is overwritten or cancelled.

[0053] For example Figure 4 As shown, in the new firmware file, the firmware data in the interval a4 to a5 is updated, and it can be determined that the firmware data in the interval a4 to a5 is the data of the touch screen firmware A. Then, the touch screen firmware A can be separated from the new firmware file, and a unique correspondence is established between the touch screen firmware A and the mode identifier of the corresponding working mode. The touch screen firmware that has not been updated in the firmware file does not need to be separated from the touch screen firmware.

[0054] In the embodiment of the present application, after the firmware file is split into each touch screen firmware, the obtained touch screen firmware can be used to load into the touch screen memory in the subsequent steps. If the firmware file is not updated, this step can be skipped, and steps S220 to S240 can be executed cyclically.

[0055] Step S220: Detect whether the working mode of the touch screen is switched.

[0056] In the embodiment of the present application, the trigger of the mode switch may be a trigger mode switch operation of the user on the touch screen, such as triggering a switch from the use mode to the test mode; the trigger of the mode switch may also be receiving a switching operation through a hardware interface electrically connected to the outside, such as entering the test mode when a test device is detected to be connected through the hardware interface, and exiting the test mode and entering the use mode when the test device is detected to be unplugged from the hardware interface; the trigger of the mode switch may also be receiving a switching instruction through wireless data transmission; the mode switch may also be that the electronic device has a physical control that receives a switching operation, such as switching the screen on or off through the power button of the electronic device, when the electronic device switches from the screen on to the screen off, the working mode is switched from the working mode under the screen on to the working mode under the screen off, and the electronic device switches from the screen off to the screen on, and the working mode is switched from the working mode under the screen off to the working mode under the screen on. The trigger of the specific mode switch is not limited in the embodiment of the present application.

[0057] In the embodiment of the present application, it is possible to detect whether the working mode is switched, and when the working mode switching is detected, the working mode after the switch can be obtained.

[0058] The specific detection method is not limited in the embodiments of the present application. As an implementation method, when each mode switch is triggered, a broadcast can be sent to the broadcast management service, and the broadcast includes the switching event and the working mode after the switch. It can be determined whether the working mode of the touch screen is switched and the working mode after the switch based on whether the broadcast manager receives the broadcast of the mode switch.

[0059] As another implementation, the current working mode of the touch screen can be detected at a certain frequency. During each detection, it is determined whether the currently detected working mode is the same as the previously detected working mode. If they are the same, it means that no working mode switch has occurred; if they are different, it can be determined that the working mode of the touch screen has switched.

[0060] In addition, in some special cases, if the touch screen of the electronic device enters the working mode from the non-working mode, it is also determined as the working mode switching. For example, after the electronic device is turned on from the off state, it enters the working mode after the power-on state, which is determined as the working mode switching of the touch screen.

[0061] Step S230: if the working mode of the touch screen is switched, the touch screen firmware corresponding to the current working mode is obtained as the firmware to be loaded according to the corresponding relationship between the mode identifier and the touch screen firmware.

[0062] Different working modes of the touch screen correspond to different touch screen firmware. After determining that the mode has switched and determining the current working mode, the touch screen firmware corresponding to the mode identifier of the current working mode can be obtained according to the correspondence between the mode identifier and the touch screen firmware, and defined as the firmware to be loaded. For example, in the correspondence between the mode identifier and the touch screen firmware, the mode identifier M1 corresponds to the touch screen firmware m1, the mode identifier M2 corresponds to the touch screen firmware m2, and the mode identifier of the current working mode is M1, then the firmware m1 to be loaded can be determined. Among them, it can be understood that the current working mode is the working mode after switching.

[0063] Optionally, in the embodiment of the present application, in order to determine whether there is touch screen firmware corresponding to the current working mode, before obtaining the touch screen firmware corresponding to the current working mode, it can be determined whether the touch screen firmware corresponding to the current working mode is stored. If yes, the touch screen firmware corresponding to the current working mode can be obtained.

[0064] The judgment method may be to judge whether there is a mode identifier of the current working mode in the corresponding relationship between the mode identifier and the touch screen firmware. If so, it is determined that the current working mode corresponds to the touch screen firmware.

[0065] If the touch screen firmware corresponding to the current working mode is not stored, in one embodiment, a prompt message that the current working mode is not supported can be displayed. In another embodiment, a firmware acquisition request can be initiated to the server to obtain the touch screen firmware corresponding to the current working mode. Optionally, the server may return a firmware file, which includes the touch screen firmware corresponding to the current working mode and the touch screen firmware for other working modes. The received firmware file is split to obtain the touch screen firmware corresponding to each working mode, and then the touch screen firmware corresponding to the current working mode is obtained. Optionally, the server may also return the touch screen firmware corresponding to the requested current working mode. If the touch screen firmware returned by the server is received, the touch screen firmware corresponding to the current working mode can be obtained.

[0066] Step S240: loading the firmware to be loaded into the touch screen memory.

[0067] The central processor loads the firmware to be loaded into the touch screen memory. Specifically, the terminal system of the electronic device can load the firmware to be loaded into the touch screen memory. The touch screen firmware stored in the touch screen memory is updated to the touch screen firmware of the current working mode.

[0068] In the embodiment of the present application, the obtained firmware file is split to obtain the touch screen firmware corresponding to each working mode. When the working mode of the electronic device is switched, the touch screen firmware corresponding to the switched working mode can be obtained, and only the touch screen firmware of the switched working mode is loaded into the touch screen memory, thereby increasing the loading speed and thus increasing the response speed of the touch screen.

[0069] The present application also provides an embodiment. In this embodiment, an example is given of how the touch screen firmware of an electronic device is loaded when a specific working mode is switched. In this embodiment, the working mode of the touch screen may include a working mode with the screen on and a working mode with the screen off. The working mode with the screen on refers to the feedback of the touch screen on a touch operation when the electronic device is in the screen-on state; the working mode with the screen off refers to the feedback of the touch screen on a touch operation when the electronic device is in the screen-off state, such as the gesture wake-up function when the screen is off. Specifically, in this embodiment, the touch screen firmware loading method specifically includes:

[0070] Step S310: Detect whether the on / off state of the touch screen switches. If the on / off state of the touch screen switches, it is determined that the working mode of the touch screen switches.

[0071] The touch screen includes a working mode when the screen is on and a working mode when the screen is off. It can be determined whether the working mode of the touch screen is switched according to the on and off state of the touch screen.

[0072] If the touch screen switches from the screen on to the screen off, it is determined that the working mode is switched from the screen on working mode to the screen off working mode; if the touch screen switches from the screen off to the screen on, it is determined that the working mode is switched from the screen off working mode to the screen on working mode.

[0073] Optionally, the electronic device needs to undergo a touch screen performance test before leaving the factory, and may also need to undergo a touch screen performance test during after-sales inspection and repair. In the embodiment of the present application, the touch screen may also have a test mode for performance testing and a usage mode for ordinary users. In addition, the test mode can be divided into a test mode with the screen on and a test mode with the screen off; the usage mode can be divided into a usage mode with the screen on and a usage mode with the screen off.

[0074] Therefore, in one embodiment, detecting whether the working mode of the touch screen has switched may include, if a test trigger operation is received and the screen is currently in a light-on state, determining that the working mode of the touch screen is switched to a test mode with the screen on. If a test trigger operation is received and the screen is currently in an off-screen state, determining that the working mode of the touch screen is switched to a test mode with the screen off. If a test exit operation is received and the screen is currently in a light-on state, determining that the working mode of the touch screen is switched to a usage mode with the screen on. If a test exit operation is received and the screen is currently in an off-screen state, determining that the working mode of the touch screen is switched to a usage mode with the screen off. Among them, the test trigger operation is an operation to control the touch screen to enter a test mode, and the test exit operation is an operation to control the touch screen to exit a test mode and enter a usage mode.

[0075] In this embodiment, the electronic device can receive the test trigger operation and the test exit operation through a hardware interface electrically connected to the outside, or can receive the test trigger operation and the test exit operation by receiving a wireless signal, so that the electronic device can be controlled to switch between the test mode and the use mode regardless of whether the screen is in the off state or the on state.

[0076] In another embodiment, the test trigger operation and test exit operation of the electronic device need to be triggered by relevant controls when the screen is on, then detecting whether the working mode of the touch screen is switched may include: if a test trigger operation is received, entering the test mode under the bright screen, and before receiving the test exit operation, if the touch screen is switched to the screen-off state, entering the test mode under the screen-off state, and if it is switched from the screen-off state to the screen-on state, entering the test mode under the screen-on state; if a test exit operation is received, entering the usage mode under the bright screen, and before receiving the test trigger operation, if the touch screen is switched to the screen-off state, entering the usage mode under the screen-off state, and if it is switched from the screen-off state to the screen-on state, entering the usage mode under the screen-on state.

[0077] Step S320: If the working mode of the touch screen is switched, the touch screen firmware corresponding to the current working mode is obtained as the firmware to be loaded.

[0078] When the touch screen switches from the on screen to the off screen, the touch screen firmware of the working mode in the off screen state is obtained; if the touch screen switches from the off screen to the on screen, the touch screen firmware of the working mode in the on screen state is obtained.

[0079] If the working mode of the touch screen includes a test mode and a use mode with the screen on, and a test mode and a use mode with the screen off, then if the current working mode is the test mode with the screen on, obtain the touch screen firmware for the test mode with the screen on; if the current working mode is the use mode with the screen on, obtain the touch screen firmware for the use mode with the screen on; if the current working mode is the use mode with the screen off, obtain the touch screen firmware for the use mode with the screen off; if the current working mode is the test mode with the screen off, obtain the touch screen firmware for the test mode with the screen off.

[0080] Step S330: Load the firmware to be loaded into the touch screen memory.

[0081] This step can refer to the corresponding steps in the above embodiment and will not be described again here.

[0082] In addition, optionally, since the touch screen memory does not include flash memory, the firmware needs to be loaded into the touch screen memory each time the screen is turned on, which may affect the screen turning on speed when the firmware supporting all operating modes of the touch screen is loaded into the touch screen memory. In the embodiment of the present application, the touch screen firmware is loaded into the touch screen memory according to the operating mode to avoid affecting the screen turning on speed. If the touch screen memory includes flash memory, the firmware file in the flash memory can be directly read. Therefore, in the embodiment of the present application, it is possible to detect whether the touch screen memory of the electronic device includes flash memory; if there is no flash memory, the method of loading the touch screen firmware according to the switching of the operating mode in the embodiment of the present application is executed, for example, the step of detecting whether the operating mode of the touch screen is switched can be executed.

[0083] Of course, in the embodiment of the present application, it is not necessary to detect whether there is flash memory. If the electronic device stores a program for executing the touch screen firmware loading method of the embodiment of the present application, it is considered that the electronic device does not have flash memory, and the touch screen firmware is loaded into the touch screen memory according to the working mode.

[0084] In the embodiment of the present application, when the touch screen switches on and off, it can be determined that the working mode of the touch screen has switched, or when a test trigger operation or a test exit operation is received, it can also be determined that the working mode of the touch screen has switched. The touch screen firmware corresponding to the switched working mode is obtained and loaded into the touch screen memory.

[0085] Step S340: if the touch screen is switched to the screen-on state, after loading the touch screen firmware of the current working mode into the touch screen memory, while the touch screen remains on, loading the touch screen firmware of other working modes into the touch screen memory.

[0086] In the embodiment of the present application, step S340 can be used as an optional step. Since the touch screen firmware needs to be written into the touch screen memory when the screen is turned on, the touch screen firmware of the current working mode is first loaded into the touch screen memory when the screen is turned on, so that the touch screen firmware loaded into the touch screen memory is not too large, thereby improving the response speed of the screen turning on.

[0087] While the screen is on, after the touch screen firmware of the current working mode is loaded, the touch screen firmware of other working modes can be loaded, so that when the touch screen is switched to other working modes, the touch screen firmware does not need to be loaded, thereby improving the processing speed of the touch screen more quickly.

[0088] In the embodiment in which this step is selected for execution, the touch screen firmware corresponding to the current working mode can be obtained and loaded into the touch screen memory only when it is detected that the touch screen switches from off to on.

[0089] Optionally, if the working mode of the touch screen includes a use mode and a test mode when the screen is on, and a use mode and a test mode when the screen is off, it can be that when the working mode of the touch screen is switched to the test mode when the screen is on, after the touch screen firmware corresponding to the test mode when the screen is on is loaded into the touch screen memory, during the process of the touch screen remaining on, the possibility that the touch screen switches from the test mode when the screen is on to the use mode when the screen is on is high, and the touch screen firmware corresponding to the use mode when the screen is on can be loaded into the touch screen memory. Furthermore, if the working mode is switched during the screen-on process, since the touch screen firmware of the working mode switched to has been loaded into the touch screen memory, it is not necessary to load the touch screen firmware corresponding to the switched working mode into the touch screen memory.

[0090] When the working mode of the touch screen is switched to the test mode with the screen off, the possibility that the touch screen switches from the test mode with the screen off to the use mode with the screen off is high, and the touch screen firmware corresponding to the test mode with the screen off can be loaded into the touch screen memory, and during the process of the touch screen remaining off, the touch screen firmware corresponding to the use mode with the screen off can be loaded into the touch screen memory. In addition, if the working mode is switched during the screen off process, since the touch screen firmware of the working mode switched to has been loaded into the touch screen memory, it is not necessary to load the touch screen firmware corresponding to the switched working mode into the touch screen memory.

[0091] After the touch screen firmware corresponding to the current working mode is loaded into the touch screen memory, before other working modes are switched to, the touch screen firmware of other working modes is loaded in advance, thereby improving the response speed of the touch screen in each working mode.

[0092] The present application embodiment also provides a touch screen firmware loading device 400. Figure 6 The device 400 may include a detection module 410, which is used to detect whether the working mode of the touch screen is switched; a firmware acquisition module 420, which is used to obtain the touch screen firmware corresponding to the current working mode as the firmware to be loaded if the working mode of the touch screen is switched, wherein different working modes of the touch screen correspond to different touch screen firmware; and a loading module 430, which is used to load the firmware to be loaded into the touch screen memory.

[0093] Optionally, in the embodiment of the present application, different working modes may correspond to different mode identifiers. The firmware acquisition module 420 may be used to acquire the touch screen firmware corresponding to the current working mode according to the corresponding relationship between the mode identifier and the touch screen firmware.

[0094] Optionally, all touch screen firmware corresponding to all working modes of the touch screen are stored in the system memory as a firmware file. The device 400 also includes a splitting module, which may include a splitting unit to split the firmware file and a touch screen firmware acquisition unit to obtain touch screen firmware corresponding to different mode identifiers.

[0095] Optionally, the splitting unit can be used to read from the beginning of the firmware file, obtain the size of the touch screen firmware currently being read, and detect whether the size of the read file is equal to the size of the touch screen firmware currently being read; if so, split the currently read touch screen firmware from the firmware file and continue to read the firmware file; if not, continue to read the firmware file.

[0096] Optionally, the touch screen firmware acquisition unit may be configured to determine the mode identifier corresponding to each touch screen firmware according to the correspondence between the mode identifier and the firmware size, and the size of each split touch screen firmware.

[0097] Optionally, the touch screen firmware acquisition unit may be used to acquire firmware identifiers of each split touch screen firmware; and determine the mode identifier corresponding to each touch screen firmware according to the corresponding relationship between the firmware identifier and the mode identifier.

[0098] Optionally, the splitting module can also be used to detect whether a new firmware file is obtained. If so, determine the updated part in the new firmware file; split the touch screen firmware corresponding to the updated part from the new firmware file; and establish a unique correspondence between the split touch screen firmware and the mode identifier.

[0099] Optionally, the device may further include a determination module for determining whether touch screen firmware corresponding to the current working mode is stored; if so, the firmware acquisition module 420 acquires the touch screen firmware corresponding to the current working mode.

[0100] Optionally, the device may also include a firmware download module, which is used to initiate a firmware acquisition request to the server to obtain the touch screen firmware corresponding to the current working mode if the touch screen firmware corresponding to the current working mode is not stored; if the touch screen firmware returned by the server is received, the firmware acquisition module 420 obtains the touch screen firmware corresponding to the current working mode.

[0101] Optionally, the working mode of the touch screen may include a working mode when the screen is on and a working mode when the screen is off. The detection module 410 may be used to detect whether the on-off state of the touch screen is switched; if the on-off state of the touch screen is switched, it is determined that the working mode of the touch screen is switched.

[0102] Optionally, the loading module 430 can also be used to load the touch screen firmware of other working modes into the touch screen memory after loading the touch screen firmware of the current working mode into the touch screen memory when the touch screen is switched to the screen-on state, and then load the touch screen firmware of other working modes into the touch screen memory while the touch screen remains on.

[0103] Optionally, the working mode of the touch screen may include a usage mode and a test mode with the screen on, and a usage mode and a test mode with the screen off. The detection module 410 may also be used to determine that the working mode of the touch screen is switched to the test mode with the screen on if a test trigger operation is received and the screen is currently in the on state; to determine that the working mode of the touch screen is switched to the test mode with the screen off if a test trigger operation is received and the screen is currently in the off state; to determine that the working mode of the touch screen is switched to the usage mode with the screen on if a test exit operation is received and the screen is currently in the on state; to determine that the working mode of the touch screen is switched to the usage mode with the screen off if a test exit operation is received and the screen is currently in the off state.

[0104] Optionally, the loading module 430 can also be used for, when the working mode of the touch screen is switched to the test mode with the screen on, after the touch screen firmware corresponding to the test mode with the screen on is loaded into the touch screen memory, while the touch screen remains on, the touch screen firmware corresponding to the usage mode with the screen on is loaded into the touch screen memory; when the working mode of the touch screen is switched to the test mode with the screen off, after the touch screen firmware corresponding to the test mode with the screen off is loaded into the touch screen memory, while the touch screen remains off, the touch screen firmware corresponding to the usage mode with the screen off is loaded into the touch screen memory.

[0105] Optionally, the detection module of the device 400 may receive a test trigger operation and a test exit operation via a hardware interface electrically connected to the outside.

[0106] Optionally, the device may further include a flash memory checking module for detecting whether the touch screen memory of the electronic device includes a flash memory. If not, the detection module 410 detects whether the working mode of the touch screen is switched.

[0107] The touch screen firmware loading method, device, electronic device and storage medium provided in the embodiments of the present application can improve the touch screen firmware loading rate and usage efficiency, increase the system screen lighting speed, and improve the user experience. In addition, when the touch screen memory does not include flash memory, the touch screen firmware loading method and device provided in the embodiments of the present application can be used to save the memory cost.

[0108] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the above-mentioned method embodiments can refer to each other; the specific working processes of the above-mentioned devices and modules can refer to the corresponding processes in the aforementioned method embodiments, which will not be repeated here.

[0109] In several embodiments provided in the present application, the coupling between modules may be electrical, mechanical or other forms of coupling.

[0110] In addition, each functional module in each embodiment of the present application can be integrated into a processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The above-mentioned integrated modules can be implemented in the form of hardware or in the form of software functional modules. Each module can be configured in different electronic devices or in the same electronic device, which is not limited by the embodiments of the present application.

[0111] Please refer to Figure 7 , which shows a structural block diagram of an electronic device 500 provided in an embodiment of the present application. The electronic device 500 may be a smart device such as a smartphone, a wearable device, an e-reader, a tablet computer, a computer, etc. The electronic device may include one or more processors 510 (only one is shown in the figure), a memory 520, and one or more programs. Among them, the memory may include a system memory and a touch screen memory, the system memory is used to store system data of the electronic device and various files called by the system, etc., and the one or more programs are stored in the system memory and are configured to be executed by one or more processors 510. The one or more programs are configured to execute the methods described in the aforementioned embodiments. The touch screen memory is used to store the touch screen operating system and touch screen related usage files, for example, the touch screen firmware can be stored.

[0112] The processor 510 may include one or more processing cores. The processor 510 uses various interfaces and lines to connect various parts of the entire electronic device 500, and executes various functions and processes data of the electronic device 500 by running or executing instructions, programs, code sets or instruction sets stored in the memory 520, and calling data stored in the memory 520. Optionally, the processor 510 can be implemented in at least one hardware form of digital signal processing (DSP), field programmable gate array (FPGA), and programmable logic array (PLA). The processor 510 can integrate one or a combination of a central processing unit (CPU), a graphics processing unit (GPU), and a modem. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing display content; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 510, but may be implemented separately through a communication chip.

[0113] The memory 520 may include a random access memory (RAM) or a read-only memory (ROM). The memory 520 may be used to store instructions, programs, codes, code sets or instruction sets. The memory 520 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function, instructions for implementing the above-mentioned various method embodiments, etc. The data storage area may also store data created by the electronic device during use, etc.

[0114] Please refer to Figure 8 , which shows a structural block diagram of a computer-readable storage medium provided in an embodiment of the present application. The computer-readable storage medium 600 stores program codes, which can be called by a processor to execute the method described in the above method embodiment.

[0115] The computer readable storage medium 600 may be an electronic memory such as a flash memory, an EEPROM (electrically erasable programmable read-only memory), an EPROM, a hard disk, or a ROM. Optionally, the computer readable storage medium 600 includes a non-transitory computer-readable storage medium. The computer readable storage medium 600 has storage space for program code 610 that performs any method step in the above method. These program codes can be read from or written to one or more computer program products. The program code 610 can be compressed, for example, in an appropriate form.

[0116] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims

1. A touch screen firmware loading method, characterized in that: The method comprises: Splitting the firmware file to obtain touch screen firmware corresponding to different mode identifiers, wherein all touch screen firmware corresponding to all working modes of the touch screen are stored in a system memory as a firmware file, different working modes correspond to different mode identifiers, and the system memory is electrically connected to a central processing unit; Detect whether the working mode of the touch screen is switched; If the working mode of the touch screen is switched, the touch screen firmware corresponding to the current working mode is obtained as the firmware to be loaded according to the correspondence between the mode identifier and the touch screen firmware, wherein different working modes of the touch screen correspond to different touch screen firmwares; Loading the firmware to be loaded into a touch screen memory, where the touch screen memory is different from the system memory; The split firmware file includes: Reading from the beginning of the firmware file, obtaining the size of the touch screen firmware currently being read, and detecting whether the size of the read file is equal to the size of the touch screen firmware currently being read, wherein data of the touch screen firmware of the same working mode in the firmware file are stored adjacently; If yes, the currently read touch screen firmware is separated from the firmware file, and the firmware file is continued to be read; If not, continue reading the firmware file.

2. The method according to claim 1, characterized in that The step of obtaining touch screen firmware corresponding to different mode identifiers includes: According to the corresponding relationship between the mode identifier and the firmware size, and the size of each split touch screen firmware, the mode identifier corresponding to each touch screen firmware is determined.

3. The method according to claim 1, characterized in that The step of obtaining touch screen firmware corresponding to different mode identifiers includes: Obtain the firmware identifier of each split touch screen firmware; According to the correspondence between the firmware identifier and the mode identifier, the mode identifier corresponding to each touch screen firmware is determined.

4. The method according to any one of claims 1 to 3, characterized in that: The method further comprises: Check whether the new firmware file is obtained; If so, determining the updated portion in the new firmware file; Separate the touch screen firmware corresponding to the updated part from the new firmware file; A unique correspondence between the split touch screen firmware and the mode identifier is established.

5. The method according to claim 1, characterized in that Before acquiring the touch screen firmware corresponding to the current working mode, the method further includes: Determine whether touch screen firmware corresponding to the current working mode is stored; If yes, execute the step of obtaining the touch screen firmware corresponding to the current working mode.

6. The method according to claim 5, characterized in that The method further comprises: If the touch screen firmware corresponding to the current working mode is not stored, a firmware acquisition request is initiated to the server to acquire the touch screen firmware corresponding to the current working mode; If the touch screen firmware returned by the server is received, the step of obtaining the touch screen firmware corresponding to the current working mode is performed.

7. The method according to any one of claims 1 to 3, characterized in that: The working mode of the touch screen includes a working mode when the screen is on and a working mode when the screen is off, and the detecting whether the working mode of the touch screen is switched includes: Detect whether the on / off state of the touch screen switches; If the on / off state of the touch screen switches, it is determined that the working mode of the touch screen switches.

8. The method according to any one of claims 1 to 3, characterized in that: The method further comprises: If the touch screen is switched to the screen-on state, after the touch screen firmware of the current working mode is loaded into the touch screen memory, while the touch screen remains on, the touch screen firmware of other working modes is loaded into the touch screen memory.

9. The method according to any one of claims 1 to 3, characterized in that: The working mode of the touch screen includes a use mode and a test mode when the screen is on, and a use mode and a test mode when the screen is off. The detecting whether the working mode of the touch screen is switched includes: If a test trigger operation is received and the screen is currently in a bright screen state, determining that the working mode of the touch screen is switched to a test mode with the screen bright; If a test trigger operation is received and the screen is currently in an off state, determining that the working mode of the touch screen is switched to a test mode with the screen off; If a test exit operation is received and the screen is currently on, determining that the working mode of the touch screen is switched to a usage mode under the screen on state; If a test exit operation is received and the screen is currently in an off state, it is determined that the working mode of the touch screen is switched to a usage mode under the off screen state.

10. The method according to any one of claims 1 to 3, characterized in that: The method further comprises: When the working mode of the touch screen is switched to the test mode with the screen on, after loading the touch screen firmware corresponding to the test mode with the screen on into the touch screen memory, while the touch screen remains on, loading the touch screen firmware corresponding to the use mode with the screen on into the touch screen memory; When the working mode of the touch screen is switched to the test mode when the screen is off, after the touch screen firmware corresponding to the test mode when the screen is off is loaded into the touch screen memory, while the touch screen remains off, the touch screen firmware corresponding to the use mode when the screen is off is loaded into the touch screen memory.

11. The method according to claim 9 or 10, characterized in that: A test trigger operation and a test exit operation are received through a hardware interface electrically connected to the outside.

12. The method according to any one of claims 1 to 3, characterized in that: The method further comprises: Detecting whether the touch screen memory includes flash memory; If not, the step of detecting whether the working mode of the touch screen is switched is performed.

13. A touch screen firmware loading device, characterized in that: The device comprises: A splitting module, used for splitting a firmware file to obtain touch screen firmware corresponding to different mode identifiers, wherein all touch screen firmware corresponding to all working modes of the touch screen are stored in a system memory as a firmware file, different working modes correspond to different mode identifiers, and the system memory is electrically connected to a central processing unit; A detection module, used to detect whether the working mode of the touch screen is switched; The firmware acquisition module is used to acquire the touch screen firmware corresponding to the current working mode as the firmware to be loaded according to the correspondence between the mode identifier and the touch screen firmware if the working mode of the touch screen is switched, wherein different working modes of the touch screen correspond to different touch screen firmwares; A loading module, used for loading the firmware to be loaded into a touch screen memory, where the touch screen memory is different from the system memory; The splitting module is further used to read from the beginning of the firmware file, obtain the size of the touch screen firmware currently being read, and detect whether the size of the read file is equal to the size of the touch screen firmware currently being read, wherein the data of the touch screen firmware of the same working mode in the firmware file are stored adjacently; if so, split the currently read touch screen firmware from the firmware file, and continue to read the firmware file; If not, continue reading the firmware file.

14. An electronic device, characterized in that: include: one or more processors; System memory; Touch screen memory; One or more programs, wherein the one or more programs are stored in the system memory and configured to be executed by the one or more processors, and the one or more programs are configured to perform the method according to any one of claims 1-12.

15. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores program codes, which can be called by a processor to execute the method according to any one of claims 1 to 12.

Citation Information

Patent Citations

  • Device and method for managing data based on semiconductor storage medium

    CN101324867A

  • Electrical appliance and screen driving method and device thereof

    CN109542384A