Embodiment
The embodiment of the invention provides direction inductor method and the device on a kind of portable terminal.Utilize Hall element and slidably between the magnet away from close, make Hall element export high-low level, thereby inform the direction of the current placement of portable terminal according to the variation of magnetic flux.So just can realize the direction induction function of portable terminal, produce considerable economic effectively reducing under the situation of portable terminal complexity and design cost.
For better describing the embodiment of the invention, now the direction inductor method on the described portable terminal of the embodiment of the invention is specifically described, in specific implementation process of the present invention:
At first portable terminal is provided with Hall element, and the relevant position that Hall element is set is provided with slideway and magnet slidably.Here, Hall element can be arranged on a certain end or centre position of portable terminal, and after this Hall element sets, just can a slideway and magnet slidably be set on the respective end of Hall element being provided with, slidably magnet can be along with the variation of portable terminal placement direction back and forth slip in slideway for this.When described portable terminal changed placement direction, described slidably magnet slided in described slideway, and near or away from set Hall element.
The shape of above-mentioned slideway can be designed to straight way or crooked slideway, as long as guarantee in the process that slidably magnet slides, its can near or just can meet the demands away from Hall element.
And set Hall element also can be one or more on portable terminal, when being provided with a plurality of Hall element, slideway and magnet slidably can all be set in each position that Hall element is set, also a slideway can only be set, make the Hall element of this slideway through all settings, so slidably in the process that magnet slides in this slideway, can with each set Hall element near or away from.
Then, when portable terminal conversion placement direction, slidably magnet can slide in slideway, and near or away from set Hall element; This Hall element just can according to described slidably magnet near or away from, export the direction that corresponding level is informed the current placement of described portable terminal.
Specifically, when portable terminal conversion placement direction, Hall element according to described slidably magnet near or away from, variation has taken place in detected magnetic flux, and this moment just can be according to operating personnel's the direction that the corresponding level of output is informed the current placement of described portable terminal that preestablishes.
In the specific implementation process, Hall element can be according to this Hall element and the set relative position of slideway, and output high level or low level are informed the current direction of placing of described portable terminal.Wherein, Hall element according to magnet slidably near or away from, can export high level or low level.Can set when slidably magnet is near Hall element, this Hall element is according to detected magnetic flux change output low level; Accordingly, when slidably magnet was away from Hall element, this Hall element was according to detected magnetic flux change output high level.Can certainly set Hall element when slidably magnet is close, the output high level; Magnet slidably away from the time, output low level.
In the specific implementation process, a Hall element is set in portable terminal, and slideway of corresponding setting and slidably during magnet, according to this Hall element and the set relative position of this slideway, can export high level or low level and inform the direction of the current placement of described portable terminal, specifically:
If described slideway is horizontally disposed with respect to described Hall element, then described Hall element is close according to described slidably magnet, export corresponding level and represent that described portable terminal vertically places, specifically exporting high level still is that low level can be set in advance by operating personnel; Simultaneously, according to described slidably magnet away from, export corresponding level and represent described portable terminal horizontal positioned.Here, if set Hall element close according to magnet slidably, the output high level represents that portable terminal vertically places, then can set accordingly Hall element according to magnet slidably away from, output low level is represented the portable terminal horizontal positioned.
In addition, if described slideway vertically is provided with respect to described Hall element, then described Hall element is close according to described slidably magnet, output high level or low level are represented described portable terminal horizontal positioned, and according to described slidably magnet away from, output low level or high level represent that described portable terminal vertically places.
Above-mentioned mentioned portable terminal includes but not limited to mobile phone, equipment such as notebook computer or removable video player.
Give an example 1: with mobile phone commonly used is example, usually need in the specific implementation process to distinguish that mobile phone is horizontal screen or perpendicular screen, be illustrated in figure 1 as the structural representation of the instantiation that present embodiment lifts, among the figure: a certain end at circuit board of mobile phone is provided with a Hall element IC, the slideway of one bending is set in respective end, slideway is horizontally disposed with respect to mobile phone, and a slidably magnet is set, and it can be slided in the middle of slideway; Above-mentioned slideway also can be arranged to other shape.
Shown in Fig. 1 left side, when mobile phone is placed vertically, slidably magnet slides into the below of Hall element IC, near Hall element IC, this moment, Hall element IC can export corresponding level according to the variation of magnetic flux, in this example, can set the variation output low level of Hall element IC according to magnetic flux, for example can be arranged to output " 0 " expression low level, mobile phone receives just judges that current phone places vertically after this low level.
Shown in Fig. 1 right side, when the mobile phone traverse, slidably the magnet slideway is away from the place of Hall element IC, this moment, Hall element IC can export corresponding level according to the variation of magnetic flux, in this example, can set the variation output high level of Hall element IC, for example can be arranged to output " 1 " and represent just can judge that current phone is a traverse after high level, mobile phone receive this high level according to magnetic flux.
Above-mentioned Hall element IC and slideway also can be arranged on other ends of mobile phone, according to slideway the difference of direction are set, and Hall element is exported the represented direction of corresponding level also difference, but principle is the same with above-mentioned given example, just repeats no more herein.
Give an example 2: be example still with mobile phone commonly used, be illustrated in figure 2 as the structural representation of another instantiation that present embodiment lifts, among the figure: in circuit board of mobile phone, be provided with two Hall elements, be respectively Hall element 1 and Hall element 2, and these two Hall elements lay respectively at set slideway two ends; In slideway, be provided with slidably magnet, this slidably magnet can slidably reciprocate in the middle of the slideway.Slideway among the embodiment as shown in Figure 2 is horizontally disposed with respect to mobile phone.
Shown in Fig. 2 left side, when mobile phone is placed vertically, slidably magnet slides into the bottom of described slideway, away from two Hall elements, this moment, two Hall elements will all be exported corresponding level according to the variation of magnetic flux, in this example, can set two Hall elements and all export high level, for example can be arranged to all export " 1 " expression high level, when mobile phone receives two Hall elements when all exporting high level, just can judge that current phone places vertically.
Shown in Fig. 2 right side, when mobile phone left during traverse, slidably the magnet slideway is near Hall element 1, and away from Hall element 2, can set the variation output low level of Hall element 1 according to magnetic flux this moment, and Hall element 2 is according to the variation output high level of magnetic flux.When mobile phone receives Hall element 1 output low level, and during Hall element 2 output high level, just can judge that current phone is a traverse left according to predefined logic.
Same, when mobile phone to the right during traverse, slidably the magnet slideway is near Hall element 2, and away from Hall element 1, can set the variation output low level of Hall element 2 according to magnetic flux this moment, and Hall element 1 is according to the variation output high level of magnetic flux.When mobile phone receives Hall element 1 output high level, and during Hall element 2 output low levels, just can judge that current phone is a traverse to the right according to predefined logic.
It should be noted that, if be provided with a plurality of Hall elements in the portable terminal, then need be according to the situation of each Hall element output voltage, set the corresponding judgment logic, make described portable terminal accurately judge the direction that current mobile terminal is placed according to the situation of each Hall element output voltage.
By the enforcement of above technical scheme, just can realize the direction induction function of portable terminal, but also can effectively reduce the complexity and the design cost of portable terminal.
The embodiment of the invention also provides the device of the direction inductor on a kind of portable terminal, is illustrated in figure 3 as the structural representation of present embodiment institute generator, and described device comprises Hall element, slideway and magnet slidably, wherein:
Described Hall element is arranged on the described portable terminal; Described slideway is arranged on the relevant position that is provided with described Hall element.
Slidably magnet is arranged in described slideway, be used for when described portable terminal changes placement direction, in described slideway, sliding, and near or away from described Hall element.
Described Hall element be used for according to described slidably magnet near or away from, export the direction that corresponding level is informed the current placement of described portable terminal.Inform that specifically the mode of direction sees described in the above method embodiment.
In addition, described Hall element is arranged on a certain end or centre position of described portable terminal.Wherein, if described Hall element is one, then described Hall element can be arranged on the centre position of described slideway; If described Hall element is two, then described Hall element can be arranged at the end positions of described slideway respectively.
In addition, described slideway can be horizontally disposed with or vertically be provided with respect to described Hall element.If described slideway is horizontally disposed with respect to described Hall element, described Hall element is close according to described slidably magnet, output high level or low level represent that described portable terminal vertically places, and according to described slidably magnet away from, output low level or high level are represented described portable terminal horizontal positioned.
If described slideway vertically is provided with respect to described Hall element, described Hall element is close according to described slidably magnet, output high level or low level are represented described portable terminal horizontal positioned, and according to described slidably magnet away from, output low level or high level represent that described portable terminal vertically places.
Above-mentioned direction inductor device also can be arranged to independent functional entity and described portable terminal maintains the connection.
It should be noted that among the said apparatus embodiment that each included unit is just divided according to function logic, but is not limited to above-mentioned division, as long as can realize function corresponding; In addition, the concrete title of each functional unit also just for the ease of mutual differentiation, is not limited to protection scope of the present invention.
In addition, one of ordinary skill in the art will appreciate that all or part of step that realizes in the foregoing description method is to instruct relevant hardware to finish by program, corresponding program can be stored in a kind of computer-readable recording medium, the above-mentioned storage medium of mentioning can be a ROM (read-only memory), disk or CD etc.
In sum, the embodiment of the invention not only can realize the direction induction function of portable terminal, but also can effectively reduce the complexity and the design cost of portable terminal.
The above; only be the preferable embodiment of the present invention; but protection scope of the present invention is not limited thereto; anyly be familiar with those skilled in the art in the technical scope that the embodiment of the invention discloses; the variation that can expect easily or replacement all should be encompassed within protection scope of the present invention.Therefore, protection scope of the present invention should be as the criterion with the protection domain of claim.