WO2021180148A1 - 识别充电盒开关盖的方法、耳机、充电盒、系统 - Google Patents
识别充电盒开关盖的方法、耳机、充电盒、系统 Download PDFInfo
- Publication number
- WO2021180148A1 WO2021180148A1 PCT/CN2021/080101 CN2021080101W WO2021180148A1 WO 2021180148 A1 WO2021180148 A1 WO 2021180148A1 CN 2021080101 W CN2021080101 W CN 2021080101W WO 2021180148 A1 WO2021180148 A1 WO 2021180148A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- processor
- information
- charging box
- cover
- verification
- Prior art date
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04R—LOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
- H04R1/00—Details of transducers, loudspeakers or microphones
- H04R1/10—Earpieces; Attachments therefor ; Earphones; Monophonic headphones
- H04R1/1025—Accumulators or arrangements for charging
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01V—GEOPHYSICS; GRAVITATIONAL MEASUREMENTS; DETECTING MASSES OR OBJECTS; TAGS
- G01V9/00—Prospecting or detecting by methods not provided for in groups G01V1/00 - G01V8/00
-
- H—ELECTRICITY
- H02—GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
- H02J—CIRCUIT ARRANGEMENTS OR SYSTEMS FOR SUPPLYING OR DISTRIBUTING ELECTRIC POWER; SYSTEMS FOR STORING ELECTRIC ENERGY
- H02J7/00—Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries
- H02J7/00032—Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries characterised by data exchange
- H02J7/00034—Charger exchanging data with an electronic device, i.e. telephone, whose internal battery is under charge
-
- H—ELECTRICITY
- H02—GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
- H02J—CIRCUIT ARRANGEMENTS OR SYSTEMS FOR SUPPLYING OR DISTRIBUTING ELECTRIC POWER; SYSTEMS FOR STORING ELECTRIC ENERGY
- H02J7/00—Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries
- H02J7/0042—Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries characterised by the mechanical construction
- H02J7/0045—Circuit arrangements for charging or depolarising batteries or for supplying loads from batteries characterised by the mechanical construction concerning the insertion or the connection of the batteries
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04R—LOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
- H04R1/00—Details of transducers, loudspeakers or microphones
- H04R1/10—Earpieces; Attachments therefor ; Earphones; Monophonic headphones
- H04R1/1041—Mechanical or electronic switches, or control elements
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04R—LOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
- H04R1/00—Details of transducers, loudspeakers or microphones
- H04R1/10—Earpieces; Attachments therefor ; Earphones; Monophonic headphones
- H04R1/1091—Details not provided for in groups H04R1/1008 - H04R1/1083
Definitions
- This application relates to the field of earphone technology, in particular to a method for identifying the switch cover of a charging box, an earphone, a charging box, a system, and a computer-readable storage medium.
- TWS True wireless Stereo
- earphones recognize the switch cover information of the charging box, which are all detected by sensors installed on the earphones.
- two magnets are correspondingly arranged on the lid of the charging box, and the information of the opening and closing lid of the charging box can be identified through the Hall-effect earphone.
- the way in which the earphone recognizes the opening and closing information of the charging box through the sensor requires additional sensors, is costly, takes up a large space, and has unstable reliability.
- a method, a device, an electronic device, and a computer-readable storage medium for identifying the switch cover of a charging box are provided.
- a method for identifying the switch cover of a charging box is applied to a headset including a first processor and a second processor, the first processor is connected to the second processor, and the method includes:
- the earphone receives the detection information sent by the charging box
- the second processor executes a first preset recognition strategy according to the detection information
- the second processor determines the switch cover status information of the charging box according to the recognition result, wherein the detection information is used to characterize the switch cover status information of the charging box cover, and the recognition result is obtained by executing the Obtained from the first preset recognition strategy.
- a method for identifying the switch cover of a charging box is applied to a headset including a first processor and a second processor, the first processor is connected to the second processor, and the method includes:
- the earphone receives the detection information sent by the charging box
- the first processor executes a second preset recognition strategy according to the detection information
- the second processor determines the switch cover status information of the charging box according to the recognition result, wherein the detection information is used to characterize the switch cover status information of the charging box cover, and the recognition result is obtained by executing the Obtained by the second preset recognition strategy.
- a method for identifying the switch cover of a charging box is applied to a charging box capable of charging a headset including a first processor and a second processor, the first processor is connected to the second processor, and the method include:
- the detection information is used to instruct the second processor to execute a first preset recognition strategy according to the detection information and to instruct the first processor to execute according to the detection information
- One of the second preset recognition strategies is also used to instruct the second processor to determine the state information of the charging box cover opening and closing according to the recognition result, wherein the detection information is used to characterize the charging box cover Cover opening and closing status information, the recognition result is obtained by executing one of the first preset recognition strategy and the second preset recognition strategy.
- a headset including:
- the first processor is configured to receive detection information sent by the charging box, where the detection information is used to characterize the state information of the cover opening and closing of the charging box cover;
- the second processor is connected to the first processor, and is configured to execute a first preset recognition strategy according to the detection information, and is also configured to determine the state information of the cover switch of the charging box according to the recognition result, wherein the The detection information is used to characterize the state information of the cover opening and closing of the charging box cover, and the recognition result is obtained by the second processor executing the first preset recognition strategy.
- a headset including:
- the first processor is configured to receive detection information sent by the charging box, where the detection information is used to characterize the cover opening and closing status information of the charging box cover, and execute a second preset identification strategy according to the detection information;
- the second processor connected to the first processor, is configured to determine the switch cover status information of the charging box according to the identification result, wherein the detection information is used to characterize the switch cover status information of the charging box cover ,
- the recognition result is obtained by the first processor executing one of the second preset recognition strategies.
- a charging box is used to charge a headset including a first processor and a second processor connected to the first processor, the charging box includes:
- Cover detection module used to detect the status information of the cover opening and closing of the charging box
- the third processor is configured to send detection information to the first processor, the detection information is used to characterize the state information of the opening and closing of the charging box, and the detection information is used to instruct the second processor to
- the detection information executes one of a first preset recognition strategy and is used to instruct the first processor to execute a second preset recognition strategy according to the detection information; the detection information is also used to instruct the second processor
- the state information of the opening and closing of the charging box is determined according to the identification result, and the identification result is obtained by executing one of the first preset identification strategy and the second preset identification strategy.
- a system for identifying the switch of a charging box includes the above-mentioned earphone and the above-mentioned charging box.
- a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of the above-mentioned method are realized.
- the above method for identifying the switch of the charging box, earphone, charging box, system and computer readable storage medium can avoid adding additional sensors on the earphone to detect the status information of the switch cover of the charging box, and significantly reduce the size and structural complexity of the earphone
- the headset communicates with the charging box by setting the first processor and/or the second processor (dual fuse), which can quickly and reliably synchronize the status information of the opening and closing cover of the charging box to the headset. Effectively ensure the accuracy of the headset to identify the status information of the switch cover.
- FIG. 1 is an application environment diagram of the method for identifying the opening and closing cover of the charging box in an embodiment
- Figure 2 is one of the flowcharts of the method for identifying the opening and closing of the charging box cover in an embodiment
- FIG. 3 is one of the flowcharts of the method for identifying the opening and closing cover of the charging box in an embodiment
- Figure 4 is one of the flowcharts of the method for identifying the opening and closing of the charging box cover in an embodiment
- FIG. 5 is one of the flowcharts of the method for identifying the opening and closing cover of the charging box in an embodiment
- Figure 6 is one of the flowcharts of the method for identifying the opening and closing of the charging box cover in an embodiment
- FIG. 7 is one of the flowcharts of the method for identifying the opening and closing cover of the charging box in an embodiment
- FIG. 8 is one of the flowcharts of the method for identifying the opening and closing cover of the charging box in an embodiment
- FIG. 9 is one of the flowcharts of the method for identifying the opening and closing cover of the charging box in an embodiment
- Fig. 10 is one of the flowcharts of the method for identifying the opening and closing of the charging box cover in an embodiment.
- first the terms “first”, “second”, etc. used in this application can be used herein to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from another element.
- the first processor may be referred to as the second processor, and similarly, the second processor may be referred to as the first processor. Both the first processor and the second processor are processors, but they are not the same processor.
- Fig. 1 is a schematic diagram of an application environment of a method for identifying a switch of a charging box in an embodiment.
- the application environment includes an earphone 110 and a charging box 120 for storing and charging the earphone 110.
- the headset 110 may be a true wireless stereo (TWS).
- TWS true wireless stereo
- the left and right earplugs of the TWS earphone 110 can work independently without cable connection by realizing the wireless separation of the left and right channels.
- the headset 110 includes a housing and various electronic components provided in the housing may include, but are not limited to, a first processor 112, a second processor 114, a headset interface module 116, a memory, a power management integrated circuit, a battery, a radio frequency circuit, and an input device. , Sensors, audio processing circuits, etc.
- the first processor 112 and the second processor 114 may be used to control the earphone interface module 116 to receive or send data from the external device and/or the charging box 120 to the external device and/or the charging box 120, the first processor 112 , The second processor 114 can be used to control the data transmission between the memory and the external device or the charging box 120, and can be used to control the power management integrated circuit and the like.
- the first processor 112 may be a controller such as a Microcontroller Unit (MCU), a CPU, a single-chip microcomputer, etc.
- the controller is configured with a plurality of functional pins, for example, may include a reset pin and a level shifter. Pins, communication pins, etc.
- Each functional pin of the first processor 112 can be connected to the second processor 114 correspondingly.
- the second processor 114 may be a Bluetooth chip, or another communication processor that can perform wireless communication with an external device, or the like.
- the first processor 112 may also be a Bluetooth chip
- the second processor 114 is a micro control unit.
- the earphone interface module 116 may include a plurality of contacts (POGO PIN), wherein the plurality of contacts are exposed outside the housing.
- POGO PIN a plurality of contacts
- two contacts can be used to realize the two functions of charging and communication.
- the 2 contacts can be used as charging contacts or as data transmission contacts. When used as a data transmission contact, it can be used to implement two-way data communication between the headset 110 and the headset 110 charging box 120.
- three contacts can also be used to realize the two functions of charging and communication. Among them, two contacts can be used as charging contacts and one contact can be used as data transmission contacts to realize the headset 110 and the charging box. Two-way data transmission between 120.
- the charging box 120 can be used to store the earphone 110 and can also charge the earphone 110 stored in the charging box 120.
- the electronic components built in the charging box 120 may include, but are not limited to, a cover detection module 122, a third processor 124, a box interface module 126, a memory, a power management circuit, a battery, and the like.
- the cover detection module 122 is used to detect the status information of opening and closing the cover of the charging box 120.
- the cover switch status information includes cover opening information and cover closing information.
- the lid detection module 122 is connected to the third processor 124, and the lid detection module 122 can generate the lid opening after detecting that the lid of the charging box 120 is opened.
- the information is sent to the third processor 124, and the lid detection module 122 can generate the lid closing information and send it to the third processor 124 after detecting that the lid of the charging box 120 is closed.
- the cover detection module 122 may include a Hall sensor and a magnet.
- the Hall sensor may be arranged at the opening position of the charging box 120, and the magnet may be arranged on the upper cover of the charging box 120.
- it can also be any type of mechanical or electronic switch, including but not limited to momentary switches, capacitive sensors, optical sensors, and micro switches. (The switch state is detected by the vibration of the charging box 120), the contact switch (for example, the switch state is determined by detecting the contact between the upper cover and the lower part).
- the box interface module 126 may include a plurality of contacts (POGO PIN).
- two contacts can be used to realize the two functions of charging and communication.
- the 2 contacts can be used as charging contacts or as data transmission contacts.
- three contacts can also be used to realize the two functions of charging and communication.
- two contacts can be used as charging contacts and one contact can be used as data transmission contacts to realize the headset 110 and the charging box. Two-way data transmission between 120.
- the multiple contacts of the earphone interface module 116 can be contacted and connected with the multiple contacts in the box interface module 126 in a one-to-one correspondence. If two contacts or one contact are used as data transmission contacts, the two-way data communication between the earphone 110 and the charging box 120 can be realized based on the earphone interface module 116 and the box interface module 126. Exemplarily, after the third process receives the switch cover status information, the switch cover status information may be transmitted to the earphone 110 based on the earphone interface module 116 and the box interface module 126.
- Fig. 2 is a flowchart of a method for identifying the switch of a charging box in an embodiment.
- the method of identifying the switch of the charging box in this embodiment is described by taking the headset 110 in FIG. 1 as an example.
- the method for identifying the opening and closing of the charging box includes step 202 to step 206.
- the earphone receives the detection information sent by the charging box, and the detection information is used to characterize the state information of the cover opening and closing of the charging box cover.
- the first processor 112 and the second processor 114 may be connected to the earphone interface module 116 respectively.
- the earphone interface module 116 is connected to the box interface module 126, two-way communication between the earphone 110 and the charging box 120 can be realized. That is, the charging box 120 can send the cover status information to the earphone 110, and at the same time, the earphone 110 can also send to the charging box 120 a verification request for verifying the authenticity of the information and response information for feeding back the received information.
- the charging box 120 is provided with a cover detection module 122 for real-time detection of the cover opening and closing status information of the charging box 120.
- the cover opening and closing status information includes cover opening information and cover closing information.
- the lid detection module 122 can generate lid opening information after detecting that the lid of the charging box 120 is opened, and send the lid opening information to the earphone 110 as detection information; the lid detection module 122 detects the opening of the charging box 120 After the box cover is closed, cover closing information can be generated, and the cover closing information is sent to the earphone 110 as detection information.
- the lid detection module 122 generates lid opening information after detecting that the lid of the charging box 120 is opened, and sends the lid opening information to the first processor 112 and the second processor 114 of the earphone 110 as detection information;
- the cover detection module 122 can generate cover closing information after detecting that the cover of the charging box 120 is closed, and send the cover closing information to the first processor 112 and the second processor 114 of the earphone 110 as detection information.
- the charging box 120 may send the detection information to the earphone 110 specifically including: the charging box 120 may send the detection information to the first processor 112 and the second processor 114 respectively according to a preset time sequence.
- the charging box 120 may first send the detection information to the first processor 112, that is, the time when the charging box 120 sends the detection information to the first processor 112 is earlier than the time when the detection information is sent to the second processor 124, or Yes, the time when the first processor 112 receives the detection information is earlier than the time when the second processor 124 receives the detection information.
- the charging box 120 may also send the detection information to the second processor 124 first, that is, the time when the charging box 120 sends the detection information to the second processor 124 is earlier than the time when the detection information is sent to the first processor 112, or, The time when the second processor 124 receives the detection information is earlier than the time when the first processor 112 receives the detection information.
- the charging box 120 can send detection information to the first processor 112 and the second processor 114 at the same time.
- the time sequence can be understood as the time sequence in which the charging box 120 sends the detection information to the first processor 112 and the second processor 114 respectively, and can also be understood as the time sequence in which the first processor 112 and the second processor 114 respectively receive the detection information.
- the detection information can be represented by codes or pulses and communicated between the charging box 120 and the earphone 110.
- codes it can be represented by one or a combination of numbers, letters and characters.
- the detection information can be represented by 010.
- the lid status information is lid closed information
- the detection information can be represented by 011.
- the detection information is represented by pulses, it can be represented by a different number of pulses. For example, when the cover closed status information is the cover open information, it can be represented by three pulses, and when the cover closed status information is the cover closed information , Can be represented by four pulses.
- the specific form of the detection information is not further limited, and may also be expressed in other ways, and is not limited to the above examples.
- the first processor 112 and the second processor 114 of the charging box 120 and the earphone 110 may pre-store the mapping relationship between the detection information and the code or the number of pulses.
- the charging box 120 may determine the specific manifestation of sending the detection information to the first processor 112 and the second processor 114 based on the detected lid opening information or lid closing information based on a preset mapping relationship.
- the first processor 112 and the second processor 114 can also identify the status information of the opening and closing of the charging box according to the mapping relationship between the detection information and the code or the number of pulses.
- Step 204 The second processor executes a first preset recognition strategy according to the detection information.
- the first preset identification strategy can be understood as an identification method for the second processor 114 to identify the state information of the opening and closing of the charging box 120 according to the detection information.
- the first preset identification strategy may be that the second processor 114 receives the detection information sent by the charging box 120, and recognizes the state information of the opening and closing of the charging box 120 according to the detection information.
- the detection information received by the first processor 112 can also be obtained from the first processor 112, and the status information of the cover opening and closing of the charging box 120 can be identified according to the detection information.
- the second processor 114 may correspondingly obtain the recognition results of recognizing the status information of the opening and closing of the charging box 120 twice.
- the first preset recognition strategy may also be that the second processor 114 recognizes the state information of the opening and closing lid of the charging box 120 according to the received detection information and according to the detection information, and sends a verification request to the charging box 120 to request verification of whether the identification result is Correctly, when the first preset identification strategy is executed, the second processor 114 can correspondingly obtain the verification information fed back by the charging box 120 according to the identification result.
- Step 206 The second processor determines the status information of the opening and closing of the charging box according to the identification result.
- the second processor 114 when the second processor 114 is executing the first preset recognition strategy, the second processor 114 correspondingly obtains the recognition results of recognizing the status information of the opening and closing of the charging box 120 twice, the second processor 114 The recognition results of the status information of the opening and closing of the charging box 120 can be compared twice to determine the status information of the opening and closing of the charging box 120.
- the second processor 114 when the second processor 114 is executing the first preset recognition strategy, and the second processor 114 correspondingly obtains the verification information fed back by the charging box 120 according to the recognition result, the second processor 114 may perform the The verification result is used to determine the status information of the opening and closing cover of the charging box 120.
- the method for identifying the opening and closing of the charging box includes step 302 to step 306.
- Step 302 the earphone receives the detection information sent by the charging box
- step 302 corresponds to step 202 in the foregoing embodiment, and will not be repeated here.
- Step 304 The first processor executes a second preset recognition strategy according to the detection information.
- the second preset identification strategy may be the detection information received by the first processor 112, and according to the detection information, identify the opening and closing status information of the charging box 120, and send a verification request to the charging box 120 to Request to verify whether the recognition result is correct.
- the first processor 112 may correspondingly obtain the verification information fed back by the charging box 120 according to the recognition result, and then send a conversion signal to the second processor according to the verification information.
- Step 306 The second processor determines the state information of the opening and closing cover of the charging box according to the identification result.
- the first processor 112 when the first processor 112 is executing the second preset recognition strategy, and the first processor 112 correspondingly obtains the verification information fed back by the charging box 120 according to the recognition result, the first processor 112 may use the The verification result is used to determine the switch cover status information of the charging box 120, and the switch cover status information is sent to the second processor, or the second processor directly receives the above verification information to determine the switch cover status information.
- both the first preset recognition strategy and the second preset recognition strategy can be correspondingly stored in the earphone 110 and the charging box 120 in advance, and can be used to independently select which strategy to use to identify the switch cover according to actual needs.
- For the status information it is also possible to determine which strategy is used first to identify the status information of the switch cover according to the recognition priority, or it can be determined by the manufacturer which strategy is used to recognize the status information of the switch cover.
- the selection of the first preset recognition strategy and the second preset recognition strategy is not further limited.
- the above method for identifying the opening and closing of the charging box includes the earphone 110 receiving the detection information sent by the charging box 120; the second processor executes the first preset identification strategy according to the detection information; and/or the first processor executes the second identification strategy according to the detection information.
- the second preset recognition strategy is obtained; additional sensors can be avoided on the earphone 110 to detect the status information of the opening and closing of the charging box 120, which significantly reduces the size and structural complexity of the earphone 110.
- the earphone 110 is set
- the first processor 112 and the second processor 114 (dual insurance mode) communicate with the charging box 120, which can quickly and reliably synchronize the opening and closing status information of the charging box 120 to the headset 110, effectively ensuring that the headset 110 recognizes the accuracy of the status information of the switch cover.
- the earphone 110 By setting the first processor 112 and the second processor 114 on the earphone 110 to identify the status information of the switch cover of the charging box 120, it is possible to avoid abnormalities, crashes, and poor real-time performance of the processor when only one processor is set.
- the earphone 110 recognizes the status information of the opening and closing of the charging box 120.
- the first processor 112 for example, a micro-control unit
- the method of the embodiment of the present application can avoid the occurrence of inaccurate recognition results caused by the weak performance of the first processor 112 At the same time, it can also avoid being unable to recognize when the first processor 112 is abnormal or crashes.
- the second processor 114 for example, a Bluetooth chip
- the startup phase will take several hundred milliseconds to several hundreds of milliseconds.
- the second processor 114 can only communicate after starting the second processor 114. If the earphone 110 is taken out by the user during the start-up phase of the second processor 114, the earphone 110 and the charging box 120 cannot continue to communicate with each other.
- the method of the application embodiment can avoid the situation that the earphone 110 cannot communicate with the charging box 120 to obtain the status information of the opening and closing lid of the charging box 120 due to the poor timeliness of the second processor 114. At the same time, it can also avoid When the second processor 114 is abnormal or fails to recognize the status information of the switch cover, it occurs.
- the execution of the first preset recognition strategy by the second processor 114 according to the detection information may specifically include steps 402 to 408.
- Step 402 The first processor receives the detection information, and sends a conversion signal to the second processor according to the detection information.
- the first processor 112 of the earphone 110 may receive the detection information, and send a conversion signal to the second processor 114 according to the received detection information.
- the first processor 112 is a micro-control unit and the second processor 114 is a Bluetooth chip as an example for description.
- the first processor 112 and the second processor 114 are electrically connected, and data transmission can be implemented between the first processor 112 and the second processor 114.
- the first processor 112 may be a micro-control unit with multiple functions. Wherein, the first processor 112 may be configured with multiple function pins, and different information may be output to the second processor 114 through the multiple function pins. Exemplarily, the first processor 112 may be configured as a cover detection pin, a reset pin, and the like. Take the cover detection pin as an example. After the first processor 112 receives the detection information sent by the charging box 120, it can perform conversion processing on the detection information to generate a corresponding conversion signal, and send the conversion signal to the second processor 114 via the cover detection pin.
- the detection information received by the first processor 112 is "010" or "three pulses", it can be recognized that the detection information is lid opening information based on the pre-stored mapping relationship; when the first processor 112 receives When the detection information of is “011” or “four pulses", based on the pre-stored mapping relationship, it can be recognized that the detection information is cover-closing information. After the first processor 112 recognizes the detection information, it can control the level state of the cover detection pin to generate a conversion signal for pairing. It can be understood that the conversion signal may be level information.
- the first processor 112 and the second processor 114 pre-store the mapping relationship between the switch cover status information and the level information.
- the level state of the lid detection pin being high corresponds to the detection information being lid opening information
- the level state of the lid detection pin being low level corresponds to the detection information being lid closing information.
- the level state of the lid detection pin being high corresponds to the detection information being lid closure information
- the level state of the lid detection pin being low level corresponds to the detection information being lid opening information.
- a high level corresponds to the cover opening information and a low level corresponds to the cover closing information as an example for description.
- the first processor 112 may convert the received lid opening information so that the lid detection pin of the first processor 112 outputs a high level (conversion Signal) to the second processor 114.
- the detection information received by the first processor 112 is cover closing information
- the first processor 112 can convert the received cover closing information so that the cover detection pin of the first processor 112 outputs a low level (conversion Signal) to the second processor 114.
- the conversion manner of the conversion signal and the specific presentation manner of the conversion signal are not limited to the above examples, and the corresponding conversion signal may also be generated through an encoding-decoding manner or other manners.
- Step 404 The second processor obtains the first state information according to the conversion signal
- the second processor 114 may also be correspondingly provided with a plurality of pins, so as to correspondingly connect with the plurality of multi-function pins of the first processor 112 in a one-to-one correspondence.
- the second processor 114 may also be provided with a signal receiving pin connected to multiple multi-function pins of the first processor 112, and when any information sent by the first processor 112 is received, it can be identified accordingly.
- the source of the information that is, the second processor 114 can correspondingly identify which functional pin of the first processing the received information originated from.
- the second processor 114 also pre-stores the corresponding relationship between the detection information and the code or the number of pulses, and also stores the mapping relationship between the switch cover status information and the level information.
- the second processor 114 may obtain the first state information for representing the state information of the switch cover based on the mapping relationship between the switch cover state information and the level information.
- the first status information is cover opening information
- the first status information is cover closing information.
- the first state information can be understood as the state information of the switch cover identified by the second processor 114 according to the conversion signal of the first processor 112 and used to characterize the charging box 120.
- Step 406 The second processor receives the detection information to obtain the second status information; where the second status information can be understood as the second processor 114 identifying the switch cover of the charging box 120 according to the detection information sent by the charging box 120 status information.
- the detection information received by the second processor 114 when the detection information received by the second processor 114 is "010" or "three pulses", it can be recognized that the detection information is lid opening information based on the pre-stored mapping relationship.
- the second status information is lid opening information; when the detection information received by the first processor 112 is "011" or "four pulses", it can be recognized that the detection information is lid closure information based on the pre-stored mapping relationship. That is, the second status information is cover-closing information.
- Step 408 The second processor obtains the identification result according to the first state information and the second state information.
- the second processor may obtain its recognition result according to the first state information and the second state information.
- the recognition result can be understood as the first status information or the second status information; when the first status information and the second status information are not the same, the recognition result It can be understood as verification information for the charging box to verify the first state information and/or the second state information.
- the second processor 114 may determine the status information of the cover opening and closing of the charging box 120 according to the recognition result. Exemplarily, when the first status information and the second status information are the same, the second processor 114 may use the first status information or the second status information as the cover opening and closing status information of the charging box 120; when the first status information and the second status information When the two status information are not the same, the second processor 114 can determine the status information of the opening and closing of the charging box 120 according to the verification information.
- step 402 is before step 406, that is, the time when the first processor 112 receives the detection information is earlier than the time when the second processor 114 receives the detection information.
- the first processor 112 may receive the detection information sent by the charging box 120 earlier than the second processor 114. At this time, the first processor 112 can quickly respond and receive the detection information, which can prevent the earphone 110 from being in In the shutdown state, it takes a while for the second processor 114 to start, and the headset 110 has been taken out of the charging box 120, and the second processor 114 cannot directly receive the detection information sent by the charging box 120.
- the processor 114 may obtain the switch cover status information from the first processor 112 to ensure the accuracy of obtaining the switch cover status information.
- the execution of the first preset recognition strategy by the second processor according to the detection information may specifically include step 502 to step 508.
- Step 502 The second processor receives the detection information, and obtains the second state information
- Step 504 The first processor receives the detection information, and sends a conversion signal to the second processor according to the detection information.
- Step 506 The second processor obtains the first state information according to the conversion signal
- Step 508 The second processor obtains the identification result according to the first state information and the second state information.
- the time when the first processor 112 receives the detection information is later than the time when the second processor 114 receives the detection information.
- the charging box 120 may first send the detection information to the second processor 114, which can improve the second processor 114's recognition of the open/closed state The speed of information to improve the efficiency of recognition.
- the second processor obtains the identification result according to the first state information and the second state information, and determines the state information of the opening and closing cover of the charging box according to the identification result, including steps 602 to 608 .
- Step 602 The second processor determines whether the first state information and the second state information are the same.
- the second processor 114 may also receive the conversion signal from the first processor 112, and obtain the first state information according to the conversion signal. Moreover, the second processor 114 may directly receive the detection information sent by the charging box 120, and obtain the second status information according to the detection information, where the first status information and the second status information are both used to indicate the cover of the charging box 120 The status information of the switch cover.
- the second processor 114 can recognize that the detection information sent by the charging box 120 is the opening of the lid.
- the information, that is, the corresponding second status information is cover opening information.
- the second processor 114 can recognize that the detection information sent by the charging box 120 is cover-closing information, that is, , The corresponding second status information is cover-closing information.
- the first status information is cover opening information
- the conversion signal received by the second processor 114 is a low-level signal
- the first status information is cover closing information
- the second processor 114 may determine whether the second state information and the first state information are equal.
- Step 604 When the second status information is the same as the first status information, the second processor uses the second status information or the first status information as the cover switch status information of the charging box.
- the second processor 114 may determine according to the second status information or the first status information Status information of the opening and closing cover of the charging box 120. Exemplarily, if the second status information or the first status information is cover opening information, it can be determined that the cover opening and closing status information of the charging box 120 is cover opening information, and if the second status information or the first status information is cover closing information At this time, it can be determined that the cover opening and closing status information of the charging box 120 is cover closing information.
- Step 606 When the second status information is different from the first status information, the second processor uses the second status information as the cover opening and closing status information of the charging box.
- the second state information obtained by the second processor 114 when the second state information obtained by the second processor 114 is different from the first state information, the second state information obtained directly by the second processor 114 can identify the state information of the cover opening and closing of the charging box 120, Because the first state information needs to be acquired after conversion based on the detection information received by the first processor 112, the first state information is more likely to be abnormal.
- the second processor 114 uses the second status information as the cover opening and closing status information of the charging box 120, which can improve the recognition efficiency.
- Step 608 When the second status information is different from the first status information, the second processor sends a first verification request to the charging box, and the second processor identifies the switch cover status information according to the first verification information fed back by the charging box.
- the verification request is used to instruct the charging box to verify the second state information and/or the first state information received by the second processor.
- the second processor 114 when the second state information is different from the first state information, the second processor 114 sends a first verification request carrying the second state information or the first state information to the charging box 120, and the first verification request It is used to instruct the charging box 120 to verify the authenticity of the second state information or the first state information, and feed back the first verification information according to the verification result.
- the second processor 114 receives the first verification information fed back by the charging box 120.
- the first verification information includes a first verification result in which the charging box 120 verifies the authenticity of the second state information, and/or a second verification result in which the charging box 120 verifies the authenticity of the first state information.
- the second processor determining the state information of the switch cover according to the first verification information fed back by the charging box includes: the second processor recognizes the state information of the switch cover according to the first verification result or the second verification result.
- the authenticity of the second state information obtained by the second processor 114 may be verified according to the first verification request.
- the second processor 114 may also send the second status information to the charging box 120 in the form of code or pulse, so that the charging box 120 can compare the received second status information with the lid opening and closing state detected by the lid detection module 122. Information is compared. If the comparison results are consistent, the second state information is true; if the comparison results are inconsistent, the second state information is false.
- the charging box 120 may feed back the first verification information to the second processor 114 according to the verification result, where the first verification information may be used to characterize the authenticity of the second state information.
- the authenticity of the first status information received by the second processor 114 may be verified according to the first verification request.
- the second processor 114 may also send the first status information to the charging box 120 in the form of code or pulse, so that the charging box 120 can compare the received first status information with the lid opening and closing state detected by the lid detection module 122. Information is compared. If the comparison results are consistent, it means that the first status information is true. If the comparison results are inconsistent, it means that the first status information is false.
- the charging box 120 may feed back the first verification information to the second processor 114 according to the verification result, where the first verification information may be used to characterize the authenticity of the first state information.
- the first verification information may also be transmitted between the charging box 120 and the first processor 112 and the second processor 114 in the form of codes or pulses.
- the first verification information can be transmitted in the form of "100" or a pulse. If the detection information is false or the second detection result is true, then the first verification information can be transmitted in the form of "100" or a pulse.
- a verification message can be transmitted in the form of "001" or two pulses.
- the second processor 114 may determine the state information of the opening and closing of the charging box 120 according to the received first verification information. If the first verification information is "100" or a pulse, it indicates that the second state information received by the second processor 114 is true or the first state information is false, that is, the first processor 112 receives information from the first processor 112. The acquired conversion signal is inaccurate, that is, it can be determined that the first processor 112 is abnormal or malfunctioning, and then the status information of the opening and closing cover of the charging box 120 can be identified according to the second status information. If the first verification information is "001" or two pulses, it indicates that the second state information received by the second processor 114 is false or the first state information is true, and the second processor 114 can determine according to the first state information. Identify the status information of the opening and closing of the charging box 120.
- the method before the second processor recognizes the switch cover status information according to the first verification information fed back by the charging box, the method further includes: the first processor receives a reset instruction sent by the charging box, and the reset instruction indicates that the charging box is verifying the first Generated when the second state information is false; the first processor performs a reset operation on the second processor according to the reset instruction so that the second processor receives the first verification information.
- the charging box 120 may send a reset instruction to the first processor 112, and the first processor 112 may perform a reset operation on the second processor 114 according to the reset instruction, so as to restore the second processor 114 to a normal state.
- the first processor 112 may be configured with a reset pin, and when the first processor 112 receives a reset instruction, it may control the level of the reset pin to invert to transmit to the reset terminal of the second processor 114 , The reset operation of the second processor 114 is implemented. It should be noted that, in the embodiment of the present application, the reset operation of the first processor 112 on the second processor 114 is not limited to the example of this example, and may also be in other manners.
- the reset command can be expressed in the form of codes or pulses.
- the specific expression form is not further limited in the embodiments of this application.
- the second processor 114 can continue to receive the first verification information fed back by the charging box, and further, can identify the state information of the opening and closing of the charging box 120 according to the received first verification information .
- the second processor identifies the switch cover status information according to the first verification information fed back by the charging box; it can also be charging
- the box sends the first verification information to the first processor, and then the first processor resets the second processor according to the first verification information, and continuously provides the second processor with a conversion signal that characterizes the state of the open/close lid. So that the second processor can obtain correct cover opening and closing information according to the conversion signal after resetting.
- the second processor 114 may identify the open/closed state information of the charging box 120 according to the second state information and the first state information, so as to improve the accuracy of identifying the open/close lid information. Further, the second processor 114 may also send the acquired second state information or the first state information to the charging box 120 to implement two-way communication with the charging box 120, so that the charging box 120 is aware of the second processing of the first processor 112 The detector 114 has received the detection information. At the same time, the second status information or the first status information can also be verified, which can avoid the situation that the first processor 112 does not respond to the detection information when an abnormality occurs, and at the same time, the recognition accuracy can be improved.
- the execution of the first preset recognition strategy by the second processor according to the detection information specifically includes steps 702 to 706.
- Step 702 The first processor obtains detection information, and sends a conversion signal to the second processor according to the detection information.
- Step 704 The second processor obtains the first state information according to the conversion signal.
- Step 702 to step 704 correspond to step 402 to step 404 in the foregoing embodiment one-to-one, and details are not described herein again.
- Step 706 The second processor sends a second verification request to the charging box.
- the second verification request is used to instruct the charging box to verify the authenticity of the first state information (the authenticity is whether the state of the open/close cover represented by the first state information is correct). Verify, and feed back the second verification information according to the verification result.
- the second verification information includes a third verification result corresponding to when the first status information is true and a fourth verification result corresponding to when the first status information is false.
- the second processor 114 sends a second verification request carrying the first state information to the charging box 120.
- the charging box 120 receives the second verification request, the authenticity of the first status information received by the second processor 114 can be verified according to the second verification request.
- the second processor 114 may also send the first status information to the charging box 120 in the form of code or pulse, so that the charging box 120 can compare the received first status information with the lid opening and closing state detected by the lid detection module 122. The information is compared and verified. If the comparison results are consistent, the first state information is true, and the charging box 120 may feed back the third verification result to the second processor 114, where the second verification information is represented by the third verification result.
- the third verification result may also be transmitted between the charging box 120 and the second processor 114 in the form of codes or pulse numbers.
- the third verification result may be transmitted in the form of "100" or one pulse.
- the second processor 114 receives the third verification result of "100" or one pulse fed back by the charging box 120, and the second processor 114 can identify the state information of the switch cover according to the received first state information.
- the charging box 120 compares the received first status information with the opening/closing status information detected by the cover detection module 122. If the comparison results are inconsistent, it means that the first status information is false, and the charging box 120 can report to the second processor 114 Send the fourth verification result.
- the fourth verification result may also carry detection information, and the second processor 114 may identify the state information of the opening and closing of the charging box 120 according to the received detection information.
- the second processor determining the state information of the switch cover of the charging box according to the identification result includes: the second processor recognizes the state information of the switch cover according to the second verification information fed back by the charging box.
- the second verification information received by the second processor 114 refers to the third verification result that the first state information is true, it indicates that the first state information obtained by the second processor 114 is correct, and the second The processor 114 may use the acquired second status information as the cover opening and closing status information of the charging box 120.
- the second processor 114 may According to the received fourth verification result, or the detection information carried by the fourth verification result, the state information of the cover opening and closing of the charging box 120 is determined.
- the first status information is cover-closing information
- the second verification information received by the second processor 114 refers to the fourth verification result that the first status information is false
- the second processor 114 may The fourth verification result directly determines that the lid opening and closing status information of the charging box 120 is lid opening information.
- the second processor 114 may also determine the state information of the opening and closing of the charging box 120 according to the detection information carried in the fourth verification result.
- the second processor 114 can actively communicate with the charging box 120 after receiving the first state information, so that the charging box 120 verifies the first state information received by the second processor 114 to determine the second state information. Whether the first status information received by the processor 114 is correct, so as to improve the reliability of the second processor 114 in recognizing the status information of the opening and closing cover.
- the execution of the second preset recognition strategy by the first processor according to the first detection signal specifically includes steps 802 to 808.
- Step 802 The first processor receives the detection information to obtain third status information.
- the third status information can be understood as the status information of the opening and closing of the charging box 120 that is identified by the first processor 112 according to the detection information sent by the charging box 120.
- the detection information received by the first processor 112 when the detection information received by the first processor 112 is "010" or “three pulses", based on the pre-stored mapping relationship, it can be recognized that the detection information is lid opening information, that is, its The third status information is lid opening information; when the detection information received by the first processor 112 is "011" or "four pulses", it can be recognized that the detection information is lid closure information based on the pre-stored mapping relationship. That is, the third status information is cover-closing information.
- the first processor sends a third verification request to the charging box; the third verification request is used to instruct the charging box to verify the authenticity of the third status information, and send it to the first processor or the second processor according to the verification result. Feedback the third verification information.
- the third verification information may be different for different processors, the third verification information received by the first processor is the fifth verification result corresponding to the detection information being true, and the third verification information received by the second processor It is the sixth verification result corresponding to when the third status information is false.
- the first processor 112 after the first processor 112 receives the detection information, the first processor 112 sends a third verification request carrying the third status information to the charging box 120.
- the authenticity of the third state information obtained by the first processor 112 may be verified according to the third verification request.
- the first processor 112 may also send the detection information to the charging box 120 in the form of codes or pulses, so that the charging box 120 performs a check on the received third status information and the cover opening and closing status information detected by the cover detection module 122.
- the charging box 120 may feed back to the first processor 112 the fifth verification result corresponding to the third state information being true, where the third verification information may be Five verification results to show.
- the charging box 120 can feed back to the second processor 114 the sixth verification result corresponding to the third state information being false, where the sixth verification result can be used as the third verification information To represent.
- the fifth verification result and the sixth verification result may also be transmitted between the charging box 120 and the first processor 112 in the form of codes or pulse numbers.
- the fifth verification result may be transmitted in the form of "100" or one pulse.
- the first processor 112 may correspondingly receive the fifth verification result of “100” or one pulse fed back by the charging box 120.
- the sixth verification result can be transmitted in the form of "001" or two pulses.
- the first processor 112 may correspondingly receive the sixth verification result of “001” or two pulses fed back by the charging box 120.
- the second processor determining the switch cover status information of the charging box according to the recognition result includes: the first processor instructs the second processor to recognize the switch cover status information according to the third verification information fed back by the charging box.
- the first processor after the first processor obtains the third status information, the first processor also sends a conversion signal to the second processor according to the third status information, and the second processor determines the charging box’s status according to the conversion signal. Switch cover information.
- the first processor 112 receives the third verification information represented by the fifth verification result, it indicates that the third state information obtained by the first processor 112 is correct, and the first processor 112 can perform the third state information
- a conversion signal (for example, a high-level or a low-level signal) is sent to the second processor 114 through the cover detection pin.
- the second processor 114 may obtain the first status information according to the received conversion signal, and identify the opening and closing status information of the charging box 120 according to the first status information.
- the second processor determining the switch cover status information of the charging box according to the recognition result includes: the second processor recognizes the switch cover status information according to the third verification information.
- the second processor 114 When the second processor 114 receives the third verification information represented by the sixth verification result sent by the charging box 120, it indicates that the third state information acquired by the first processor 112 is false, that is, the first processor 112 acquires The third status information of does not accurately represent the status information of the cover opening and closing of the charging box 120.
- the second processor 114 may determine the state information of the opening and closing of the charging box 120 according to the received sixth verification result. Further, the sixth verification result may also carry its detection information. That is, the second processor 114 may determine the state information of the opening and closing of the charging box 120 according to the received detection information.
- the first processor 112 may actively communicate with the charging box 120 after receiving the detection information, so that the charging box 120 verifies the third state information detection information acquired by the first processor 112 to determine the first processor 112 Whether the third status information obtained by the first processor 112 is correct, so as to improve the reliability of the second processor 114 in identifying the status information of the open/close cover.
- the method may further include: sending a conversion signal to the second processor according to the third state information , The second processor determines the cover opening and closing information of the charging box according to the conversion signal.
- This solution can enable the second processor to obtain the status information of the switch cover as soon as possible, so as to perform operations such as Bluetooth disconnection or reconnection in time. If the third status information is verified to be wrong, it can be corrected again, thus taking into account the response speed of the headset And accuracy.
- Similar operations can also be performed in other solutions.
- the status of the switch cover can also be determined according to the second status information, and then the charging box After verification, it is determined whether correction is required; in another scheme of the first preset identification strategy, after the second processor obtains the first state information, it first determines the state of the switch cover according to the first state information to perform Bluetooth connection or disconnection. On, after the first status information is verified by the charging box, it is determined whether correction is needed based on the feedback verification information.
- the method for identifying the opening and closing cover of the charging box in any of the above embodiments further includes the step: the second processor 114 charges The box 120 sends response information, and the response information is used to indicate that the second processor 114 recognizes the status information of the opening and closing cover of the charging box 120.
- the second processor 114 may send response information to the charging box 120 to inform the charging box 120 that the earphone 110 has received the status information of the opening and closing cover.
- Fig. 9 is a flowchart of a method for identifying the opening and closing of the charging box cover in an embodiment.
- the method of identifying the opening and closing of the charging box cover in this embodiment will be described by taking the operation on the charging box 120 in FIG. 1 as an example.
- the charging box 120 can charge the earphone 110 including the first processor 112 and the second processor 114.
- the method for recognizing the opening and closing of the charging box includes steps 902 to 904.
- Step 902 Detect the status information of the cover opening and closing of the charging box cover, and generate detection information according to the status information of the opening and closing cover.
- a cover detection module 122 is provided in the charging box 120 for real-time detection of status information of the cover opening and closing of the charging box 120.
- the cover opening and closing status information includes cover opening information and cover closing information.
- the cover detection module 122 may include a Hall sensor and a magnet. When the charging box 120 of the earphone 110 is opened, the magnet is far away from the Hall sensor, and the cover of the charging box 120 is determined by detecting changes in the signal of the Hall sensor The status information of the switch cover.
- the Hall sensor may be arranged at the opening position of the charging box 120, and the magnet may be arranged on the upper cover of the charging box 120.
- the switch cover of the charging box 120 in addition to detecting the status information of the switch cover of the charging box 120 through Hall sensors and magnets, it can also be any type of mechanical or electronic switch, including but not limited to momentary switches, capacitive sensors, optical sensors, and micro switches.
- the switch state is detected by the vibration of the charging box 120), the contact switch (for example, the switch state is determined by detecting the contact between the upper cover and the lower part).
- the lid detection module 122 generates lid opening information after detecting that the lid of the charging box 120 is opened, and generates detection information based on the lid opening information; the lid detection module 122 detects that the lid of the charging box 120 is closed. Can generate closing information, and generate detection information based on closing information.
- Step 904 Send detection information to the headset; the detection information is used to instruct the second processor to execute the first preset recognition strategy according to the detection information; or, the first processor executes the second preset identification strategy according to the detection information; and is also used to instruct The second processor determines the switch cover status information of the charging box according to the recognition result, where the detection information is used to characterize the switch cover status information of the charging box cover, and the recognition result is determined by executing the first preset recognition strategy or the second preset recognition Strategy.
- the lid detection module 122 can generate lid opening information after detecting that the lid of the charging box 120 is opened, and send the lid opening information to the earphone 110 as detection information; the lid detection module 122 detects the opening of the charging box 120 After the box cover is closed, cover closing information can be generated, and the cover closing information is sent to the earphone 110 as detection information.
- the lid detection module 122 generates lid opening information after detecting that the lid of the charging box 120 is opened, and sends the lid opening information to the first processor 112 and the second processor 114 of the earphone 110 as detection information;
- the cover detection module 122 can generate cover closing information after detecting that the cover of the charging box 120 is closed, and send the cover closing information to the first processor 112 and the second processor 114 of the earphone 110 as detection information.
- the charging box 120 may send the detection information through the earphone 110 specifically including: the charging box 120 may send the detection information to the first processor 112 and the second processor 114 respectively according to a preset time sequence.
- the charging box 120 may first send the detection information to the first processor 112, that is, the time when the charging box 120 sends the detection information to the first processor 112 is earlier than the time when the detection information is sent to the second processor 124, or Yes, the time when the first processor 112 receives the detection information is earlier than the time when the second processor 124 receives the detection information.
- the charging box 120 may also send the detection information to the second processor 124 first, that is, the time when the charging box 120 sends the detection information to the second processor 124 is earlier than the time when the detection information is sent to the first processor 112, or, The time when the second processor 124 receives the detection information is earlier than the time when the first processor 112 receives the detection information.
- the charging box 120 can send detection information to the first processor 112 and the second processor 114 at the same time.
- the time sequence can be understood as the time sequence in which the charging box 120 sends the detection information to the first processor 112 and the second processor 114 respectively, and can also be understood as the time sequence in which the first processor 112 and the second processor 114 respectively receive the detection information.
- the detection information can be represented by codes or pulses and communicated between the charging box 120 and the earphone 110.
- code When the detection information is expressed by code, it can be expressed by one or a combination of numbers, letters and characters.
- the detection information when the detection information is the cover opening information, it can be represented by 010.
- the detection information is the cover closure Information can be represented by 011.
- the detection information when the detection information is represented by pulses, it can be represented by a different number of pulses. For example, when the detection information is cover-opening information, it can be represented by three pulses.
- the detection information is cover-closing information it can be represented by four pulses. To represent the pulse.
- the specific form of the detection information is not further limited, and may also be expressed in other ways, and is not limited to the above examples.
- the first preset identification strategy can be understood as an identification method for the second processor 114 to identify the state information of the opening and closing of the charging box 120 according to the detection information.
- the first preset identification strategy may be that the second processor 114 receives the detection information sent by the charging box 120, and recognizes the state information of the opening and closing of the charging box 120 according to the detection information.
- the detection information received by the first processor 112 may also be obtained from the first processor 112, and the second state information is obtained according to the conversion signal generated by the detection information to identify the state information of the opening and closing of the charging box 120.
- the second processor 114 may correspondingly obtain the above two status information for comparison to determine the status information of the opening and closing cover of the charging box 120.
- the first preset identification strategy may also be that the second processor 114 obtains the first state information according to the received detection information, and determines the state information of the opening and closing of the charging box 120 according to the first state information, and according to the first state information and/ Or the second state information sends a verification request to the charging box 120 to request to verify whether the first state information and/or the second state information is correct.
- the second processor 114 can obtain and follow The verification information fed back by the charging box 120 is used to identify the status information of the opening and closing of the charging box 120.
- the second preset recognition strategy may be that the first processor 112 recognizes the status information of the opening and closing of the charging box 120 according to the received detection information and according to the detection information, and sends a verification request to the charging box 120 To request to verify whether the recognition result is correct.
- the first processor 112 may correspondingly obtain the verification information fed back by the charging box 120 according to the verification request, and instruct the second processor 114 to determine the state of the opening and closing lid of the charging box 120 according to the verification information. information.
- the charging box 120 detects the opening and closing status information of the charging box 120 and generating detection information according to the opening and closing status information, and the charging box 120 sends the detection information to the earphone 110.
- the detection information is used for instructing the second processor to execute the first preset recognition strategy according to the detection information; or, the first processor executes the second preset recognition strategy according to the detection information; further, it is also used for instructing the second processor according to
- the identification result determines the status information of the switch cover of the charging box, which can avoid adding additional sensors to the earphone 110 to detect the status information of the switch cover of the charging box 120, which significantly reduces the size and structural complexity of the earphone 110.
- the earphone 110 By setting the first processor 112 and the second processor 114 (dual insurance) to communicate with the charging box 120, the status information of the opening and closing cover of the charging box 120 can be synchronized to the earphone 110 quickly and reliably, effectively ensuring The earphone 110 recognizes the accuracy of the status information of the switch cover.
- the method for identifying the opening and closing cover of the charging box further includes: receiving the first verification request or the second verification request issued by the second processor executing the first preset strategy, and checking the first state according to the first verification request. Information and/or second state information is verified, and the first verification information is sent to the first processor or the second processor; or, the first state information is verified according to the second verification request, and the second verification information is Sent to the second processor.
- the charging box 120 when the charging box 120 receives the first verification request, the authenticity of the first status information received by the second processor 114 may be verified according to the first verification request. For example, the charging box 120 compares the received first status information with the cover opening and closing status information detected by the cover detection module 122. If the comparison results are consistent, the first status information is true. If the comparison results are inconsistent, the first status information is One status information is false. The charging box 120 may feed back the first verification information to the second processor 114 according to the verification result, where the first verification information may be used to characterize the authenticity of the first state information.
- the charging box 120 when the charging box 120 verifies the detection information according to the first verification request, and the first verification result is false, it indicates that the second processor 114 may be abnormal.
- the charging box 120 may send a reset instruction to the first processor 112, and the first processor 112 may perform a reset operation on the second processor 114 according to the reset instruction, so as to restore the second processor 114 to a normal state.
- the second processor 114 returns to the normal state, the second processor 114 can continue to receive the first verification information fed back by the charging box, and further, can identify the state information of the opening and closing of the charging box 120 according to the received first verification information .
- the second processor 114 may also send the acquired second state information to the charging box 120 to implement two-way communication with the charging box 120, so that the charging box 120 knows the first processor 112 and the second processor 112.
- the second status information is received by the device 114.
- the second status information can also be verified to improve the accuracy of recognition.
- the method for identifying the opening and closing cover of the charging box further includes: receiving a second verification request sent by the second processor, and verifying the first status information according to the second verification request; when the first status information is When true, the second verification information of the third verification result is fed back to the second processor; when the first status information is false, the second verification information of the fourth verification result is fed back to the second processor; wherein, the second verification information It is used to instruct the second processor to identify the status information of the switch cover according to the second verification information.
- the authenticity of the first status information received by the second processor 114 may be verified according to the second verification request.
- the second processor 114 may also send the first status information to the charging box 120 in the form of code or pulse, so that the charging box 120 can compare the received first status information with the lid opening and closing state detected by the lid detection module 122. The information is compared and verified. If the comparison results are consistent, the first state information is true, and the charging box 120 may feed back the third verification result to the second processor 114, where the second verification information is represented by the third verification result.
- the charging box 120 compares the received first status information with the opening/closing status information detected by the cover detection module 122. If the comparison results are inconsistent, it means that the first status information is false, and the charging box 120 can report to the second processor 114 Send the fourth verification result, where the third verification information can be represented by the fourth verification result. Further, the detection information is carried in the fourth verification result, and the second processor 114 can identify the state information of the opening and closing of the charging box 120 according to the received detection information.
- the charging box 120 can verify the first status information received by the second processor 114 to determine whether the first status information received by the second processor 114 is correct, so as to improve the recognition of the switch cover by the second processor 114. Reliability of status information.
- the method for identifying the opening and closing cover of the charging box further includes: receiving a third verification request issued by the first processor to execute the second preset policy, and verifying the third status information according to the third verification request, And send the third verification result to the first processor or the second processor.
- the charging box 120 when the charging box 120 receives the third verification request, the authenticity of the third state information obtained by the first processor 112 may be verified according to the third verification request. For example, the charging box 120 compares and verifies the received third status information with the cover opening and closing status information detected by the cover detection module 122. If the comparison results are consistent, it means that the third status information is true and the charging box 120 can report to the first The processor 112 feeds back the fifth verification result corresponding to the third state information being true, where the third verification information may be represented by the fifth verification result. If the comparison results are inconsistent, it means that the third state information is false, and the charging box 120 can feed back to the second processor 114 the sixth verification result corresponding to the third state information being false, where the sixth verification result can be used as the third verification information To represent.
- the first processor 112 When the first processor 112 receives the third verification information indicated by the fifth verification result, it indicates that the third state information acquired by the first processor 112 is accurate, and the first processor 112 can perform the third state information For conversion, a conversion signal (for example, a high-level or a low-level signal) is sent to the second processor 114 through the cover detection pin. The second processor 114 may obtain the first status information according to the received conversion signal, and identify the opening and closing status information of the charging box 120 according to the first status information.
- a conversion signal for example, a high-level or a low-level signal
- the second processor 114 When the second processor 114 receives the third verification information represented by the sixth verification result sent by the charging box 120, it indicates that the third status information received by the first processor 112 is false, that is, the first processor 112 The received detection information does not accurately represent the status information of the cover opening and closing of the charging box 120.
- the second processor 114 may identify the state information of the opening and closing of the charging box 120 according to the received detection information.
- the charging box 120 can verify the third state information obtained by the first processor 112 to determine whether the third state information obtained by the first processor 112 is correct, so as to improve the recognition of the switch by the second processor 114. Reliability of cover status information.
- the second processor can perform operations such as disconnecting the Bluetooth connection or Bluetooth connection back according to the status information of the switch cover in time, after obtaining the third status information, first generate a conversion based on the third status information
- the signal is sent to the second processor, so that the second processor first performs corresponding operations according to the conversion signal, and then determines whether to perform corresponding adjustments after obtaining the third verification information. So as to ensure accuracy while improving the response speed of the headset.
- Fig. 10 is a flowchart of a method for identifying the opening and closing of the charging box cover in an embodiment.
- the method of identifying the opening and closing of the charging box cover in this embodiment will be described by taking the headset 110 and the charging box 120 in FIG. 1 as an example.
- the method for identifying the opening and closing of the charging box includes step 1002 to step 1010.
- Step 1002 The charging box detects the status information of the opening and closing cover of the charging box cover, and generates detection information according to the status information of the opening and closing cover;
- Step 1004 The charging box sends detection information to the earphone
- Step 1006 the earphone receives the detection information sent by the charging box
- Step 1008 the second processor executes a first preset identification strategy according to the detection information; or, the first processor executes a second preset identification strategy according to the detection information;
- Step 1010 The second processor determines the status information of the opening and closing cover of the charging box according to the identification result, where the detection information is used to characterize the opening and closing status information of the charging box lid, and the identification result is performed by executing the first preset identification strategy or the second preset identification strategy. Obtained from a preset recognition strategy.
- step 1002 and step 1004 correspond to steps 902-904 in the foregoing embodiment one-to-one
- step 1006 corresponds to step 204 and step 304 in the foregoing embodiment
- step 1008 corresponds to step 206 and step 306 in the foregoing embodiment. No longer.
- the above method for identifying the opening and closing of the charging box includes the earphone 110 receiving the detection information sent by the charging box 120; the second processor executes the first preset identification strategy according to the detection information; or the first processor executes the second preset according to the detection information Identification strategy; the second processor determines the switch cover status information of the charging box according to the recognition result, where the detection information is used to characterize the switch cover status information of the charging box cover, and the recognition result is achieved by executing the first preset recognition strategy or the second
- the preset recognition strategy can avoid adding additional sensors on the earphone 110 to detect the status information of the opening and closing of the charging box 120, which significantly reduces the size and structural complexity of the earphone 110.
- the first The processor 112 and the second processor 114 communicate with the charging box 120, which can quickly and reliably synchronize the opening and closing status information of the charging box 120 to the earphone 110, effectively ensuring the earphone 110 to recognize The accuracy of the status information of the switch cover.
- the present application also provides a headset 110, which includes a first processor 112 and a second processor 114.
- the first processor 112 is used to receive the detection information sent by the charging box 120, and the detection information is used to characterize the state information of the cover opening and closing of the charging box 120;
- the second processor 114 is connected to the first processor 112 and uses According to the detection information, execute a first preset identification strategy to identify the switch cover status information of the charging box 120; or, the first processor 112 is further configured to execute a second preset identification strategy according to the detection information to identify the switch cover of the charging box 120 status information.
- the present application also provides a charging box 120, which includes a cover detection module 122 and a third processor 124.
- the cover detection module 122 is used to detect the cover opening and closing status information of the charging box 120;
- the third processor 124 is used to send detection information to the first processor 112, and the detection information is used to characterize the cover opening and closing status information of the charging box 120.
- the detection information is used to instruct the second processor 114 to execute the first preset identification strategy according to the detection information; or, the first processor 112 to execute the second preset identification strategy according to the detection information; and also to instruct the second processor 114 to execute according to the
- the identification result determines the status information of the opening and closing of the charging box 120, where the detection information is used to characterize the opening and closing status information of the lid of the charging box 120, and the identification result is obtained by executing the first preset identification strategy or the second preset identification strategy .
- the present application also provides a system for identifying the switch of a charging box, including the earphone 110 and the charging box 120 in any of the above embodiments.
- the present application also provides a computer-readable storage medium on which a computer program is stored, characterized in that, when the computer program is executed by a processor, the steps of the method for identifying the switch cover of the charging box in any of the above embodiments are realized.
- This application also provides a computer program product containing instructions, which when running on a computer, causes the computer to execute a method for identifying the opening and closing of the charging box.
- Non-volatile memory may include read only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory.
- Volatile memory may include random access memory (RAM), which acts as external cache memory.
- RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous Link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
- SRAM static RAM
- DRAM dynamic RAM
- SDRAM synchronous DRAM
- DDR SDRAM double data rate SDRAM
- ESDRAM enhanced SDRAM
- SLDRAM synchronous Link (Synchlink) DRAM
- Rambus direct RAM
- DRAM direct memory bus dynamic RAM
- RDRAM memory bus dynamic RAM
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- Acoustics & Sound (AREA)
- Signal Processing (AREA)
- Power Engineering (AREA)
- Life Sciences & Earth Sciences (AREA)
- General Life Sciences & Earth Sciences (AREA)
- General Physics & Mathematics (AREA)
- Geophysics (AREA)
- Charge And Discharge Circuits For Batteries Or The Like (AREA)
- Telephone Set Structure (AREA)
- Telephone Function (AREA)
Abstract
一种识别充电盒开关盖的方法,识别充电盒开关盖的方法包括:耳机接收充电盒发送的检测信息;第二处理器根据检测信息执行第一预设识别策略;第二处理器根据识别结果确定充电盒的开关盖状态信息,其中,检测信息用于表征充电盒盒盖的开关盖状态信息,识别结果是通过执行第一预设识别策略得到的。
Description
相关申请的交叉引用
本申请要求于2020年3月11日提交中国专利局、申请号为2020101650341、发明名称为“识别充电盒开关盖的方法、耳机、充电盒、系统”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
本申请涉及耳机技术领域,特别是涉及一种识别充电盒开关盖的方法、耳机、充电盒、系统和计算机可读存储介质。
这里的陈述仅提供与本申请有关的背景信息,而不必然地构成现有示例性技术。
一般,真无线立体声(True wireless Stereo简称TWS)耳机识别充电盒的开关盖信息,都是通过设置在耳机上的传感器来检测的,例如,可在耳机的左耳塞和右耳塞各设置一颗霍尔传感器,并在充电盒子的盒盖上对应设置两颗磁铁,通过霍尔效应耳机能够识别充电盒的开关盖信息。耳机通过传感器来识别充电盒的开关盖信息的方式器需要增加额外的传感器、成本高、占用空间大且可靠性不稳定。
发明内容
根据本申请的各种实施例,提供一种识别充电盒开关盖的方法、装置、电子设备、计算机可读存储介质。
一种识别充电盒开关盖的方法,应用于包括第一处理器和第二处理器的耳机,所述第一处理器与所述第二处理器连接,所述方法包括:
所述耳机接收充电盒发送的检测信息;
所述第二处理器根据所述检测信息执行第一预设识别策略;
所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是通过执行所述第一预设识别策略得到的。
一种识别充电盒开关盖的方法,应用于包括第一处理器和第二处理器的耳机,所述第一处理器与所述第二处理器连接,所述方法包括:
所述耳机接收充电盒发送的检测信息;
所述第一处理器根据所述检测信息执行第二预设识别策略;
所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是通过执行所述第二预设识别策略得到的。
一种识别充电盒开关盖的方法,应用于能够为包括第一处理器和第二处理器的耳机进行充电的充电盒,所述第一处理器与所述第二处理器连接,所述方法包括:
检测所述充电盒盒盖的开关盖状态信息,并根据所述开关盖状态信息生成检测信息;
向所耳机发送所述检测信息,所述检测信息用于指示所述第二处理器根据所述检测信息执行第一预设识别策略和用于指示所述第一处理器根据所述检测信息执行第二预设识别策略中的一个;还用于指示所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是通过执行所述第一预设识别策略和所述第二预设识别策略中的一个得到的。
一种耳机,包括:
第一处理器,用于接收充电盒发送的检测信息,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息;
第二处理器,与所述第一处理器连接,用于根据所述检测信息执行第一预设识别策略,还用于根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是所述第二处理器执行所述第一预设识别策略得到的。
一种耳机,包括:
第一处理器,用于接收充电盒发送的检测信息,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,并根据所述检测信息执行第二预设识别策略;
第二处理器,与所述第一处理器连接,用于根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是所述第一处理器执行第二预设识别策略中的一个得到的。一种充电盒,用于为包括第一处理器和与所述第一处理器连接的第二处理器的耳机充电,所述充电盒包括:
盖检测模块,用于检测所述充电盒的开关盖状态信息;
第三处理器,用于向所述第一处理器发送检测信息,所述检测信息用于表征所述充电盒的开关盖状态信息,所述检测信息用于指示所述第二处理器根据所述检测信息执行第一预设识别策略和用于指示所述第一处理器根据所述检测信息执行第二预设识别策略中的一个;所述检测信息还用于指示所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,所述识别结果是通过执行所述第一预设识别策略和所述第二预设识别策略中的一个得到的。
一种识别充电盒开关的系统,包括如上述的耳机和上述的充电盒。
一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现如上述的方法的步骤。
上述识别充电盒开关的方法、耳机、充电盒、系统和计算机可读存储介质,可以避免在耳机上增设额外的传感器来检测充电盒的开关盖状态信息,显著降低了耳机的尺寸和结构复杂度,同时,在耳机中通过设置第一处理器和/或第二处理器(双保险的方式)来与充电盒进行通信,可以快速、并且可靠地将充电盒的开关盖状态信息同步给耳机,有效地保证了耳机识别开关盖状态信息的准确性。
本申请的一个或多个实施例的细节在下面的附图和描述中提出。本申请的其他特征、目的和优点将从说明书、附图以及权利要求书变得明显。
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1为一个实施例中识别充电盒开关盖的方法的应用环境图;
图2为一个实施例中识别充电盒开关盖的方法的流程图之一;
图3为一个实施例中识别充电盒开关盖的方法的流程图之一;
图4为一个实施例中识别充电盒开关盖的方法的流程图之一;
图5为一个实施例中识别充电盒开关盖的方法的流程图之一;
图6为一个实施例中识别充电盒开关盖的方法的流程图之一;
图7为一个实施例中识别充电盒开关盖的方法的流程图之一;
图8为一个实施例中识别充电盒开关盖的方法的流程图之一;
图9为一个实施例中识别充电盒开关盖的方法的流程图之一;
图10为一个实施例中识别充电盒开关盖的方法的流程图之一。
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。
可以理解,本申请所使用的术语“第一”、“第二”等可在本文中用于描述各种元件,但这些元件不受这些术语限制。这些术语仅用于将第一个元件与另一个元件区分。举例来说,在不脱离本申请的范围的情况下,可以将第一处理器称为第二处理器,且类似地,可将第二处理器称为第一处理器。第一处理器和第二处理器两者都是处理器,但其不是同一处理器。
图1为一个实施例中识别充电盒开关的方法的应用环境示意图。如图1所示,该应用环境包括耳机110和用于收纳并为该耳机110进行充电的充电盒120。
在其中一个实施例中,耳机110可以为真无线立体声(True wireless Stereo,TWS)。TWS耳机110的左右两只耳塞无需线缆连接通过实现左右声道的无线分离即可独立工作。耳机110包括壳体以及设置在壳体内的各电子部件可以包括但不限于第一处理器112、第二处理器114、耳机接口模块116、存储器、电源管理集成电路、电池、射频电路、输入设备、传感器、音频处理电路等。
第一处理器112、第二处理器114可以用于控制耳机接口模块116,用于从外部设备和/或充电盒120接收或发送数据至外部设备和/或充电盒120,第一处理器112、第二处理器114可以用于控制存储器与外部设备或充电盒120的数据传输等,并且可以用于控制电源管理集成电路等。示例性的,第一处理器112可以为微控制单元(Microcontroller Unit,MCU)、CPU、单片机等控制器,该控制器被配置有多个功能引脚,例如可包括复位引脚、电平转换引脚、通讯引脚等等。第一处理器112的各个功能引脚可对应与第二处理器114连接。示例性的,第二处理器114可以为蓝牙芯片,或其他可以与外部设备进行无线通信的通信处理器等。当然,第一处理器112也可以为蓝牙芯片,第二处理器114为微控制单元。
耳机接口模块116可包括多个触点(POGO PIN),其中,多个触点外露于壳体。示例性的,可以采用2个触点来实现充电与通信的两个功能。2个触点既可以作为充电触点,也可以作为数据传输触点。当作为数据传输触点时,则可以用于实现耳机110与耳机110充电盒120之间的数据双向通信。示例性的,也可以采用3个触点来实现充电与通信的两个功能,其中,2个触点可作为充电触点,1个触点作为数据传输触点,以实现耳机110与充电盒120之间的数据双向传输。
在其中一个实施例中,充电盒120可用于收纳耳机110,并且还可以为收纳在充电盒120内的耳机110进行充电。其中,内置在充电盒120内的各电子部件可以包括但不限于盖检测模块122、第三处理器124、盒接口模块126、存储器、电源管理电路、电池等。
盖检测模块122用于检测充电盒120盒盖的开关盖状态信息。其中,该开关盖状态信息包括开盖信息和关盖信息。其中,盖检测模块122与第三处理器124连接,盖检测模块122可以将检测到的开关盖状态信息,例如,盖检测模块122在检测到充电盒120的盒盖打开后即可生成开盖信息并将其发送给第三处理器124,并且盖检测模块122在检测到充电盒120的盒盖关闭后即可生成关盖信息并将其发送给第三处理器124。
示例性的,盖检测模块122可包括霍尔传感器及磁铁,其中,当耳机110充电盒120开盖时,磁铁远离霍尔传感器,通过检测霍尔传感器的信号的变化来判断充电盒120盒盖的开关盖状态信息。例如,霍尔传感器可设置在充电盒120的开口位置,磁铁可设置在充电盒120的上盖。另外,除了可以通过霍尔传感器与磁铁来检测充电盒120的开关盖状态信息之外,还可以为任何类型的机械或电子开关,包括但不限于瞬时开关、电容传感器、光学传感器、微动开关(通过充电盒120的震动来检测开关状态)、接触开关(例如通过检测上盖和下部的接触来判断开关状态)。
盒接口模块126可包括多个触点(POGO PIN)。示例性的,可以采用2个触点来实现充电与通信的两个功能。2个触点既可以作为充电触点,也可以作为数据传输触点。示例性的,也可以采用3个触点来实现充电与通信的两个功能,其中,2个触点可作为充电触点,1个触点作为数据传输触点,以实现耳机110与充电盒120之间的数据双向传输。
将耳机110收纳在充电盒120中时,耳机接口模块116的多个触点可与盒接口模块126内的多个触点一一对应接触连接。若将2个触点或1个触点作为数据传输触点时,则可以基于耳机接口模块116和盒接口模块126实现耳机110与充电盒120之间的数据双向通信。示例性的,当第三处理接收到开关 盖状态信息后,可以基于耳机接口模块116和盒接口模块126将该开关盖状态信息传输至耳机110。
图2为一个实施例中识别充电盒开关的方法的流程图。本实施例中的识别充电盒开关的方法,以运行于图1中的耳机110上为例进行描述。如图2所示,识别充电盒开关盖的方法包括步骤202至步骤206。
步骤202,耳机接收充电盒发送的检测信息,检测信息用于表征充电盒盒盖的开关盖状态信息。
在其中一个实施例中,第一处理器112、第二处理器114可分别与耳机接口模块116连接。当耳机接口模块116与盒接口模块126连接时,可以实现耳机110和充电盒120之间的双向通信。也即,充电盒120可以向耳机110发送开关盖状态信息,同时,耳机110也可以向充电盒120发送用于校验信息真伪的验证请求及用于反馈接收到信息的应答信息等。
充电盒120中设有盖检测模块122,用于实时检测充电盒120盒盖的开关盖状态信息。其中,开关盖状态信息包括开盖信息和关盖信息。示例性的,盖检测模块122在检测到充电盒120的盒盖打开后即可生成开盖信息,并将开盖信息作为检测信息发送给耳机110;盖检测模块122在检测到充电盒120的盒盖关闭后即可生成关盖信息,并将关盖信息作为检测信息发送给耳机110。具体的,盖检测模块122在检测到充电盒120的盒盖打开后即可生成开盖信息,并将开盖信息作为检测信息发送给耳机110的第一处理器112和第二处理器114;盖检测模块122在检测到充电盒120的盒盖关闭后即可生成关盖信息,并将关盖信息作为检测信息发送给耳机110的第一处理器112和第二处理器114。
在其中一个实施例中,充电盒120可以向耳机110发送检测信息具体可包括:充电盒120可以按照预设时序分别向第一处理器112和第二处理器114发送检测信息。
示例性的,充电盒120可以先向第一处理器112发送检测信息,即充电盒120向第一处理器112发送检测信息的时刻早于向第二处理器124发送检测信息的时刻,亦或是,第一处理器112接收检测信息的时刻早于第二处理器124接收检测信息的时刻。充电盒120也可以先向第二处理器124发送检测信息,即充电盒120向第二处理器124发送检测信息的时刻早于向第一处理器112发送检测信息的时刻,亦或是,第二处理器124接收检测信息的时刻早于第一处理器112接收检测信息的时刻。
在其中一个实施例中,充电盒120可以同时向第一处理器112和第二处理器114发送检测信息。
时序可以理解为充电盒120分别向第一处理器112、第二处理器114发送检测信息的时间顺序,也可以理解为第一处理器112、第二处理器114分别接收检测信息的时间顺序。
在其中一个实施例中,检测信息可以以编码或脉冲来表示并在充电盒120与耳机110之间进行通讯。当检测信息用编码来表示时,可以用数字、字母和字符中的一个或组合方式来表示,示例性的,当开关盖状态信息为开盖信息时,检测信息可以用010来表示,当关盖状态信息为关盖信息时,检测信息可以用011来表示。当检测信息用脉冲来表示时,可以用不同的脉冲数来表示,示例性的,当关盖状态信息为开盖信息时,可以三个脉冲来表示,当关盖状态信息为关盖信息时,可以用四个脉冲来表示。
需要说明的是,在本申请实施例中,检测信息的具体形式不做进一步的限定,还可以为其他的方式来表示,不限于上述举例说明。
在其中一个实施例中,充电盒120、耳机110的第一处理器112和第二处理器114可以预先存储其检测信息与编码或脉冲数的映射关系。充电盒120可以根据检测到的开盖信息或关盖信息基于预设的映射关系来确定向第一处理器112和第二处理器114发送该检测信息的具体表现形式。同时,第一处理器112和第二处理器114也可以根据检测信息与编码或脉冲数的映射关系,来识别充电盒的开关盖状态信息。
步骤204,第二处理器根据检测信息执行第一预设识别策略。
第一预设识别策略可以理解为第二处理器114根据检测信息识别充电盒120的开关盖状态信息的识别方法。示例性的,第一预设识别策略可以为第二处理器114接收充电盒120发送的检测信息,并根据该检测信息来识别充电盒120的开关盖状态信息。同时,还可以从第一处理器112处获取第一处理器112接收到的检测信息,并根据该检测信息来识别充电盒120的开关盖状态信息。在执行该第一预设识别策略时,第二处理器114可以对应获取两次识别充电盒120的开关盖状态信息的识别结果。第一预设识别策略还可以为第二处理器114根据接收的检测信息,并根据该检测信息识别充电盒120的开关盖状 态信息,并向充电盒120发送验证请求以请求验证其识别结果是否正确,在执行该第一预设识别策略时,第二处理器114可以对应获取充电盒120根据该识别结果反馈的验证信息。
步骤206,第二处理器根据识别结果确定充电盒的开关盖状态信息。
在其中一个实施例中,当第二处理器114在执行第一预设识别策略时,第二处理器对应获取两次识别充电盒120的开关盖状态信息的识别结果时,第二处理器114可以对比两次识别充电盒120的开关盖状态信息的识别结果,以确定充电盒120的开关盖状态信息。
在其中一个实施例中,当第二处理器114在执行第一预设识别策略,第二处理器114对应获取充电盒120根据该识别结果反馈的验证信息时,第二处理器114可以根据该验证结果来确定充电盒120的开关盖状态信息。
如图3所示,识别充电盒开关盖的方法包括步骤302至步骤306。
步骤302,耳机接收充电盒发送的检测信息;
其中,步骤302与前述实施例中步骤202对应,在此,不再赘述。
步骤304,第一处理器根据检测信息执行第二预设识别策略。
在其中一个实施例中,第二预设识别策略可以为,第一处理器112接收的检测信息,并根据该检测信息识别充电盒120的开关盖状态信息,并向充电盒120发送验证请求以请求验证其识别结果是否正确。在执行该第二预设识别策略时,第一处理器112可以对应获取充电盒120根据该识别结果反馈的验证信息,再根据该验证信息发送转换信号给第二处理器。
步骤306,第二处理器根据识别结果确定充电盒的开关盖状态信息。
在其中一个实施例中,当第一处理器112在执行第二预设识别策略,第一处理器112对应获取充电盒120根据该识别结果反馈的验证信息时,第一处理器112可以根据该验证结果来确定充电盒120的开关盖状态信息,在将该开关盖状态信息发送给第二处理器,或者,直接由第二处理器接收上述验证信息来确定开关盖状态信息。
需要说明的是,第一预设识别策略和第二预设识别策略均可预先对应存储在耳机110和充电盒120中,可以根据实际需求,由用于自主选择使用哪种策略来识别开关盖状态信息,也可以根据识别优先级先确定优先使用哪种策略来识别开关盖状态信息,也可以由出厂商来确定使用哪种策略来识别开关盖状态信息。在本申请实施例中,对第一预设识别策略和第二预设识别策略的选择不做进一步的限定。
上述识别充电盒开关盖的方法,包括耳机110接收充电盒120发送的检测信息;第二处理器根据检测信息执行第一预设识别策略;和/或,第一处理器根据检测信息执行第二预设识别策略;第二处理器根据识别结果确定充电盒的开关盖状态信息,其中,检测信息用于表征充电盒盒盖的开关盖状态信息,识别结果是通过执行第一预设识别策略或第二预设识别策略得到的;可以避免在耳机110上增设额外的传感器来检测充电盒120的开关盖状态信息,显著降低了耳机110的尺寸和结构复杂度,同时,在耳机110中通过设置第一处理器112和第二处理器114(双保险的方式)来与充电盒120进行通信,可以快速、并且可靠地将充电盒120的开关盖状态信息同步给耳机110,有效地保证了耳机110识别开关盖状态信息的准确性。
通过在耳机110设置第一处理器112和第二处理器114来识别充电盒120的开关盖状态信息,可以避免仅设置一个处理器时该处理器出现异常、死机、实时性能差而导致无法使耳机110识别出充电盒120的开关盖状态信息。示例性的,若一般耳机110中仅设置第一处理器112(例如,微控制单元)时,本申请实施例的方法可以避免因第一处理器112性能弱而导致的识别结果不准确的发生,同时,还可以避免因第一处理器112出现异常或出现死机时无法识别。若一般耳机110中仅设置第二处理器114(例如,蓝牙芯片)时,若充电盒120的开盖动作发生在第二处理器114的开机启动阶段,开机启动阶段会有几百毫秒到几秒钟的启动时间,启动之后第二处理器114才能进行通信,如果在耳机110在第二处理器114的启动阶段被用户拿出,则耳机110和充电盒120之间就无法继续通信,本申请实施例的方法可以避免因第二处理器114的时效性较差而导致耳机110无法与充电盒120进行通信以获取充电盒120的开关盖状态信息的情况发生,同时,还可以避免因第二处理器114出现异常或死机时无法识别开关盖状态信息的情况发生。
如图4所示,在其中一个实施例中,第二处理器114根据检测信息执行第一预设识别策略具体可包括步骤402至步骤408。
步骤402,第一处理器接收检测信息,并根据检测信息向第二处理器发送转换信号;
在其中一个实施例中,耳机110的第一处理器112可以接收该检测信息,并根据接收的检测信息向第二处理器114发送转换信号。
在本申请实施例中,以第一处理器112为微控制单元、第二处理器114为蓝牙芯片为例进行说明。其中,第一处理器112与第二处理器114电连接,第一处理器112和第二处理器114之间可以实现数据传输。
在其中一个实施例中,第一处理器112可以为具有多功能的微控制单元。其中,第一处理器112中可配置有多个功能引脚,可以通过多个功能引脚向第二处理器114来输出不同的信息。示例性的,第一处理器112可被配置为盖检测引脚、复位引脚等。以盖检测引脚为例进行说明。当第一处理器112接收到充电盒120发送的检测信息后,可以对检测信息进行转换处理,以生成相应的转换信号,并将给转换信号经盖检测引脚发送给第二处理器114。
具体的,当第一处理器112接收的检测信息为“010”或“三个脉冲”时,可以基于预先存储的映射关系,可以识别出检测信息为开盖信息;当第一处理器112接收的检测信息为“011”或“四个脉冲”时,可以基于预先存储的映射关系,可以识别出检测信息为关盖信息。当第一处理器112识别出检测信息后,可以控制盖检测引脚的电平状态,进行生成对用的转换信号。可以理解的是,转换信号可以为电平信息。
第一处理器112和第二处理器114中预先存储有开关盖状态信息与电平信息之间的映射关系。例如,盖检测引脚的电平状态为高电平对应于检测信息为开盖信息,盖检测引脚的电平状态为低电平对应于检测信息为关盖信息。或,盖检测引脚的电平状态为高电平对应于检测信息为关盖信息,盖检测引脚的电平状态为低电平对应于检测信息为开盖信息。
在本申请实施例中,以高电平对应开盖信息,低电平对应关盖信息为例进行说明。当第一处理器112接收的检测信息为开盖信息时,第一处理器112可对接收到的开盖信息进行转换,以使第一处理器112的盖检测引脚输出高电平(转换信号)至第二处理器114。当第一处理器112接收的检测信息为关盖信息时,第一处理器112可对接收到的关盖信息进行转换,以使第一处理器112的盖检测引脚输出低电平(转换信号)至第二处理器114。
需要说明的是,转换信号的转换方式及其转换信号的具体呈现方式不限于上述举例说明,还可以通过编码-解码的方式或其他方式来生成相应的转换信号。
步骤404,第二处理器根据转换信号得到第一状态信息;
在其中一个实施例中,第二处理器114也可以对应设置多个引脚,以对应与第一处理器112的多个多功能引脚一一对应连接。或,第二处理器114也可以设置一个与第一处理器112的多个多功能引脚连接的信号接收引脚,当接收到第一处理器112发送的任一信息时,都可以对应识别出该信息的来源,也即,第二处理器114器可以对应识别出所接收的信息是源自第一处理的哪个功能引脚。
第二处理器114中,也预先存储有用于检测信息与编码或脉冲数的对应关系,同时也存储有开关盖状态信息与电平信息之间的映射关系。当第二处理器114接收到第一处理器112发送的转换信号时,可以基于开关盖状态信息与电平信息之间的映射关系获取用于表示开关盖状态信息的第一状态信息。示例性的,当接收的转换信号为高电平时,则第一状态信息为开盖信息;当接收的转换信号为低电平时,则第一状态信息为关盖信息。其中,第一状态信息可以理解为第二处理器114根据第一处理器112的转换信号识别出的用于表征充电盒120的开关盖状态信息。
步骤406,第二处理器接收检测信息得到第二状态信息;其中,第二状态信息可以理解为第二处理器114根据充电盒120发送的检测信息识别出的用于表征充电盒120的开关盖状态信息。
在其中一个实施例中,当第二处理器114接收的检测信息为“010”或“三个脉冲”时,可以基于预先存储的映射关系,可以识别出检测信息为开盖信息,也即其第二状态信息为开盖信息;当第一处理 器112接收的检测信息为“011”或“四个脉冲”时,可以基于预先存储的映射关系,可以识别出检测信息为关盖信息,也即其第二状态信息为关盖信息。
步骤408,第二处理器根据第一状态信息和第二状态信息得到识别结果。
在其中一个实施例中,第二处理器可以根据第一状态信息和第二状态信息来获取其识别结果。示例性的,当第一状态信息和第二状态信息相同时,其识别结果可以理解为第一状态信息或第二状态信息;当第一状态信息和第二状态信息不相同时,其识别结果可以理解为充电盒对第一状态信息和/或第二状态信息进行验证的验证信息。
进一步的,第二处理器114可以根据给识别结果来确定其充电盒120的开关盖状态信息。示例性的,当第一状态信息和第二状态信息相同时,第二处理器114可以将第一状态信息或第二状态信息作为充电盒120的开关盖状态信息;当第一状态信息和第二状态信息不相同时,第二处理器114可根据该验证信息来确定充电盒120的开关盖状态信息。
在本申请实施例中,其中,步骤402在步骤406之前,也即第一处理器112接收检测信息的时刻早于第二处理器114接收检测信息的时刻。
本实施例中,第一处理器112可以早于第二处理器114接收到充电盒120发送的检测信息,此时,第一处理器112能够快速响应并接收该检测信息,可以避免耳机110处于关机状态,第二处理器114的启动需要一段时间,而耳机110已经从充电盒120被拿出,而第二处理器114而无法直接接收充电盒120发送的检测信息的情况发生,而第二处理器114可以从第一处理器112处获取开关盖状态信息,以确保了获取开关盖状态信息的准确性。
如图5所示,在其中一个实施例中,第二处理器根据检测信息执行第一预设识别策略具体可包括步骤502至步骤508。
步骤502,第二处理器接收检测信息,得到第二状态信息;
步骤504,第一处理器接收检测信息,并根据检测信息向第二处理器发送转换信号;
步骤506,第二处理器根据转换信号获取第一状态信息;
步骤508,第二处理器根据第一状态信息和第二状态信息得到识别结果。
本实施例中,第一处理器112接收检测信息的时刻晚于第二处理器114接收检测信息的时刻。具体的,当耳机110处于开机状态下,即第二处理器114处于工作状态时,充电盒120可以先将检测信息发送给第二处理器114,这样可以提高第二处理器114识别开关盖状态信息的速度,以提高识别效率。
如图6所示,在其中一个实施例中,第二处理器根据第一状态信息和第二状态信息得到识别结果,并根据识别结果确定充电盒的开关盖状态信息,包括步骤602-步骤608。
步骤602,第二处理器判断第一状态信息和第二状态信息是否相同。
在其中一个实施例中,第二处理器114也可以从第一处理器112接收转换信号,并根据该转换信号来获取第一状态信息。而且,第二处理器114可以直接接收充电盒120发送的检测信息,并根据该检测信息得到第二状态信息,其中,第一状态信息和第二状态信息都是用于表示充电盒120盒盖的开关盖状态信息。
示例性的,若第二处理器114接收的检测信息的表现形式是“010”,或其表现形式为三个脉冲,第二处理器114可识别出,充电盒120发送的检测信息为开盖信息,也即,其对应的第二状态信息为开盖信息。若第二处理器114接收的检测信息的表现形式是“011”,或其表现形式为四个脉冲,第二处理器114可识别出,充电盒120发送的检测信息为关盖信息,也即,其对应的第二状态信息为关盖信息。
若第二处理器114接收的转换信号为高电平信号,其第一状态信息为开盖信息,若第二处理器114接收的转换信号为低电平信号,则第一状态信息为关盖信息。
第二处理器114可以判断第二状态信息和第一状态信息是否相等。
步骤604,当第二状态信息与第一状态信息相同时,第二处理器以第二状态信息或第一状态信息作为充电盒的开关盖状态信息。
当第二状态信息和第一状态信息均为开盖信息或第二状态信息和第一状态信息均为关盖信息时,第 二处理器114可根据第二状态信息或第一状态信息来确定充电盒120的开关盖状态信息。示例性的,若第二状态信息或第一状态信息为开盖信息时,则可确定充电盒120的开关盖状态信息为开盖信息,若第二状态信息或第一状态信息为关盖信息时,则可确定充电盒120的开关盖状态信息为关盖信息。
步骤606,当第二状态信息与第一状态信息不同时,第二处理器以第二状态信息作为充电盒的开关盖状态信息。
在其中一个实施例中,第二处理器114获取的第二状态信息和第一状态信息不同时,第二处理器114可以直接获取的第二状态信息来识别充电盒120的开关盖状态信息,因为第一状态信息需要根据第一处理器112接收的检测信息转换后来获取,第一状态信息出现异常的可能性较大。当第二状态信息与第一状态信息不同时,第二处理器114以第二状态信息作为充电盒120的开关盖状态信息,可以提高识别效率。
步骤608,当第二状态信息与第一状态信息不同时,第二处理器向充电盒发送第一验证请求,第二处理器根据充电盒反馈的第一验证信息识别开关盖状态信息,第一验证请求用于指示充电盒对第二处理器接收的第二状态信息和/或第一状态信息进行验证。
在其中一个实施例中,当第二状态信息与第一状态信息不同时,第二处理器114向充电盒120发送携带第二状态信息或第一状态信息的第一验证请求,第一验证请求用于指示充电盒120对第二状态信息或第一状态信息的真伪进行验证,并根据验证结果反馈第一验证信息。第二处理器114接收充电盒120反馈的第一验证信息。
第一验证信息包括充电盒120对第二状态信息的真伪进行验证的第一验证结果,和/或,充电盒120对第一状态信息的真伪进行验证的第二验证结果。
第二处理器根据充电盒反馈的第一验证信息确定开关盖状态信息,包括:第二处理器根据第一验证结果或第二验证结果识别开关盖状态信息。
具体的,当充电盒120接收到第一验证请求时,可以根据第一验证请求来对第二处理器114获取的第二状态信息的真伪进行验证。例如,第二处理器114也可以以编码或脉冲的方式将第二状态信息发送给充电盒120,以使充电盒120对接收的第二状态信息与盒盖检测模块122检测出的开关盖状态信息进行对比,若对比结果一致,则说明第二状态信息为真,若对比结果不一致,说明第二状态信息为假。充电盒120可根据验证结果向第二处理器114反馈第一验证信息,其中,第一验证信息可用于表征第二状态信息的真伪。
具体的,当充电盒120接收到第一验证请求时,可以根据第一验证请求来对第二处理器114接收到的第一状态信息的真伪进行验证。例如,第二处理器114也可以以编码或脉冲的方式将第一状态信息发送给充电盒120,以使充电盒120对接收的第一状态信息与盒盖检测模块122检测出的开关盖状态信息进行对比,若对比结果一致,则说明第一状态信息为真,若对比结果不一致,说明第一状态信息为假。充电盒120可根据验证结果向第二处理器114反馈第一验证信息,其中,第一验证信息可用于表征第一状态信息的真伪。
在其中一个实施例中,第一验证信息也可以通过编码或脉冲数的形式在充电盒120和第一处理器112、第二处理器114之间进行传输。示例性的,若检测信息为真或第二检测结果为假,则第一验证信息可以以“100”或一个脉冲的形式来传输,若检测信息为假或第二检测结果为真,则第一验证信息可以以“001”或两个脉冲的形式来传输。
第二处理器114可以根据接收的第一验证信息,来确定充电盒120的开关盖状态信息。若第一验证信息为“100”或一个脉冲,则表明第二处理器114接收的第二状态信息为真或第一状态信息为假,也即第一处理器112从第一处理器112处获取的转换信号不准确,也即,可以判定出,第一处理器112出现异常或故障,进而可以根据第二状态信息来识别充电盒120的开关盖状态信息。若第一验证信息为“001”或两个脉冲,则表明第二处理器114接收的第二状态信息为假或第一状态信息为真,进而第二处理器114可以根据第一状态信息来识别充电盒120的开关盖状态信息。
在其中一个实施例中,第二处理器根据充电盒反馈的第一验证信息识别开关盖状态信息前,还包括:第一处理器接收充电盒发送的复位指令,复位指令为充电盒在验证第二状态信息为假时生成;第一处理 器根据复位指令对第二处理器进行复位操作以使第二处理器接收第一验证信息。
具体的,当充电盒120根据第一验证请求对第二状态信息进行验证,其第一验证结果为假时,表明第二处理器114可能出现异常。充电盒120可向第一处理器112发送复位指令,第一处理器112根据该复位指令可对第二处理器114进行复位操作,以使第二处理器114恢复至正常状态。示例性的,第一处理器112可配置有复位引脚,当第一处理器112接收到复位指令时,可以控制复位引脚的电平发生翻转,以传输至第二处理器114的复位端,实现对第二处理器114的复位操作。需要说明的是,在本申请实施例中,第一处理器112对第二处理器114的复位操作不限于本实例的举例说明,还可以为其他方式。
在其中一个实施例中,复位指令可以通过编码或脉冲的方式来表示。其具体表现形式在本申请实施例中,不做进一步的限定。
当第二处理器114恢复至正常状态时,第二处理器114则可继续接收充电盒反馈的第一验证信息,进而,可以根据接收的第一验证信息来识别充电盒120的开关盖状态信息。
此外,当第一验证信息表征的是第二状态信息为假时,说明第二处理器出现异常,第二处理器根据充电盒反馈的第一验证信息识别开关盖状态信息;还可以是,充电盒将第一验证信息发给第一处理器,再由第一处理器根据第一验证信息触发对第二处理器进行复位,并向第二处理器持续提供一个表征开关盖状态的转换信号,以使得第二处理器在复位后可以根据该转换信号得到正确的开关盖信息。
在本申请实施例中,第二处理器114可以根据第二状态信息和第一状态信息来识别充电盒120的开关盖状态信息,以提高识别开关盖信息的准确性。进一步的,第二处理器114还可以将获取的第二状态信息或第一状态信息发送给充电盒120,与充电盒120实现双向通信,以使充电盒120知晓第一处理器112第二处理器114接收到了检测信息。同时,还可以使对第二状态信息或第一状态信息进行校验,可以避免第一处理器112出现异常时对检测信息无响应的情况发生,同时,还可以提高识别的准确性。
如图7所示,在其中一个实施例中,第二处理器根据检测信息执行第一预设识别策略具体包括步骤702至步骤706。
步骤702,第一处理器获取检测信息,并根据检测信息向第二处理器发送转换信号。
步骤704,第二处理器根据转换信号得到第一状态信息。
步骤702-步骤704与前述实施例中步骤402-步骤404一一对应,在此,不再赘述。
步骤706,第二处理器向充电盒发送第二验证请求,第二验证请求用于指示充电盒对第一状态信息的真伪(真伪即第一状态信息表征的开关盖状态是否正确)进行验证,并根据验证结果反馈第二验证信息。在其中一个实施例中,第二验证信息包括第一状态信息为真时对应的第三验证结果和第一状态信息为假时对应的第四验证结果。
具体的,第二处理器114根据转换信号获取第一状态信息后,第二处理器114向充电盒120发送携带第一状态信息的第二验证请求。当充电盒120接收到第二验证请求时,可以根据第二验证请求来对第二处理器114接收到的第一状态信息的真伪进行验证。例如,第二处理器114也可以以编码或脉冲的方式将第一状态信息发送给充电盒120,以使充电盒120对接收的第一状态信息与盒盖检测模块122检测出的开关盖状态信息进行对比验证,若对比结果一致,则说明第一状态信息为真,充电盒120可以向第二处理器114反馈第三验证结果,其中,第二验证信息用第三验证结果来表示。
在其中一个实施例中,第三验证结果也可以通过编码或脉冲数的形式在充电盒120和第二处理器114之间进行传输。示例性的,第三验证结果可以以“100”或一个脉冲的形式来传输。第二处理器114接收充电盒120反馈的“100”或一个脉冲的第三验证结果则第二处理器114可以根据接收的第一状态信息来识别开关盖状态信息。
充电盒120对接收的第一状态信息与盒盖检测模块122检测出的开关盖状态信息进行对比,若对比结果不一致,则说明第一状态信息为假,充电盒120可向第二处理器114发送第四验证结果。其中,第四验证结果中还可以携带检测信息,第二处理器114可根据接收的检测信息来识别充电盒120的开关盖状态信息。进一步的,第二处理器根据识别结果确定充电盒的开关盖状态信息,包括:第二处理器根据充电盒反馈的第二验证信息识别开关盖状态信息。
示例性的,第二处理器114接收的第二验证信息指的是第一状态信息为真的第三验证结果时,则表明第二处理器114获取的第一状态信息是正确的,第二处理器114可以将获取的第二状态信息作为充电盒120的开关盖状态信息。
第二处理器114接收的第二验证信息指的是第一状态信息为假的第四验证结果时,则表明第二处理器114获取的第一状态信息是错误的,第二处理器114可根据接收的第四验证结果,或第四验证结果携带的检测信息来确定充电盒120的开关盖状态信息。示例性的,若第一状态信息为关盖信息,第二处理器114接收的第二验证信息指的是第一状态信息为假的第四验证结果时,第二处理器114可以根据该第四验证结果直接确定器充电盒120的开关盖状态信息为开盖信息。第二处理器114还可以根据第四验证结果携带的检测信息来确定充电盒120的开关盖状态信息。
本实施例中,第二处理器114接收到第一状态信息后可主动与充电盒120进行通讯,以使充电盒120对第二处理器114接收的第一状态信息进行验证,以确定第二处理器114接收的第一状态信息是否正确,以提高第二处理器114识别开关盖状态信息的可靠性。
如图8所示,在其中一个实施例中,第一处理器根据第一检测信执行第二预设识别策略具体包括步骤802至步骤808。
步骤802,第一处理器接收检测信息得到第三状态信息。
其中,第三状态信息可以理解为第一处理器112根据充电盒120发送的检测信息识别出的用于表征充电盒120的开关盖状态信息。
在其中一个实施例中,当第一处理器112接收的检测信息为“010”或“三个脉冲”时,可以基于预先存储的映射关系,可以识别出检测信息为开盖信息,也即其第三状态信息为开盖信息;当第一处理器112接收的检测信息为“011”或“四个脉冲”时,可以基于预先存储的映射关系,可以识别出检测信息为关盖信息,也即其第三状态信息为关盖信息。
步骤804,第一处理器向充电盒发送第三验证请求;第三验证请求用于指示充电盒对第三状态信息的真伪进行验证,并根据验证结果向第一处理器或第二处理器反馈第三验证信息。其中,针对不同的处理器,该第三验证信息可以是不同的,第一处理器接收的第三验证信息为检测信息为真对应的第五验证结果,第二处理器接收的第三验证信息为第三状态信息为假时对应的第六验证结果。在其中一个实施例中,当第一处理器112接收到检测信息后,第一处理器112向充电盒120发送携带第三状态信息的第三验证请求。当充电盒120接收到第三验证请求时,可以根据第三验证请求来对第一处理器112获取的第三状态信息的真伪进行验证。例如,第一处理器112也可以以编码或脉冲的方式将检测信息发送给充电盒120,以使充电盒120对接收的第三状态信息与盒盖检测模块122检测出的开关盖状态信息进行对比验证,若对比结果一致,则说明第三状态信息为真,充电盒120可以向第一处理器112反馈第三状态信息为真对应的第五验证结果,其中,第三验证信息可以用第五验证结果来表示。若对比结果不一致,则说明第三状态信息为假,充电盒120可以向第二处理器114反馈第三状态信息为假对应的第六验证结果,其中,第三验证信息可以用第六验证结果来表示。在其中一个实施例中,第五验证结果和第六验证结果也可以通过编码或脉冲数的形式在充电盒120和第一处理器112之间进行传输。示例性的,第五验证结果可以以“100”或一个脉冲的形式来传输。第一处理器112可对应接收充电盒120反馈的“100”或一个脉冲的第五验证结果。第六验证结果可以以“001”或二个脉冲的形式来传输。第一处理器112可对应接收充电盒120反馈的“001”或二个脉冲的第六验证结果。
进一步的,第二处理器根据识别结果确定充电盒的开关盖状态信息,包括:第一处理器根据充电盒反馈的第三验证信息指示第二处理器识别开关盖状态信息。
在其中一个实施例中,在第一处理器得到第三状态信息后,第一处理器还会根据第三状态信息向第二处理器发送转换信号,第二处理器根据转换信号确定充电盒的开关盖信息。当第一处理器112接收到用第五验证结果表示的第三验证信息时,则表明第一处理器112获取的第三状态信息是正确的,第一处理器112可以将第三状态信息进行转换,通过盖检测引脚向第二处理器114发送转换信号(例如,高电平或低电平信号)。第二处理器114可以根据接收到的转换信号获取第一状态信息,并根据第一状态信息来识别充电盒120的开关盖状态信息。
可选的,第二处理器根据识别结果确定充电盒的开关盖状态信息,包括:第二处理器根据第三验证信息识别开关盖状态信息。
当第二处理器114接收到充电盒120发送的用第六验证结果表示的第三验证信息时,则表明第一处理器112获取的第三状态信息为假,即,第一处理器112获取的第三状态信息并不能准确的表示充电盒120的开关盖状态信息。第二处理器114可以根据接收的第六验证结果来确定充电盒120的开关盖状态信息。进一步的,第六验证结果还可以携带其检测信息。也即,第二处理器114可以根据接收的检测信息来确定充电盒120的开关盖状态信息。
本申请实施例中,第一处理器112接收到检测信息后可主动与充电盒120进行通讯,以使充电盒120对第一处理器112获取的第三状态信息检测信息进行验证,以确定第一处理器112获取的第三状态信息是否正确,以提高第二处理器114识别开关盖状态信息的可靠性。
进一步的,为了保障时效性和准确性,可以在第一处理器得到检测信息后,根据该检测信息得到第三状态信息后,方法还包括:根据第三状态信息向第二处理器发送转换信号,第二处理器根据转换信号确定充电盒的开关盖信息。该方案可以使得第二处理器尽快的获得开关盖状态信息,从而及时进行蓝牙断开或回连等操作,若第三状态信息被验证后是错误的可以再进行修正,从而兼顾耳机的反应速度和准确性。
在其他方案中也可以有类似操作,比如,在第一预设识别策略下,第一状态信息和第二状态信息不同时,也可以先按照第二状态信息确定开关盖状态,然后待充电盒验证后再决定是否需要校正;在第一预设识别策略的另一种方案下,第二处理器获得第一状态信息后,先按照第一状态信息确定开关盖状态从而执行蓝牙回连或断开,当第一状态信息被充电盒验证后,在根据反馈的验证信息,决定是否需要校正。
在其中一个实施例中,上述任意实施例中的识别充电盒开关盖的方法,在第二处理器114识别出充电盒120的开关盖状态信息后,还包括步骤:第二处理器114向充电盒120发送应答信息,应答信息用于表示第二处理器114识别出充电盒120的开关盖状态信息。当第二处理器114识别出充电盒120的开关盖状态信息后,可以向充电盒120发送应答信息,以告知充电盒120耳机110接收到开关盖状态信息。
图9为一个实施例中识别充电盒开关盖的方法的流程图。本实施例中的识别充电盒开关盖的方法,以运行于图1中的充电盒120上为例进行描述。其中,充电盒120能够为包括第一处理器112和第二处理器114的耳机110进行充电。如图9所示,识别充电盒开关盖的方法包括步骤902至步骤904。
步骤902,检测充电盒盒盖的开关盖状态信息,并根据开关盖状态信息生成检测信息。
在其中一个实施例中,充电盒120中设有盖检测模块122,用于实时检测充电盒120盒盖的开关盖状态信息。其中,开关盖状态信息包括开盖信息和关盖信息。示例性的,盖检测模块122可包括霍尔传感器及磁铁,其中,当耳机110充电盒120开盖时,磁铁远离霍尔传感器,通过检测霍尔传感器的信号的变化来判断充电盒120盒盖的开关盖状态信息。例如,霍尔传感器可设置在充电盒120的开口位置,磁铁可设置在充电盒120的上盖。另外,除了可以通过霍尔传感器与磁铁来检测充电盒120的开关盖状态信息之外,还可以为任何类型的机械或电子开关,包括但不限于瞬时开关、电容传感器、光学传感器、微动开关(通过充电盒120的震动来检测开关状态)、接触开关(例如通过检测上盖和下部的接触来判断开关状态)。
具体的,盖检测模块122在检测到充电盒120的盒盖打开后即可生成开盖信息,并根据开盖信息生成检测信息;盖检测模块122在检测到充电盒120的盒盖关闭后即可生成关盖信息,并根据关盖信息生成检测信息。
步骤904,向耳机发送检测信息;检测信息用于指示第二处理器根据检测信息执行第一预设识别策略;或,第一处理器根据检测信息执行第二预设识别策略;还用于指示第二处理器根据识别结果确定充电盒的开关盖状态信息,其中,检测信息用于表征充电盒盒盖的开关盖状态信息,识别结果是通过执行第一预设识别策略或第二预设识别策略得到的。
示例性的,盖检测模块122在检测到充电盒120的盒盖打开后即可生成开盖信息,并将开盖信息作为检测信息发送给耳机110;盖检测模块122在检测到充电盒120的盒盖关闭后即可生成关盖信息,并 将关盖信息作为检测信息发送给耳机110。
具体的,盖检测模块122在检测到充电盒120的盒盖打开后即可生成开盖信息,并将开盖信息作为检测信息发送给耳机110的第一处理器112和第二处理器114;盖检测模块122在检测到充电盒120的盒盖关闭后即可生成关盖信息,并将关盖信息作为检测信息发送给耳机110的第一处理器112和第二处理器114。在其中一个实施例中,充电盒120可以耳机110发送检测信息具体可包括:充电盒120可以按照预设时序分别向第一处理器112和第二处理器114发送检测信息。
示例性的,充电盒120可以先向第一处理器112发送检测信息,即充电盒120向第一处理器112发送检测信息的时刻早于向第二处理器124发送检测信息的时刻,亦或是,第一处理器112接收检测信息的时刻早于第二处理器124接收检测信息的时刻。充电盒120也可以先向第二处理器124发送检测信息,即充电盒120向第二处理器124发送检测信息的时刻早于向第一处理器112发送检测信息的时刻,亦或是,第二处理器124接收检测信息的时刻早于第一处理器112接收检测信息的时刻。
在其中一个实施例中,充电盒120可以同时向第一处理器112和第二处理器114发送检测信息。
时序可以理解为充电盒120分别向第一处理器112、第二处理器114发送检测信息的时间顺序,也可以理解为第一处理器112、第二处理器114分别接收检测信息的时间顺序。
在其中一个实施例中,检测信息可以以编码或脉冲来表示并在充电盒120与耳机110之间进行通讯。当检测信息用编码来表示时,可以用数字、字母和字符中的一个或组合方式来表示,示例性的,当检测信息为开盖信息时,可以用010来表示,当检测信息为关盖信息时,可以用011来表示。当检测信息用脉冲来表示时,可以用不同的脉冲数来表示,示例性的,当检测信息为开盖信息时,可以三个脉冲来表示,当检测信息为关盖信息时,可以用四个脉冲来表示。
需要说明的是,在本申请实施例中,检测信息的具体形式不做进一步的限定,还可以为其他的方式来表示,不限于上述举例说明。
第一预设识别策略可以理解为第二处理器114根据检测信息识别充电盒120的开关盖状态信息的识别方法。示例性的,第一预设识别策略可以为第二处理器114接收充电盒120发送的检测信息,并根据该检测信息来识别充电盒120的开关盖状态信息。同时,还可以从第一处理器112处获取第一处理器112接收到的检测信息,并根据该检测信息生成的转换信号,得到第二状态信息来识别充电盒120的开关盖状态信息。在执行该第一预设识别策略时,第二处理器114可以对应获取上述两个状态信息进行对比,以确定充电盒120的开关盖状态信息。
第一预设识别策略还可以为第二处理器114根据接收的检测信息得到第一状态信息,并根据该第一状态信息确定充电盒120的开关盖状态信息,并根据第一状态信息和/或第二状态信息向充电盒120发送验证请求以请求验证第一状态信息和/或第二状态信息是否正确,在执行该第一预设识别策略时,第二处理器114可以对应获取并根据充电盒120反馈的验证信息来识别充电盒120的开关盖状态信息。
在其中一个实施例中,第二预设识别策略可以为,第一处理器112根据接收的检测信息,并根据该检测信息识别充电盒120的开关盖状态信息,并向充电盒120发送验证请求以请求验证其识别结果是否正确。在执行该第二预设识别策略时,第一处理器112可以对应获取充电盒120根据验证请求反馈的验证信息,并根据该验证信息指示第二处理器114来确定充电盒120的开关盖状态信息。上述识别充电盒开关盖的方法,充电盒120检测充电盒120盒盖的开关盖状态信息并根据开关盖状态信息生成检测信息,充电盒120向耳机110发送检测信息。检测信息用于指示以使第二处理器根据检测信息执行第一预设识别策略;或,第一处理器根据检测信息执行第二预设识别策略;进一步使得还用于指示第二处理器根据识别结果确定充电盒的开关盖状态信息,可以避免在耳机110上增设额外的传感器来检测充电盒120的开关盖状态信息,显著降低了耳机110的尺寸和结构复杂度,同时,在耳机110中通过设置第一处理器112和第二处理器114(双保险的方式)来与充电盒120进行通信,可以快速、并且可靠地将充电盒120的开关盖状态信息同步给耳机110,有效地保证了耳机110识别开关盖状态信息的准确性。
在其中一个实施例中,识别充电盒开关盖的方法还包括:接收第二处理器执行第一预设策略发出的第一验证请求或第二验证请求,并根据第一验证请求对第一状态信息和/或第二状态信息进行验证,并将第一验证信息发送给第一处理器或第二处理器;或者,根据第二验证请求对第一状态信息进行验证, 并将第二验证信息发送给第二处理器。
具体的,当充电盒120接收到第一验证请求时,可以根据第一验证请求来对第二处理器114接收到的第一状态信息的真伪进行验证。例如,使充电盒120对接收的第一状态信息与盒盖检测模块122检测出的开关盖状态信息进行对比,若对比结果一致,则说明第一状态信息为真,若对比结果不一致,说明第一状态信息为假。充电盒120可根据验证结果向第二处理器114反馈第一验证信息,其中,第一验证信息可用于表征第一状态信息的真伪。
在其中一个实施例中,当充电盒120根据第一验证请求对检测信息进行验证,其第一验证结果为假时,表明第二处理器114可能出现异常。充电盒120可向第一处理器112发送复位指令,第一处理器112根据该复位指令可对第二处理器114进行复位操作,以使第二处理器114回复至正常状态。当第二处理器114恢复至正常状态时,第二处理器114则可继续接收充电盒反馈的第一验证信息,进而,可以根据接收的第一验证信息来识别充电盒120的开关盖状态信息。在本申请实施例中,第二处理器114还可以将获取的第二状态信息发送给充电盒120,与充电盒120实现双向通信,以使充电盒120知晓第一处理器112、第二处理器114接收到了第二状态信息。同时,还可以对第二状态信息进行校验,以提高识别的准确性。
在其中一个实施例中,识别充电盒开关盖的方法,还包括:接收第二处理器发送的第二验证请求,并根据第二验证请求对第一状态信息进行验证;当第一状态信息为真时,向第二处理器反馈第三验证结果的第二验证信息;当第一状态信息为假时,向第二处理器反馈第四验证结果的第二验证信息;其中,第二验证信息用于指示第二处理器根据第二验证信息识别开关盖状态信息。
具体的,当充电盒120接收到第二验证请求时,可以根据第二验证请求来对第二处理器114接收到的第一状态信息的真伪进行验证。例如,第二处理器114也可以以编码或脉冲的方式将第一状态信息发送给充电盒120,以使充电盒120对接收的第一状态信息与盒盖检测模块122检测出的开关盖状态信息进行对比验证,若对比结果一致,则说明第一状态信息为真,充电盒120可以向第二处理器114反馈第三验证结果,其中,第二验证信息用第三验证结果来表示。
充电盒120对接收的第一状态信息与盒盖检测模块122检测出的开关盖状态信息进行对比,若对比结果不一致,则说明第一状态信息为假,充电盒120可向第二处理器114发送第四验证结果,其中,第三验证信息可以用第四验证结果来表示。进一步的,第四验证结果中携带了检测信息,第二处理器114可根据接收的检测信息来识别充电盒120的开关盖状态信息。
本实施例中,充电盒120可对第二处理器114接收的第一状态信息进行验证,以确定第二处理器114接收的第一状态信息是否正确,以提高第二处理器114识别开关盖状态信息的可靠性。
在其中一个实施例中,识别充电盒开关盖的方法,还包括:接收第一处理器执行第二预设策略发出的第三验证请求,并根据第三验证请求对第三状态信息进行验证,并将第三验证结果发送给第一处理器或第二处理器。
在其中一个实施例中,当充电盒120接收到第三验证请求时,可以根据第三验证请求来对第一处理器112获取的第三状态信息的真伪进行验证。例如,充电盒120对接收的第三状态信息与盒盖检测模块122检测出的开关盖状态信息进行对比验证,若对比结果一致,则说明第三状态信息为真,充电盒120可以向第一处理器112反馈第三状态信息为真对应的第五验证结果,其中,第三验证信息可以用第五验证结果来表示。若对比结果不一致,则说明第三状态信息为假,充电盒120可以向第二处理器114反馈第三状态信息为假对应的第六验证结果,其中,第三验证信息可以用第六验证结果来表示。
当第一处理器112接收到用第五验证结果表示的第三验证信息时,则表明第一处理器112获取的第三状态信息是准确的,第一处理器112可以将第三状态信息进行转换,通过盖检测引脚向第二处理器114发送转换信号(例如,高电平或低电平信号)。第二处理器114可以根据接收到的转换信号获取第一状态信息,并根据第一状态信息来识别充电盒120的开关盖状态信息。
当第二处理器114接收到充电盒120发送的用第六验证结果表示的第三验证信息时,则表明第一处理器112接收到的第三状态信息为假,即,第一处理器112接收的检测信息并不能准确的表示充电盒120的开关盖状态信息。第二处理器114可以根据接收的检测信息来识别充电盒120的开关盖状态信息。
本申请实施例中,充电盒120可对第一处理器112获取的第三状态信息进行验证,以确定第一处理器112获取的第三状态信息是否正确,以提高第二处理器114识别开关盖状态信息的可靠性。
为了提升获取开关盖状态的速度,以便第二处理器及时根据开关盖状态信息进行断开蓝牙连接或蓝牙回连等操作,可以在获取到第三状态信息后,先根据第三状态信息生成转换信号发送给第二处理器,以使得第二处理器先根据转换信号进行相应操作,待获得第三验证信息后再判断是否进行对应调整。从而保障准确性的同时可以提升耳机的反应速度。
图10为一个实施例中识别充电盒开关盖的方法的流程图。本实施例中的识别充电盒开关盖的方法,以运行于图1中的耳机110和充电盒120上为例进行描述。如图10所示,识别充电盒开关盖的方法包括步骤1002至步骤1010。
步骤1002,充电盒检测充电盒盒盖的开关盖状态信息,并根据开关盖状态信息生成检测信息;
步骤1004,充电盒向耳机发送检测信息;
步骤1006,耳机接收充电盒发送的检测信息;
步骤1008,第二处理器根据检测信息执行第一预设识别策略;或,第一处理器根据检测信息执行第二预设识别策略;
步骤1010,第二处理器根据识别结果确定充电盒的开关盖状态信息,其中,检测信息用于表征充电盒盒盖的开关盖状态信息,识别结果是通过执行第一预设识别策略或第二预设识别策略得到的。
其中,步骤1002步骤1004与前述实施例中步骤902-步骤904一一对应,步骤1006与前述实施例中步骤204、步骤304对应,步骤1008与前述实施例中步骤206、步骤306对应在此,不再赘述。
上述识别充电盒开关盖的方法,包括耳机110接收充电盒120发送的检测信息;第二处理器根据检测信息执行第一预设识别策略;或,第一处理器根据检测信息执行第二预设识别策略;第二处理器根据识别结果确定充电盒的开关盖状态信息,其中,检测信息用于表征充电盒盒盖的开关盖状态信息,识别结果是通过执行第一预设识别策略或第二预设识别策略得到的,可以避免在耳机110上增设额外的传感器来检测充电盒120的开关盖状态信息,显著降低了耳机110的尺寸和结构复杂度,同时,在耳机110中通过设置第一处理器112和第二处理器114(双保险的方式)来与充电盒120进行通信,可以快速、并且可靠地将充电盒120的开关盖状态信息同步给耳机110,有效地保证了耳机110识别开关盖状态信息的准确性。
应该理解的是,虽然图2-10的流程图中的各个步骤按照箭头的指示依次显示,但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,这些步骤可以以其它的顺序执行。而且,图2-10中的至少一部分步骤可以包括多个子步骤或者多个阶段,这些子步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,这些子步骤或者阶段的执行顺序也不必然是依次进行,而是可以与其它步骤或者其它步骤的子步骤或者阶段的至少一部分轮流或者交替地执行。
本申请还提供一种耳机110,包括第一处理器112和第二处理器114。其中,第一处理器112,用于接收充电盒120发送的检测信息,检测信息用于表征充电盒120盒盖的开关盖状态信息;第二处理器114,与第一处理器112连接,用于根据检测信息执行第一预设识别策略以识别充电盒120的开关盖状态信息;或,第一处理器112还用于根据检测信息执行第二预设识别策略以识别充电盒120的开关盖状态信息。
本申请还提供一种充电盒120,包括:盖检测模块122和第三处理器124。其中,盖检测模块122,用于检测充电盒120的开关盖状态信息;第三处理器124,用于向第一处理器112发送检测信息,检测信息用于表征充电盒120的开关盖状态信息,检测信息用于指示第二处理器114根据检测信息执行第一预设识别策略;或,第一处理器112根据检测信息执行第二预设识别策略;还用于指示第二处理器114根据识别结果确定充电盒120的开关盖状态信息,其中,检测信息用于表征充电盒120盒盖的开关盖状态信息,识别结果是通过执行第一预设识别策略或第二预设识别策略得到的。
本申请还提供一种识别充电盒开关的系统,包括上述任一实施例中的耳机110和充电盒120。
本申请还提供一种计算机可读存储介质,其上存储有计算机程序,其特征在于,计算机程序被处理 器执行时实现上述任一实施例中的识别充电盒开关盖的方法的步骤。
本申请还提供一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行识别充电盒开关盖的方法。
本申请所使用的对存储器、存储、数据库或其它介质的任何引用可包括非易失性和/或易失性存储器。非易失性存储器可包括只读存储器(ROM)、可编程ROM(PROM)、电可编程ROM(EPROM)、电可擦除可编程ROM(EEPROM)或闪存。易失性存储器可包括随机存取存储器(RAM),它用作外部高速缓冲存储器。作为说明而非局限,RAM以多种形式可得,诸如静态RAM(SRAM)、动态RAM(DRAM)、同步DRAM(SDRAM)、双数据率SDRAM(DDR SDRAM)、增强型SDRAM(ESDRAM)、同步链路(Synchlink)DRAM(SLDRAM)、存储器总线(Rambus)直接RAM(RDRAM)、直接存储器总线动态RAM(DRDRAM)、以及存储器总线动态RAM(RDRAM)。
以上实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对本申请专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。
Claims (27)
- 一种识别充电盒开关盖的方法,应用于包括第一处理器和第二处理器的耳机,所述第一处理器与所述第二处理器连接,所述方法包括:所述耳机接收充电盒发送的检测信息;所述第二处理器根据所述检测信息执行第一预设识别策略;所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是通过执行所述第一预设识别策略得到的。
- 根据权利要求1所述的方法,其特征在于,所述第二处理器根据所述检测信息执行第一预设识别策略,包括:所述第一处理器接收所述检测信息,并根据所述检测信息向所述第二处理器发送转换信号;所述第二处理器根据所述转换信号得到第一状态信息;所述第二处理器接收所述检测信息得到第二状态信息;所述第二处理器根据所述第二状态信息和所述第一状态信息得到所述识别结果。
- 根据权利要求1所述的方法,其特征在于,所述第二处理器根据检测信息执行第一预设识别策略,包括:所述第二处理器接收检测信息,得到第二状态信息;所述第一处理器接收所述检测信息,并根据所述检测信息向第二处理器发送转换信号;所述第二处理器根据转换信号获取第一状态信息;所述第二处理器根据所述第一状态信息和所述第二状态信息得到识别结果。
- 根据权利要求2或3所述的方法,其特征在于,所述第二处理器根据第二状态信息和所述第一状态信息得到所述识别结果,所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,包括:所述第二处理器判断所述第二状态信息和第一状态信息是否相同;当所述第二状态信息与所述第一状态信息相同时,所述第二处理器以所述第二状态信息和所述第一状态信息中的一个作为所述开关盖状态信息。
- 根据权利要求4所述的方法,其特征在于,当所述第二状态信息与所述第一状态信息不同时,所述第二处理器以所述第二状态信息作为所述开关盖状态信息。
- 根据权利要求4所述的方法,其特征在于,当所述第二状态信息与所述第一状态信息不同时,所述第二处理器向所述充电盒发送第一验证请求,所述第二处理器根据所述充电盒反馈的第一验证信息确定所述开关盖状态信息,所述第一验证请求用于指示所述充电盒对所述第二处理器接收的所述第二状态信息和所述第一状态信息中的至少一个进行验证,并根据验证结果反馈所述第一验证信息。
- 根据权利要求6所述的方法,其特征在于,所述第一验证信息包括所述充电盒对所述第二状态信息的真伪进行验证的第一验证结果,和所述充电盒对所述第一状态信息的真伪进行验证的第二验证结果中的一个;其中,所述第二处理器根据所述充电盒反馈的第一验证信息识别所述开关盖状态信息,包括:所述第二处理器根据所述第一验证结果和所述第二验证结果中的至少一个识别所述开关盖状态信息。
- 根据权利要求6所述的方法,其特征在于,所述第二处理器根据所述充电盒反馈的第一验证信息识别所述开关盖状态信息前,还包括:所述第一处理器接收所述充电盒发送的复位指令,所述复位指令为所述充电盒在验证所述第二状态信息为假时生成;所述第一处理器根据所述复位指令对所述第二处理器进行复位操作以使所述第二处理器接收所述第一验证信息。
- 根据权利要求1所述的方法,其特征在于,所述第一处理器和所述第二处理器按照预设时序接收所述充电盒发送的所述检测信息。
- 根据权利要求1所述的方法,其特征在于,所述第二处理器根据所述检测信息执行所述第一 预设识别策略,包括:所述第一处理器获取所述检测信息,并根据所述检测信息向所述第二处理器发送转换信号;所述第二处理器根据所述转换信号得到第一状态信息;所述第二处理器向所述充电盒发送第二验证请求,所述第二验证请求用于指示所述充电盒对所述第一状态信息的真伪进行验证,并根据验证结果反馈所述第二验证信息;所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,包括:所述第二处理器根据所述充电盒反馈的第二验证信息识别所述开关盖状态信息。
- 根据权利要求10所述的方法,其特征在于,所述第二验证信息包括所述第一状态信息为真时对应的第三验证结果和所述第一状态信息为假时对应的第四验证结果;其中,所述第二处理器根据所述充电盒反馈的第二验证信息识别所述开关盖状态信息,包括:所述第二处理器根据所述第三验证结果和所述第四验证结果中的一个识别所述充电盒的开关盖状态信息。
- 一种识别充电盒开关盖的方法,应用于包括第一处理器和第二处理器的耳机,所述第一处理器与所述第二处理器连接,所述方法包括:所述耳机接收充电盒发送的检测信息;所述第一处理器根据所述检测信息执行第二预设识别策略;所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是通过执行所述第二预设识别策略得到的。
- 根据权利要求12所述的方法,其特征在于,所述第一处理器根据所述第一检测信息执行所述第二预设识别策略,包括:所述第一处理器接收所述检测信息得到第三状态信息;所述第一处理器向所述充电盒发送第三验证请求;所述第三验证请求用于指示所述充电盒对所述第三状态信息的真伪进行验证,并根据验证结果向所述第一处理器或第二处理器反馈第三验证信息;所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,包括:所述第一处理器根据所述充电盒反馈的第三验证信息指示所述第二处理器识别所述开关盖状态信息;其中,所述第一处理器接收的所述第三验证信息为所述第三状态信息为真对应的第五验证结果。
- 根据权利要求12所述的方法,其特征在于,所述第一处理器根据所述第一检测信息执行所述第二预设识别策略,包括:所述第一处理器接收所述检测信息得到第三状态信息;所述第一处理器向所述充电盒发送第三验证请求;所述第三验证请求用于指示所述充电盒对所述第三状态信息的真伪进行验证,并根据验证结果向所述第一处理器或第二处理器反馈第三验证信息;所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,包括:所述第二处理器根据所述第三验证信息识别所述开关盖状态信息;其中,所述第二处理器接收的所述第三验证信息为所述第三状态信息为假时对应的第六验证结果。
- 根据权利要求13或14所述的方法,其特征在于,在所述第一处理器得到所述第三状态信息后,所述方法还包括:根据所述第三状态信息向所述第二处理器发送所述转换信号,所述第二处理器根据所述转换信号确定所述充电盒的开关盖信息。
- 一种识别充电盒开关盖的方法,应用于能够为包括第一处理器和第二处理器的耳机进行充电的充电盒,所述第一处理器与所述第二处理器连接,所述方法包括:检测所述充电盒盒盖的开关盖状态信息,并根据所述开关盖状态信息生成检测信息;向所耳机发送所述检测信息,所述检测信息用于指示所述第二处理器根据所述检测信息执行第一预设识别策略和用于指示所述第一处理器根据所述检测信息执行第二预设识别策略中的一个;还用于指示所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是通过执行所述第一预设识别策略和所述第二预设识别策略中的一个得到的。
- 根据权利要求16所述的方法,其特征在于,所述向所述耳机发送所述检测信息,包括:按照预设时序分别向所述第一处理器和所述第二处理器发送所述检测信息。
- 根据权利要求16所述的方法,其特征在于,所述向所述耳机发送所述检测信息,包括:同时向所述第一处理器和所述第二处理器发送所述检测信息。
- 根据权利要求16所述的方法,其特征在于,所述方法还包括:接收所述第二处理器执行所述第一预设策略发出的第一验证请求;根据所述第一验证请求对第一状态信息和第二状态信息中的至少一种进行验证,并将所述第一验证信息发送给所述第一处理器和所述第二处理器中的一个。
- 根据权利要求16所述的方法,其特征在于,所述方法还包括:接收所述第二处理器执行所述第一预设策略发出的第二验证请求;根据所述第二验证请求对所述第一状态信息进行验证,并将所述第二验证信息发送给所述第二处理器。
- 根据权利要求16所述的方法,其特征在于,所述方法还包括:接收所述第一处理器执行所述第二预设策略发出的第三验证请求;根据所述第三验证请求对所述第三状态信息进行验证,并将第三验证结果发送给所述第一处理器和所述第二处理器中的一个。
- 一种耳机,包括:第一处理器,用于接收充电盒发送的检测信息,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息;第二处理器,与所述第一处理器连接,用于根据所述检测信息执行第一预设识别策略,还用于根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是所述第二处理器执行所述第一预设识别策略得到的。
- 一种耳机,包括:第一处理器,用于接收充电盒发送的检测信息,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,并根据所述检测信息执行第二预设识别策略;第二处理器,与所述第一处理器连接,用于根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是所述第一处理器执行第二预设识别策略中的一个得到的。
- 一种充电盒,用于为包括第一处理器和与所述第一处理器连接的第二处理器的耳机充电,所述充电盒包括:盖检测模块,用于检测所述充电盒的开关盖状态信息;第三处理器,用于向所述第一处理器发送检测信息,所述检测信息用于表征所述充电盒的开关盖状态信息,所述检测信息用于指示所述第二处理器根据所述检测信息执行第一预设识别策略和用于指示所述第一处理器根据所述检测信息执行第二预设识别策略中的一个;所述检测信息还用于指示所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,所述识别结果是通过执行所述第一预设识别策略和所述第二预设识别策略中的一个得到的。
- 一种识别充电盒开关的系统,包括如权利要求22或23所述的耳机和权利要求24所述的充电盒。
- 一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现如下步骤:所述耳机接收充电盒发送的检测信息;所述第二处理器根据所述检测信息执行第一预设识别策略;所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是通过执行所述第一预设识别策略得到的。
- 一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现如 下步骤:所述耳机接收充电盒发送的检测信息;所述第一处理器根据所述检测信息执行第二预设识别策略;所述第二处理器根据识别结果确定所述充电盒的开关盖状态信息,其中,所述检测信息用于表征所述充电盒盒盖的开关盖状态信息,所述识别结果是通过执行所述第二预设识别策略得到的。
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
EP21768306.9A EP4117303A4 (en) | 2020-03-11 | 2021-03-11 | CHARGING CASE COVER OPEN/CLOSE IDENTIFICATION METHOD, EARPHONE, CHARGING CASE AND SYSTEM |
US17/941,807 US20230007381A1 (en) | 2020-03-11 | 2022-09-09 | Method for identifying cover opening/closing of charging box |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010165034.1 | 2020-03-11 | ||
CN202010165034.1A CN113395620B (zh) | 2020-03-11 | 2020-03-11 | 识别充电盒开关盖的方法、耳机、充电盒、系统 |
Related Child Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US17/941,807 Continuation US20230007381A1 (en) | 2020-03-11 | 2022-09-09 | Method for identifying cover opening/closing of charging box |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2021180148A1 true WO2021180148A1 (zh) | 2021-09-16 |
Family
ID=77615323
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2021/080101 WO2021180148A1 (zh) | 2020-03-11 | 2021-03-11 | 识别充电盒开关盖的方法、耳机、充电盒、系统 |
Country Status (4)
Country | Link |
---|---|
US (1) | US20230007381A1 (zh) |
EP (1) | EP4117303A4 (zh) |
CN (1) | CN113395620B (zh) |
WO (1) | WO2021180148A1 (zh) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US12003346B2 (en) * | 2020-01-13 | 2024-06-04 | Maxim Integrated Products, Inc. | System and method for dual-port communication and power delivery |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN206949751U (zh) * | 2015-09-30 | 2018-02-02 | 苹果公司 | 用于一对无线耳塞的盒和用于便携式收听设备的盒 |
CN109121033A (zh) * | 2018-07-23 | 2019-01-01 | 歌尔股份有限公司 | 蓝牙耳机充电盒和充电盒组件 |
US20190075385A1 (en) * | 2017-09-01 | 2019-03-07 | Cresyn Co., Ltd. | Wireless earphone and charging case |
CN110225427A (zh) * | 2019-05-11 | 2019-09-10 | 出门问问信息科技有限公司 | 耳机充电盒及其数据传输方法、耳机 |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP3189671B1 (en) * | 2014-09-05 | 2020-11-11 | Earin AB | Longitudinal arranged wireless earbuds and the charging thereof |
WO2019133876A1 (en) * | 2017-12-28 | 2019-07-04 | Starkey Laboratories, Inc. | Hearing device case including charger |
CN208316972U (zh) * | 2018-07-04 | 2019-01-01 | 东莞泰升音响科技有限公司 | 具低功耗语音唤醒功能蓝牙耳机 |
CN209710282U (zh) * | 2019-05-11 | 2019-11-29 | 出门问问信息科技有限公司 | 无线耳机充电盒的开盖通讯装置、充电盒及耳机 |
-
2020
- 2020-03-11 CN CN202010165034.1A patent/CN113395620B/zh active Active
-
2021
- 2021-03-11 WO PCT/CN2021/080101 patent/WO2021180148A1/zh unknown
- 2021-03-11 EP EP21768306.9A patent/EP4117303A4/en not_active Withdrawn
-
2022
- 2022-09-09 US US17/941,807 patent/US20230007381A1/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN206949751U (zh) * | 2015-09-30 | 2018-02-02 | 苹果公司 | 用于一对无线耳塞的盒和用于便携式收听设备的盒 |
US20190075385A1 (en) * | 2017-09-01 | 2019-03-07 | Cresyn Co., Ltd. | Wireless earphone and charging case |
CN109121033A (zh) * | 2018-07-23 | 2019-01-01 | 歌尔股份有限公司 | 蓝牙耳机充电盒和充电盒组件 |
CN110225427A (zh) * | 2019-05-11 | 2019-09-10 | 出门问问信息科技有限公司 | 耳机充电盒及其数据传输方法、耳机 |
Non-Patent Citations (1)
Title |
---|
See also references of EP4117303A4 * |
Also Published As
Publication number | Publication date |
---|---|
CN113395620A (zh) | 2021-09-14 |
EP4117303A4 (en) | 2023-08-09 |
CN113395620B (zh) | 2022-08-09 |
EP4117303A1 (en) | 2023-01-11 |
US20230007381A1 (en) | 2023-01-05 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR101606289B1 (ko) | 프로그래머블 컨트롤러 | |
US20190021001A1 (en) | Data communication method for wireless power charging and electronic device using the same | |
US11567748B2 (en) | Interface device having updatable firmware, mobile device, and firmware update method | |
US9761282B2 (en) | Memory system and operating method thereof | |
US11227479B2 (en) | Sensing device for sensing open-or-closed state of door and method for controlling the same | |
WO2021180148A1 (zh) | 识别充电盒开关盖的方法、耳机、充电盒、系统 | |
US8364872B2 (en) | Slave and communicating method between a master and the same | |
CN109450912B (zh) | 数据传输方法、装置和设备 | |
CN109154925A (zh) | 通信设备、通信方法、程序和通信系统 | |
CN106055497A (zh) | 一种电路板的通讯方法及其电路板 | |
US11934164B2 (en) | Remote resetting to factory default settings; a method and a device | |
US10637290B2 (en) | Systems and methods for charging wireless audio devices | |
CN113037498B (zh) | 离线设备的安全认证方法 | |
WO2017080411A1 (zh) | 一种充电参数的校验方法及设备和充电器 | |
CN105142237B (zh) | 设备配对方法和系统 | |
KR20190058266A (ko) | 전력계통 고장기록시스템 | |
KR102169101B1 (ko) | 전력 변환 회로의 보호 제어 장치 및 그 제어 방법 | |
TW202131720A (zh) | 使用者設備及其方法 | |
JP2012093856A (ja) | Icチップ、icチップにおける初期化方法、icチップ用処理プログラム、携帯端末 | |
US10142318B2 (en) | Self-adaptive communication method for encryption dongle | |
JP2015216595A (ja) | 無線通信装置 | |
KR20190138463A (ko) | 복수의 nfc 동작 모드를 지원하는 전자 장치 및 전자 장치의 동작 방법 | |
TWI738627B (zh) | 具有錯誤偵測功能的智能網卡系統及錯誤偵測方法 | |
CN114662082B (zh) | 电子设备的访问控制方法、可读介质和电子设备 | |
CN116361140A (zh) | 测试方法及装置、电子设备、存储介质 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 21768306 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
ENP | Entry into the national phase |
Ref document number: 2021768306 Country of ref document: EP Effective date: 20221005 |