CN115729629A - USB device identification method, terminal device and system - Google Patents

USB device identification method, terminal device and system Download PDF

Info

Publication number
CN115729629A
CN115729629A CN202111015367.7A CN202111015367A CN115729629A CN 115729629 A CN115729629 A CN 115729629A CN 202111015367 A CN202111015367 A CN 202111015367A CN 115729629 A CN115729629 A CN 115729629A
Authority
CN
China
Prior art keywords
usb
processor
starting
equipment
item
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111015367.7A
Other languages
Chinese (zh)
Inventor
相超
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Honor Device Co Ltd
Original Assignee
Honor Device Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Honor Device Co Ltd filed Critical Honor Device Co Ltd
Priority to CN202111015367.7A priority Critical patent/CN115729629A/en
Publication of CN115729629A publication Critical patent/CN115729629A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Stored Programmes (AREA)

Abstract

The embodiment of the application provides a USB device identification method, a terminal device and a system, which are applied to the technical field of electronics. According to the method, when the USB equipment is determined to be inserted but not successfully identified, software reset can be performed on the USB equipment firstly, and when the USB equipment still cannot be identified after software reset, hardware reset is performed on the USB equipment. Through software reset and hardware reset, the operation of manually plugging and unplugging the USB equipment is simulated, the identification of the USB equipment can be recovered without manual intervention, the operation of a user is simplified, and the use experience of the user is improved.

Description

USB device identification method, terminal device and system
Technical Field
The present application relates to the field of electronic technologies, and in particular, to a method, a terminal device, and a system for identifying a USB device.
Background
With the rapid development of the technology, terminal devices such as a notebook computer and a desktop computer have become common tools in life and work of people, but in the use process of the terminal devices, an operating system often fails due to various reasons, and in order to repair the operating system failure, after the terminal devices identify a Universal Serial Bus (USB) device, the operating system can be repaired or reinstalled by loading a boot program file in the USB device.
However, in the process of booting the terminal device, there may be a situation that the USB device inserted into the USB port cannot be successfully identified, which may affect the repair or reinstallation of the operating system.
Disclosure of Invention
The identification method, the terminal device and the system of the USB device provided by the embodiment of the application are used for improving the success rate of the terminal device for identifying the USB device inserted into the USB port, so that the terminal device can repair or reinstall the operating system by using the bootstrap file in the USB device.
In a first aspect, an embodiment of the present application provides a method for identifying a USB device, where the method is applied to a terminal device, and the terminal device has a USB port, and the method includes: judging whether starting is carried out by a USB starting item or not in the starting process of the terminal equipment; when starting with a USB starting item, determining whether a USB device is inserted into a USB port; when a USB device is inserted into the USB port, whether the USB device is successfully identified as a USB starting device is determined; when the USB equipment is not successfully identified as the USB starting equipment, executing software reset operation, and determining whether the USB equipment is successfully identified as the USB starting equipment again; when the USB equipment is not successfully identified as USB starting equipment, executing hardware reset operation, and continuously determining whether the USB equipment is successfully identified as the USB starting equipment or not; and when the USB equipment is successfully identified as the USB starting equipment, loading the bootstrap program file in the USB equipment.
The specific operations executed by the terminal device may be executed by a processor in the terminal device. Therefore, when the terminal equipment does not successfully identify the USB equipment serving as the USB starting equipment, the USB equipment can be reset in a software resetting mode, and when the USB equipment still cannot be identified, the USB equipment is reset in a hardware resetting mode so as to supply power after the USB equipment is powered off. Through software reset and hardware reset, the operation of manually plugging and unplugging the USB equipment is simulated, so that the reliability of USB equipment identification is improved, the identification of the USB equipment can be recovered without manual intervention, the operation of a user is simplified, and the use experience of the user is improved.
In an alternative implementation, the terminal device includes a processor and a USB hub connected to each other, the USB hub being connected to the USB port; performing a software reset operation comprising: the processor controls the USB hub to send a reset instruction to the USB device. Therefore, the USB hub is controlled to send the reset instruction to the USB equipment, so that the software reset operation of the USB equipment is realized, the execution steps of the initialization operation of the USB equipment after the software reset are reduced, the probability that the processor with the set duration can finish the initialization operation of the USB equipment is improved, and the probability that the processor successfully identifies the USB equipment as USB starting equipment is improved.
In an optional implementation manner, after performing the software reset operation and determining again whether the USB device is successfully identified as the USB boot device, the method further includes: when the USB equipment is not successfully identified as the USB starting equipment, at least one software resetting operation is continuously executed, and whether the USB equipment is successfully identified as the USB starting equipment or not is determined after each software resetting operation is executed. In this way, the probability of successfully identifying the USB device as a USB-enabled device is further improved by performing a plurality of software reset operations.
In an optional implementation manner, the terminal device includes a processor, an embedded controller, and a USB hub, which are connected in sequence; performing a hardware reset operation comprising: the processor controls the embedded controller to send a reset level signal to the USB concentrator; the reset level signal comprises a low level signal and a high level signal separated by a preset time length. Therefore, by executing the hardware reset operation, all the USB equipment connected with the USB concentrator is powered off and then powered on, and all the USB equipment connected with the terminal equipment is set to be in an idle state, so that the interference of other USB equipment connected with the terminal equipment on the USB equipment serving as USB starting equipment is reduced, and the probability of successfully identifying the USB equipment serving as the USB starting equipment is improved.
In an optional implementation manner, after performing a hardware reset operation and continuing to determine whether the USB device is successfully identified as the USB boot device, the method further includes: when the USB equipment is still not successfully identified as the USB starting equipment, at least one hardware reset operation is continuously executed, and whether the USB equipment is successfully identified as the USB starting equipment or not is determined after each hardware reset operation is executed. In this way, the probability of successfully identifying the USB device as a USB-enabled device is further improved by performing multiple hardware reset operations.
In an optional implementation manner, the processor controls the embedded controller to send a reset level signal for multiple times, and a preset duration corresponding to the reset level signal sent for the (N + 1) th time is longer than a preset duration corresponding to the reset level signal sent for the nth time, where N is a positive integer. Therefore, the preset time length of the current reset level signal is set to be longer than the preset time length of the previous reset level signal, so that data in a register included in the USB equipment after power failure can be eliminated more thoroughly, the possibility that the USB equipment after hardware reset is in a complete power-on state is improved, and the possibility that the USB equipment is successfully identified is further improved.
In an optional implementation manner, the preset duration corresponding to the N +1 th sent reset level signal is M times of the preset duration corresponding to the nth sent reset level signal, and M is a positive integer greater than 1. Therefore, the programming difficulty of the program code corresponding to the preset duration of the multi-time reset level signal is reduced.
In an alternative implementation, the terminal device includes a processor and a USB hub connected to each other, the USB hub being connected to the USB port; determining whether a USB device is plugged into the USB port, comprising: the processor receives the connection state reported by the USB concentrator; the processor determines whether a USB device is inserted into the USB port according to the connection state.
In an optional implementation manner, determining whether the USB device is successfully identified as the USB enabled device includes: initializing the USB equipment; and detecting whether the file system type of the USB device is read from the USB device and the bootstrap file type corresponding to the bootstrap file. Generally, if the USB device needs to be started, the USB device stores a corresponding boot file, so as to detect whether the USB device is successfully identified as a USB starting device based on reading the file system type and the boot file type.
In an alternative implementation, the terminal device includes a processor and a USB hub connected to each other, the USB hub being connected to the USB port; initializing the USB device, including: the processor performs initialization operation on the USB port through the USB hub; the processor performs configuration operations for the USB device through the USB hub.
In an alternative implementation, the processor performs an initialization operation on the USB port through the USB hub, including: the processor sends a port state acquisition instruction to the USB hub; the processor receives the port state of the USB port returned by the USB hub according to the port state acquisition instruction; when the port state is a busy state, the processor sends a port state clearing instruction to the USB hub so as to clear the port state of the USB port; the processor sends a write port status instruction to the USB hub, causing the USB hub to send a reset instruction to the USB device and set the port status of the USB port to an idle state.
In an alternative implementation, the processor performs configuration operations on the USB device via the USB hub, including: the processor sends an equipment descriptor acquisition instruction to the USB equipment through the USB hub; the processor receives the device descriptor returned by the USB device according to the device descriptor acquisition instruction; when the device type corresponding to the field in the device descriptor is a storage device, the processor sends a configuration descriptor acquisition instruction to the USB device through the USB hub; the processor receives a configuration descriptor returned by the USB equipment according to the configuration descriptor acquisition instruction; and when the product type corresponding to the field in the configuration descriptor is the USB flash disk, the processor sends a configuration instruction to the USB device through the USB hub so as to set the USB device in a configuration state.
In an optional implementation manner, the terminal device includes a processor, an embedded controller, a keyboard and a display screen, the keyboard is connected with the embedded controller, the embedded controller is connected with the processor, the display screen is connected with the processor, and the keyboard includes a first startup shortcut key, a startup item moving key and a startup item storing key; before the processor judges whether to start with the USB starting item, the method further comprises the following steps: in the starting process of the terminal equipment, when a processor receives a first starting request which is sent by an embedded controller and aims at a Basic Input and Output System (BIOS) setting interface, the processor controls a display screen to display the BIOS setting interface, the first starting request is generated when the embedded controller detects the pressing operation of a first starting shortcut key, the BIOS setting interface comprises a starting item list, and the starting item list comprises a hard disk starting item, a USB starting item and a network starting item; when the processor receives a sequence change request which is sent by the embedded controller and aims at the startup item list, the processor changes the sequence of each startup item in the startup item list, wherein the sequence change request is generated when the embedded controller detects the pressing operation of a startup item moving key; when the processor receives a storage request aiming at the startup item list sent by the embedded controller, the processor stores the startup item list, wherein the storage request is generated when the embedded controller detects the pressing operation of a startup item storage key; in the process of starting up the terminal equipment, the processor judges whether to start up by using a USB starting item, and the method comprises the following steps: and in the process of restarting the terminal equipment, the processor judges whether the first starting item in the stored starting item list is a USB starting item. In this way, the USB startup item can be set as the first startup item in the startup item list by changing the startup sequence of each startup item in the startup item list, so that the USB startup item is used for startup in the process of restarting the terminal device.
In an optional implementation manner, the terminal device includes a processor, an embedded controller, a keyboard and a display screen, the keyboard is connected with the embedded controller, the embedded controller is connected with the processor, the display screen is connected with the processor, and the keyboard includes a second start shortcut key and a start item selection key; in the starting process of the terminal equipment, the processor judges whether to start by a USB starting item, and the method comprises the following steps: in the starting process of the terminal equipment, when the processor receives a second starting request which is sent by the embedded control and aims at the starting item selection interface, the processor controls the display screen to display the starting item selection interface, the second starting request is generated when the embedded controller detects the pressing operation of a second starting shortcut key, and the starting item selection interface at least comprises a USB starting item; when the processor receives a starting item selection request sent by the embedded controller, the processor determines whether the selected starting item is a USB starting item according to the starting item selection request, and the starting item selection request is generated when the embedded controller detects the pressing operation of a starting item selection key. Therefore, the starting sequence of each starting item in the starting item list does not need to be changed, and the starting is directly carried out through the selected USB starting item in the starting process.
In a second aspect, an embodiment of the present application provides a terminal device, including a processor and a memory; the memory stores computer-executable instructions; the processor is used for executing the computer execution instructions stored by the memory, so that the processor executes the identification method of the USB device.
In an optional implementation manner, the terminal device further includes a signal adjustment module, where the signal adjustment module includes a first filtering unit and a voltage stabilizing unit; the first filtering unit is respectively connected with the embedded controller and the USB concentrator and is used for filtering the reset level signal output by the embedded controller; one end of the voltage stabilizing unit is connected with the first level signal end, and the other end of the voltage stabilizing unit is connected in a channel between the embedded controller and the USB concentrator and used for performing voltage stabilizing processing on the reset level signal output by the embedded controller. Therefore, the anti-interference performance of the reset level signal output to the USB concentrator by the embedded controller can be improved through the first filtering unit, and the stability of the reset level signal output to the USB concentrator by the embedded controller can be improved through the voltage stabilizing unit.
In an optional implementation manner, the first filtering unit includes a first resistor and a first capacitor; the first end of the first resistor is connected with the embedded controller, the second end of the first resistor is connected with the first end of the first capacitor, the first end of the first capacitor is also connected with the USB concentrator, and the second end of the first capacitor is connected with the grounding end; the voltage stabilizing unit comprises a voltage stabilizing diode, the anode of the voltage stabilizing diode is connected with the second end of the first resistor, and the cathode of the voltage stabilizing diode is connected with the first level signal end.
In a third aspect, an embodiment of the present application provides a computer-readable storage medium, where a computer program or an instruction is stored, and when the computer program or the instruction is executed, the method for identifying a USB device is implemented.
In a fourth aspect, an embodiment of the present application provides an identification system for a USB device, where the identification system includes the USB device and the terminal device, and a bootstrap file is stored in the USB device.
The effects of the possible implementations of the second aspect to the fourth aspect are similar to the effects of the first aspect and the possible designs of the first aspect, and are not described herein again.
Drawings
Fig. 1 is a flowchart of an identification method of a USB device in the related art according to an embodiment of the present application;
fig. 2 is a schematic diagram of an identification system of a USB device according to an embodiment of the present disclosure;
fig. 3 is a flowchart of an identification method for a USB device according to an embodiment of the present disclosure;
fig. 4 is a schematic structural diagram of a hardware system of a terminal device according to an embodiment of the present application;
FIG. 5 is a schematic diagram of a BIOS setup interface according to an embodiment of the present application;
FIG. 6 is a schematic diagram illustrating a connection between a USB hub and a USB device according to an embodiment of the present application;
FIG. 7 is a diagram illustrating relationships between descriptors of USB devices according to an embodiment of the present application;
FIG. 8 is a schematic diagram illustrating a connection between an embedded controller and a USB hub according to an embodiment of the present application;
FIG. 9 is a flowchart illustrating another USB device identification method according to an embodiment of the present application;
fig. 10 is a schematic hardware structure diagram of an identification apparatus of a USB device according to an embodiment of the present application.
Detailed Description
In the embodiments of the present application, terms such as "first" and "second" are used to distinguish the same or similar items having substantially the same function and action. For example, the first chip and the second chip are only used for distinguishing different chips, and the sequence order thereof is not limited. Those skilled in the art will appreciate that the terms "first," "second," etc. do not denote any order or quantity, nor do the terms "first," "second," etc. denote any order or importance.
It should be noted that in the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or explanations. Any embodiment or design described herein as "exemplary" or "e.g.," is not necessarily to be construed as preferred or advantageous over other embodiments or designs. Rather, use of the word "exemplary" or "such as" is intended to present concepts related in a concrete fashion.
In the embodiments of the present application, "at least one" means one or more, "a plurality" means two or more. "and/or" describes the association relationship of the associated objects, meaning that there may be three relationships, e.g., a and/or B, which may mean: a alone, A and B together, and B alone, wherein A and B may be singular or plural. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship. "at least one of the following" or similar expressions refer to any combination of these items, including any combination of the singular or plural items. For example, at least one (one) of a, b, or c, may represent: a, b, c, a-b, a-c, b-c, or a-b-c, wherein a, b, c may be single or multiple.
With the continuous development of USB peripheral technologies, USB devices have experienced high-speed development from USB1.0, USB1.1, USB2.0 to USB3.0, and for forward compatibility, a USB bus has been developed from an Open Host Controller Interface (OHCI) to a Universal Host Controller Interface (UHCI), and then to an Enhanced Host Controller Interface (EHCI) until the development of the current extensible host controller interface (XHCI) technology. The USB bus not only serves as a connection device to provide charging and data transfer tasks, but also extends the security specifications to ensure compatibility.
The OHCI is a standard supporting USB1.0, not only supports USB, but also supports other interfaces, such as an IEEE 1394 interface, and is biased to realize tasks by hardware, and software driving is relatively simple; UHCI is the interface standard of USB1.0 and USB1.1 which is dominated by Intel, is incompatible with OHCI, the task of software drive of UHCI is heavy, and needs to be made more complicated, but can use a USB controller of cheaper and simpler hardware; the EHCI is an Intel-dominated interface standard for USB2.0, which provides only the high-speed functionality of USB2.0, while relying on UHCI or OHCI to provide support for full-speed (full-speed) or low-speed (low-speed) devices; the xHCI is the interface standard of the latest USB3.0 at present, and has great improvement in speed, energy conservation, virtualization and the like compared with OHCI, UHCI and EHCI, and supports USB devices with all kinds of speeds, such as USB3.0 Super-speed, USB2.0 Low-speed, USB2.0 Full-speed, USB2.0 High-speed, USB1.1 Low-speed and USB1.1 Full-speed.
At present, terminal devices such as notebook computers and desktop computers become common tools in life and work of people, and the terminal devices are also provided with USB interfaces with different interface standards.
In the process of using the terminal device, an operating system of the terminal device often fails for various reasons, for example, when the terminal device is used to access the internet, the operating system suddenly crashes due to misoperation or invasion of virus malware. Therefore, it is necessary to set a corresponding bootstrap file in a USB device (such as a USB disk), and insert the USB device into a USB port of a terminal device, so as to implement repair or reinstallation of an operating system based on the bootstrap file in the USB device after the terminal device successfully identifies that the USB device is a USB boot device.
Specifically, as shown in fig. 1, in the booting process of the terminal device, a processor in the terminal device executes step 101, and detects whether a user presses an F12 key on a keyboard, and after pressing the F12 key, the processor controls a display screen of the terminal device to display a start item selection interface, where the start item selection interface includes a plurality of start items, such as a USB start item, a Hard Disk Drive (HDD) start item, and a preboot execution environment (PXE) start item; the user may select one of the boot items from the boot item selection interface, after selecting the boot item, the processor executes step 102, to determine whether the boot condition is USB boot, that is, whether the boot item selected by the user is a USB boot item, and when the boot item selected by the user is a USB boot item, the processor executes step 103 to load a BIOS USB boot program, where an execution process after loading the BIOS USB boot program includes step 104, step 105, and step 106 of subsequent execution.
After step 103, the processor continues to step 104, detecting whether a USB device is inserted into the USB port of the terminal device, and when detecting that no USB device is inserted into the USB port of the terminal device, continuing to wait for the insertion of the USB device; when detecting that the USB equipment is inserted into the USB port of the terminal equipment, the processor executes step 105 to initialize the USB equipment inserted into the USB port, namely to complete the configuration and connection work of the USB equipment; after the processor completes initialization of the USB device, the processor performs step 106 to detect whether the USB device is successfully identified as a USB boot device; when the processor successfully identifies that the USB device inserted into the USB port is a USB boot device, the processor can execute step 107, and load a bootstrap file in the USB device to realize the repair or reinstallation of the operating system; and when the processor fails to recognize that the USB equipment inserted into the USB port is the USB starting equipment, the execution operation is finished, and the bootstrap program file in the USB equipment cannot be loaded to realize the repair or reinstallation of the operating system.
It should be noted that, when it is not detected that the user presses the F12 key on the keyboard, the execution operation is ended this time; when the starting item selected by the user is not a USB starting item, the processor executes a corresponding operation according to the selected starting item, which is to mainly describe a scenario in which the starting condition is USB starting, and this scenario is not described in the embodiment of the present application too much, that is, when the starting condition is not USB starting, the process step in the embodiment of the present application is ended.
Aiming at the situation that the USB equipment serving as the USB starting equipment cannot be successfully identified in the starting process of the terminal equipment, the analysis shows that the reason is as follows: the continuous development of USB technology has led to a wide range of brands and models of USB devices in the market, and there are differences in electrical characteristics of different USB devices, that is, there is a problem that the USB interface of the terminal device is incompatible with the interface standard between USB devices. For example, the USB interface of the terminal device is USB3.0, but the USB interface of the inserted USB device is USB2.0 or USB1.0, and the signal transmission rates of the two are different, and since the signal transmission rate of the USB device is low, the initialization operation of the USB device by the processor may not be completed in a set time (for example, 30 ms), so that the terminal device may fail to successfully identify the USB device as a USB boot device in a boot stage.
Another reason is that: because many USB devices are connected to the terminal device, for example, the terminal device is connected to a keyboard, a mouse, and other devices, the USB devices connected to the terminal device may interfere with the USB devices serving as USB boot devices, and therefore, the terminal device may fail to successfully identify the USB devices as USB boot devices in the boot stage.
If the terminal device cannot successfully recognize that the USB device inserted into the USB port is a USB boot device, the terminal device cannot be loaded into the boot program file in the USB device, which affects repair or reinstallation of the operating system.
At present, in order to enable a terminal device to recognize a USB device as a USB start device, all connected USB devices (such as a keyboard and a mouse) on the terminal device may be initialized in a manner of restarting the terminal device for multiple times, so as to reduce interference of the devices on the USB device as the USB start device, or in a manner of plugging and unplugging the USB device for multiple times, an execution step in an initialization operation on the USB device after the plugging and unplugging operation is reduced, so as to improve a probability that a processor for setting a duration can complete the initialization operation on the USB device. Therefore, the terminal equipment can successfully identify the USB equipment which is inserted into the USB port of the terminal equipment and is used as the USB starting equipment in the starting-up stage.
However, in this way, manual intervention by the user is required, that is, the user needs to manually restart the terminal device or re-plug the USB device, so that the user operation is cumbersome, and the user experience is affected.
Based on this, an embodiment of the present application provides a method for identifying a USB device, where when a processor in a terminal device does not successfully identify a USB device serving as a USB boot device, the USB device may be reset by a software reset method, that is, the USB device may be reset by controlling a USB hub to send a reset instruction, and when the USB device still cannot be successfully identified, the USB device may be reset by a hardware reset method, that is, an embedded controller is controlled to send a reset level signal, so as to power off the USB device and then supply power. Through software reset and hardware reset, the operation of manually plugging and unplugging the USB equipment is simulated, the identification of the USB equipment can be recovered without manual intervention, the operation of a user is simplified, and the use experience of the user is improved.
The method for identifying the USB equipment provided by the embodiment of the application can be suitable for the terminal equipment which needs to be repaired or reinstalled by the USB starting equipment, such as a notebook computer, a tablet computer, a desktop assembly computer and an all-in-one machine.
In order to better understand the embodiment of the present application, a scenario of the identification system of the USB device according to the embodiment of the present application is described below. Referring to fig. 2, the identification system of the USB device includes a terminal device 21 and a USB device 22, and the terminal device 21 is illustrated as a notebook computer in fig. 2.
As shown in a in fig. 2, at this time, the USB device 22 is not yet inserted into the USB port (not shown) of the terminal device 21, a bootstrap file is stored in the USB device 22, and if it is necessary to reinstall or repair the operating system of the terminal device 22 by using the bootstrap file in the USB device 22, as shown in b in fig. 2, the USB device 22 may be inserted into the USB port of the terminal device 21 before or during the boot of the terminal device 21.
Fig. 3 is a flowchart of an identification method for a USB device according to an embodiment of the present disclosure. Referring to fig. 3, the method for the terminal device to identify the USB device may include the following steps:
step 301, in the process of starting up the terminal device, the processor detects whether the user presses the first start shortcut key.
The identification method of the USB device in the embodiment of the present application is specifically applied to a terminal device, and as shown in fig. 4, the terminal device includes a processor 201, a USB hub 202, a USB port, an Embedded Controller (EC) 204, a keyboard 205, a display 206, a sensor 207, a Read Only Memory (ROM) chip 208, and the like.
In the terminal device, the USB hub 202 may also be referred to as a USB bus, and the number of USB ports connected to the USB hub 202 may be 1 or more, and as shown in fig. 4, 3 USB ports connected to the USB hub 202, which are a USB port 203a, a USB port 203b, and a USB port 203c, are provided in the terminal device. Of course, the number of USB ports of different types of terminal devices may be different, and this is not limited in this embodiment of the present application.
The processor 201 is connected to the embedded controller 204, the USB hub 202, the display 206, the sensor 207, and the ROM chip 208, the embedded controller 204 is connected to the keyboard 205 and the USB hub 202, and the USB hub 202 is further connected to each USB port.
In addition, the terminal device further includes a power supply module (not shown in fig. 4), which is respectively connected to the processor 201, the USB hub 202, the embedded controller 204, the display 206, and the ROM chip 208, and is used for supplying power to the connected devices.
The keyboard 205 is provided with keys such as a power-on key and a first start shortcut key, and the embedded controller 204 detects pressing operations of the user on the keys on the keyboard 205 in real time. When a user presses a power-on key, the embedded controller 204 detects that the user presses the power-on key, the embedded controller 204 sends a power-on request to the processor 201, and the processor 201 executes a power-on operation according to the power-on request sent by the embedded controller 204, so that the terminal device starts to start up.
In the process of starting up the terminal device, the embedded controller 204 may detect whether the user presses the first start shortcut key, and send a condition that whether the first start shortcut key is pressed to the processor 201, so as to detect the pressing operation of the first start shortcut key by the processor 201, that is, detect whether the user presses the first start shortcut key.
The first start shortcut key may be an F2 key on the keyboard 205, and it should be understood that the first start shortcut keys corresponding to different types of terminal devices may be different, and the first start shortcut key in this embodiment may also be another key on the keyboard 205, such as a Delete key.
Step 302, when the processor detects that the user presses the first start shortcut key, the processor controls the display screen to display a BIOS setting interface.
Taking the first start shortcut key as an F2 key as an example, when the embedded controller 204 detects that the user presses the F2 key, the embedded controller 204 generates a first start request and sends the first start request to the processor 201, when the processor 201 receives the first start request sent by the embedded controller 204, the processor 201 may determine that the user presses the F2 key, and then the processor 201 controls the display screen 206 to display a BIOS setting interface according to the first start request.
The BIOS is a set of programs that are fixed into the ROM chip 208 on the motherboard of the terminal device, providing the lowest level, most direct hardware setup and control for the computer, which is the first program to run on power. The BIOS program takes important tasks such as system power-on self-test, hardware initialization, etc., and the start of the system application program is guided by the BIOS program.
As shown in fig. 5, a boot item list is displayed in the BIOS setting interface, and the boot item list includes a hard disk boot item (HDD Device), a USB boot item (USB Device), and a network boot item (PXE Device).
Before the sequence of each boot entry in the boot entry list in the BIOS setting interface is not changed, the boot sequence of each boot entry in the boot entry list is generally as shown in a in fig. 5, where the first boot entry is a hard disk boot entry, the second boot entry is a USB boot entry, and the third boot entry is a network boot entry.
In addition, names of each starting device, such as a hard disk name, an Extensible Firmware Interface (EFI) USB device, and the like, are also displayed in the BIOS setting interface; the BIOS setting interface further displays detailed information of each boot device, a status of the boot device, and the like, for example, displays a size of a hard disk, a detailed name of a USB device, a physical address (MAC) of a PXE device, and the like, where the status of each boot device is an open status or a closed status, and when the status of the boot device is the open status, it indicates that a boot item corresponding to the boot device is open, and when the status of the boot device is the closed status, it indicates that the boot item corresponding to the boot device is closed, and the status of each boot device may be controlled from the open status to the closed status, or from the closed status to the open status, by an Enter key on the keyboard 205.
It should be noted that when it is not detected that the user presses the first start shortcut key (e.g., the F2 key) on the keyboard, the normal boot process is directly executed without executing the subsequent steps provided in the embodiment of the present application.
Step 303, when the processor detects that the user presses the start item moving key, the processor changes the start order of each start item in the start item list.
A startup item moving key is further arranged on the keyboard 205, if a user needs to change the startup sequence of each startup item in the startup item list in the BIOS setting interface, the startup item moving key can be pressed down, when the embedded controller 204 detects that the user presses the startup item moving key, the embedded controller 204 generates a sequence change request and sends the sequence change request to the processor 201, when the processor 201 receives the sequence change request sent by the embedded controller 204, the processor 201 can determine that the user presses the startup item moving key, and then the processor 201 changes the sequence of each startup item in the startup item list according to the sequence change request.
The starting item moving key may be an F5 key or an F6 key in the keyboard 205, where the F5 key indicates that the starting sequence of the selected starting item is turned forward, and the F6 key indicates that the starting sequence of the selected starting item is turned backward. It should be understood that the starting item moving key corresponding to different types of terminal devices may be different, and the starting item moving key in the embodiment of the present application may also be other keys on the keyboard 205, and the like.
In the embodiment of the present application, the USB startup item needs to be adjusted to be the first startup item in the startup item list, and then after the USB startup item is selected by the cursor, the user may press the F5 key to change the USB startup item from the second startup item in the startup item list to the first startup item, thereby changing the startup sequence of each startup item in the startup item list in the BIOS setting interface, and the startup sequence of each startup item in the changed startup item list is shown as b in fig. 5.
Step 304, when the processor detects that the user presses the startup item saving key, the processor saves the changed startup item list.
A startup item saving key is further arranged on the keyboard 205, when a user adjusts the USB startup item to be the first startup item in the startup item list, the user can press the startup item saving key, when the embedded controller 204 detects that the user presses the startup item saving key, the embedded controller 204 generates a saving request and sends the saving request to the processor 201, when the processor 201 receives the saving request sent by the embedded controller 204, the processor 201 can determine that the user presses the startup item saving key, and then the processor 201 saves the changed startup item list according to the saving request.
The startup item saving key may be an F10 key in the keyboard 205, it should be understood that startup item saving keys corresponding to different types of terminal devices may be different, and the startup item saving key in this embodiment may also be another key on the keyboard 205.
It should be noted that, in some scenarios, if the first startup item in the BIOS setting interface is already set as the USB startup item before the current startup operation, the first startup item in the BIOS setting interface displayed in step 302 is the USB startup item, and therefore, the startup sequence of each startup item in the startup item list does not need to be changed, that is, step 303 does not need to be executed, and the user may directly press a startup item saving key (for example, the F10 key) to exit the BIOS setting interface, or the user may also press a Ctrl key + Alt key + Delete key to exit the BIOS setting interface. After exiting the BIOS setup interface, the terminal device may continue to perform the processes of step 305 to step 313 in the embodiment of the present application.
Step 305, in the process of restarting the terminal device, the processor judges whether the first startup item in the stored startup item list is a USB startup item.
After the processor 201 saves the changed startup item list, the terminal device is restarted, and in the process of restarting the terminal device, the processor determines whether the first startup item in the saved startup item list is a USB startup item, that is, determines whether the terminal device is started up with a USB startup item.
After restarting the terminal device, the BIOS executes a Power On Self Test (POST) program, which includes execution codes sequentially executing four phases of the BIOS power on self test program stored in the BIOS ROM chip, and enters a computer operating system after passing the power on self test. The four phases are a security phase (SEC) phase, a pre-EFI initialization (PEI) phase, a driver execution environment (DXE) phase, and a Boot Device Selection (BDS) phase.
The SEC stage is mainly used for receiving the starting, restarting, abnormal signals and the like of the system, opening up a space on a Cache (Cache) to be used as a memory, and transmitting system parameters to the PEI stage; the PEI phase is mainly related preparation work for the DXE phase, that is, initialization operations of a Central Processing Unit (CPU), a chip, a motherboard, and a memory are performed, and parameters required by the DXE phase are encapsulated and transmitted to the DXE phase; the DXE stage mainly carries out a large amount of driver loading and initialization work, namely traversing all drivers (drivers) in the firmware, and when the drivers are executed, indicating that the system finishes the initialization operation; the BDS phase mainly loads necessary device drivers and executes corresponding boot items according to user selection, for example, if a user sets a first boot item in a boot item list as a USB boot item in advance, it is detected whether the first boot item in the boot item list is a USB boot item in the BDS phase.
Since each stage has its own firmware storage location to be sequentially read and executed in the BIOS power on self test stage, and since these stages are standardized, detailed processes thereof are not described in detail in the embodiments of the present application.
In step 306, when the first boot item in the boot item list is a USB boot item, the processor loads a BIOS USB boot program.
When the processor determines that the first boot item in the saved boot item list is the USB boot item, the processor loads a BIOS USB boot program, where the BIOS USB boot program is mainly used to boot the processor to detect insertion of a USB device, boot the processor to perform initialization operation on the USB device, and the boot processor identifies the USB device as the USB boot device, that is, the running process after the BIOS USB boot program is loaded includes steps 307 to 310 of subsequent execution.
It should be noted that, when the first startup item in the startup item list is not a USB startup item, the processor executes a corresponding operation according to the first startup item in the startup item list, and ends the flow steps in the embodiment of the present application.
In step 307, the processor detects whether a USB device is plugged into the USB port.
As shown in fig. 6, a hub controller and D + and D-signal lines connected to the hub controller are provided in the USB hub 202, and a USB device controller and D + and D-signal lines connected to the USB device controller are provided in the USB device 22. A second resistor R2 is connected in parallel to the D + signal line in the USB device 22, the second resistor R2 may be referred to as a pull-up resistor, one end of the second resistor R2 is connected to the D + signal line in the USB device, and the other end of the second resistor R2 is connected to a high-level signal terminal (e.g., 3.3V); a third resistor R3 is connected in parallel to the D + signal line in the USB hub 202, a fourth resistor R4 is connected in parallel to the D-signal line in the USB hub 202, the third resistor R3 and the fourth resistor R4 may be called pull-down resistors, one end of the third resistor R3 is connected to the D + signal line in the USB hub 202, the other end of the third resistor R3 is connected to the ground terminal, one end of the fourth resistor R4 is connected to the D-signal line in the USB hub 202, and the other end of the fourth resistor R4 is connected to the ground terminal.
When no USB device 22 is plugged into the USB port, the D + signal line and the D-signal line in the USB hub 202 are pulled down to a low level by the pull-down resistors (i.e., the third resistor R3 and the fourth resistor R4) connected thereto, i.e., the levels of the D + signal line and the D-signal line in the USB hub 202 are both 0; when the USB device 22 is plugged into the USB port, the second resistor R2 and the third resistor R3 are connected in series to divide the voltage, so as to pull up the level of the D + signal line in the USB hub 202, and at this time, the level of the D-signal line in the USB hub 202 is still 0.
It should be understood that the USB device shown in fig. 6 is directed to a full-speed device or a high-speed device, and the second resistor R2 is connected to the D + signal line, while for a USB device that is a low-speed device, the second resistor R2 is connected to the D-signal line in the USB device 22, and when the USB device 22 is plugged into the USB port, the level of the D-signal line in the USB hub 202 is pulled high.
When the level of a signal line (D + signal line or D-signal line) in the USB hub 202 is pulled high, the USB hub 202 detects that a USB device is plugged into the USB port, the USB hub 202 reports the connection status of the USB port to the processor 201, and the processor 201 detects whether a USB device is plugged into the USB port according to the connection status reported by the USB hub 202.
In step 308, when a USB device is plugged into the USB port, the processor performs an initialization operation on the USB port.
When the connection state reported by the USB hub 202 indicates that a USB device is inserted into the USB port, the processor needs to perform an initialization operation on the USB device, and read various descriptor information from the USB device, so that the processor can determine which kind of device the inserted USB device is according to the read descriptor information, so that the processor can load an appropriate driver to prepare for subsequent communication between the processor and the USB device, and the initialization operation on the USB device may also be referred to as an enumeration operation on the USB device. When the connection status reported by the USB hub 202 indicates that no USB device is plugged into the USB port, the USB hub continues to wait for the USB device to be plugged.
When the processor performs an initialization operation on the USB device, the initialization operation of the processor on the USB port and the configuration operation of the processor on the USB device are mainly included.
The initialization operation on the USB port mainly includes: the method comprises the steps that firstly, a processor sends a Port state acquisition instruction Get _ Port _ Status to a USB hub, the USB hub responds to the Port state acquisition instruction and returns the Port state of a USB Port to the processor, the processor receives the Port state of the USB Port returned by the USB hub according to the Port state acquisition instruction, and the Port state is a busy state or an idle state; secondly, if the Port state is a busy state, the processor sends a Port state clearing instruction Clear _ Port _ Feature to the USB hub, and the USB hub clears a flag bit in a Port state (Status _ Change) register according to the Port state clearing instruction so as to Clear the Port state of the USB Port; and thirdly, the processor sends a write Port state instruction Set _ Port _ Feature to the USB hub, the USB hub sends a reset instruction reset to the USB device in response to the write Port state instruction, the USB hub maintains the reset instruction reset for at least 10ms, then the USB hub updates a Port update (Port _ Change) register, and the update of the Port _ Change register updates a Status _ Change register, so that the Port state of the USB Port is Set to be in an idle state.
Optionally, after setting the Port Status of the USB Port to the idle Status, the processor may continue to send a Port Status obtaining instruction Get _ Port _ Status to the USB hub, and determine whether the Status of the USB Port is the idle Status.
In step 309, the processor performs a configuration operation for the USB device.
After the initialization operation of the processor on the USB port is completed, the processor needs to perform a configuration operation on the USB device, and the configuration operation is mainly used to obtain various descriptor information of the USB device.
As shown in fig. 7, each USB Device has a Device descriptor (Device) that determines how many configurations the USB Device has, and each Configuration has a corresponding Configuration descriptor (e.g., configuration0 and Configuration 1); the configuration descriptor defines how many interfaces are in the configuration, and each Interface has a corresponding Interface descriptor (such as Interface0, interface1, interface2 and Interface 3); how many endpoints the interface has are defined in the interface descriptor, each Endpoint corresponds to an Endpoint descriptor (such as Endpoint1, endpoint2 to Endpoint1X, etc.), and the Endpoint descriptor defines the size, type, etc. of the Endpoint. It can be seen that the relationship between the descriptors of each USB device is distributed in multiple layers, with the device descriptors at the top layer, the configuration descriptors at the second layer, the interface descriptors at the third layer, and the endpoint descriptors at the bottom layer.
The configuration operation on the USB device is that the processor acquires a corresponding descriptor from the USB device, and determines information such as a device type of the inserted USB device, so that the processor can load an appropriate driver according to the acquired information to establish a communication mechanism between the processor and the USB device.
The configuration operation on the USB device mainly includes: in the first step, the processor sends a device descriptor acquisition instruction to the USB device through the USB hub, and the USB device sends its corresponding device descriptor to the processor through the USB hub in response to the device descriptor acquisition instruction. Specifically, the processor may first perform an operation of sending a Device descriptor obtaining instruction Get _ Device _ descriptor to the USB Device for the first time to obtain a maximum packet length supported by the default control pipe, and wait for a response of the USB Device within a limited time; then, the processor sends a write Address instruction Set _ Address to the USB device to allocate a unique device Address to the USB device, the USB device reads the write Address instruction Set _ Address, returns a confirmation instruction to the processor, and saves the device Address allocated by the processor, and then all instructions of the processor to the USB device are sent to the allocated device Address, and at this moment, the USB device is in an Address state; then, the processor sends a Device descriptor obtaining instruction Get _ Device _ descriptor to the USB Device, and the USB Device sends all fields of the Device descriptor corresponding to the USB Device to the processor in response to the Device descriptor obtaining instruction received for the second time. The device descriptor includes information such as a device manufacturer identifier VID and a product identifier PID of the USB device, and the device type of the USB device can be determined by the product identifier PID, that is, the device type of the USB device is determined to be any one of the storage device, the display device, and the charging device.
Secondly, when the device type corresponding to the field in the device descriptor is a storage device, the processor sends a configuration descriptor acquisition instruction to the USB device through the USB hub, and the USB device sends a configuration descriptor corresponding to the configuration descriptor acquisition instruction to the processor through the USB hub in response to the configuration descriptor acquisition instruction, where the configuration descriptor includes a vendor description, a product description (including a product type), a model and the like of the USB device, the product description refers to whether the USB device with the device type being the storage device is a USB disk or a removable hard disk, and the model refers to an interface standard of a USB supported by the USB device, for example, whether the USB device is a USB2.0 or a USB3.0.
In practice, when the USB device sends its corresponding configuration descriptor to the processor, the USB device also sends the interface descriptor to the processor together with the endpoint descriptor, etc.
After the processor receives the configuration descriptor sent by the USB device, the processor needs to judge whether the corresponding device driver is installed, when the corresponding device driver is installed, the device driver is directly loaded, if the corresponding device driver is not installed, the installation process of the device driver can be started, and the device driver is loaded after the installation is finished.
Thirdly, when the product type corresponding to the field in the Configuration descriptor is a USB disk and the device driver corresponding to the USB device is loaded, the processor generates a Configuration value according to the Configuration information included in the Configuration descriptor read from the USB device, and then the processor sends a Configuration instruction Set _ Configuration (x) to the USB device through the USB hub, where x represents a Configuration value other than 0, and if the Configuration is successful, the USB device is Set to the Configuration state.
After the enumeration of the USB device is completed, the interfaces and endpoints in the USB device have default working configurations, and the USB device completes the necessary configuration and connection work.
In step 310, the processor detects whether the USB device is successfully identified as a USB boot device.
In the embodiment of the present application, a boot program file is stored in the USB device, and the boot program file is an execution program file. After the initialization operation of the USB device by the processor is completed, the processor may attempt to read type information of the USB device, where the type information includes a file system type of the USB device and a type of a bootstrap file corresponding to the bootstrap file.
When the processor reads the file system type of the USB device and the bootstrap file type corresponding to the bootstrap file from the USB device, determining that the USB device is successfully identified as a USB starting device; and when the processor does not read the file system type of the USB device and/or the bootstrap file type corresponding to the bootstrap file from the USB device, determining that the USB device is not successfully identified as the USB starting device.
Therefore, the processor can detect whether the USB device is successfully identified as the USB boot device based on detecting whether the file system type of the USB device is read from the USB device and the bootstrap file type corresponding to the bootstrap file.
The USB starting device refers to a USB flash disk provided with a WINPE system, which can be understood as a simplified version of Windows or Windows Server, and the PE can directly run without installation and can guide a micro system and a minimum operating system of the system.
For example, the file system type may be a New Technology File System (NTFS) type, NTFS being a file system of the Windows NT operating environment and the Windows NT advanced Server network operating System environment; the boot file type refers to whether the file format of the boot file stored in the USB device is winpeshl.
If the processor detects only that the USB device is inserted, but fails to recognize the USB device as the USB boot device, the reason for the failure of the recognition is mainly due to the failure of the initialization operation of the processor on the USB device. The initialization operation of the USB device is a series of ordered and consecutive processes, a request in any link in the middle is wrong, or no response is made within a specified time, the initialization process fails, and after the initialization process fails, the processor cannot try to read the type information of the USB device, so that the processor cannot read the file system type and the bootstrap file type.
For example, the interface standard of the USB interface of the USB disk is USB2.0, but the interface standard of the USB interface of the terminal device is USB3.0, and the transmission speed of USB3.0 is greater than the transmission speed of USB2.0, when the processor of the terminal device sends a certain instruction to the USB device during the initialization process, because the transmission speed of the USB interface is slow, the processor does not receive the response information returned by the USB device based on the instruction within a long time, so that the whole initialization operation cannot be completed within a set time, and the processor may determine that the initialization process fails, and then the file system type and the bootstrap file type of all USB devices cannot be read subsequently.
In step 311, when the USB device is not successfully identified as the USB boot device for the first time, the processor controls the USB hub to send a reset instruction to the USB device to perform software reset.
When the processor does not successfully recognize the USB device as the USB starting device for the first time (i = 1), the processor sends a write Port status instruction Set _ Port _ Feature to the USB hub, and the USB hub sends a reset instruction reset to the USB device in response to the write Port status instruction, so that the status of the USB Port corresponding to the USB hub is restored to the initial status, and in the process, the USB hub and the USB device are not powered off. Based on the mode, the software reset of the USB equipment is realized.
After the processor controls the USB hub to send a reset command to the USB device, and performs software reset on the USB device, the processor performs step 309 and step 310 again, that is, performs configuration operation on the USB device again, and detects whether the USB device is successfully identified as the USB boot device again (i.e., for the second time).
It should be noted that the reason why the USB device as the USB boot device cannot be successfully identified in the boot process of the terminal device may be: the USB interface of the terminal device is incompatible with the interface standard of the USB device, for example, the USB interface of the terminal device is USB3.0, but the USB interface of the inserted USB device is USB2.0 or USB1.0, and since the signal transmission rate of the USB device is low, there may be a case that the initialization operation of the USB device by the processor cannot be completed in the set time length, that is, in the set time length, the initialization operation of the USB device by the processor may only be partially performed, and all the operations cannot be completed. For example, when the processor initializes the USB device, the processor may first obtain the port state of the USB port, when the port state is busy, the processor needs to clear the port state of the USB port, and then send a reset instruction to the USB device through the USB hub, and set the port state of the USB port to an idle state, and if the time duration spent in these steps reaches a set time duration, all steps of the initialization operation on the USB device are not completed within the set time duration, and the initialization operation on the USB device by the processor fails.
However, since some operations have already been performed in the previous initialization operation, these operations may reduce the steps performed for the initialization operation of the USB device after the software reset operation. For example, when the port state of the USB port is already set to the idle state at the time of the first initialization operation, after the software reset operation is performed, the port state clearing operation when the port state is the busy state does not need to be performed again.
Therefore, the execution steps of the initialization operation of the USB device after the software is reset are reduced in the embodiment of the present application, so that the probability that the processor can complete the initialization operation of the USB device with the set duration is increased, and the probability that the processor successfully identifies the USB device as the USB boot device is increased.
It can be understood that, in the embodiment of the present application, when the processor fails to recognize that the USB device is the USB boot device for the first time (i.e., i = 1), the processor performs a software reset operation on the USB device, and detects whether the USB device is successfully recognized as the USB boot device after the software reset operation is performed again, and when the USB device is not successfully recognized as the USB boot device, the processor may directly perform the hardware reset operation in step 312; or, when the processor does not successfully recognize the USB device as the USB boot device after one software reset operation, the processor may further continue to perform at least one software reset operation, and detect whether the USB device is successfully recognized as the USB boot device after each software reset operation is performed.
Optionally, the number of times that the processor executes the software reset operation on the USB device serving as the USB boot device in this embodiment is K, where K is a positive integer, and when the processor completes the K-th software reset operation and fails to successfully identify that the USB device is the USB boot device, the processor executes the hardware reset operation in step 312.
In step 312, when the USB device is not successfully identified as a USB boot device for the first time, the processor controls the embedded controller to send a reset level signal to the USB hub at least once, so as to perform hardware reset on the USB device.
After the processor performs software reset on the USB device, when the processor detects that the USB device is still not successfully identified as the USB starting device for the second time (i = 2), the processor sends a control instruction to the embedded controller, the embedded controller sends a low level signal to the USB hub according to the control instruction, the USB hub controls the USB device to be powered off based on the low level signal, after waiting for a preset time, the embedded controller sends a high level signal to the USB hub, and the USB hub supplies power to the USB device again based on the high level signal. Based on the above manner, the hardware reset of the USB device is implemented, and for convenience of description, the low level signal and the high level signal after the preset time interval are collectively referred to as a reset level signal.
After the processor controls the embedded controller to send a reset level signal to the USB hub, and performs a hardware reset on the USB device, the processor performs step 308, step 309, and step 310 again, i.e., continues to perform the initialization operation on the USB device (including the initialization operation on the USB port and the configuration operation on the USB device), and continues (i.e., for the third time) to detect whether the USB device is successfully identified as a USB boot device.
When the USB device is not successfully identified as the USB-enabled device for the third time (i.e., i = 3), the processor continues to perform steps 312, 308, 309, and 310, and when performing step 310, it is detected for the fourth time (i.e., i = 4) whether the USB device is successfully identified as the USB-enabled device; when the USB device is not successfully identified as the USB boot device for the fourth time, the processor continues to perform step 312, step 308, step 309, and step 310, and when step 310 is performed, it is detected for the fifth time whether the USB device is successfully identified as the USB boot device; when the USB device is not successfully identified as the USB-enabled device for the fifth time (i.e. i = 5), the execution process of the embodiment of the present application is ended, which indicates that the USB device as the USB-enabled device is still not successfully identified after the software reset and the hardware reset for 3 times.
The above process indicates that the number of times of executing the hardware reset in the embodiment of the present application may be 3, that is, the processor controls the embedded controller to send a reset level signal to the USB hub 3 times. It is to be understood that the number of times of executing the hardware reset in the embodiment of the present application may not be limited to 3 times, and may also be 1 time, 2 times, 4 times, or the like.
It should be noted that, after the software reset operation, the USB device serving as the USB boot device may still be unsuccessfully identified, which may be caused by interference of other USB devices connected to the terminal device with the USB boot device, so that the USB device serving as the USB boot device cannot be successfully identified.
In some embodiments, the processor controls the embedded controller to send the reset level signal for multiple times, that is, the number of times of executing the hardware reset is multiple times, a preset duration corresponding to the reset level signal sent for the (N + 1) th time is longer than a preset duration corresponding to the reset level signal sent for the nth time, and N is a positive integer.
For example, the processor controls the embedded controller to send a reset level signal for 3 times to the USB hub, the preset duration corresponding to the reset level signal sent for 2 nd time is longer than the preset duration corresponding to the reset level signal sent for 1 st time, and the preset duration corresponding to the reset level signal sent for 3 rd time is longer than the preset duration corresponding to the reset level signal sent for 2 nd time.
The embodiment of the application is mainly that the preset duration corresponding to the reset level signal sent for the (N + 1) th time is longer than the preset duration corresponding to the reset level signal sent for the nth time, because after the USB device is controlled to be powered off by the low level signal included in the reset level signal, data in the register included in the USB device gradually disappear, and if the time between the low level signal and the high level signal is short, the data in the register included in the USB device may not be completely eliminated, therefore, under the condition that the data in the register included in the USB device is not completely eliminated, and after the USB device is powered again by the high level signal included in the reset level signal, the USB device is not actually completely in a re-power-on state. Therefore, the preset time length corresponding to the reset level signal sent for the (N + 1) th time is longer than the preset time length corresponding to the reset level signal sent for the nth time, so that data in a register included in the USB device after power failure can be eliminated more thoroughly, the possibility that the USB device after hardware reset is in a complete power-on state is improved, and the possibility that the USB device is successfully identified is further improved.
Optionally, the preset duration corresponding to the N +1 th sent reset level signal is M times of the preset duration corresponding to the nth sent reset level signal, and M is a positive integer greater than 1.
For example, M may be 2, the processor controls the embedded controller to send a reset level signal to the USB hub for 3 times, a preset duration corresponding to the reset level signal sent for the 2 nd time is 2 times of a preset duration corresponding to the reset level signal sent for the 1 st time, and a preset duration corresponding to the reset level signal sent for the 3 rd time is 2 times of a preset duration corresponding to the reset level signal sent for the 2 nd time.
Taking the preset duration corresponding to the reset level signal sent at the 1 st time as 50ms as an example, the preset duration corresponding to the reset level signal sent at the 2 nd time is 100ms, and the preset duration corresponding to the reset level signal sent at the 3 rd time is 200ms.
The preset duration corresponding to the reset level signal sent for the (N + 1) th time is an integral multiple of the preset duration corresponding to the reset level signal sent for the nth time, and is mainly considered from the implementation angle of program codes.
It can be understood that, a ratio of the preset duration corresponding to the N +1 th sent reset level signal to the preset duration corresponding to the nth sent reset level signal may be equal to a ratio of the preset duration corresponding to the nth sent reset level signal to the preset duration corresponding to the N-1 st sent reset level signal, and of course, may also be unequal to.
Fig. 8 is a schematic diagram illustrating a connection between an embedded controller and a USB hub according to an embodiment of the present application. Referring to fig. 8, the embedded controller 204 is connected to an EN (enable) pin of the USB hub 202, and is configured to send a reset level signal to the EN pin of the USB hub 202.
As shown in fig. 8, the terminal device further includes a signal adjusting module, which includes a first filtering unit 41 and a voltage stabilizing unit 42; the first filtering unit 41 is respectively connected to the embedded controller 204 and the USB hub 202, and is configured to filter the reset level signal output by the embedded controller 204, so as to improve the anti-interference performance of the reset level signal output by the embedded controller 204 to the USB hub 202; one end of the voltage stabilizing unit 42 is connected to the first level signal end V5P0A _ PG, and the other end of the voltage stabilizing unit is connected to a path between the embedded controller 204 and the USB hub 202, and is configured to perform voltage stabilizing processing on the reset level signal output by the embedded controller 204, so as to improve stability of the reset level signal output by the embedded controller 204 to the USB hub 202.
The first filtering unit 41 includes a first resistor R1 and a first capacitor C1, a first end of the first resistor R1 is connected to the embedded controller 204, a second end of the first resistor R1 is connected to a first end of the first capacitor C1, the first end of the first capacitor C1 is further connected to an EN pin of the USB hub 202, and the second end of the first capacitor C1 is connected to a ground GND; the voltage stabilizing unit 42 includes a voltage stabilizing diode D1, an anode of the voltage stabilizing diode D1 is connected to the second end of the first resistor R1, and a cathode of the voltage stabilizing diode D1 is connected to the first level signal terminal V5P0A _ PG.
IN addition, the USB hub 202 further includes an input pin IN, an output pin OUT, a ground pin GND, etc., where the input pin is connected to the input power terminal V5P0A, the output pin OUT is connected to the USB port, and the ground pin GND is connected to the ground terminal GND.
The terminal device further includes a second filtering unit 43, one end of the second filtering unit 43 is connected to a path between the input power terminal V5P0A and the input pin IN of the USB hub, and the other end of the second filtering unit 43 is connected to the ground terminal GND, which is used for filtering the power signal input from the input power terminal V5P0A to the USB hub 202. The second filtering unit 43 includes a second capacitor C2 and a third capacitor C3 connected IN parallel, a first end of the second capacitor C2 is connected IN a path between the input power terminal V5P0A and the input pin IN of the USB hub, a second end of the second capacitor C2 is connected with the ground terminal GND, a first end of the third capacitor C3 is connected IN a path between the input power terminal V5P0A and the input pin IN of the USB hub, and a second end of the third capacitor C3 is connected with the ground terminal GND.
In step 313, when the USB device is successfully identified as a USB boot device, the processor loads the boot program file in the USB device via the USB hub.
When the processor successfully identifies that the USB device is a USB boot device, the processor may successfully identify that the USB device is a USB boot device after software reset, or may successfully identify that the USB device is a USB boot device after a certain hardware reset, the processor reads and loads a bootstrap file in the USB device through the USB hub, reinstalls an operating system of the terminal device based on the bootstrap file, or repair the operating system of the terminal device.
If the fault of the operating system is repaired by adopting the fault repairing program, the bootstrap program file actually refers to a fault repairing program file; if the reinstallation of the operating system is used to repair the failure of the operating system, the boot program file actually refers to a program that boots the terminal device to reinstall the operating system.
In summary, when the processor in the terminal device does not successfully recognize the USB device as the USB boot device, the embodiment of the present application may reset the USB device in a software reset manner first, and when the USB device still cannot be recognized, the embodiment of the present application resets the USB device in at least one hardware reset manner. Through software reset and hardware reset, the operation of manually plugging and unplugging the USB equipment is simulated, the identification of the USB equipment can be recovered without manual intervention, the operation of a user is simplified, and the use experience of the user is improved.
Correspondingly, whether the terminal equipment has faults or not can be detected in the software resetting and hardware resetting modes in the embodiment of the application, and the problem solving efficiency is improved. For example, after the operating system is started, the USB device can be normally identified, but the USB device cannot be normally identified in the startup stage, so that the user may mistakenly assume that the main board of the terminal device fails; however, in the embodiment of the present application, the USB device is not normally identified in the process of starting the identification, but after the software reset and the hardware reset, the USB device can be normally identified, and it is determined that the main board of the terminal device has no fault, which is caused by the incompatibility between the interface standard of the USB port of the terminal device and the interface standard of the USB device.
Fig. 9 is a flowchart of another USB device identification method according to an embodiment of the present application. Referring to fig. 9, the method for the terminal device to identify the USB device may include the following steps:
step 901, in the process of starting up the terminal device, the processor detects whether the user presses the second start shortcut key.
A power-on key and a second start-up shortcut key are arranged on the keyboard 205, and the embedded controller 204 detects pressing operations of various keys on the keyboard 205 by a user. When a user presses a power-on key, the embedded controller 204 detects that the user presses the power-on key, the embedded controller 204 sends a power-on request to the processor 201, and the processor 201 executes a power-on operation according to the power-on request sent by the embedded controller 204, so that the terminal device starts to start up.
In the process of starting up the terminal device, the embedded controller 204 may detect whether the user presses the second start shortcut key, and send the condition that whether the second start shortcut key is pressed to the processor 201, so as to implement detection of the pressing operation of the second start shortcut key by the processor 201, that is, detect whether the user presses the second start shortcut key.
The second start shortcut key may be an F12 key on the keyboard 205, and it should be understood that the second start shortcut keys corresponding to different types of terminal devices may be different, and the second start shortcut key in this embodiment may also be another key on the keyboard 205.
And 902, when the processor detects that the user presses the second start shortcut key, the processor controls the display screen to display a start item selection interface.
Taking the second start shortcut key as the F12 key as an example for explanation, when the embedded controller 204 detects that the user presses the F12 key, the embedded controller 204 generates a second start request and sends the second start request to the processor, when the processor 201 receives the second start request sent by the embedded controller 204, the processor 201 may determine that the user presses the F12 key, and then the processor 201 controls the display 206 to display the start item selection interface according to the second start request.
The starting item selection interface at least comprises a USB starting item, and optionally, the starting item selection interface further comprises starting items such as a hard disk starting item and a network starting item.
Step 903, when the processor detects that the user presses the start item selection key, the processor judges whether the selected start item is a USB start item.
The keyboard 205 is further provided with a start item selection key, when a user needs to start with a USB start item, the cursor is moved to the position of the USB start item in the start item selection interface, then the user presses the start item selection key, when the embedded controller 204 detects that the user presses the start item selection key, the embedded controller 204 generates a start item selection request, the start item selection request includes a start item selected by the cursor when the start item selection key is pressed, the embedded controller 204 sends the start item selection request to the processor 201, when the processor 201 receives the start item selection request sent by the embedded controller 204, the processor 201 can determine that the user presses the start item selection key, and then the processor judges whether the selected start item is a USB start item according to the start item selection request, that is, judges whether to start with the USB start item.
The startup item selection key may be an Enter key in the keyboard 205, it should be understood that the startup item selection keys corresponding to different types of terminal devices may be different, and the startup item selection key in the embodiment of the present application may also be other keys on the keyboard 205.
In step 904, the processor loads the BIOS USB boot program when the selected boot item is a USB boot item.
Step 905, the processor detects whether a USB device is plugged into the USB port.
In step 906, when a USB device is plugged into the USB port, the processor performs an initialization operation on the USB port.
In step 907, the processor performs a configuration operation on the USB device.
In step 908, the processor detects whether the USB device is successfully identified as a USB boot device.
In step 909, when the USB device is not successfully identified as the USB boot device for the first time, the processor controls the USB hub to send a reset instruction to the USB device for software reset.
In step 910, when the USB device is not successfully identified as a USB boot device for the first time, the processor controls the embedded controller to send a reset level signal to the USB hub at least once, so as to perform hardware reset on the USB device.
Step 911, when the USB device is successfully identified as the USB boot device, the processor loads the boot program file in the USB device through the USB hub.
The specific implementation of steps 904 to 911 shown in fig. 9 is similar to the specific implementation of steps 306 to 313 shown in fig. 3, and for avoiding repetition, it is not repeated here,
it can be understood that, in the process of starting with the USB startup item shown in fig. 9, the startup sequence of each startup item in the startup item list does not need to be changed, whereas in the process of starting with the USB startup item shown in fig. 3, the startup sequence of each startup item in the startup item list needs to be changed, and the USB startup item is set as the first startup item in the startup item list.
In summary, when the processor in the terminal device does not successfully identify the USB device that is the USB boot device, the embodiment of the present application may reset the USB device in a software reset manner first, and reset the USB device in at least one hardware reset manner when the USB device is still unidentifiable. Through software reset and hardware reset, the operation of manually plugging and unplugging the USB equipment is simulated, the identification of the USB equipment can be recovered without manual intervention, the operation of a user is simplified, and the use experience of the user is improved.
The terminal device in the embodiment of the application can be a notebook computer, a tablet computer, a desktop assembly computer, an all-in-one machine and the like, and can also be other electronic devices which need to be repaired or reinstalled by using the USB starting device.
In the embodiment of the application, the terminal device comprises a hardware layer, an operating system layer running on the hardware layer, and an application layer running on the operating system layer. The hardware layer includes hardware such as a central processing unit (cpu), a Memory Management Unit (MMU), and a memory (also referred to as a main memory). The operating system may be any one or more computer operating systems that implement business processes via processes (processes), such as a Linux operating system, a Unix operating system, or a windows operating system. The application layer comprises applications such as a browser, an address list, word processing software, instant messaging software and the like.
The above description has been made on the identification method of the USB device according to the embodiment of the present application, and the following description is made on an apparatus for performing the identification method of the USB device according to the embodiment of the present application. Those skilled in the art can understand that the method and the apparatus can be combined and referred to each other, and the identification apparatus of the USB device provided in the embodiments of the present application can perform the steps in the identification method of the USB device described above.
Fig. 10 is a schematic hardware structure diagram of an identification apparatus of a USB device according to an embodiment of the present application. Referring to fig. 10, the apparatus may be deployed in a terminal device, the apparatus including: a memory 209, a processor 201, an interface circuit 210, an embedded controller 204, a USB hub 202, and a USB port 203, wherein the memory 209, the processor 201, and the interface circuit 210 may communicate, and illustratively, the memory 209, the processor 201, and the interface circuit 210 may communicate via a communication bus; the processor 201 may also communicate with an embedded controller 204 and a USB hub 202, the embedded controller 204 may communicate with the USB hub 202, and the USB hub 202 may communicate with a USB port 203.
The memory 209 may be a read-only memory, a static memory device, a dynamic memory device, or a Random Access Memory (RAM). The memory 209 may store a computer program, which is controlled by the processor 201 to execute, and the interface circuit 210 performs communication, thereby implementing the identification method of the USB device provided in the above-described embodiment of the present application.
In a possible implementation manner, the computer execution instructions in the embodiment of the present application may also be referred to as application program codes, which is not specifically limited in the embodiment of the present application.
Optionally, the interface circuit 210 may further include a transmitter and/or a receiver. Alternatively, the processor 201 may be a general-purpose central processing unit, a microprocessor, an Application Specific Integrated Circuit (ASIC), a Graphics Processing Unit (GPU), or one or more Integrated circuits.
The processor 201 may also be an integrated circuit chip having signal processing capabilities. In implementation, the function of identification of the USB device of the present application may be performed by an integrated logic circuit of hardware or an instruction in the form of software in the processor 201. The processor 201 may also be a general-purpose processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, a discrete gate or transistor logic device, or a discrete hardware component, which can implement or execute the methods, steps, and logic blocks disclosed in the embodiments of the present application below. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the methods disclosed in the embodiments below in connection with the present application may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in the memory 209, and the processor 201 reads the information in the memory 209, and completes the function of identifying the USB device according to the embodiment of the present application in combination with the hardware thereof.
The embodiment of the application also provides a computer readable storage medium. The methods described in the above embodiments may be implemented in whole or in part by software, hardware, firmware, or any combination thereof. If implemented in software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media may include computer storage media and communication media, and may include any medium that can communicate a computer program from one place to another. A storage media may be any target media that can be accessed by a computer.
In one possible implementation, a computer-readable medium may include RAM, ROM, a compact disk-read-only memory (CD-ROM) or other optical disk storage, magnetic disk storage or other magnetic storage devices, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer. Also, any connection is properly termed a computer-readable medium. For example, if the software is transmitted from a website, server, or other remote source using a coaxial cable, fiber optic cable, twisted pair, digital Subscriber Line (DSL), or wireless technologies such as infrared, radio, and microwave, then the coaxial cable, fiber optic cable, twisted pair, DSL, or wireless technologies such as infrared, radio, and microwave are included in the definition of medium. Disk and Disc, as used herein, includes Disc, laser Disc, optical Disc, digital Versatile Disc (DVD), floppy disk and blu-ray Disc where disks usually reproduce data magnetically, while discs reproduce data optically with lasers. Combinations of the above should also be included within the scope of computer-readable media.
Embodiments of the present application are described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processing unit of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processing unit of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
The above embodiments are provided to explain the purpose, technical solutions and advantages of the present application in further detail, and it should be understood that the above embodiments are merely illustrative of the present application and are not intended to limit the scope of the present application, and any modifications, equivalent substitutions, improvements and the like made on the basis of the technical solutions of the present application should be included in the scope of the present application.

Claims (19)

1. A USB device identification method is applied to a terminal device, wherein the terminal device is provided with a USB port, and the method comprises the following steps:
judging whether the terminal equipment is started by a USB starting item or not in the starting process of the terminal equipment;
when the USB starting item is used for starting, determining whether a USB device is inserted into the USB port;
when a USB device is inserted into the USB port, determining whether the USB device is successfully identified as a USB starting device;
when the USB equipment is not successfully identified as the USB starting equipment, executing software reset operation, and determining whether the USB equipment is successfully identified as the USB starting equipment again;
when the USB equipment is not successfully identified as USB starting equipment, executing hardware reset operation, and continuously determining whether the USB equipment is successfully identified as the USB starting equipment or not;
and when the USB equipment is successfully identified as the USB starting equipment, loading the bootstrap program file in the USB equipment.
2. The method of claim 1, wherein the end device comprises a processor and a USB hub connected to each other, the USB hub being connected to the USB port; the executing the software reset operation comprises:
and the processor controls the USB hub to send a reset instruction to the USB equipment.
3. The method of claim 1, after the performing a software reset operation and determining again whether the USB device is successfully identified as a USB enabled device, further comprising:
when the USB equipment is not successfully identified as the USB starting equipment, at least one software resetting operation is continuously executed, and whether the USB equipment is successfully identified as the USB starting equipment or not is determined after each software resetting operation is executed.
4. The method according to claim 1, wherein the terminal device comprises a processor, an embedded controller and a USB hub which are connected in sequence; the executing a hardware reset operation includes:
the processor controls the embedded controller to send a reset level signal to the USB hub; the reset level signal comprises a low level signal and a high level signal after a preset time interval.
5. The method of claim 1, wherein after the performing a hardware reset operation and continuing to determine whether the USB device is successfully identified as a USB enabled device, further comprising:
when the USB equipment is still not successfully identified as the USB starting equipment, at least one hardware reset operation is continuously executed, and whether the USB equipment is successfully identified as the USB starting equipment or not is determined after each hardware reset operation is executed.
6. The method according to claim 4, wherein the processor controls the embedded controller to send the reset level signal for a plurality of times, and the preset duration corresponding to the reset level signal sent for the (N + 1) th time is longer than the preset duration corresponding to the reset level signal sent for the nth time, where N is a positive integer.
7. The method according to claim 6, wherein the preset duration corresponding to the reset level signal sent N +1 time is M times the preset duration corresponding to the reset level signal sent N time, and M is a positive integer greater than 1.
8. The method of claim 1, wherein the end device comprises a processor and a USB hub connected to each other, the USB hub being connected to the USB port; the determining whether a USB device is plugged into the USB port includes:
the processor receives the connection state reported by the USB concentrator;
and the processor determines whether a USB device is inserted into the USB port according to the connection state.
9. The method of claim 1, wherein the determining whether the USB device is successfully identified as a USB-enabled device comprises:
initializing the USB equipment;
and detecting whether the file system type of the USB device is read from the USB device and the bootstrap file type corresponding to the bootstrap file.
10. The method of claim 9, wherein the end device comprises a processor and a USB hub connected to each other, the USB hub being connected to the USB port; the initializing the USB device includes:
the processor performing an initialization operation for the USB port through the USB hub;
the processor performs configuration operations for the USB device through the USB hub.
11. The method of claim 10, wherein the processor performs initialization operations for the USB port via the USB hub, comprising:
the processor sends a port state acquisition instruction to the USB hub;
the processor receives the port state of the USB port returned by the USB hub according to the port state acquisition instruction;
when the port state is a busy state, the processor sends a port state clearing instruction to the USB hub so as to clear the port state of the USB port;
and the processor sends a port writing state instruction to the USB hub, so that the USB hub sends a reset instruction to the USB equipment, and the port state of the USB port is set to be an idle state.
12. The method of claim 10, wherein the processor performs configuration operations on the USB device via the USB hub, comprising:
the processor sends a device descriptor acquisition instruction to the USB device through the USB hub;
the processor receives the device descriptor returned by the USB device according to the device descriptor acquisition instruction;
when the device type corresponding to the field in the device descriptor is a storage device, the processor sends a configuration descriptor acquisition instruction to the USB device through the USB hub;
the processor receives a configuration descriptor returned by the USB equipment according to the configuration descriptor acquisition instruction;
and when the product type corresponding to the field in the configuration descriptor is a USB flash disk, the processor sends a configuration instruction to the USB equipment through the USB hub so as to set the USB equipment in a configuration state.
13. The method according to claim 1, wherein the terminal device comprises a processor, an embedded controller, a keyboard and a display screen, the keyboard is connected with the embedded controller, the embedded controller is connected with the processor, the display screen is connected with the processor, and the keyboard comprises a first startup shortcut key, a startup item moving key and a startup item saving key;
before the judging whether the starting is carried out by the USB starting item, the method further comprises the following steps:
in the starting process of the terminal equipment, when the processor receives a first starting request aiming at a BIOS setting interface sent by the embedded controller, the processor controls the display screen to display the BIOS setting interface; the first starting request is generated when the embedded controller detects the pressing operation of the first starting shortcut key, the BIOS setting interface comprises a starting item list, and the starting item list comprises a hard disk starting item, a USB starting item and a network starting item;
when the processor receives a sequence change request which is sent by the embedded controller and aims at the startup item list, the processor changes the sequence of each startup item in the startup item list; the sequence change request is generated when the embedded controller detects the pressing operation of the starting item moving key;
when the processor receives a storage request for the startup item list sent by the embedded controller, the processor stores the startup item list; the saving request is generated when the embedded controller detects the pressing operation of the starting item saving key;
in the process of starting up the terminal device, judging whether the terminal device is started up by a USB starting item or not includes:
and in the process of restarting the terminal equipment, the processor judges whether a first starting item in the stored starting item list is the USB starting item.
14. The method according to claim 1, wherein the terminal device comprises a processor, an embedded controller, a keyboard and a display screen, wherein the keyboard is connected with the embedded controller, the embedded controller is connected with the processor, the display screen is connected with the processor, and the keyboard comprises a second start shortcut key and a start item selection key;
in the process of starting up the terminal device, judging whether the terminal device is started up by a USB starting item or not includes:
in the starting process of the terminal equipment, when the processor receives a second starting request which is sent by the embedded control and aims at a starting item selection interface, the processor controls the display screen to display the starting item selection interface; the second starting request is generated by the embedded controller when the pressing operation of the second starting shortcut key is detected, and the starting item selection interface at least comprises a USB starting item;
when the processor receives a starting item selection request sent by the embedded controller, the processor determines whether the selected starting item is a USB starting item according to the starting item selection request; the launch item selection request is generated by the embedded controller upon detection of a pressing operation of the launch item selection key.
15. A terminal device comprising a processor and a memory;
the memory stores computer-executable instructions;
the processor is configured to execute the computer-executable instructions stored by the memory to cause the processor to perform the method of identifying a USB device as claimed in any one of claims 1 to 14.
16. The terminal device of claim 15, further comprising a signal conditioning module, wherein the signal conditioning module comprises a first filtering unit and a voltage stabilizing unit;
the first filtering unit is respectively connected with the embedded controller and the USB concentrator and is used for filtering the reset level signal output by the embedded controller;
one end of the voltage stabilizing unit is connected with the first level signal end, and the other end of the voltage stabilizing unit is connected in a passage between the embedded controller and the USB concentrator and is used for performing voltage stabilizing processing on the reset level signal output by the embedded controller.
17. The terminal device of claim 16, wherein the first filtering unit comprises a first resistor and a first capacitor; the first end of the first resistor is connected with the embedded controller, the second end of the first resistor is connected with the first end of the first capacitor, the first end of the first capacitor is further connected with the USB hub, and the second end of the first capacitor is connected with a grounding end;
the voltage stabilizing unit comprises a voltage stabilizing diode, the anode of the voltage stabilizing diode is connected with the second end of the first resistor, and the cathode of the voltage stabilizing diode is connected with the first level signal end.
18. A computer-readable storage medium, in which a computer program or instructions are stored, which, when executed, implement the identification method of a USB device according to any one of claims 1 to 14.
19. A system for identifying a USB device, the system comprising a USB device having a bootstrap file stored therein and a terminal device as claimed in any one of claims 15 to 17.
CN202111015367.7A 2021-08-31 2021-08-31 USB device identification method, terminal device and system Pending CN115729629A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111015367.7A CN115729629A (en) 2021-08-31 2021-08-31 USB device identification method, terminal device and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111015367.7A CN115729629A (en) 2021-08-31 2021-08-31 USB device identification method, terminal device and system

Publications (1)

Publication Number Publication Date
CN115729629A true CN115729629A (en) 2023-03-03

Family

ID=85291572

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111015367.7A Pending CN115729629A (en) 2021-08-31 2021-08-31 USB device identification method, terminal device and system

Country Status (1)

Country Link
CN (1) CN115729629A (en)

Similar Documents

Publication Publication Date Title
CN106990958B (en) Expansion assembly, electronic equipment and starting method
KR100990188B1 (en) A method for booting a host device from an MMC/SD device, a host device bootable from an MMC/SD device and an MMC/SD device method a host device may be booted from
US10228952B2 (en) System and method for accelerated boot performance
US9778844B2 (en) Installation of operating system on host computer using virtual storage of BMC
US7103765B2 (en) Method and system for providing a modulized server on board
US20070250564A1 (en) Method And System For Providing A Modular Server On USB Flash Storage
US9542201B2 (en) Network bios management
CN103412769A (en) External card parameter configuration method, equipment and system
CN109426613B (en) Method for retrieving debugging data in UEFI and computer system thereof
US7356684B2 (en) Booting system and/or method for initializing peripherals
US7467290B2 (en) Method and system for providing a modular server on USB flash storage
US20220214945A1 (en) System Booting Method and Apparatus, Node Device, and Computer-Readable Storage Medium
CN107135462B (en) Bluetooth pairing method of UEFI firmware and computing system thereof
CN109426527B (en) Computer system and method for sharing Bluetooth data between UEFI firmware and operating system
CN110688235B (en) System and method for sharing wireless connection information between UEFI firmware and OS
US6526525B1 (en) PCI debugging device, method and system
US20130097412A1 (en) Performing A Boot Sequence In A Multi-Processor System
US10198270B2 (en) Dynamic hardware configuration via firmware interface at computing device boot
US9501444B2 (en) USB device and method thereof for automatically recognizing microsoft windowing operating system version
CN116627472A (en) Firmware program upgrading method and server of high-speed peripheral component equipment
WO2023123896A1 (en) Disc loading control method, apparatus, and device, and readable storage medium
CN115729629A (en) USB device identification method, terminal device and system
CN112667544A (en) Method, device, system and medium for controlling mainboard slot enabling
TW201734800A (en) Method for setting redundant array of independent disks
CN118034722A (en) Operating system installation method, device, storage medium, and program product

Legal Events

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