Method, device, sound playing device and medium for adjusting earphone contact

By using Hall sensors and electromagnets in the charging box to detect the magnetic field strength and dynamically adjust the electromagnet current, the problem of unstable connection between the TWS headphones is solved, and the stable contact between the headphones and the charging box is achieved to ensure normal charging and communication. conduct.

CN115119113BActive Publication Date: 2024-11-15GEER TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210753514.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-29
Publication Date
2024-11-15
Estimated Expiration
2042-06-29

AI Technical Summary

Technical Problem

The existing TWS headsets have unstable contact points in the charging box, resulting in problems such as charging failure and abnormal communication.

Method used

Using the method of combining Hall sensor and electromagnet, by detecting the magnetic field strength of the electromagnet in the charging box, dynamically adjusting the electromagnet current to fine-tune the position of the earphones to ensure that the contact points are in full contact.

Benefits of technology

Improve the physical contact stability between the headphones and the charging box, ensuring the normal operation of charging and communication of the headphones.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115119113B_ABST
    Figure CN115119113B_ABST
Patent Text Reader

Abstract

The present application discloses a method, device, sound playback device and medium for adjusting the contact of earphones, and relates to the field of communication technology. The method is applied to a sound playback device including earphones and a charging box, and a Hall sensor and a circuit for adjusting the current of the electromagnet are newly added in the charging box; including: obtaining the current magnetic field strength at the electromagnet detected by the Hall sensor; controlling the output current of the circuit for adjusting the electromagnet current according to the relationship between the current magnetic field strength and the target magnetic field strength so as to adjust the current magnetic field strength. In this method, by controlling the output current of the circuit for adjusting the electromagnet current and based on the principle of electromagnetism, the output current is changed while changing the magnetic field strength, so that the force between the electromagnet on the earphone and the electromagnet on the charging box changes, thereby adjusting the position of the earphone. It can be seen that by dynamically adjusting the electromagnet, the stability of the physical contact between the earphone and the charging box is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communication technology, and in particular to a method, device, sound playing device and medium for adjusting earphone contact. Background Art

[0002] For example, nowadays True Wireless Stereo (TWS) headphones are becoming more and more popular. TWS headphones consist of a charging box and headphones. Most of the charging boxes of TWS headphones have the function of charging the headphones and communicating with the headphones. There are two contact points for communication between the charging box and the headphones. One of these two points is used for the charging box and the headphones to share the ground, and the other is used for charging and communication. The appearance of TWS headphones currently on the market varies. When the headphones are placed in the charging box, due to structural limitations or the influence of shaking, there is a state where the headphones are in the box, but the contact points are not connected or the contact is unstable. This may cause problems such as the headphones not being able to charge, abnormal communication between the headphones and the charging box, etc.

[0003] It can be seen that how to improve the stability of the physical contact between the earphones and the charging box is a technical problem that people in this field urgently need to solve. Summary of the invention

[0004] The purpose of this application is to provide a method, device, sound playback device and medium for adjusting earphone contact, so as to improve the stability of physical contact between earphones and charging box.

[0005] In order to solve the above technical problems, the present application provides a method for adjusting the contact between earphones and a charging box, which is applied to a sound playing device including earphones and a charging box, wherein the earphone end is provided with a first electromagnet and a first contact point; the charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the electromagnet current; the first electromagnet and the second electromagnet have opposite magnetic properties; the Hall sensor is provided at the second electromagnet to measure the magnetic field strength at the second electromagnet; the method comprises:

[0006] Acquire the current magnetic field strength at the second electromagnet detected by the Hall sensor;

[0007] The input signal value of the circuit for adjusting the electromagnet current is obtained according to the relationship between the current magnetic field strength and the target magnetic field strength; wherein the target magnetic field strength is the magnetic field strength measured by the Hall sensor obtained when the first contact point is in full contact with the second contact point;

[0008] The output current of the circuit for adjusting the electromagnet current is controlled according to the input signal value so as to adjust the current magnetic field strength.

[0009] Preferably, the number of the second electromagnets and the number of the Hall sensors are at least 2, and both are arranged at the bottom of the charging bin, and any two of the second electromagnets are respectively located on both sides of the bottom center line of the charging bin; the number of the circuits for adjusting the electromagnet current is at least 2; the second electromagnets, the Hall sensors, and the circuits for adjusting the electromagnet current correspond one to one;

[0010] The obtaining of the current magnetic field strength at the second electromagnet detected by the Hall sensor comprises:

[0011] Transmitting a pulse signal to the earphone at a fixed frequency;

[0012] When it is determined by the pulse signal that a link is established with the headset, obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor;

[0013] The step of controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength comprises:

[0014] In the case where the current magnetic field strength at the current second electromagnet measured by the Hall sensor is greater than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is obtained; wherein the target second electromagnet is another second electromagnet at the bottom of the charging bin opposite to the current second electromagnet; the output current in the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet; and the step of obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor is returned;

[0015] In the case where the current magnetic field strength at the current second electromagnet measured by the Hall sensor is less than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the current second electromagnet is obtained; the output current in the circuit for adjusting the electromagnet current corresponding to the current second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet; and the step of obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor is returned.

[0016] Preferably, the number of the second electromagnets and the number of the Hall sensors are both 4, and the number of the circuits for adjusting the electromagnet current is 4; each of the second electromagnets is arranged at four positions of the charging compartment;

[0017] The step of controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength comprises:

[0018] Respectively obtaining the absolute value of the difference between the current magnetic field strength at the corresponding second electromagnet measured by each Hall sensor and the target magnetic field strength;

[0019] Obtain the second electromagnet corresponding to when the absolute value of the difference is the largest;

[0020] In the case where the current magnetic field strength at the second electromagnet corresponding to the time when the absolute value of the difference measured by the Hall sensor is maximum is greater than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is obtained; wherein the target second electromagnet is the second electromagnet at a diagonal position of the second electromagnet corresponding to the time when the absolute value of the difference is maximum; the output current in the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the second electromagnet corresponding to the time when the absolute value of the difference is maximum; and the step of obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor is returned;

[0021] When the current magnetic field strength at the second electromagnet corresponding to the time when the absolute value of the difference measured by the Hall sensor is maximum is less than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the second electromagnet corresponding to the time when the absolute value of the difference is maximum is obtained; the output current in the circuit for adjusting the electromagnet current corresponding to the second electromagnet corresponding to the time when the absolute value of the difference is maximum is increased according to the input signal value so as to adjust the current magnetic field strength at the second electromagnet corresponding to the time when the absolute value of the difference is maximum; and the step of obtaining the current magnetic field strength at the second electromagnet corresponding to each Hall sensor detected is returned.

[0022] Preferably, after controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength, the method further comprises:

[0023] Outputting prompt information indicating that the adjustment of the earphone is completed and / or recording the number of times the earphone is adjusted.

[0024] Preferably, after controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength, the method further comprises:

[0025] After the adjustment of the earphone is completed, the step of returning to the step of transmitting a pulse signal to the earphone at a fixed frequency within a preset time.

[0026] Preferably, after controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength, the method further comprises:

[0027] When the earphone is ready to communicate with the charging box, the output current of each circuit for adjusting the electromagnet current is adjusted to 0.

[0028] In order to solve the above technical problems, the present application also provides a sound playback device, including: earphones, a charging box;

[0029] The earphone end is provided with a first electromagnet and a first contact point;

[0030] The charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the current of the electromagnet; the magnetic properties of the first electromagnet are opposite to those of the second electromagnet;

[0031] The Hall sensor is disposed at the second electromagnet and is used to measure the magnetic field strength at the second electromagnet;

[0032] The charging box is used to obtain the current magnetic field strength at the second electromagnet detected by the Hall sensor; obtain the input signal value of the circuit for adjusting the electromagnet current based on the relationship between the current magnetic field strength and the target magnetic field strength; control the output current of the circuit for adjusting the electromagnet current based on the input signal value so as to adjust the current magnetic field strength; wherein the target magnetic field strength is the magnetic field strength measured by the Hall sensor obtained when the first contact point is in full contact with the second contact point.

[0033] In order to solve the above technical problems, the present application also provides a device for adjusting the contact between earphones and a charging box, which is applied to a sound playing device including earphones and a charging box, wherein the earphone end is provided with a first electromagnet and a first contact point; the charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the electromagnet current; the first electromagnet and the second electromagnet have opposite magnetic properties; the Hall sensor is provided at the second electromagnet to measure the magnetic field strength at the second electromagnet; the device comprises:

[0034] A first acquisition module, used to acquire the current magnetic field strength at the second electromagnet detected by the Hall sensor;

[0035] a second acquisition module, configured to acquire an input signal value of the circuit for adjusting the electromagnet current according to a relationship between the current magnetic field strength and a target magnetic field strength; wherein the target magnetic field strength is the magnetic field strength measured by the Hall sensor acquired when the first contact point is in full contact with the second contact point;

[0036] A control module is used to control the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength.

[0037] In order to solve the above technical problems, the present application also provides a device for adjusting the contact between the earphone and the charging box, comprising:

[0038] Memory for storing computer programs;

[0039] A processor is used to implement the steps of the above-mentioned method for adjusting the contact between the earphone and the charging box when executing the computer program.

[0040] In order to solve the above technical problems, the present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the above-mentioned method for adjusting the contact between the earphone and the charging box are implemented.

[0041] The present application provides a method for adjusting the contact between earphones and a charging box, which is applied to a sound playback device including earphones and a charging box, wherein the earphone end is provided with a first electromagnet and a first contact point; the charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the electromagnet current; the first electromagnet and the second electromagnet have opposite magnetic properties; the Hall sensor is provided at the second electromagnet to measure the magnetic field strength at the second electromagnet; the method comprises: obtaining the current magnetic field strength at the second electromagnet detected by the Hall sensor; obtaining the input signal value of the circuit for adjusting the electromagnet current according to the relationship between the current magnetic field strength and the target magnetic field strength; wherein the target magnetic field strength is the magnetic field strength measured by the Hall sensor obtained when the first contact point is in full contact with the second contact point; and controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value to adjust the current magnetic field strength. In the method, both the earphone and the charging box are provided with electromagnets, so when the contact between the earphone and the charging box changes, the magnetic field strength detected by the Hall sensor on the charging box at the electromagnet will also change. By controlling the output current of the circuit used to adjust the electromagnet current and based on the principle of electromagnetism, when the output current is changed, the magnetic field strength will also change accordingly, so that the force between the electromagnet on the earphone and the magnetic pole of the electromagnet on the charging box changes, thereby adjusting the position of the earphone. It can be seen that this method improves the stability of the physical contact between the earphone and the charging box by dynamically adjusting the electromagnet.

[0042] In addition, the present application also provides a device for adjusting the contact between the earphone and the charging box, a sound playing device, and a computer-readable storage medium, which have the same or corresponding technical features as the above-mentioned method for adjusting the contact between the earphone and the charging box, and the effect is the same as above. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] In order to more clearly illustrate the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0044] Figure 1 A schematic diagram of charging a charging box provided in an embodiment of the present application;

[0045] Figure 2 A flowchart of a method for adjusting the contact between an earphone and a charging box provided in an embodiment of the present application;

[0046] Figure 3 A structural diagram of a device for adjusting the contact between an earphone and a charging box provided in one embodiment of the present application;

[0047] Figure 4 A structural diagram of a device for adjusting the contact between an earphone and a charging box provided in another embodiment of the present application;

[0048] Figure 5 An overall flow chart of the method for adjusting the contact between the earphone and the charging box provided in an embodiment of the present application. DETAILED DESCRIPTION

[0049] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0050] The core of this application is to provide a method, device, sound playback device and medium for adjusting earphone contact, so as to improve the stability of physical contact between earphones and charging box.

[0051] TWS earphones consist of a charging box and earphones. Most of the charging boxes of TWS earphones have the function of charging and communicating with the earphones. The earphone end and the charging compartment of the charging box are provided with opposite magnetic poles and contact points. Currently, two contact points are set on the earphones and the charging box, one of which is used for the earphones to communicate or charge with the charging box, and the other contact point is used for the earphones and the charging box to share the ground. Figure 1 This is a schematic diagram of charging a charging box provided in an embodiment of the present application. Figure 1 As shown, a charging module is provided on the charging box, and a charging module and a headphone battery are provided on the earphone. When the charging box charges the earphone, the charging contact point of the earphone contacts the charging contact point of the charging box; another contact point of the earphone contacts another contact point of the charging box and shares the ground. When the earphone contacts the charging box, it may be restricted by the structure, etc., resulting in the earphone being in the box, the contact point is not connected or the contact is unstable, which may cause the earphone to fail to charge or the earphone box and the charging box to communicate abnormally. Therefore, the present application adds a Hall sensor at the position of the electromagnet at the bottom of the charging box to detect the magnetic field strength at the electromagnet, and adjusts the output current of the circuit for adjusting the electromagnet current according to the change of the magnetic field strength, thereby achieving the change of the magnetic field strength at the electromagnet, and fine-tuning the position of the earphone through the interaction force between the electromagnet on the earphone and the electromagnet on the charging box, so that the contact point of the earphone and the charging box is in contact as completely as possible, and it is ensured that the charging box can charge the earphone normally and the earphone and the charging box can communicate normally. It should be noted that the method of contact between the earphone and the charging box provided in the present application is also applicable to all contact communication devices.

[0052] In order to enable personnel in this technical field to better understand the present application scheme, the present application is further described in detail below in conjunction with the accompanying drawings and specific implementation methods. This embodiment provides a method for adjusting the contact between earphones and a charging box, which is applied to a sound playback device including earphones and a charging box. The earphone end is provided with a first electromagnet and a first contact point; the charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the electromagnet current; the first electromagnet and the second electromagnet have opposite magnetic properties; the Hall sensor is provided at the second electromagnet to measure the magnetic field strength at the second electromagnet. Figure 2 A flowchart of a method for adjusting the contact between an earphone and a charging box provided in an embodiment of the present application, such as Figure 2 As shown, the method includes:

[0053] S10: Acquire the current magnetic field strength at the second electromagnet detected by the Hall sensor;

[0054] S11: obtaining an input signal value of a circuit for adjusting an electromagnet current according to a relationship between a current magnetic field strength and a target magnetic field strength;

[0055] The target magnetic field strength is the magnetic field strength measured by the Hall sensor when the first contact point is in full contact with the second contact point;

[0056] S12: Controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength.

[0057] Since the earphone and the charging box need to be in contact to charge and communicate, the earphone end and the charging box of the charging box are provided with electromagnets of different names. Through the interaction of the magnetic poles of different names, the earphone can contact the contact point of the charging box. There is no limitation on the number of the first electromagnets provided on the earphone and the number of the second electromagnets provided on the charging box, as long as the magnetic poles of the first electromagnet are opposite to the magnetic poles of the second electromagnet. A Hall sensor is provided at the second electromagnet, and the contact between the contact point of the earphone and the contact point of the charging box can be judged according to the magnetic field strength detected by the Hall sensor. This embodiment is provided with a circuit for adjusting the electromagnet current. The position of the circuit for adjusting the electromagnet current is not limited and is determined according to the actual situation. When the contact point of the earphone is not in contact or not in full contact with the contact point of the charging box, the output of the pulse width modulation (PWM) can be controlled to increase the output current of the circuit for the electromagnet current, change the interaction force between the electromagnet on the earphone and the electromagnet on the charging box, and achieve the purpose of fine-tuning the position of the earphone.

[0058] There are two charging compartments for placing earphones in the charging box. The shape of the charging compartment is usually set according to the shape of the earphones placed, so that the position of the earphones in the charging compartment is relatively stable. Here, a second electromagnet is set on the charging box as an example. When the earphones located in the two charging compartments detect the position of the earphones through a second electromagnet, a Hall sensor is set at the position of the second electromagnet. The specific position is not limited. For example, the Hall sensor is set at the center of the second electromagnet. When the contact points of the two earphones are fully in contact with the contact points of the corresponding charging compartments, the magnetic field strength at the electromagnet position measured by the Hall sensor is obtained, which can be called the target magnetic field strength and recorded as M. In practice, due to structural reasons, each second electromagnet may have a corresponding target magnetic field strength. Adjustment of the earphone position usually refers to fine-tuning the earphone position when the earphone is in the charging box. When the earphone is not in the charging box, there is no need to adjust the position of the earphone. Therefore, the earphone can also be measured by the Hall sensor when it is not in the charging box. The magnetic field strength at the electromagnet position can be N. After obtaining M and N, M and N can be stored in Flash. When comparing the magnetic field strength, M and N can be obtained from Flash. If the positions of the two earphones change, the magnetic field strength of the electromagnet on the earphone and the electromagnet on the charging box at the position of the second electromagnet will also change, and the magnetic field strength at the position of the second electromagnet is measured by the Hall sensor. When the magnetic field strength detected by the Hall sensor is less than the target magnetic field strength, it means that the earphone is away from the contact point on the charging box, and the difference between the magnetic field strength detected by the Hall sensor and the target magnetic field strength is obtained. According to the magnetic field difference, the change value of the output current of the circuit for adjusting the electromagnet current is found as the input signal value of the circuit for adjusting the electromagnet current, and the output current of the circuit for adjusting the electromagnet current is increased according to the input signal value to adjust the current magnetic field strength.

[0059] The method for adjusting the contact between the earphone and the charging box provided in this embodiment is applied to a sound playback device including an earphone and a charging box, wherein the earphone end is provided with a first electromagnet and a first contact point; the charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the electromagnet current; the first electromagnet and the second electromagnet have opposite magnetic properties; the Hall sensor is provided at the second electromagnet to measure the magnetic field strength at the second electromagnet; the method comprises: obtaining the current magnetic field strength at the second electromagnet detected by the Hall sensor; obtaining the input signal value of the circuit for adjusting the electromagnet current according to the relationship between the current magnetic field strength and the target magnetic field strength; wherein the target magnetic field strength is the magnetic field strength measured by the Hall sensor obtained when the first contact point is in full contact with the second contact point; and controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value to adjust the current magnetic field strength. In this method, the earphone and the charging box are both provided with electromagnets, so when the contact between the earphone and the charging box changes, the magnetic field strength detected by the Hall sensor on the charging box at the electromagnet will also change. By controlling the output current of the circuit used to adjust the electromagnet current and based on the principle of electromagnetism, when the output current is changed, the magnetic field strength will also change accordingly, so that the force between the electromagnet on the earphone and the magnetic pole of the electromagnet on the charging box changes, thereby adjusting the position of the earphone. It can be seen that this method improves the stability of the physical contact between the earphone and the charging box by dynamically adjusting the electromagnet.

[0060] In implementation, in order to be able to adjust the position of the earphone more accurately and quickly, so that the contact point of the earphone is in full contact with the contact point of the charging box as much as possible, the preferred implementation method is that the number of second electromagnets and the number of Hall sensors are at least 2, both of which are arranged at the bottom of the charging bin, and any two second electromagnets are respectively located on both sides of the bottom center line of the charging bin; the number of circuits for adjusting the electromagnet current is at least 2; the second electromagnet, the Hall sensor, and the circuit for adjusting the electromagnet current correspond one to one;

[0061] Obtaining the current magnetic field strength at the second electromagnet detected by the Hall sensor includes:

[0062] Send a pulse signal to the earphone at a fixed frequency;

[0063] When it is determined that a link is established with the headset through the pulse signal, obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor;

[0064] Controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength includes:

[0065] When the current magnetic field strength at the current second electromagnet measured by the Hall sensor is greater than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is obtained; wherein the target second electromagnet is another second electromagnet at the bottom of the charging bin opposite to the current second electromagnet; the output current in the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet; and the step of obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor is returned;

[0066] When the current magnetic field strength at the current second electromagnet measured by the Hall sensor is less than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the current second electromagnet is obtained; the output current in the circuit for adjusting the electromagnet current corresponding to the current second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet; and the step of obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor is returned.

[0067] There is a single bus chip on the earphone and the charging box. When the single bus chip on the charging box sends a pulse signal, if the single bus chip on the earphone receives the pulse signal, the earphone sends a signal to establish a link to the charging box, so as to determine whether the contact point of the earphone is in full contact or incomplete contact with the contact point of the charging box, and then measures the magnetic field strength at the corresponding electromagnet through the Hall sensor. A flag bit can be set inside the single bus chip to determine whether the earphone is in the charging box. The single bus chip on the charging box can send a pulse signal to the single bus chip of the earphone at a fixed frequency or a non-fixed frequency, and there is no limitation on this. In this embodiment, the single bus chip on the charging box transmits a pulse signal to the earphone at a fixed frequency, and the specific value of the fixed frequency is not limited and is determined according to actual conditions.

[0068] In this embodiment, the number of second electromagnets is at least 2, and any two second electromagnets are respectively located on both sides of the bottom center line of the charging bin. Since the contact point of the earphone is in full contact with the contact point of the charging box, the center of the earphone usually coincides with the center of the bottom of the charging box. Taking two second electromagnets as an example, if the two second electromagnets are both located on the same side of the bottom center line of the charging bin, when the earphone is close to the two electromagnets, the value of the magnetic field strength detected by the Hall sensor is greater than the target magnetic field strength, and then by increasing the output current in the circuit for adjusting the electromagnet current corresponding to another electromagnet, when the output current is increased, the earphone is further away from the bottom center of the charging bin, that is, the position of the earphone is further away from the target position. The target position here refers to the position of the earphone when the contact point of the earphone is in full contact with the contact point of the charging box, resulting in the earphone being unable to charge normally and communicate normally with the charging box. Therefore, the two second electromagnets need to be located on both sides of the bottom center line of the charging bin. When a Hall sensor detects that the magnetic field strength at the corresponding electromagnet is greater than the target magnetic field strength, it means that the earphone is close to the electromagnet. Therefore, it is necessary to increase the output current in the circuit corresponding to the electromagnet on the opposite side of the electromagnet for adjusting the electromagnet current, according to the principle of electromagnetism, so that the magnetic field strength at the electromagnet on the opposite side of the electromagnet is enhanced, and then the electromagnet on the opposite side of the electromagnet is attracted to the earphone, and the position of the earphone is adjusted so that the earphone is away from the electromagnet; when a Hall sensor detects that the magnetic field strength at the corresponding electromagnet is less than the target magnetic field strength, it means that the earphone is away from the electromagnet. Therefore, it is necessary to increase the output current in the circuit corresponding to the electromagnet for adjusting the electromagnet current, according to the principle of electromagnetism, so that the magnetic field strength at the electromagnet is enhanced, and then the earphone is attracted to the electromagnet, and the position of the earphone is adjusted so that the earphone is close to the electromagnet. In addition, for the value of the increased output current, the change value of the output current of the corresponding circuit for adjusting the electromagnet current can be determined by the magnetic field difference according to the difference between the magnetic field strength detected by the Hall sensor and the target magnetic field strength.

[0069] In practice, multiple adjustments may be required to ensure that the contact point of the earphone is in complete contact with the contact point of the charging box or the contact area reaches the preset requirements. Therefore, after completing one adjustment of the earphone position, you can continue to determine whether the position of the earphone needs to be adjusted based on the magnetic field strength value.

[0070] The method provided in this embodiment realizes the contact between the earphone and the charging box through at least two second electromagnets, at least two Hall sensors, and at least two circuits for adjusting the electromagnet current. It is possible to adjust the position of the earphone more accurately and quickly so that the contact point of the earphone is in as complete contact as possible with the contact point of the charging box.

[0071] In practice, since the location of the charging compartment is relatively small, when more second electromagnets and Hall sensors are set at the bottom of the charging compartment, more space may be needed at the bottom of the charging compartment, and when one electromagnet changes, the change in the magnetic field detected by the Hall sensor is not obvious, and thus the current location of the earphone cannot be accurately and quickly determined. Therefore, the preferred implementation is that the number of second electromagnets and the number of Hall sensors are both 4, and the number of circuits for adjusting the electromagnet current is 4; each second electromagnet is set at four positions of the charging compartment;

[0072] Controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength includes:

[0073] respectively obtaining the absolute value of the difference between the current magnetic field strength at the corresponding second electromagnet measured by each Hall sensor and the target magnetic field strength;

[0074] Obtain the second electromagnet corresponding to the time when the absolute value of the difference is the largest;

[0075] When the current magnetic field strength at the corresponding second electromagnet when the absolute value of the difference measured by the Hall sensor is the largest is greater than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is obtained; wherein the target second electromagnet is the second electromagnet at a diagonal position of the second electromagnet corresponding to the absolute value of the difference being the largest; the output current in the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the corresponding second electromagnet when the absolute value of the difference is the largest; and the step of obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor is returned;

[0076] When the current magnetic field strength at the second electromagnet corresponding to the time when the absolute value of the difference measured by the Hall sensor is the largest is less than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the second electromagnet corresponding to the time when the absolute value of the difference is the largest is obtained; the output current in the circuit for adjusting the electromagnet current corresponding to the second electromagnet corresponding to the time when the absolute value of the difference is the largest is increased according to the input signal value so as to adjust the current magnetic field strength at the second electromagnet corresponding to the time when the absolute value of the difference is the largest; and the step of obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor is returned.

[0077] The bottom end of the earphone handheld part is a square, and the corresponding shape of the bottom of the charging case is a square. Four second electromagnets and four Hall sensors are set at the four corners of the bottom of the charging case. Assume that there are four second electromagnets A, B, C, and D, respectively. Among them, A is diagonal to C, and B is diagonal to C. When the center of the bottom end of the earphone handheld part coincides with the center of the bottom of the charging case, the target magnetic field strength values ​​at each second electromagnet are equal; assuming that the value of the magnetic field strength at A detected by the Hall sensor corresponding to A is greater than the target magnetic field strength, it means that the earphone is close to A. Therefore, it is necessary to increase the output current in the circuit corresponding to C for adjusting the electromagnet current to adjust the earphone away from A; assuming that the value of the magnetic field strength at A detected by the Hall sensor corresponding to A is less than the target magnetic field strength, it means that the earphone is far away from A. Therefore, it is necessary to increase the output current in the circuit corresponding to A for adjusting the electromagnet current to adjust the earphone close to A.

[0078] When adjusting the position of the earphone, in order to quickly make the contact point of the earphone and the contact point of the charging box fully contact or the contact area reach the preset requirements, the one with the largest difference between the current magnetic field strength and the target magnetic field strength is processed each time.

[0079] The method provided in this embodiment for achieving contact between the earphone and the charging box by using four second electromagnets, four Hall sensors, and four circuits for adjusting the electromagnet current can reduce the occupied area of ​​the bottom of the charging compartment compared to the case where more than four electromagnets are set; the change in magnetic field strength can be obtained more clearly. In addition, each time the difference between the current magnetic field strength and the target magnetic field strength is the largest, the earphone position can be adjusted more quickly and accurately.

[0080] In implementation, in order to facilitate the user to understand the contact status of the earphone and the charging box, the preferred implementation mode is that after controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength, it also includes:

[0081] The output is used to indicate that the adjustment of the earphone is completed and / or to record the number of times the earphone is adjusted.

[0082] There is no limitation on the prompting method and content of the prompting information, which are determined according to the actual situation. There is no limitation on the recording cycle and location when recording the number of times the earphone is adjusted, which are also determined according to the actual situation.

[0083] The output provided in this embodiment is used to indicate the prompt information of completing the adjustment of the earphone and / or record the number of times the earphone is adjusted, so that the user can intuitively understand the contact status of the earphone and the charging box.

[0084] In practice, after completing one adjustment of the earphone, there may be human factors that cause the contact between the contact point of the earphone and the contact point of the charging box to change, so the position of the earphone needs to be determined again. A preferred implementation is that after controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value to adjust the current magnetic field strength, it also includes:

[0085] After the adjustment of the earphone is completed, the process returns to the step of transmitting a pulse signal to the earphone at a fixed frequency within a preset time.

[0086] The specific value of the preset time is not limited and is determined according to actual conditions. The embodiment provides a step of returning to the step of transmitting a pulse signal to the earphone at a fixed frequency within a preset time after the earphone is adjusted, so as to monitor the position of the earphone and adjust the situation where the earphone contact point is not in contact or is not in full contact with the charging box contact point.

[0087] When the earphone and the charging box need to communicate, if magnetism exists, the communication may be affected. Therefore, a preferred implementation is that after controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength, it also includes:

[0088] When the earphones and the charging box are ready to communicate, the output current of each circuit used to adjust the electromagnet current is adjusted to 0.

[0089] Since the electromagnetic field may interfere with the single-bus communication between the earphones and the charging box, before the charging box needs to communicate with the earphones, the charging box controls the current of the circuit used to adjust the electromagnet current so that the magnetism at the contact point is 0, thereby reducing the interference of the electromagnetic field on the communication between the earphones and the charging box.

[0090] This embodiment provides a sound playback device, including: earphones, a charging box;

[0091] The earphone end is provided with a first electromagnet and a first contact point;

[0092] The charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the current of the electromagnet; the first electromagnet has opposite magnetic properties to the second electromagnet;

[0093] The Hall sensor is arranged at the second electromagnet and is used to measure the magnetic field strength at the second electromagnet;

[0094] The charging box is used to obtain the current magnetic field strength at the second electromagnet detected by the Hall sensor; obtain the input signal value of the circuit for adjusting the electromagnet current based on the relationship between the current magnetic field strength and the target magnetic field strength; control the output current of the circuit for adjusting the electromagnet current based on the input signal value so as to adjust the current magnetic field strength; wherein the target magnetic field strength is the magnetic field strength measured by the Hall sensor obtained when the first contact point is in full contact with the second contact point.

[0095] The sound playback device provided in this embodiment has corresponding technical features as the method for adjusting the earphone contact mentioned above, and has the same beneficial effects as the method for adjusting the earphone contact mentioned above. The method for adjusting the earphone contact has been described in detail above, and the specific embodiment of the sound playback device will not be repeated here.

[0096] In the above embodiments, the method for adjusting the contact between the earphone and the charging box is described in detail, and the present application also provides an embodiment corresponding to the device for adjusting the contact between the earphone and the charging box. It should be noted that the present application describes the embodiments of the device part from two perspectives, one is based on the functional module perspective, and the other is based on the hardware perspective.

[0097] Figure 3 A structural diagram of a device for adjusting the contact between earphones and a charging box provided for an embodiment of the present application. The device is applied to a sound playback device including earphones and a charging box, wherein the earphone end is provided with a first electromagnet and a first contact point; the charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the electromagnet current; the first electromagnet and the second electromagnet have opposite magnetic properties; the Hall sensor is provided at the second electromagnet to measure the magnetic field strength at the second electromagnet. This embodiment, based on the perspective of functional modules, includes:

[0098] A first acquisition module 10 is used to acquire the current magnetic field strength at the second electromagnet detected by the Hall sensor;

[0099] A second acquisition module 11 is used to obtain an input signal value of a circuit for adjusting the electromagnet current according to a relationship between a current magnetic field strength and a target magnetic field strength; wherein the target magnetic field strength is a magnetic field strength measured by a Hall sensor obtained when the first contact point is in full contact with the second contact point;

[0100] The control module 12 is used to control the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength.

[0101] Since the embodiments of the device part correspond to the embodiments of the method part, please refer to the description of the embodiments of the method part for the embodiments of the device part, and will not be repeated here. The method for adjusting the contact between the earphone and the charging box mentioned above has corresponding technical features and the effect is the same as above.

[0102] Figure 4 This is a structural diagram of a device for adjusting the contact between the earphone and the charging box provided in another embodiment of the present application. This embodiment is based on the hardware perspective, such as Figure 4 As shown, the device for adjusting the contact between the earphone and the charging box includes:

[0103] A memory 20, used for storing computer programs;

[0104] The processor 21 is used to implement the steps of the method for adjusting the contact between the earphone and the charging box as mentioned in the above embodiment when executing the computer program.

[0105] Among them, the processor 21 may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 21 can be implemented in at least one hardware form of a digital signal processor (DSP), a field-programmable gate array (FPGA), and a programmable logic array (PLA). The processor 21 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a central processing unit (CPU); the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor 21 may be integrated with a graphics processing unit (GPU), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor 21 may also include an artificial intelligence (AI) processor, which is used to process computing operations related to machine learning.

[0106] The memory 20 may include one or more computer-readable storage media, which may be non-transitory. The memory 20 may also include a high-speed random access memory, and a non-volatile memory, such as one or more disk storage devices, flash memory storage devices. In this embodiment, the memory 20 is at least used to store the following computer program 201, wherein, after the computer program is loaded and executed by the processor 21, it can implement the relevant steps of the method for adjusting the contact between the earphone and the charging box disclosed in any of the aforementioned embodiments. In addition, the resources stored in the memory 20 may also include an operating system 202 and data 203, etc., and the storage method may be temporary storage or permanent storage. Among them, the operating system 202 may include Windows, Unix, Linux, etc. Data 203 may include, but is not limited to, the data involved in the above-mentioned method for adjusting the contact between the earphone and the charging box.

[0107] In some embodiments, the device for adjusting the contact between the earphone and the charging box may also include a display screen 22, an input and output interface 23, a communication interface 24, a power supply 25 and a communication bus 26.

[0108] Those skilled in the art will understand that Figure 4 The structure shown in does not constitute a limitation on the device for adjusting the contact between the earphones and the charging box, and may include more or fewer components than shown in the figure.

[0109] The device for adjusting the contact between the earphone and the charging box provided in the embodiment of the present application includes a memory and a processor. When the processor executes the program stored in the memory, it can implement the following method: a method for adjusting the contact between the earphone and the charging box, and the effect is the same as above.

[0110] Finally, the present application also provides an embodiment corresponding to a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps recorded in the above method embodiment are implemented.

[0111] It is understandable that if the method in the above embodiment is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program code.

[0112] The computer-readable storage medium provided in the present application includes the above-mentioned method for adjusting the contact between the earphones and the charging box, and the effect is the same as above.

[0113] In order to enable those skilled in the art to better understand the technical solution of the present application, Figure 5 Further details of the above application are given. Figure 5 This is an overall flow chart of the method for adjusting the contact between the earphone and the charging box provided in an embodiment of the present application. Figure 5 As shown, the method includes:

[0114] S13: Turn on the charging box;

[0115] S14: Get M and N from Flash;

[0116] S15: Determine whether the earphone is in the charging box according to the internal flag of the single bus chip; if so, proceed to step S16 to step S23; if not, proceed to step S24 to step S26;

[0117] S16: Read the magnetic field size S measured by the Hall sensor;

[0118] S17: Determine whether S is greater than N and less than M; if so, proceed to step S18;

[0119] S18: Calculate the difference Q between S and M;

[0120] S19: Determine whether the number of times the magnetism is changed is greater than 3; if so, proceed to step S20; if not, proceed to step S21;

[0121] S20: Based on the original current change, the output current of the circuit is increased to make the magnetism stronger so as to adjust the position of the earphone;

[0122] S21: The charging box controls the PWM output for controlling the electromagnet circuit according to the size of the Q value, changes the current circuit and thus changes the magnetic field strength to adjust the position of the earphone;

[0123] S22: record the number of times the magnetism is changed;

[0124] S23: delay 30s; return to step S15;

[0125] S24: Determine whether the charging box and the headset are ready to communicate; if so, proceed to step S25;

[0126] S25: Adjust the PWM output to make the magnetism at the contact point zero;

[0127] S26: Determine whether the communication is completed; if so, return to step S15.

[0128] It can be seen that this method improves the stability of the physical contact between the earphones and the charging box by dynamically adjusting the electromagnetism.

[0129] The above is a detailed introduction to the method, device, sound playback device and medium for adjusting the headphone contact provided by the present application. The various embodiments in the specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same and similar parts between the embodiments can be referenced to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description. It should be pointed out that for ordinary technicians in this technical field, without departing from the principles of the present application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall within the scope of protection of the claims of the present application.

[0130] It should also be noted that, in this specification, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "comprise", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the statement "comprises a ..." does not exclude the presence of other identical elements in the process, method, article or device including the element.

Claims

1. A method for adjusting the contact between an earphone and a charging box, characterized in that: Applicable to a sound playback device including earphones and a charging box, the earphone end is provided with a first electromagnet and a first contact point; the charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the electromagnet current; the first electromagnet and the second electromagnet have opposite magnetic properties; the Hall sensor is provided at the second electromagnet, and is used to measure the magnetic field strength at the second electromagnet; the method comprises: Acquire the current magnetic field strength at the second electromagnet detected by the Hall sensor; The input signal value of the circuit for adjusting the electromagnet current is obtained according to the relationship between the current magnetic field strength and the target magnetic field strength; wherein the target magnetic field strength is the magnetic field strength measured by the Hall sensor obtained when the first contact point is in full contact with the second contact point; controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength; The number of the second electromagnets and the number of the Hall sensors are at least 2, and both are arranged at the bottom of the charging bin, and any two of the second electromagnets are respectively located on both sides of the bottom center line of the charging bin; the number of the circuits for adjusting the electromagnet current is at least 2; the second electromagnets, the Hall sensors, and the circuits for adjusting the electromagnet current correspond one to one; The step of controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength comprises: In the case where the current magnetic field strength at the current second electromagnet measured by the Hall sensor is greater than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is obtained; wherein the target second electromagnet is another second electromagnet at the bottom of the charging bin that is opposite to the current second electromagnet; the output current in the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet; When the current magnetic field strength at the current second electromagnet measured by the Hall sensor is less than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the current second electromagnet is obtained; and the output current in the circuit for adjusting the electromagnet current corresponding to the current second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet.

2. The method for adjusting the contact between the earphone and the charging box according to claim 1, characterized in that: The obtaining of the current magnetic field strength at the second electromagnet detected by the Hall sensor comprises: Transmitting a pulse signal to the earphone at a fixed frequency; In the case where it is determined by the pulse signal that a link is established with the headset, obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor; After increasing the output current in the circuit for adjusting the electromagnet current corresponding to the target second electromagnet according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet, or after increasing the output current in the circuit for adjusting the electromagnet current corresponding to the current second electromagnet according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet, the method further includes: Return to the step of obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor.

3. The method for adjusting the contact between the earphone and the charging box according to claim 2, characterized in that: The number of the second electromagnets and the number of the Hall sensors are both 4, and the number of the circuits for adjusting the electromagnet current is 4; each of the second electromagnets is arranged at four positions of the charging compartment; The step of controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength comprises: Respectively obtaining the absolute value of the difference between the current magnetic field strength at the corresponding second electromagnet measured by each Hall sensor and the target magnetic field strength; Obtain the second electromagnet corresponding to when the absolute value of the difference is the largest; In the case where the current magnetic field strength at the second electromagnet corresponding to the time when the absolute value of the difference measured by the Hall sensor is maximum is greater than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is obtained; wherein the target second electromagnet is the second electromagnet at a diagonal position of the second electromagnet corresponding to the time when the absolute value of the difference is maximum; the output current in the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the second electromagnet corresponding to the time when the absolute value of the difference is maximum; and the step of obtaining the current magnetic field strength at the corresponding second electromagnet detected by each Hall sensor is returned; When the current magnetic field strength at the second electromagnet corresponding to the time when the absolute value of the difference measured by the Hall sensor is maximum is less than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the second electromagnet corresponding to the time when the absolute value of the difference is maximum is obtained; the output current in the circuit for adjusting the electromagnet current corresponding to the second electromagnet corresponding to the time when the absolute value of the difference is maximum is increased according to the input signal value so as to adjust the current magnetic field strength at the second electromagnet corresponding to the time when the absolute value of the difference is maximum; and the step of obtaining the current magnetic field strength at the second electromagnet corresponding to each Hall sensor detected is returned.

4. The method for adjusting the contact between the earphone and the charging box according to claim 2 or 3, characterized in that: After controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength, the method further includes: Outputting prompt information indicating that the adjustment of the earphone is completed and / or recording the number of times the earphone is adjusted.

5. The method for adjusting the contact between the earphone and the charging box according to claim 4, characterized in that: After controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength, the method further includes: After the adjustment of the earphone is completed, the step of returning to the step of transmitting a pulse signal to the earphone at a fixed frequency within a preset time.

6. The method for adjusting the contact between the earphone and the charging box according to claim 2 or 3, characterized in that: After controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength, the method further includes: When the earphone is ready to communicate with the charging box, the output current of each circuit for adjusting the electromagnet current is adjusted to 0.

7. A sound playing device, characterized in that: include: Earphones, charging box; The earphone end is provided with a first electromagnet and a first contact point; The charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the electromagnet current; the first electromagnet and the second electromagnet have opposite magnetic properties; the number of the second electromagnets and the number of the Hall sensors are at least 2, all of which are arranged at the bottom of the charging compartment, and any two of the second electromagnets are respectively located on both sides of the bottom center line of the charging compartment; the number of the circuits for adjusting the electromagnet current is at least 2; the second electromagnet, the Hall sensor, and the circuit for adjusting the electromagnet current correspond one to one; The Hall sensor is disposed at the second electromagnet and is used to measure the magnetic field strength at the second electromagnet; The charging box is used to obtain the current magnetic field strength at the second electromagnet detected by the Hall sensor; The input signal value of the circuit for adjusting the electromagnet current is obtained according to the relationship between the current magnetic field strength and the target magnetic field strength; the output current of the circuit for adjusting the electromagnet current is controlled according to the input signal value so as to adjust the current magnetic field strength; wherein the target magnetic field strength is the magnetic field strength measured by the Hall sensor obtained when the first contact point is in full contact with the second contact point; The step of controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength comprises: In the case where the current magnetic field strength at the current second electromagnet measured by the Hall sensor is greater than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is obtained; wherein the target second electromagnet is another second electromagnet at the bottom of the charging bin that is opposite to the current second electromagnet; the output current in the circuit for adjusting the electromagnet current corresponding to the target second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet; When the current magnetic field strength at the current second electromagnet measured by the Hall sensor is less than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the current second electromagnet is obtained; and the output current in the circuit for adjusting the electromagnet current corresponding to the current second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet.

8. A device for adjusting the contact between an earphone and a charging box, characterized in that: Applicable to a sound playback device including earphones and a charging box, the earphone end is provided with a first electromagnet and a first contact point; the charging compartment of the charging box is provided with a second electromagnet, a second contact point, a Hall sensor, and a circuit for adjusting the electromagnet current; the first electromagnet and the second electromagnet have opposite magnetic properties; the Hall sensor is arranged at the second electromagnet to measure the magnetic field strength at the second electromagnet; the number of the second electromagnets and the number of the Hall sensors are at least 2, all of which are arranged at the bottom of the charging compartment, and any two of the second electromagnets are respectively located on both sides of the bottom center line of the charging compartment; the number of the circuits for adjusting the electromagnet current is at least 2; The second electromagnet, the Hall sensor, and the circuit for adjusting the electromagnet current correspond to each other one by one; The device comprises: A first acquisition module, used to acquire the current magnetic field strength at the second electromagnet detected by the Hall sensor; a second acquisition module, configured to acquire an input signal value of the circuit for adjusting the electromagnet current according to a relationship between the current magnetic field strength and a target magnetic field strength; wherein the target magnetic field strength is the magnetic field strength measured by the Hall sensor acquired when the first contact point is in full contact with the second contact point; A control module, used for controlling the output current of the circuit for adjusting the electromagnet current according to the input signal value so as to adjust the current magnetic field strength; The control module is specifically used to obtain the input signal value of the circuit for adjusting the electromagnet current corresponding to the target second electromagnet when the current magnetic field strength at the current second electromagnet measured by the Hall sensor is greater than the corresponding target magnetic field strength; wherein the target second electromagnet is another second electromagnet at the bottom of the charging bin that is opposite to the current second electromagnet; and increase the output current in the circuit for adjusting the electromagnet current corresponding to the target second electromagnet according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet; When the current magnetic field strength at the current second electromagnet measured by the Hall sensor is less than the corresponding target magnetic field strength, the input signal value of the circuit for adjusting the electromagnet current corresponding to the current second electromagnet is obtained; and the output current in the circuit for adjusting the electromagnet current corresponding to the current second electromagnet is increased according to the input signal value so as to adjust the current magnetic field strength at the current second electromagnet.

9. A device for adjusting the contact between an earphone and a charging box, characterized in that: include: Memory for storing computer programs; A processor, configured to implement the steps of the method for adjusting the contact between the earphone and the charging box as described in any one of claims 1 to 6 when executing the computer program.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method for adjusting the contact between the earphone and the charging box as described in any one of claims 1 to 6 are implemented.