Electronic equipment
By using the first and second sensors in a foldable phone to obtain magnetic field data and combining it with an adsorption magnet design, the problem of large errors in the shape change of the electronic compass is solved, and accurate magnetic field measurement is achieved in different states.
Patent Information
- Application Number
- CN202410474503.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-18
- Publication Date
- 2025-10-24
AI Technical Summary
When using an electronic compass in an electronic device with a flexible shape, such as a foldable phone, the measurement results may have large errors due to changes in the magnetic field generated by the internal components.
The first and second sensors are used to respectively obtain magnetic field data of the electronic device in different states, and the processor determines the geomagnetic field data based on these data. The position design of the adsorption magnet and the sensor is combined to reduce the influence of the interfering magnetic field.
It effectively reduces the measurement error of the electronic compass and ensures accurate acquisition of geomagnetic field data under different conditions.
Smart Images

Figure CN120831094A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] Embodiments of the present application relate to the technical field of electronic devices, and in particular to an electronic device. BACKGROUND
[0002] Electronic compass is an instrument for orientation by measuring the earth's magnetic field, which is widely used in various electronic devices. However, the morphology of electronic devices such as folding mobile phones is not fixed, and the magnetic field generated by the internal devices of the electronic device changes with the change of the morphology of the electronic device, which easily affects the measurement results of the electronic compass, resulting in a large error of the electronic compass. SUMMARY
[0003] Embodiments of the present application provide an electronic device, which can reduce the error of the electronic compass.
[0004] Embodiments of the present application provide an electronic device, comprising a first middle frame, a second middle frame, a first sensor, a second sensor and a processor, wherein the second middle frame is foldably connected with the first middle frame, the second middle frame can be folded or unfolded relative to the first middle frame, the first sensor is configured to obtain first magnetic field data in its vicinity, the second sensor is configured to obtain second magnetic field data in its vicinity, the first sensor and the second sensor can be arranged on the first middle frame or the second middle frame, and the processor is connected with the first sensor and the second sensor, and is configured to determine the geomagnetic field data of the position where the electronic device is located according to the first magnetic field data and the second magnetic field data.
[0005] Through the above arrangement, the processor can determine the geomagnetic field data of the position where the electronic device is located according to the first magnetic field data and the second magnetic field data, thereby effectively reducing the influence of the interference magnetic field on the geomagnetic field data, and further reducing the error of the electronic compass.
[0006] In some embodiments that can include the above embodiments, the electronic device comprises an adsorption magnet, which is configured to attract the first middle frame and the second middle frame by magnetic force when the first middle frame and the second middle frame are folded together. Through the above arrangement, the electronic device can maintain the folded state.
[0007] In some embodiments that can include the above embodiments, the first sensor is arranged on the first middle frame, and the second sensor is arranged on the second middle frame, the processor selects the first magnetic field data as the geomagnetic field data when the first middle frame and the second middle frame are folded together, and the processor selects the second magnetic field data as the geomagnetic field data when the first middle frame is unfolded relative to the second middle frame.
[0008] Through the above arrangement, the processor can select one of the first magnetic field data and the second magnetic field data which is less disturbed by the magnetic field formed by the adsorption magnet and other devices as the geomagnetic field data, so as to reduce the error of the measurement results of the geomagnetic field data.
[0009] In some embodiments that can include the above-mentioned embodiments, the first sensor and the second sensor have a spacing distance between a projection of the first sensor on the first middle frame and a projection of the second sensor on the first middle frame when the first middle frame and the second middle frame are folded together.
[0010] With the above arrangement, the first sensor and the second sensor are interfered by magnetic fields formed by the attracting magnets and the like to different degrees when the first middle frame and the second middle frame are folded together, and the processor can select the one of the first magnetic field data and the second magnetic field data that is less interfered as the geomagnetic field data.
[0011] In some embodiments that can include the above-mentioned embodiments, the first middle frame includes a first top edge and a first bottom edge arranged oppositely, and the electronic device further includes a first circuit board arranged on the first middle frame, the first circuit board being arranged closer to the first top edge than to the first bottom edge, the first sensor being arranged on the first circuit board and closer to the first top edge.
[0012] With the above arrangement, the first sensor can be away from some electronic devices in the electronic device, so as to reduce the degree of interference on the first sensor and to reduce the error of the measurement result of the geomagnetic field data.
[0013] In some embodiments that can include the above-mentioned embodiments, the second middle frame includes a second top edge and a second bottom edge arranged oppositely, and the electronic device further includes a second circuit board arranged on the second middle frame, the second circuit board being arranged closer to the second bottom edge, the second sensor being arranged on the second circuit board and closer to the second bottom edge.
[0014] With the above arrangement, the second sensor can be away from some electronic devices in the electronic device, so as to reduce the degree of interference on the second sensor and to reduce the error of the measurement result of the geomagnetic field data.
[0015] In some embodiments that can include the above-mentioned embodiments, the electronic device further includes an electronic device arranged on at least one of the first middle frame and the second middle frame, the processor is connected to the electronic device, a magnetic field formed by a current generated by the electronic device when the electronic device is working can interfere with the first sensor and the second sensor, the processor is configured to determine whether the electronic device is in a working state, if the processor determines that the electronic device is not working, the processor selects the first magnetic field data as the geomagnetic field data when the first middle frame and the second middle frame are folded together, and the processor selects the second magnetic field data as the geomagnetic field data when the first middle frame is unfolded relative to the second middle frame.
[0016] With the above arrangement, the processor can select the one of the first magnetic field data and the second magnetic field data that is less interfered as the geomagnetic field data, so as to reduce the error of the measurement result of the geomagnetic field data.
[0017] In some embodiments that can include the above-mentioned embodiments, when the processor determines that the electronic device is working, the processor performs data fitting based on the first magnetic field data when the first middle frame and the second middle frame are folded together, the processor determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data, the processor performs data fitting based on the second magnetic field data when the first middle frame is unfolded relative to the second middle frame, and the processor determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data.
[0018] Through the above arrangement, the processor can reduce the measurement error of the first magnetic field data or the second magnetic field data to reduce the error of the measurement result of the geomagnetic field data.
[0019] In some embodiments that can include the above-mentioned embodiments, the first magnetic field data includes a first magnetic field strength, a second magnetic field strength, and a third magnetic field strength, the second magnetic field data includes a fourth magnetic field strength, a fifth magnetic field strength, and a sixth magnetic field strength, and the geomagnetic field data includes a seventh magnetic field strength, an eighth magnetic field strength, and a ninth magnetic field strength, wherein the first magnetic field strength, the fourth magnetic field strength, and the seventh magnetic field strength all extend along an X-axis direction, the second magnetic field strength, the fifth magnetic field strength, and the ninth magnetic field strength all extend along a Y-axis direction, the third magnetic field strength, the sixth magnetic field strength, and the ninth magnetic field strength all extend along a Z-axis direction, the X-axis direction is perpendicular to the Y-axis direction, and the Z-axis direction is perpendicular to both the X-axis direction and the Y-axis direction, and the processor determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data by taking the smaller one of the first magnetic field strength and the fourth magnetic field strength as the seventh magnetic field strength, taking the smaller one of the second magnetic field strength and the fifth magnetic field strength as the eighth magnetic field strength, and taking the smaller one of the third magnetic field strength and the sixth magnetic field strength as the ninth magnetic field strength.
[0020] Through the above arrangement, the processor takes the one of the first magnetic field strength and the fourth magnetic field strength that is less disturbed by the magnetic field formed by the current when the electronic device is working as the seventh magnetic field strength, takes the one of the second magnetic field strength and the fifth magnetic field strength that is less disturbed as the eighth magnetic field strength, and takes the one of the third magnetic field strength and the sixth magnetic field strength that is less disturbed as the ninth magnetic field strength, and represents the geomagnetic field data by the vector sum of the seventh magnetic field strength, the eighth magnetic field strength, and the ninth magnetic field strength to reduce the error of the measurement result of the geomagnetic field data.
[0021] In some embodiments that can include the above-mentioned embodiments, the electronic device includes at least one of an antenna, a camera module, and a speaker.
[0022] In some embodiments that can include the above-mentioned embodiments, the processor is connected to the first sensor through a first integrated circuit bus and is connected to the second sensor through a second integrated circuit bus. Through the above arrangement, the processor can simultaneously acquire the first magnetic field data and the second magnetic field data.
[0023] In some embodiments which can include the above-mentioned embodiments, the first sensor and the second sensor each include a magnetometer. Through the above-mentioned arrangement, the first sensor can acquire first magnetic field data in its vicinity, and the second sensor can acquire second magnetic field data in its vicinity.
[0024] In some embodiments which can include the above-mentioned embodiments, the electronic device further includes a flexible display panel, which covers the first middle frame and the second middle frame. Through the above-mentioned arrangement, the processor can control the flexible display panel to display an electronic compass according to the geomagnetic field data, so that the user can learn the orientation of the current position according to the electronic compass. BRIEF DESCRIPTION OF DRAWINGS
[0025] Figure 1 Structure diagram of an electronic device provided by an embodiment of the present application Figure 1 ;
[0026] Figure 2 Structure diagram of an electronic device provided by an embodiment of the present application Figure 2 ;
[0027] Figure 3 Structure diagram of a first sensor, a second sensor, a processor, a first integrated circuit bus and a second integrated circuit bus in an electronic device provided by an embodiment of the present application;
[0028] Figure 4 Structure diagram of an electronic device provided by an embodiment of the present application Figure 3 ;
[0029] Figure 5 Step diagram of a method for determining geomagnetic field data of a position where an electronic device is located provided by an embodiment of the present application.
[0030] REFERENCE SIGNS:
[0031] 100: first sensor; 200: second sensor; 300: processor; 310: first integrated circuit bus; 320: second integrated circuit bus; 400: first middle frame; 410: first top edge; 420: first bottom edge; 430: first side edge; 440: second side edge; 450: first circuit board; 460: first battery; 500: second middle frame; 510: second top edge; 520: second bottom edge; 530: third side edge; 540: fourth side edge; 550: second circuit board; 551: first board body; 552: second board body; 560: second battery; 600: adsorbing magnet; 610: first magnet; 620: second magnet; 630: third magnet; 640: fourth magnet; 700: flexible circuit board. DETAILED DESCRIPTION
[0032] To make the purpose, technical solutions, and advantages of the embodiments of this application more clear, the technical solutions in the embodiments of this application will be clearly and completely described below in conjunction with the drawings in the embodiments of this application. Obviously, the described embodiments are part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0033] The embodiment of the present application provides an electronic device, which may include a foldable mobile phone, a foldable tablet computer, a laptop computer, etc. The embodiment of the present application will be introduced by taking the electronic device including a foldable mobile phone as an example. It is understandable that the electronic device in the embodiment of the present application is not limited to a foldable mobile phone. Please refer to Figure 1 The electronic device of an embodiment of the present application includes a first middle frame 400, which includes a first top edge 410 and a first bottom edge 420 arranged opposite to each other, and includes a first side edge 430 and a second side edge 440 arranged opposite to each other. The two ends of the first top edge 410 are respectively connected to the first side edge 430 and the second side edge 440, and the two ends of the first bottom edge 420 are respectively connected to the first side edge 430 and the second side edge 440. In some embodiments, the first top edge 410, the first bottom edge 420, the first side edge 430 and the second side edge 440 form a rectangular frame. The length of the first top edge is greater than the length of the first side edge.
[0034] In some implementations, the first middle frame 400 also includes a first middle plate, which is located in a rectangular area surrounded by the first top edge 410, the first bottom edge 420, the first side edge 430, and the second side edge 440. The first middle plate can be connected to at least one of the first top edge 410, the first bottom edge 420, and the first side edge 430.
[0035] Please refer to Figure 1 The electronic device of the embodiment of the present application further includes a second middle frame 500, which includes a second top edge 510 and a second bottom edge 520 arranged opposite to each other, and includes a third side edge 530 and a fourth side edge 540 arranged opposite to each other. The two ends of the second top edge 510 are respectively connected to the third side edge 530 and the fourth side edge 540, and the two ends of the second bottom edge 520 are respectively connected to the third side edge 530 and the fourth side edge 540. In some embodiments, the second top edge 510, the second bottom edge 520, the third side edge 530 and the fourth side edge 540 form a rectangular frame. The size of the second middle frame 500 can be the same as that of the first middle frame 400. Among them, the length of the second top edge 510 is greater than the length of the third side edge 530.
[0036] In some implementations, the second middle frame 500 further includes a second middle plate, which is located in a rectangular region surrounded by the second top edge 510, the second bottom edge 520, the third side edge 530, and the fourth side edge 540, and can be connected to at least one of the second top edge 510, the second bottom edge 520, the third side edge 530, and the fourth side edge 540.
[0037] In the embodiments of the present application, the second middle frame 500 is foldably connected to the first middle frame 400. For example, the second middle frame 500 can be connected to the first middle frame 400 through a hinge to allow the second middle frame 500 to be folded or unfolded relative to the first middle frame 400. The embodiments of the present application do not limit the structure of the hinge as long as it can allow the second middle frame 500 to be folded or unfolded relative to the first middle frame 400.
[0038] Please refer to Figure 2 In some implementations, the first top edge 410 and the second bottom edge 520 are close to each other, and the hinge can be arranged between the first top edge 410 and the second bottom edge 520. When the first middle frame 400 is unfolded relative to the second middle frame 500, the first middle frame 400 and the second middle frame 500 are arranged in sequence in a direction perpendicular to the first top edge 410. When the first middle frame 400 and the second middle frame 500 are folded together, the second top edge 510 is close to the first bottom edge 420. In some implementations, the hinge can be connected to the first top edge 410 and the second bottom edge 520, or the hinge can be connected to the first middle plate and the second middle plate.
[0039] Please refer to Figure 1 In other implementations, the first side edge 430 and the fourth side edge 540 are close to each other, and the hinge can be arranged between the first side edge 430 and the fourth side edge 540. One end of the first top edge 410 is close to one end of the second top edge 510, and one end of the first bottom edge 420 is close to one end of the second bottom edge 520. When the second middle frame 500 is unfolded, the first middle frame 400 and the second middle frame 500 are arranged in sequence in an extension direction of the first top edge 410. When the first middle frame 400 and the second middle frame 500 are folded together, the first top edge 410 is close to the second top edge 510, and the first bottom edge 420 is close to the second bottom edge 520. In some implementations, the hinge can be connected to the first side edge 430 and the fourth side edge 540, or the hinge can be connected to the first middle plate and the second middle plate.
[0040] Please refer to Figure 1 In some embodiments, when the first middle frame 400 and the second middle frame 500 are folded together, the projection of the second middle frame 500 on the first middle frame 400 can coincide with the first middle frame 400, or when the first middle frame 400 and the second middle frame 500 are folded together, the projection of the second middle frame 500 on the first middle frame 400 can coincide with part of the first middle frame 400.
[0041] Please refer to Figure 1 The electronic device of the embodiment of the present application further comprises an adsorption magnet 600, which is used to attract the first middle frame 400 and the second middle frame 500 by magnetic force when the first middle frame 400 and the second middle frame 500 are folded together, so that the electronic device remains in the folded state. In some implementations, the adsorption magnet 600 comprises a first magnet 610, a second magnet 620, a third magnet 630 and a fourth magnet 640. Among them, the first magnet 610 and the second magnet 620 are arranged on the first middle frame 400, and the third magnet 630 and the fourth magnet 640 are arranged on the second middle frame 500. The first magnet 610 and the third magnet 630 are oppositely arranged, and the second magnet 620 and the fourth magnet 640 are oppositely arranged. When the first middle frame 400 and the second middle frame 500 are folded together, the first magnet 610 is close to the third magnet 630, the magnetism of the first magnet 610 is opposite to that of the third magnet 630, so that the first magnet 610 and the third magnet 630 attract each other; the second magnet 620 is close to the fourth magnet 640, the magnetism of the second magnet 620 is opposite to that of the fourth magnet 640, so that the second magnet 620 and the fourth magnet 640 attract each other, and under the action of the magnetic force, the first middle frame 400 and the second middle frame 500 remain in the folded state. In an alternative embodiment, the first magnet 610 is arranged close to the junction of the first top edge 410 and the second side edge 440, the second magnet 620 is arranged close to the junction of the first bottom edge 420 and the second side edge 440, the third magnet 630 is arranged close to the junction of the second top edge 510 and the third side edge 530, and the fourth magnet 640 is arranged close to the junction of the second bottom edge 520 and the third side edge 530.
[0042] Please refer to Figure 1 The electronic device of the embodiment of the present application further comprises a first battery 460, which is arranged on the first middle frame 400. The first battery 460 can be arranged close to the first bottom edge 420. In an alternative embodiment, the electronic device further comprises a second battery 560, which is arranged on the second middle frame 500. The second battery 560 can be arranged close to the junction of the second top edge 510 and the third side edge 530.
[0043] The electronic device of the embodiment of the present application further comprises a flexible display panel, which covers the first middle frame 400 and the second middle frame 500. When the first middle frame 400 and the second middle frame 500 are folded together, the flexible display panel is bent; when the first middle frame 400 is unfolded relative to the second middle frame 500, the flexible display panel is unfolded.
[0044] Please refer to Figure 1The electronic device provided in the embodiments of the present application further comprises a first sensor 100, which is arranged on the first middle frame 400 or the second middle frame 500, and is configured to acquire first magnetic field data in the vicinity of the first sensor 100. The first magnetic field data comprises geomagnetic field data of a position where the electronic device is located.
[0045] It should be understood that the magnetic field in the vicinity of the first sensor 100 and the second sensor 200 comprises a geomagnetic field and an interference magnetic field. The interference magnetic field can comprise a first interference magnetic field and a second interference magnetic field. The first interference magnetic field comprises a magnetic field formed by the adsorbing magnet 600 and the like. The second interference magnetic field comprises a magnetic field formed by an electric current generated by the electronic device such as a loudspeaker and a display panel when the electronic device is working. The geomagnetic field data comprises a direction and a strength of the geomagnetic field. Figure 1
[0046] It should be understood that the magnetic field in the vicinity of the first sensor 100 and the second sensor 200 comprises a geomagnetic field and an interference magnetic field. The interference magnetic field can comprise a first interference magnetic field and a second interference magnetic field. The first interference magnetic field comprises a magnetic field formed by the adsorbing magnet 600 and the like. The second interference magnetic field comprises a magnetic field formed by an electric current generated by the electronic device such as a loudspeaker and a display panel when the electronic device is working. The geomagnetic field data comprises a direction and a strength of the geomagnetic field.
[0047] In an optional embodiment, the first sensor 100 and the second sensor 200 can each comprise any one of a magnetometer, a Hall effect sensor and a giant magnetoresistance magnetic field sensor.
[0048] It should be understood that the magnetic field in the vicinity of the first sensor 100 and the second sensor 200 comprises a geomagnetic field and an interference magnetic field. The interference magnetic field can comprise a first interference magnetic field and a second interference magnetic field. The first interference magnetic field comprises a magnetic field formed by the adsorbing magnet 600 and the like. The second interference magnetic field comprises a magnetic field formed by an electric current generated by the electronic device such as a loudspeaker and a display panel when the electronic device is working. The geomagnetic field data comprises a direction and a strength of the geomagnetic field. Figure 1 The electronic device provided in the embodiments of the present application further comprises a processor 300, which is arranged on the first middle frame 400 or the second middle frame 500, and is connected to the first sensor 100 and the second sensor 200, so as to acquire the first magnetic field data and the second magnetic field data. The processor 300 is configured to determine the geomagnetic field data of the position where the electronic device is located according to the first magnetic field data and the second magnetic field data. The processor 300 can control the flexible display panel to display an electronic compass according to the geomagnetic field data, so that a user can know the direction of the current position according to the electronic compass.
[0049] The electronic device provided in the embodiments of the present application further comprises a processor 300, which is arranged on the first middle frame 400 or the second middle frame 500, and is connected to the first sensor 100 and the second sensor 200, so as to acquire the first magnetic field data and the second magnetic field data. The processor 300 is configured to determine the geomagnetic field data of the position where the electronic device is located according to the first magnetic field data and the second magnetic field data. The processor 300 can control the flexible display panel to display an electronic compass according to the geomagnetic field data, so that a user can know the direction of the current position according to the electronic compass.
[0050] In an optional embodiment, the processor 300 can include any one of an application processor 300 (AP) and a system on chip (SoC).
[0051] In an optional embodiment, the processor 300 is connected with the first sensor 100 through a first serial peripheral interface (SCI), and the processor 300 is connected with the second sensor 200 through a second serial peripheral interface.
[0052] Please refer to Figure 3 and Figure 4 In the embodiments of the present application, the processor 300 is connected with the first sensor 100 through a first inter-integrated circuit (I2C) bus 310, and the processor 300 is connected with the second sensor 200 through a second inter-integrated circuit bus 320. Through the above setting, the processor 300 is connected with the first sensor 100 and the second sensor 200 respectively, so as to be able to simultaneously acquire the first magnetic field data and the second magnetic field data.
[0053] In an optional embodiment, the first sensor 100 and the second sensor 200 are simultaneously located in the first middle frame 400 or the second middle frame 500, and the first sensor 100 and the second sensor 200 are arranged at intervals. The interference magnetic field near the first sensor 100 and the second sensor 200 is different, so as to reduce the influence of the interference magnetic field on the geomagnetic field data.
[0054] Please refer to Figure 1 In another optional embodiment, the first sensor 100 and the second sensor 200 are respectively located in the first middle frame 400 and the second middle frame 500. For example, the first sensor 100 is arranged in the first middle frame 400, and the second sensor 200 is arranged in the second middle frame 500; or, the first sensor 100 is arranged in the second middle frame 500, and the second sensor 200 is arranged in the first middle frame 400.
[0055] In an optional embodiment, in the state that the electronic device in the embodiments of the present application is powered on, the processor 300 is further configured to determine whether the first middle frame 400 is folded or unfolded relative to the second middle frame 500. When the first middle frame 400 and the second middle frame 500 are folded together, the processor 300 determines one of the first magnetic field data and the second magnetic field data as the geomagnetic field data; when the first middle frame 400 is unfolded relative to the second middle frame 500, the processor 300 determines the other of the first magnetic field data and the second magnetic field data as the geomagnetic field data.
[0056] It can be understood that the first middle frame 400 and the second middle frame 500 are foldable connected, and the relative positions between the adsorbing magnets 600 and other devices change in the process of folding or unfolding of the first middle frame 400 relative to the second middle frame 500, resulting in that the first interference magnetic field formed by the adsorbing magnets 600 and other devices also changes. That is, the magnetic field data of the first interference magnetic field is different in the folded state of the electronic device and in the unfolded state of the electronic device. That is, the interference degree of the first interference magnetic field on the first sensor 100 is different in the folded state of the electronic device and in the unfolded state of the electronic device; the interference degree of the first interference magnetic field on the second sensor 200 is different in the folded state of the electronic device and in the unfolded state of the electronic device.
[0057] In the folded state of the electronic device, the interference degrees of the first interference magnetic field on the first sensor 100 and the second sensor 200 are different, and the interference degree of the first interference magnetic field on one of the first sensor 100 and the second sensor 200 is smaller. At this time, the processor 300 takes the magnetic field data collected by the sensor with smaller interference degree of the first interference magnetic field as the geomagnetic field data, so as to reduce the influence of the first interference magnetic field and further reduce the error of the measurement result. Similarly, in the unfolded state of the electronic device, the interference degrees of the first interference magnetic field on the first sensor 100 and the second sensor 200 are also different, and the interference degree of the first interference magnetic field on the other of the first sensor 100 and the second sensor 200 is smaller. At this time, the processor 300 takes the magnetic field data collected by the sensor with smaller interference degree of the first interference magnetic field as the geomagnetic field data, so as to reduce the influence of the interference magnetic field and further reduce the error of the measurement result.
[0058] In some implementations, the magnetic field data of the first interference magnetic field formed by the adsorbing magnets 600 and other devices is relatively stable (for example, the first interference magnetic field strength at different positions in the electronic device is stable), and accordingly, the first sensor 100 and the second sensor 200 can be arranged at positions with smaller first interference magnetic field strength in the electronic device, such as positions away from the adsorbing magnets 600 and other devices.
[0059] For example, in some implementations, when the first middle frame 400 and the second middle frame 500 are folded together, the interference degree of the first interference magnetic field on the second sensor 200 is smaller, and the processor 300 determines the second magnetic field data as the geomagnetic field data; when the first middle frame 400 is unfolded relative to the second middle frame 500, the interference degree of the first interference magnetic field on the first sensor 100 is smaller, and the processor 300 determines the first magnetic field data as the geomagnetic field data.
[0060] In other implementations, when the first middle frame 400 and the second middle frame 500 are folded together, the first sensor 100 is less disturbed by the first interfering magnetic field, and the processor 300 determines the first magnetic field data as the geomagnetic field data; when the first middle frame 400 is unfolded relative to the second middle frame 500, the second sensor 200 is less disturbed by the first interfering magnetic field, and the processor 300 determines the second magnetic field data as the geomagnetic field data.
[0061] In an optional embodiment, when the first middle frame 400 and the second middle frame 500 are folded together, the projection of the first sensor 100 on the first middle frame 400 partially overlaps the projection of the second sensor 200 on the first middle frame 400.
[0062] For more details, please refer to Figure 1 In other embodiments, when the first middle frame 400 and the second middle frame 500 are folded together, the projection of the first sensor 100 on the first middle frame 400 is spaced apart from the projection of the second sensor 200 on the first middle frame 400. Through the above arrangement, when the first middle frame 400 and the second middle frame 500 are folded together, the first sensor 100 and the second sensor 200 are located at different positions in the first interfering magnetic field, and one of the first sensor 100 and the second sensor 200 is less disturbed by the first interfering magnetic field.
[0063] For more details, please refer to Figure 1 The electronic device of the embodiments of the present application further includes a first circuit board 450, which is arranged on the first middle frame 400. In some embodiments, the first circuit board 450 is arranged close to the first top edge 410. In the implementation where the first battery 460 is arranged close to the first bottom edge 420, the first circuit board 450 and the first battery 460 are arranged in sequence along a direction perpendicular to the first top edge 410. The first sensor 100 is arranged on the first circuit board 450, and the first sensor 100 can be arranged close to the first top edge 410. In an optional embodiment, the electronic device of the embodiments of the present application further includes a charging port, which is arranged on the first middle frame 400 and arranged close to the first bottom edge 420. The charging port is used to connect an external charging device to charge the first battery 460 and the second battery 560. The first sensor 100 is arranged close to the first top edge 410 and can be away from the charging port and other devices on the first middle frame 400. It can be understood that, during the charging process of the electronic device, the magnetic field generated by the charging current can interfere with the first sensor 100, resulting in errors in the measurement results. The first sensor 100 is arranged away from the charging port, which can reduce the measurement errors.
[0064] For more details, please refer to Figure 1In an alternative embodiment, the first sensor 100 is arranged close to one end of the first top edge 410. In some implementations, the first sensor 100 is arranged close to the junction of the first top edge 410 and the first side edge 430. Alternatively, the first sensor 100 is arranged close to the junction of the first top edge 410 and the second side edge 440.
[0065] For example, the electronic device can include a first sensor 100 arranged on the first circuit board 450. The first sensor 100 can be arranged close to the first top edge 410 of the first middle frame 400. In some implementations, the first sensor 100 is arranged close to the junction of the first top edge 410 and the first side edge 430. Alternatively, the first sensor 100 is arranged close to the junction of the first top edge 410 and the second side edge 440. Figure 1 In some embodiments, the electronic device can further include a second circuit board 550 arranged on the second middle frame 500. In some implementations, the second circuit board 550 can be arranged close to the junction of the second bottom edge 520 and the fourth side edge 540. The second circuit board 550 can include a first board body 551 arranged close to the fourth side edge 540 and a second board body 552 arranged close to the second bottom edge 520. The first board body 551 can be arranged perpendicular to the second bottom edge 520, and the second board body 552 can be arranged parallel to the second bottom edge 520. The first board body 551 and the second board body 552 can be connected to each other, and the junction of the first board body 551 and the second board body 552 can be arranged close to the junction of the second bottom edge 520 and the fourth bottom edge. In some implementations, the first board body 551 and the second battery 560 can be arranged along the extension direction of the second bottom edge 520, and the second board body 552 and the second battery 560 can be arranged along a direction perpendicular to the second bottom edge 520.
[0066] In some embodiments, the electronic device can further include a second sensor 200 arranged on the second circuit board 550. In some implementations, the second sensor 200 can be arranged on the first board body 551, or the second sensor 200 can be arranged on the second board body 552. The second sensor 200 can be arranged close to the second bottom edge 520. In an alternative embodiment, the second sensor 200 can be arranged close to one end of the second bottom edge 520. In some implementations, the second sensor 200 can be arranged close to the junction of the second bottom edge 520 and the third side edge 530, or the second sensor 200 can be arranged close to the junction of the second bottom edge 520 and the fourth side edge 540.
[0067] In an alternative embodiment, the electronic device can further include a flexible circuit board 700 arranged at the junction of the first middle frame 400 and the second middle frame 500. The flexible circuit board 700 can be used to connect the first circuit board 450 and the second circuit board 550.
[0068] For example, the electronic device can include a first sensor 100 arranged on the first circuit board 450. The first sensor 100 can be arranged close to the first top edge 410 of the first middle frame 400. In some implementations, the first sensor 100 is arranged close to the junction of the first top edge 410 and the first side edge 430. Alternatively, the first sensor 100 is arranged close to the junction of the first top edge 410 and the second side edge 440. Figure 1The electronic device of the embodiments of the present application further includes an electronic device, which is arranged on at least one of the first middle frame 400 and the second middle frame 500. In some implementations, the electronic device can include at least one of an antenna, a camera module, and a speaker. It can be understood that a second interference magnetic field formed by the current generated in the working process of the electronic device can interfere with the first sensor 100 or the second sensor 200, resulting in a larger error in the measurement result.
[0069] In the above implementation, the camera module is arranged on the first middle frame 400, and the camera module can be arranged close to the first top edge 410. In some implementations, the camera module is arranged close to the junction of the first top edge 410 and the first side edge 430. The first sensor 100 can be arranged close to the junction of the first top edge 410 and the second side edge 440 to be away from the camera module, thereby reducing the interference of the camera module on the first sensor 100 in the working process and reducing the error in the measurement result. Alternatively, the camera module is arranged close to the junction of the first top edge 410 and the second side edge 440. The first sensor 100 can be arranged close to the junction of the first top edge 410 and the first side edge 430 to be away from the camera module and reduce the error in the measurement result.
[0070] In the above implementation, the speaker is arranged on the second middle frame 500, and the speaker can be arranged close to the second top edge 510. The second sensor 200 can be arranged close to the second bottom edge 520 to be away from the speaker, thereby reducing the interference of the speaker on the second sensor 200 in the working process and reducing the error in the measurement result.
[0071] In the embodiments of the present application, the processor 300 is connected with the electronic device, and the processor 300 is configured to determine whether the electronic device is in a working state, so as to determine whether the first sensor 100 and the second sensor 200 are interfered by a second interference magnetic field formed by the current generated in the working process of the electronic device. When the processor 300 determines that the electronic device is not working, the first sensor 100 and the second sensor 200 are not interfered by the second interference magnetic field, and the processor 300 selects the magnetic field data measured by the first sensor 100 and the second sensor 200 which is less interfered by a first interference magnetic field formed by the attracting magnet 600 and other devices as the geomagnetic field data.
[0072] In an alternative embodiment, when the first middle frame 400 and the second middle frame 500 are folded together, and the processor 300 determines that the electronic device is not working, the processor 300 determines the second magnetic field data as the geomagnetic field data; when the first middle frame 400 is unfolded relative to the second middle frame 500, and the processor 300 determines that the electronic device is not working, the processor 300 determines the first magnetic field data as the geomagnetic field data.
[0073] In an alternative embodiment, when the first middle frame 400 and the second middle frame 500 are folded together, and the processor 300 judges that the electronic device is not working, the first sensor 100 is less disturbed by the first interference magnetic field, and the first sensor 100 is not disturbed by the second interference magnetic field, and the processor 300 determines the first magnetic field data as the geomagnetic field data; when the first middle frame 400 is unfolded relative to the second middle frame 500, and the processor 300 judges that the electronic device is not working, the second sensor 200 is less disturbed by the first interference magnetic field, and the second sensor 200 is not disturbed by the second interference magnetic field, and the processor 300 determines the second magnetic field data as the geomagnetic field data. Through the above setting, the error of the measurement result is reduced.
[0074] In some embodiments, when the processor 300 judges that the electronic device is in a working state, the first sensor 100 and the second sensor 200 are both disturbed by the second interference magnetic field, and the processor 300 determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data.
[0075] For example, when the first middle frame 400 and the second middle frame 500 are folded together, and the processor 300 judges that the electronic device is working, the first sensor 100 is less disturbed by the first interference magnetic field, and the first sensor 100 and the second sensor 200 are both disturbed by the second interference magnetic field, the processor 300 performs data fitting based on the first magnetic field data, and the processor 300 determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data to reduce the error of the measurement result; when the first middle frame 400 is unfolded relative to the second middle frame 500, and the processor 300 judges that the electronic device is working, the second sensor 200 is less disturbed by the first interference magnetic field, and the first sensor 100 and the second sensor 200 are both disturbed by the second interference magnetic field, the processor 300 performs data fitting based on the second magnetic field data, and the processor 300 determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data to reduce the error of the measurement result.
[0076] In an alternative embodiment, the first magnetic field data includes a first magnetic field strength along the X-axis direction, a second magnetic field strength along the Y-axis direction, and a third magnetic field strength along the Z-axis direction. It can be understood that the first magnetic field data is a vector, the first magnetic field strength is a component of the first magnetic field data along the X-axis direction, the second magnetic field strength is a component of the first magnetic field data along the Y-axis direction, and the third magnetic field strength is a component of the first magnetic field data along the Z-axis direction. The vector sum of the first magnetic field strength, the second magnetic field strength, and the third magnetic field strength is the first magnetic field data.
[0077] In an optional embodiment, the second magnetic field data comprises a fourth magnetic field strength along the X-axis direction, a fifth magnetic field strength along the Y-axis direction, and a sixth magnetic field strength along the Z-axis direction. The second magnetic field data is a vector, the fourth magnetic field strength is a component of the second magnetic field data along the X-axis direction, the fifth magnetic field strength is a component of the second magnetic field data along the Y-axis direction, and the sixth magnetic field strength is a component of the second magnetic field data along the Z-axis direction. The vector sum of the fourth magnetic field strength, the fifth magnetic field strength, and the sixth magnetic field strength is the second magnetic field data.
[0078] In an optional embodiment, the geomagnetic field data comprises a seventh magnetic field strength along the X-axis direction, an eighth magnetic field strength along the Y-axis direction, and a ninth magnetic field strength along the Z-axis direction. The geomagnetic field data is a vector, the seventh magnetic field strength is a component of the geomagnetic field data along the X-axis direction, the eighth magnetic field strength is a component of the geomagnetic field data along the Y-axis direction, and the ninth magnetic field strength is a component of the geomagnetic field data along the Z-axis direction. The vector sum of the seventh magnetic field strength, the eighth magnetic field strength, and the ninth magnetic field strength is the geomagnetic field data.
[0079] In the above embodiments, the X-axis direction is perpendicular to the Y-axis direction, and the Z-axis direction is perpendicular to both the X-axis direction and the Y-axis direction. For example, the X-axis direction is parallel to the first middle frame 400, the Y-axis direction is parallel to the first middle frame 400, and the Y-axis direction is perpendicular to the X-axis direction, or the Z-axis direction is perpendicular to the first middle frame 400, the Z-axis direction is parallel to the first middle frame 400, and the Z-axis direction is perpendicular to the Y-axis direction.
[0080] In the embodiments of the present application, the processor 300 determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data can comprise: taking the smaller one of the first magnetic field strength and the fourth magnetic field strength as the seventh magnetic field strength. It can be understood that, compared with the magnetic field (the second interference magnetic field) formed by the current generated when the electronic device works, the component of the geomagnetic field along the X-axis direction is smaller. If the first sensor 100 and the second sensor 200 are disturbed by the second interference magnetic field, the first magnetic field data and the second magnetic field data will be obviously larger than the component of the actual geomagnetic field data along the X-axis direction at the position of the electronic device. Through the above setting, the one of the first magnetic field strength and the fourth magnetic field strength which is less disturbed by the second interference magnetic field can be taken as the seventh magnetic field strength, so as to reduce the error of the measurement result.
[0081] In an optional embodiment, the processor 300 can further determine the geomagnetic field data according to the first magnetic field data and the second magnetic field data by taking the smaller one of the second magnetic field strength and the fifth magnetic field strength as an eighth magnetic field strength. Compared with the second interference magnetic field, the geomagnetic field has a smaller component along the Y-axis direction. If the first sensor 100 and the second sensor 200 are interfered by the second interference magnetic field, the second magnetic field strength and the fifth magnetic field strength will be obviously larger than the component of the actual geomagnetic field data along the Y-axis direction at the position of the electronic device. By the above setting, the smaller one of the second magnetic field strength and the fifth magnetic field strength, which is less interfered by the second interference magnetic field, can be taken as the eighth magnetic field strength, so as to reduce the error of the measurement result.
[0082] In an optional embodiment, the processor 300 can further determine the geomagnetic field data according to the first magnetic field data and the second magnetic field data by taking the smaller one of the third magnetic field strength and the sixth magnetic field strength as a ninth magnetic field strength. Compared with the second interference magnetic field, the geomagnetic field has a smaller component along the Z-axis direction. If the first sensor 100 and the second sensor 200 are interfered by the second interference magnetic field, the third magnetic field strength and the sixth magnetic field strength will be obviously larger than the component of the actual geomagnetic field data along the Z-axis direction at the position of the electronic device. By the above setting, the smaller one of the third magnetic field strength and the sixth magnetic field strength, which is less interfered by the second interference magnetic field, can be taken as the ninth magnetic field strength, so as to reduce the error of the measurement result.
[0083] In the above embodiment, the processor 300 takes the smaller one of the first magnetic field strength and the fourth magnetic field strength as the seventh magnetic field strength, the smaller one of the second magnetic field strength and the fifth magnetic field strength as the eighth magnetic field strength, and the smaller one of the third magnetic field strength and the sixth magnetic field strength as the ninth magnetic field strength, so as to effectively reduce the influence of the second interference magnetic field on the geomagnetic field data, and further reduce the error of the measurement result of the electronic compass.
[0084] It can be understood that the first magnetic field data is A, the first magnetic field intensity is Xa, the second magnetic field intensity is Ya, and the third magnetic field intensity is Za. Then the first magnetic field data includes the first magnetic field intensity along the X-axis direction, the second magnetic field intensity along the Y-axis direction, and the third magnetic field intensity along the Z-axis direction, which can be represented as A=(Xa,Ya,Za). The second magnetic field data is B, the first magnetic field intensity is Xb, the second magnetic field intensity is Yb, and the third magnetic field intensity is Zb. Then the second magnetic field data includes the fourth magnetic field intensity along the X-axis direction, the fifth magnetic field intensity along the Y-axis direction, and the sixth magnetic field intensity along the Z-axis direction, which can be represented as B=(Xb,Yb,Zb). The geomagnetic field data is C, the seventh magnetic field intensity is Xc, the eighth magnetic field intensity is Yc, and the ninth magnetic field intensity is Zc. Then the geomagnetic field data includes the seventh magnetic field intensity along the X-axis direction, the eighth magnetic field intensity along the Y-axis direction, and the ninth magnetic field intensity along the Z-axis direction, which can be represented as: C=(Xc,Yc,Zc).
[0085] In some implementations, "when the first middle frame 400 and the second middle frame 500 are folded together, the processor 300 determines one of the first magnetic field data and the second magnetic field data as the geomagnetic field data; when the first middle frame 400 is unfolded relative to the second middle frame 500, the processor 300 determines the other of the first magnetic field data and the second magnetic field data as the geomagnetic field data" can include:
[0086] C=(Xa,Ya,Za)&(Xb,Yb,Zb)=(Xa,Ya,Za), wherein XaXb, YaYb, and ZaZb;
[0087] C=(Xa,Ya,Za)&(Xb,Yb,Zb)=(Xb,Yb,Zb), wherein XbXa, YbYa, and ZbZa.
[0088] In some implementations, "the processor 300 determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data" can include:
[0089] C=(Xa,Ya,Za)&(Xb,Yb,Zb)=(Xa,Yb,Zb), wherein XaXb, YbYa, and ZbZa;
[0090] C=(Xa,Ya,Za)&(Xb,Yb,Zb)=(Xa,Ya,Zb), wherein XaXb, YaYb, and ZbZa;
[0091] C=(Xa,Ya,Za)&(Xb,Yb,Zb)=(Xb,Ya,Za), wherein XbXa, YaYb, and ZaZb;
[0092] C=(Xa, Ya, Za) & (Xb, Yb, Zb) = (Xa, Yb, Za), wherein Xa < Xb, Yb < Ya, Za < Zb;
[0093] C=(Xa, Ya, Za) & (Xb, Yb, Zb) = (Xb, Yb, Za), wherein Xb < Xa, Yb < Ya, Za < Zb;
[0094] C=(Xa, Ya, Za) & (Xb, Yb, Zb) = (Xb, Ya, Zb), wherein Xb < Xa, Ya < Yb, Zb < Za.
[0095] Please refer to Figure 5 The embodiment of the application further provides a method for determining geomagnetic field data of a position where an electronic device is located, which comprises:
[0096] S100, a processor judges whether a first middle frame is folded or unfolded relative to a second middle frame.
[0097] S110, when the first middle frame and the second middle frame are folded together, the processor determines first magnetic field data as the geomagnetic field data.
[0098] S120, when the first middle frame is unfolded relative to the second middle frame, the processor determines second magnetic field data as the geomagnetic field data.
[0099] In an alternative embodiment, the method for determining geomagnetic field data of a position where an electronic device is located can further comprise:
[0100] S210, a processor judges whether an electronic device is in a working state.
[0101] S211, when the electronic device is not in the working state, the processor determines the first magnetic field data as the geomagnetic field data.
[0102] S212, when the electronic device is in the working state, the processor determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data.
[0103] In an alternative embodiment, the method for determining geomagnetic field data of a position where an electronic device is located can further comprise:
[0104] S220, a processor judges whether an electronic device is in a working state.
[0105] S221, when the electronic device is not in the working state, the processor determines the second magnetic field data as the geomagnetic field data.
[0106] S222, when the electronic device is in the working state, the processor determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data.
[0107] It should be noted that in the description of the embodiments of the present application, unless otherwise clearly specified and limited, the terms "connected", "connected" should be understood in a broad sense, for example, it can be fixedly connected, or integrally connected; it can also be mechanically connected, or electrically connected; it can be directly connected, or indirectly connected through an intermediate medium, or the communication inside two components. For those skilled in the art, the specific meaning of the above terms in the embodiments of the present application can be understood according to the specific circumstances.
[0108] Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present application, but not to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that: it can still modify the technical solutions recorded in the foregoing embodiments, or make equivalent replacement for part or all of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the embodiments of the present application.
Claims
1. An electronic device, comprising: The application relates to an electronic device, comprising: a first middle frame; a second middle frame foldably connected with the first middle frame; a first sensor for acquiring first magnetic field data, the first sensor being arranged on the first middle frame or the second middle frame; a second sensor for acquiring second magnetic field data, the second sensor being arranged on the first middle frame or the second middle frame; a processor for determining geomagnetic field data of a position where the electronic device is located according to the first magnetic field data and the second magnetic field data.
2. The electronic device of claim 1, wherein, The first sensor is arranged on the first middle frame, and the second sensor is arranged on the second middle frame. When the first middle frame and the second middle frame are folded together, the processor determines the first magnetic field data as the geomagnetic field data. When the first middle frame is unfolded relative to the second middle frame, the processor determines the second magnetic field data as the geomagnetic field data.
3. The electronic device of claim 2, wherein, When the first middle frame and the second middle frame are folded together, the projection of the first sensor on the first middle frame is spaced apart from the projection of the second sensor on the first middle frame.
4. The electronic device of claim 3, wherein, The electronic device further comprises a first circuit board, the first sensor is arranged on the first circuit board, and the first circuit board is arranged on the first middle frame. The first middle frame comprises oppositely arranged first top and bottom edges, the first circuit board is arranged close to the first top edge, and the first sensor is arranged close to the first top edge.
5. The electronic device of claim 3 or 4, wherein, The electronic device further comprises a second circuit board, the second sensor is arranged on the second circuit board, and the second circuit board is arranged on the second middle frame. The second middle frame comprises oppositely arranged second top and bottom edges, the second circuit board is arranged close to the second bottom edge, and the second sensor is arranged close to the second bottom edge.
6. The electronic device of any one of claims 2 to 5, wherein, The electronic device further comprises an electronic device arranged on the first middle frame and / or the second middle frame, and the processor is connected with the electronic device. When the first middle frame and the second middle frame are folded together, and the electronic device is not working, the processor determines the first magnetic field data as the geomagnetic field data. When the first middle frame is unfolded relative to the second middle frame, and the electronic device is not working, the processor determines the second magnetic field data as the geomagnetic field data.
7. The electronic device of claim 6, wherein, When the first middle frame and the second middle frame are folded together, and the electronic device is working, the processor determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data. When the first middle frame is unfolded relative to the second middle frame, and the electronic device is working, the processor determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data.
8. The electronic device of claim 7, wherein, The first magnetic field data comprises a first magnetic field intensity along an X-axis direction, a second magnetic field intensity along a Y-axis direction, and a third magnetic field intensity along a Z-axis direction. The second magnetic field data comprises a fourth magnetic field intensity along the X-axis direction, a fifth magnetic field intensity along the Y-axis direction, and a sixth magnetic field intensity along the Z-axis direction. The geomagnetic field data comprises a seventh magnetic field intensity along the X-axis direction, an eighth magnetic field intensity along the Y-axis direction, and a ninth magnetic field intensity along the Z-axis direction. The X-axis direction is perpendicular to the Y-axis direction, and the Z-axis direction is perpendicular to both the X-axis direction and the Y-axis direction. The processor determines the geomagnetic field data according to the first magnetic field data and the second magnetic field data by taking the smaller one of the first magnetic field intensity and the fourth magnetic field intensity as the seventh magnetic field intensity, taking the smaller one of the second magnetic field intensity and the fifth magnetic field intensity as the eighth magnetic field intensity, and taking the smaller one of the third magnetic field intensity and the sixth magnetic field intensity as the ninth magnetic field intensity.
9. The electronic device of any of claims 6-8, wherein, The electronic device comprises at least one of an antenna, a camera module, and a speaker.
10. The electronic device of any of claims 1 to 9, wherein, The processor is connected to the first sensor through a first integrated circuit bus, and is connected to the second sensor through a second integrated circuit bus.
11. The electronic device of any of claims 1 to 10, wherein, The first sensor and the second sensor each comprise a magnetometer.
12. The electronic device of any of claims 1 to 11, wherein, The electronic device further comprises a flexible display panel, which covers the first middle frame and the second middle frame.