CN110248181B - Self-reset method, device and system for external equipment and computer readable medium - Google Patents

Self-reset method, device and system for external equipment and computer readable medium Download PDF

Info

Publication number
CN110248181B
CN110248181B CN201910446362.6A CN201910446362A CN110248181B CN 110248181 B CN110248181 B CN 110248181B CN 201910446362 A CN201910446362 A CN 201910446362A CN 110248181 B CN110248181 B CN 110248181B
Authority
CN
China
Prior art keywords
interface number
external equipment
interface
self
camera
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.)
Active
Application number
CN201910446362.6A
Other languages
Chinese (zh)
Other versions
CN110248181A (en
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.)
Beijing Kuangshi Technology Co Ltd
Original Assignee
Beijing Kuangshi Technology 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 Beijing Kuangshi Technology Co Ltd filed Critical Beijing Kuangshi Technology Co Ltd
Priority to CN201910446362.6A priority Critical patent/CN110248181B/en
Publication of CN110248181A publication Critical patent/CN110248181A/en
Application granted granted Critical
Publication of CN110248181B publication Critical patent/CN110248181B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N17/00Diagnosis, testing or measuring for television systems or their details
    • H04N17/002Diagnosis, testing or measuring for television systems or their details for television cameras

Landscapes

  • Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • General Health & Medical Sciences (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Stored Programmes (AREA)

Abstract

The invention provides a self-resetting method, a self-resetting device, a self-resetting system and a computer readable medium of external equipment, wherein the self-resetting method of the external equipment comprises the following steps: according to an interface connected with external equipment, allocating an interface number for each external equipment, and establishing an interface number allocation table; when detecting that a device access event occurs, judging whether a newly accessed external device belongs to the interface number distribution table; and if the newly accessed external equipment belongs to the interface number distribution table, distributing the interface number corresponding to the newly accessed external equipment in the interface number distribution table to the newly accessed external equipment. The external equipment self-resetting method, the device, the system and the computer readable medium can keep the original interface number of the external equipment after the external equipment is restarted, and avoid the problem that the application layer can not open the equipment due to the change of the interface number of the equipment after the equipment is restarted.

Description

Self-reset method, device and system for external equipment and computer readable medium
Technical Field
The invention relates to the technical field of face recognition, in particular to a self-resetting method, a self-resetting device, a self-resetting system and a computer readable medium of external equipment.
Background
The situation that a plurality of cameras exist simultaneously often occurs in a face recognition system, for example, the face recognition system can be connected with an RGB camera, an IR (infrared) camera, an OCR (optical character recognition) camera for characters and matting, and the like. In order to facilitate integration and development, a USB interface is adopted in a plurality of systems to connect the camera, when the camera is used, for example, in the process of repeated switching or interference, the camera may be jammed and reset, and the like, and at the moment, the phenomena of jamming, black screen and the like occur in the video stream output on the screen, so that the user interface is static, and at the moment, the user can only restart the device to solve the problem, and the user experience is influenced.
Disclosure of Invention
In order to solve the problems, the invention provides a self-resetting scheme of external equipment. The following briefly describes the self-resetting scheme of the peripheral device proposed by the present invention, and further details will be described in the following detailed description with reference to the drawings.
According to an aspect of the embodiments of the present invention, there is provided a self-resetting method for an external device, the method including: according to an interface connected with external equipment, allocating an interface number for each external equipment, and establishing an interface number allocation table; when detecting that a device access event occurs, judging whether a newly accessed external device belongs to the interface number distribution table; and if the newly accessed external equipment belongs to the interface number distribution table, distributing the interface number corresponding to the newly accessed external equipment in the interface number distribution table to the newly accessed external equipment.
In one embodiment, the external device includes a camera.
In one embodiment, the method further comprises: when the video stream interruption of a certain camera is detected, determining the interface number of the camera; performing power-off restart on the camera corresponding to the interface number; wherein the device access event comprises the reboot.
In one embodiment, the method further comprises: if the newly accessed external equipment does not belong to the interface number distribution table, a new interface number is distributed to the newly accessed external equipment, and the new interface number is different from the original interface number in the interface number distribution table; and updating the interface number allocation table.
In one embodiment, establishing the interface number assignment table includes: recording the interface number allocated to each external device and the unique device identifier of the external device, wherein the interface number and the unique device identifier have a one-to-one correspondence relationship.
In one embodiment, whether the newly accessed external device belongs to the interface number allocation table is determined according to the unique device identifier.
In one embodiment, the interface comprises a USB interface.
According to another aspect of the embodiments of the present invention, there is provided a self-resetting device for an external device, including: the first distribution module is used for distributing an interface number for each external device according to the interface connected with the external device and establishing an interface number distribution table; the judging module is used for judging whether the newly accessed external equipment belongs to the interface number distribution table or not when detecting that an equipment access event occurs; and the second allocation module is used for allocating the interface number corresponding to the newly accessed external equipment in the interface number allocation table to the equipment if the newly accessed external equipment belongs to the interface number allocation table.
According to another aspect of the embodiments of the present invention, there is provided an external device self-resetting system, which includes a storage device and a processor, wherein the storage device stores thereon a computer program executed by the processor, and the computer program, when executed by the processor, performs any one of the external device self-resetting methods described above.
According to still another aspect of the embodiments of the present invention, there is provided a computer readable medium, on which a computer program is stored, the computer program, when executed, executing the external device self-resetting method of any one of the above.
The external equipment self-resetting method, the device, the system and the computer readable medium provided by the embodiment of the invention can automatically restart the external equipment after the external equipment is stuck, and retain the original interface number of the external equipment after the external equipment is restarted, so that the problem that the external equipment cannot be opened by an application layer due to the change of the interface number of the external equipment after the external equipment is restarted is avoided, the external equipment is self-reset under the condition that a user does not sense the external equipment, and the user experience is improved.
Drawings
The above and other objects, features and advantages of the present invention will become more apparent by describing in more detail embodiments of the present invention with reference to the attached drawings. The accompanying drawings are included to provide a further understanding of the embodiments of the invention and are incorporated in and constitute a part of this specification, illustrate embodiments of the invention and together with the description serve to explain the principles of the invention and not to limit the invention. In the drawings, like reference numbers generally represent like parts or steps.
FIG. 1 illustrates a schematic block diagram of an example electronic device for implementing an peripheral self-reset method, apparatus, system, and computer-readable medium in accordance with embodiments of the present invention;
FIG. 2 is a schematic flow chart diagram illustrating a method for self-resetting an external device according to an embodiment of the present invention;
fig. 3 shows a schematic block diagram of an external device self-resetting apparatus according to an embodiment of the present invention; and
fig. 4 shows a schematic block diagram of an external device self-reset system according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, exemplary embodiments according to the present invention will be described in detail below with reference to the accompanying drawings. It is to be understood that the described embodiments are merely a subset of embodiments of the invention and not all embodiments of the invention, with the understanding that the invention is not limited to the example embodiments described herein. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the invention described herein without inventive step, shall fall within the scope of protection of the invention.
First, an example electronic device 100 for implementing an external device self-reset method, apparatus, system, and computer-readable medium according to embodiments of the present invention is described with reference to fig. 1.
As shown in FIG. 1, electronic device 100 includes one or more processors 102, one or more memory devices 104, an input device 106, an output device 108, and an image sensor 110, which are interconnected via a bus system 112 and/or other form of connection mechanism (not shown). It should be noted that the components and structure of the electronic device 100 shown in fig. 1 are exemplary only, and not limiting, and the electronic device may have other components and structures as desired.
The processor 102 may be a Central Processing Unit (CPU) or other form of processing unit having data processing capabilities and/or instruction execution capabilities, and may control other components in the electronic device 100 to perform desired functions.
The storage 104 may include one or more computer program products that may include various forms of computer-readable storage media, such as volatile memory and/or non-volatile memory. The volatile memory may include, for example, Random Access Memory (RAM), cache memory (cache), and/or the like. The non-volatile memory may include, for example, Read Only Memory (ROM), hard disk, flash memory, etc. On which one or more computer program instructions may be stored that may be executed by processor 102 to implement client-side functionality (implemented by the processor) and/or other desired functionality in embodiments of the invention described below. Various applications and various data, such as various data used and/or generated by the applications, may also be stored in the computer-readable storage medium.
The input device 106 may be a device used by a user to input instructions and may include one or more of a keyboard, a mouse, a microphone, a touch screen, and the like.
The output device 108 may output various information (e.g., images or sounds) to an external (e.g., user), and may include one or more of a display, a speaker, and the like.
The image sensor 110 may take images (e.g., photographs, videos, etc.) desired by the user and store the taken images in the storage device 104 for use by other components. The image sensor 110 may be implemented in the form of an external device.
It should be noted that the components and the structure of the electronic device 100 shown in fig. 1 are only exemplary, and although the electronic device 100 shown in fig. 1 includes a plurality of different devices, some of the devices may not be necessary, some of the devices may be more in number, and the like, as required, and the present invention is not limited thereto.
Referring to fig. 2, a self-reset method 200 of an external device according to an embodiment of the present invention will be described, where the self-reset method 200 of an external device may be used in various face recognition systems, and may also be used in other systems with multiple external devices.
As shown in fig. 2, in step S210, an interface number is allocated to each external device according to the interface connected to the external device, and an interface number allocation table is established.
Taking the witness verification system as an example, the witness verification system may be connected to one or more RGB cameras, IR cameras and/or OCR cameras at the same time. The testimony verification system can be connected with a plurality of cameras of different types and can also be connected with a plurality of cameras of the same type. Besides the camera, the people's card verification system can also be connected with other external devices, such as an identity card reader, and is used for reading personal information stored in the certificate by adopting a short-distance wireless communication technology so as to be used for follow-up comparison and verification.
In one embodiment, the interface includes a USB (Universal Serial bus) interface with plug and play and hot plug capabilities. The interface also comprises other interfaces for realizing the connection and communication between the host computer and the external equipment.
Illustratively, when the testimony verification system is powered on, the testimony verification system automatically allocates an interface number to each of the external devices according to the interfaces connected with the external devices. For example, the USB peripheral device may include an RGB camera (USBID ═ 1), an IR camera (USBID ═ 2), an OCR camera (USBID ═ 3), and an identification card reader (USBID ═ 4), where USBID represents the interface number of the USB peripheral device. And the application of the upper layer operates the corresponding external equipment according to the interface numbers.
And when the interface number of the external equipment is completely distributed, establishing an interface number distribution table. For example:
USB ID description of the apparatus
1 RGB camera
2 IR camera
3 OCR camera
4 Identity card reader
In the interface number distribution table, the interface number distributed to each external device and the unique device identifier of the corresponding device are recorded, and the interface number and the unique device identifier have a one-to-one correspondence relationship. In other words, the interface number is associated and bound with the unique device identification.
The unique device identifier is an inherent identifier unique to each device, such as a device ID, a serial number, a device name, and the like, and used for indicating the uniqueness of the device.
In step S220, when it is detected that a device access event occurs, it is determined whether the accessed device belongs to the interface number allocation table.
Because the interface number and the unique device identification have a one-to-one correspondence relationship in the interface number distribution table, when a device access event is detected, whether the newly accessed external device belongs to the interface number distribution table can be judged according to the unique device identification of the newly accessed external device.
In one embodiment, the external device is a camera, and when the system detects that the camera fails, the application layer automatically performs power-off restart, and the system considers that the device access event occurs. Namely, when the video stream of a certain camera is detected to be interrupted, the interface number of the camera is determined, and the camera corresponding to the interface number is powered off and restarted.
Specifically, when a certain camera fails, the upper application layer detects that the video stream of the camera is interrupted, and immediately notifies the system firmware layer of the interface number of the failed camera. And the system firmware layer realizes the power-off restart of the camera by opening and closing the power supply circuit of the camera corresponding to the interface number. As described above, the application layer determines whether the external device is jammed by detecting whether the video stream is interrupted, so that the external device is automatically restarted when the external device is jammed, and does not need to be manually restarted by a user.
It can be understood that, when the device access event is an outage restart automatically performed by the application layer, the unique device identifier of the newly accessed external device is the same as the original device in the table, so that it can be determined that the newly accessed external device belongs to the interface number allocation table.
In another embodiment, the device access event may also be caused by an unexpected external device or an artificially operated external device restarting, and according to an actual situation, the newly accessed external device may belong to the interface number allocation table or may not belong to the interface number allocation table, and the application layer determines this according to the unique device identifier of the device.
In step S230, if the newly accessed external device belongs to the interface number allocation table, the interface number corresponding to the newly accessed external device in the interface number allocation table is allocated to the newly accessed external device.
Taking the above table as an example, suppose that the USB data signal of the IR camera with USB ID 2 is disturbed, and the USB data stream is interrupted. At this time, because the USB power supply is always available, the existing system may automatically assume that a hot plug has occurred, and the IR camera assigns a new USB ID 5 instead of maintaining its original USB ID 2, which may cause an exception when the upper layer application continues to operate the IR camera according to the original USB ID 2.
In contrast, in the embodiment of the present invention, in step S220, the application layer performs power-off restart on the IR camera when detecting that the data stream is interrupted, determines that the IR camera belongs to the interface number allocation table according to the device ID and the like of the IR camera, and in step S230, allocates the original USB ID (USB ID ═ 2) to the IR camera according to the correspondence between the device ID and the USB ID, and the application in the upper layer continues to operate the corresponding IR camera according to the USB ID 2, thereby avoiding the situation that the USB ID of the device after restart changes and the application layer cannot open the device, and implementing an imperceptible restart.
In an embodiment, if the newly accessed external device does not belong to the interface number allocation table, a new interface number is allocated to the newly accessed external device, where the new interface number is different from an original interface number in the interface number allocation table. And then updating the interface number distribution table.
Specifically, if the newly-accessed external device is not in the interface number allocation table, the newly-accessed external device is considered as a newly-inserted external device. Illustratively, referring to the table above, the currently largest USB ID may be added by 1 and assigned to the newly connected external device, for example, USB ID 5. And then, updating an interface number distribution table, and recording the interface number of the newly accessed external equipment and the unique equipment identification associated with the interface number in a list.
Illustratively, the external device self-reset method 200 according to the embodiment of the present invention may be implemented in a device, apparatus or system having a memory and a processor.
Illustratively, the external device self-resetting method 200 according to the embodiment of the present invention may be deployed at a face recognition system, such as a human authentication system, a face recognition access control system, and the like.
Alternatively, the external device self-resetting method 200 according to the embodiment of the present invention may also be deployed on a server side (or a cloud side).
Based on the above description, the external device self-reset method according to the embodiment of the invention can automatically restart the external device when the external device is in a pause, and the original interface number of the external device is retained after the external device is restarted, so that the problem that the external device cannot be opened by an application layer due to the change of the interface number of the external device after the external device is restarted is avoided, the external device is subjected to non-perception self-reset under the condition that a user does not perceive the external device, and the user experience is improved.
The above exemplary steps included in the external device self-resetting method according to the embodiment of the present invention are exemplarily described.
The following describes a self-resetting device of an external device according to another aspect of the present invention with reference to fig. 3.
Fig. 3 shows a schematic block diagram of an external device self-resetting apparatus 300 according to an embodiment of the present invention.
As shown in fig. 3, the external device self-resetting apparatus 300 according to the embodiment of the present invention includes a first allocating module 310, a determining module 320, and a second allocating module 330. The modules may respectively perform the steps/functions of the peripheral self-reset method described above in connection with fig. 2.
The first allocating module 310 is configured to allocate an interface number to each external device according to the interface connected to the external device, and establish an interface number allocation table.
Taking the witness verification system as an example, the witness verification system may be connected to one or more RGB cameras, IR cameras and/or OCR cameras at the same time. The testimony verification system can be connected with a plurality of cameras of different types and can also be connected with a plurality of cameras of the same type. Besides the camera, the people's card verification system can also be connected with other external devices, such as an identity card reader, and is used for reading personal information stored in the certificate by adopting a short-distance wireless communication technology so as to be used for follow-up comparison and verification.
In one embodiment, the interface includes a USB (Universal Serial bus) interface with plug and play and hot plug capabilities. The interface also comprises other interfaces for realizing the connection and communication between the host computer and the external equipment.
Illustratively, when the testimony verification system is powered on, the testimony verification system automatically allocates an interface number to each of the external devices according to the interfaces connected with the external devices. For example, the USB peripheral device may include an RGB camera (USBID ═ 1), an IR camera (USBID ═ 2), an OCR camera (USBID ═ 3), and an identification card reader (USBID ═ 4), where USBID represents the interface number of the USB peripheral device. And the application of the upper layer operates the corresponding external equipment according to the interface numbers.
And when the interface number of the external equipment is completely distributed, establishing an interface number distribution table. For example:
USB ID description of the apparatus
1 RGB camera
2 IR camera
3 OCR camera
4 Identity card reader
In the interface number distribution table, the interface number distributed to each external device and the unique device identifier of the corresponding device are recorded, and the interface number and the unique device identifier have a one-to-one correspondence relationship. In other words, the interface number is associated and bound with the unique device identification.
The unique device identifier is an inherent identifier unique to each device, such as a device ID, a serial number, a device name, and the like, and used for indicating the uniqueness of the device.
The determining module 320 is configured to determine whether the accessed device belongs to the interface number allocation table when detecting that a device access event occurs.
Because the interface number and the unique device identification have a one-to-one correspondence relationship in the interface number distribution table, when a device access event is detected, whether the newly accessed external device belongs to the interface number distribution table can be judged according to the unique device identification of the newly accessed external device.
In an embodiment, the external device self-resetting apparatus 300 further includes a restart module, configured to automatically perform power-off restart on the application layer when detecting that the camera fails, and when detecting that the restart occurs, the system considers that the device access event occurs. Namely, when the video stream of a certain camera is detected to be interrupted, the interface number of the camera is determined, and the camera corresponding to the interface number is powered off and restarted.
Specifically, when a certain camera fails, the restart module detects that the video stream of the camera is interrupted, and immediately notifies the system firmware layer of the interface number of the failed camera. And the system firmware layer realizes the power-off restart of the camera by opening and closing the power supply circuit of the camera corresponding to the interface number. As described above, the restart module determines whether the external device is jammed by detecting whether the video stream is interrupted, so that the external device is automatically restarted when the external device is jammed, and does not need to be manually restarted by a user.
It can be understood that, when the device access event is an outage restart automatically performed by the application layer, the unique device identifier of the newly accessed external device is the same as the original device in the table, so that it can be determined that the newly accessed external device belongs to the interface number allocation table.
In another embodiment, the device access event may also be caused by an unexpected or manually-operated external device restart, and according to an actual situation, the newly accessed external device may or may not belong to the interface number allocation table, and the application layer determines this according to the unique device identifier of the device.
The second allocating module 330 is configured to allocate, if the newly accessed external device belongs to the interface number allocation table, the interface number corresponding to the newly accessed external device in the interface number allocation table to the newly accessed external device.
Taking the above table as an example, suppose that the USB data signal of the IR camera with USB ID 2 is disturbed, and the USB data stream is interrupted. At this time, because the USB power supply is always available, the existing system may automatically assume that a hot plug has occurred, and the IR camera assigns a new USB ID 5 instead of maintaining its original USB ID 2, which may cause an exception when the upper layer application continues to operate the IR camera according to the original USB ID 2.
In contrast, in the embodiment of the present invention, when detecting that a data stream is interrupted, the restart module performs power-off restart on the IR camera, and determines that the IR camera belongs to the interface number allocation table according to the device ID and the like of the IR camera, and the second allocation module 330 allocates its original USB ID (USB ID is 2) to the IR camera according to the correspondence between the device ID and the USB ID, and the application in the upper layer continues to operate the corresponding IR camera according to the USB ID 2, thereby avoiding a situation that the USB ID of the device changes after restart and the application layer cannot open the device, and implementing an imperceptible restart.
In an embodiment, if the newly accessed external device does not belong to the interface number allocation table, a new interface number is allocated to the newly accessed external device, where the new interface number is different from an original interface number in the interface number allocation table. And then updating the interface number distribution table.
Specifically, if the newly-accessed external device is not in the interface number allocation table, the newly-accessed external device is considered as a newly-inserted external device. Illustratively, referring to the table above, the currently largest USB ID may be added by 1 and assigned to the newly connected external device, for example, USB ID 5. And then, updating an interface number distribution table, and recording the interface number of the newly accessed external equipment and the unique equipment identification associated with the interface number in a list.
Based on the above description, the external device self-reset device according to the embodiment of the invention can automatically restart the external device when the external device is in a pause, and the original interface number of the external device is retained after the external device is restarted, so that the problem that the external device cannot be opened by an application layer due to the change of the interface number of the external device after the external device is restarted is avoided, the non-perception self-reset of the external device is realized under the condition that a user does not perceive, and the user experience is improved.
Fig. 4 illustrates a schematic block diagram of an add-on self-reset system 400, according to an embodiment of the present invention. The peripheral self-reset system 400 includes a storage device 410 and a processor 420.
The storage device 410 stores program codes for implementing corresponding steps in the peripheral self-reset method according to the embodiment of the present invention. The processor 420 is configured to run the program codes stored in the storage 410 to perform the corresponding steps of the peripheral self-reset method according to the embodiment of the present invention, and to implement the corresponding modules in the peripheral self-reset device according to the embodiment of the present invention.
In one embodiment, the program code, when executed by processor 420, causes the peripheral self-reset system 400 to perform the following steps: according to an interface connected with external equipment, allocating an interface number for each external equipment, and establishing an interface number allocation table; when detecting that a device access event occurs, judging whether a newly accessed external device belongs to the interface number distribution table; and if the newly accessed external equipment belongs to the interface number distribution table, distributing the interface number corresponding to the newly accessed external equipment in the interface number distribution table to the newly accessed external equipment.
In one embodiment, the external device includes a camera.
In one embodiment, the program code, when executed by the processor 420, further causes the peripheral self-reset system 400 to perform: when the video stream interruption of a certain camera is detected, determining the interface number of the camera; and performing power-off restart on the camera corresponding to the interface number.
In one embodiment, the program code, when executed by the processor 420, further causes the peripheral self-reset system 400 to perform: if the newly accessed external equipment does not belong to the interface number distribution table, a new interface number is distributed to the newly accessed external equipment, and the new interface number is different from the original interface number in the interface number distribution table; and updating the interface number allocation table.
In one embodiment, establishing the interface number assignment table includes: recording the interface number allocated to each external device and the unique device identifier of the external device, wherein the interface number and the unique device identifier have a one-to-one correspondence relationship.
In one embodiment, whether the newly accessed external device belongs to the interface number allocation table is determined according to the unique device identifier.
In one embodiment, the interface comprises a USB interface.
In addition, according to an embodiment of the present invention, there is also provided a storage medium on which program instructions are stored, which when executed by a computer or a processor are used to execute corresponding steps of the external device self-resetting method according to an embodiment of the present invention, and are used to implement corresponding modules in the external device self-resetting apparatus according to an embodiment of the present invention. The storage medium may include, for example, a memory card of a smart phone, a storage component of a tablet computer, a hard disk of a personal computer, a Read Only Memory (ROM), an Erasable Programmable Read Only Memory (EPROM), a portable compact disc read only memory (CD-ROM), a USB memory, or any combination of the above storage media. The computer-readable storage medium may be any combination of one or more computer-readable storage media.
In one embodiment, the computer program instructions may implement the functional modules of the external device self-resetting apparatus according to the embodiment of the present invention when executed by a computer, and/or may execute the external device self-resetting method according to the embodiment of the present invention.
In one embodiment, the computer program instructions, when executed by a computer or processor, cause the computer or processor to perform the steps of: according to an interface connected with external equipment, allocating an interface number for each external equipment, and establishing an interface number allocation table; when detecting that a device access event occurs, judging whether a newly accessed external device belongs to the interface number distribution table; and if the newly accessed external equipment belongs to the interface number distribution table, distributing the interface number corresponding to the newly accessed external equipment in the interface number distribution table to the newly accessed external equipment.
In one embodiment, the external device includes a camera.
In one embodiment, the computer program instructions, when executed by a computer or processor, further cause the computer or processor to perform: when the video stream interruption of a certain camera is detected, determining the interface number of the camera; and performing power-off restart on the camera corresponding to the interface number.
In one embodiment, the computer program instructions, when executed by a computer or processor, further cause the computer or processor to perform: if the newly accessed external equipment does not belong to the interface number distribution table, a new interface number is distributed to the newly accessed external equipment, and the new interface number is different from the original interface number in the interface number distribution table; and updating the interface number allocation table.
In one embodiment, establishing the interface number assignment table includes: recording the interface number allocated to each external device and the unique device identifier of the external device, wherein the interface number and the unique device identifier have a one-to-one correspondence relationship.
In one embodiment, whether the newly accessed external device belongs to the interface number allocation table is determined according to the unique device identifier.
In one embodiment, the interface comprises a USB interface.
According to the external equipment self-reset method, the external equipment self-reset device, the external equipment self-reset system and the computer readable medium, the external equipment can be automatically restarted when the external equipment is in a pause, the original interface number of the external equipment is reserved after the external equipment is restarted, and the problem that the external equipment cannot be opened by an application layer due to the fact that the interface number of the external equipment is changed after the external equipment is restarted is solved, so that the external equipment is subjected to no-perception self-reset under the condition that a user does not perceive the external equipment, and user experience is improved.
Although the illustrative embodiments have been described herein with reference to the accompanying drawings, it is to be understood that the foregoing illustrative embodiments are merely exemplary and are not intended to limit the scope of the invention thereto. Various changes and modifications may be effected therein by one of ordinary skill in the pertinent art without departing from the scope or spirit of the present invention. All such changes and modifications are intended to be included within the scope of the present invention as set forth in the appended claims.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
In the several embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described device embodiments are merely illustrative, and for example, the division of the units is only one logical functional division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another device, or some features may be omitted, or not executed.
In the description provided herein, numerous specific details are set forth. It is understood, however, that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
Similarly, it should be appreciated that in the description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the invention and aiding in the understanding of one or more of the various inventive aspects. However, the method of the present invention should not be construed to reflect the intent: that the invention as claimed requires more features than are expressly recited in each claim. Rather, as the following claims reflect, inventive aspects lie in less than all features of a single disclosed embodiment. Thus, the claims following the detailed description are hereby expressly incorporated into this detailed description, with each claim standing on its own as a separate embodiment of this invention.
It will be understood by those skilled in the art that all of the features disclosed in this specification (including any accompanying claims, abstract and drawings), and all of the processes or elements of any method or apparatus so disclosed, may be combined in any combination, except combinations where such features are mutually exclusive. Each feature disclosed in this specification (including any accompanying claims, abstract and drawings) may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise.
Furthermore, those skilled in the art will appreciate that while some embodiments described herein include some features included in other embodiments, rather than other features, combinations of features of different embodiments are meant to be within the scope of the invention and form different embodiments. For example, in the claims, any of the claimed embodiments may be used in any combination.
The various component embodiments of the invention may be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. Those skilled in the art will appreciate that a microprocessor or other suitable processor may be used in practice to implement some or all of the functionality of some of the modules according to embodiments of the invention. The present invention may also be embodied as apparatus programs (e.g., computer programs and computer program products) for performing a portion or all of the methods described herein. Such programs implementing the present invention may be stored on computer-readable media or may be in the form of one or more signals. Such a signal may be downloaded from an internet website or provided on a carrier signal or in any other form.
It should be noted that the above-mentioned embodiments illustrate rather than limit the invention, and that those skilled in the art will be able to design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by one and the same item of hardware. The usage of the words first, second and third, etcetera do not indicate any ordering. These words may be interpreted as names.
The above description is only for the specific embodiment of the present invention or the description thereof, and the protection scope of the present invention is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present invention, and the changes or substitutions should be covered within the protection scope of the present invention. The protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (8)

1. A self-resetting method of an external device is characterized by comprising the following steps:
according to an interface connected with external equipment, allocating an interface number for each external equipment, and establishing an interface number allocation table, wherein the external equipment comprises a camera;
when the video stream interruption of a certain camera is detected, determining the interface number of the camera;
performing power-off restart on the camera corresponding to the interface number;
when detecting that a device access event occurs, judging whether a newly accessed external device belongs to the interface number distribution table, wherein the device access event comprises the power-off restart;
and if the newly accessed external equipment belongs to the interface number distribution table, distributing the interface number corresponding to the newly accessed external equipment in the interface number distribution table to the newly accessed external equipment.
2. The peripheral device self-resetting method according to claim 1, further comprising:
if the newly accessed external equipment does not belong to the interface number distribution table, a new interface number is distributed to the newly accessed external equipment, and the new interface number is different from the original interface number in the interface number distribution table; and
and updating the interface number distribution table.
3. The peripheral device self-reset method according to claim 1, wherein the establishing the interface number allocation table comprises:
recording the interface number allocated to each external device and the unique device identifier of the external device, wherein the interface number and the unique device identifier have a one-to-one correspondence relationship.
4. The peripheral device self-reset method according to claim 3, wherein whether the newly accessed peripheral device belongs to the interface number allocation table is determined according to the unique device identifier.
5. The peripheral device self-resetting method according to claim 1, wherein the interface comprises a USB interface.
6. The utility model provides an external equipment is from resetting means which characterized in that, external equipment is from resetting means includes:
the first distribution module is used for distributing an interface number for each external device according to the interface connected with the external device, and establishing an interface number distribution table, wherein the external device comprises a camera;
the restarting module is used for determining the interface number of a certain camera when the video stream of the camera is detected to be interrupted, and performing power-off restarting on the camera corresponding to the interface number;
the judging module is used for judging whether a newly accessed external device belongs to the interface number distribution table or not when detecting that a device access event occurs, wherein the device access event comprises the power-off restart; and the number of the first and second groups,
and the second allocating module is used for allocating the interface number corresponding to the newly accessed external equipment in the interface number allocation table to the equipment if the newly accessed external equipment belongs to the interface number allocation table.
7. An peripheral self-reset system, comprising a storage device and a processor, the storage device having stored thereon a computer program for execution by the processor, the computer program, when executed by the processor, performing the peripheral self-reset method of any one of claims 1-5.
8. A computer-readable medium, having stored thereon a computer program which, when executed, performs the peripheral self-reset method of any of claims 1-5.
CN201910446362.6A 2019-05-27 2019-05-27 Self-reset method, device and system for external equipment and computer readable medium Active CN110248181B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910446362.6A CN110248181B (en) 2019-05-27 2019-05-27 Self-reset method, device and system for external equipment and computer readable medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910446362.6A CN110248181B (en) 2019-05-27 2019-05-27 Self-reset method, device and system for external equipment and computer readable medium

Publications (2)

Publication Number Publication Date
CN110248181A CN110248181A (en) 2019-09-17
CN110248181B true CN110248181B (en) 2020-12-22

Family

ID=67884947

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910446362.6A Active CN110248181B (en) 2019-05-27 2019-05-27 Self-reset method, device and system for external equipment and computer readable medium

Country Status (1)

Country Link
CN (1) CN110248181B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112738505B (en) * 2021-04-06 2021-06-08 浙江华创视讯科技有限公司 Video communication method, device, medium and electronic equipment
CN113965381A (en) * 2021-10-21 2022-01-21 公安部第三研究所 Method, device, processor and computer readable storage medium for realizing security encryption function of monitoring video

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101727360A (en) * 2008-10-24 2010-06-09 安凯(广州)微电子技术有限公司 Hardware self-resetting method, device and mobile multimedia processor
CN105740180B (en) * 2014-12-10 2019-08-02 中国移动通信集团重庆有限公司 The virtual machine cut-in method and device of USB device
CN106933583A (en) * 2017-03-06 2017-07-07 联想(北京)有限公司 The method and computer equipment of hardware device are recognized in operating system
CN108255646B (en) * 2018-01-17 2022-02-01 重庆大学 Industrial control application program fault self-recovery method based on heartbeat detection
CN109344096A (en) * 2018-09-07 2019-02-15 彩讯科技股份有限公司 A kind of method, apparatus, equipment and storage medium connecting external equipment

Also Published As

Publication number Publication date
CN110248181A (en) 2019-09-17

Similar Documents

Publication Publication Date Title
CN110431556B (en) Electronic device and method for identifying counterfeits of biometric information
US11429439B2 (en) Task scheduling based on performance control conditions for multiple processing units
TWI684886B (en) Method and device for generating security problems and identity verification
CN107329750B (en) Identification method and skip method of advertisement page in application program and mobile terminal
EP3287866A1 (en) Electronic device and method of providing image acquired by image sensor to application
CN106157344B (en) Verification picture generation method and device
US9848072B2 (en) Electronic device monitoring method and apparatus
CN110888746B (en) Memory management method and device, storage medium and electronic equipment
KR102237373B1 (en) Method for task scheduling and Electronic device using the same
US20140344896A1 (en) Method and apparatus for using electronic device
US10402222B2 (en) Task migration method and apparatus
US9292753B2 (en) Parallel face detection and tracking system
CN110248181B (en) Self-reset method, device and system for external equipment and computer readable medium
CN108875516B (en) Face recognition method, device, system, storage medium and electronic equipment
CN112181333A (en) Multi-display based device
CN111104825A (en) Face registry updating method, device, equipment and medium
CN105637470A (en) Dirty data management for hybrid drives
CN112149570B (en) Multi-person living body detection method, device, electronic equipment and storage medium
KR102316846B1 (en) Method for sorting a media content and electronic device implementing the same
CN111401206A (en) Panorama sharing method, system, device and medium
US20190349517A1 (en) Video capturing system and network system to support privacy mode
US20170118401A1 (en) Electronic device and method for processing image
CN108875538B (en) Attribute detection method, device and system and storage medium
KR20170094895A (en) Method and electronic device for verifying fingerprint
CN107710211A (en) Intelligent terminal system starts method, apparatus and intelligent terminal

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
GR01 Patent grant
GR01 Patent grant