[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN118783981A - Antenna switching method, device, terminal equipment and storage medium - Google Patents

Antenna switching method, device, terminal equipment and storage medium Download PDF

Info

Publication number
CN118783981A
CN118783981A CN202410922745.7A CN202410922745A CN118783981A CN 118783981 A CN118783981 A CN 118783981A CN 202410922745 A CN202410922745 A CN 202410922745A CN 118783981 A CN118783981 A CN 118783981A
Authority
CN
China
Prior art keywords
antenna
current
actual current
frequency band
switching
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202410922745.7A
Other languages
Chinese (zh)
Inventor
陈再成
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Realme Mobile Telecommunications Shenzhen Co Ltd
Original Assignee
Realme Mobile Telecommunications Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Realme Mobile Telecommunications Shenzhen Co Ltd filed Critical Realme Mobile Telecommunications Shenzhen Co Ltd
Priority to CN202410922745.7A priority Critical patent/CN118783981A/en
Publication of CN118783981A publication Critical patent/CN118783981A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B1/00Details of transmission systems, not covered by a single one of groups H04B3/00 - H04B13/00; Details of transmission systems not characterised by the medium used for transmission
    • H04B1/02Transmitters
    • H04B1/04Circuits
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B1/00Details of transmission systems, not covered by a single one of groups H04B3/00 - H04B13/00; Details of transmission systems not characterised by the medium used for transmission
    • H04B1/02Transmitters
    • H04B1/04Circuits
    • H04B1/0458Arrangements for matching and coupling between power amplifier and antenna or between amplifying stages
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B1/00Details of transmission systems, not covered by a single one of groups H04B3/00 - H04B13/00; Details of transmission systems not characterised by the medium used for transmission
    • H04B1/38Transceivers, i.e. devices in which transmitter and receiver form a structural unit and in which at least one part is used for functions of transmitting and receiving
    • H04B1/40Circuits
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. Transmission Power Control [TPC] or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0209Power saving arrangements in terminal devices
    • H04W52/0261Power saving arrangements in terminal devices managing power supply demand, e.g. depending on battery level
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B1/00Details of transmission systems, not covered by a single one of groups H04B3/00 - H04B13/00; Details of transmission systems not characterised by the medium used for transmission
    • H04B1/02Transmitters
    • H04B1/04Circuits
    • H04B2001/0408Circuits with power amplifiers

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Transmitters (AREA)

Abstract

本申请实施例公开了一种天线切换的方法、装置、终端设备及存储介质,用于在当前工作频段使用的第一天线的第一实际电流满足预设条件的情况下,可以将第一天线切换为第二天线进行通信,因为第二天线的参考电流小于第一实际电流,从而可以降低终端设备的功耗。本申请实施例方法应用于射频系统,所述射频系统包括多个天线,所述方法包括:检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流;在第一实际电流满足预设条件的情况下,将第一天线切换为第二天线,使用第二天线进行通信,第二天线为多个天线中支持在当前工作频段的天线内,使用目标发射功率对应的参考电流小于第一实际电流的天线;其中,多个天线包括第一天线和第二天线。

The embodiment of the present application discloses a method, apparatus, terminal device and storage medium for antenna switching, which is used to switch the first antenna to the second antenna for communication when the first actual current of the first antenna used in the current working frequency band meets the preset conditions, because the reference current of the second antenna is less than the first actual current, thereby reducing the power consumption of the terminal device. The method of the embodiment of the present application is applied to a radio frequency system, and the radio frequency system includes multiple antennas, and the method includes: detecting the target transmission power and the corresponding first actual current of the first antenna used in the current working frequency band; when the first actual current meets the preset conditions, switching the first antenna to the second antenna, and using the second antenna for communication, the second antenna is an antenna among multiple antennas that supports the current working frequency band, and the reference current corresponding to the target transmission power is less than the first actual current; wherein the multiple antennas include the first antenna and the second antenna.

Description

天线切换的方法、装置、终端设备及存储介质Antenna switching method, device, terminal equipment and storage medium

技术领域Technical Field

本申请涉及通信领域,尤其涉及一种天线切换的方法、装置、终端设备及存储介质。The present application relates to the field of communications, and in particular to a method, apparatus, terminal equipment and storage medium for antenna switching.

背景技术Background Art

随着射频新技术如5G、双卡双通(dual sim dual active,DSDA)、上行多进多出(Up Link Multiple-Input Multiple-Output,UL MIMO)等功能的实现,终端设备整机的功耗越来越大,续航要求也越来越严格。目前射频技术大部分在优化传导功耗,如提高功率放大器(Power Amplifier,PA)本身效率、优化通路插损、包络跟踪(Envelope Tracking,ET)功能等方式去降低功耗;也有通过天线切换来解决,目前天线切换方案是基于信号强度来进行切换的。但会出现信号强度好,但是整机功耗比较大的情况,所以会造成终端设备升温快,影响待机时长,进而影响用户体验的问题。With the implementation of new RF technologies such as 5G, dual sim dual active (DSDA), and uplink multiple-input multiple-output (UL MIMO), the power consumption of terminal equipment is increasing, and the battery life requirements are becoming more and more stringent. Currently, most RF technologies are optimizing conduction power consumption, such as improving the efficiency of the power amplifier (PA), optimizing the path insertion loss, and using the envelope tracking (ET) function to reduce power consumption; there are also solutions through antenna switching. The current antenna switching solution is based on signal strength. However, there may be a situation where the signal strength is good, but the power consumption of the whole device is relatively large, which will cause the terminal equipment to heat up quickly, affecting the standby time, and thus affecting the user experience.

发明内容Summary of the invention

本申请实施例提供了一种天线切换的方法、装置、终端设备及存储介质,用于在当前工作频段使用的第一天线的第一实际电流满足预设条件的情况下,可以将第一天线切换为第二天线进行通信,因为第二天线的参考电流小于第一实际电流,从而可以降低终端设备的功耗。An embodiment of the present application provides an antenna switching method, apparatus, terminal device and storage medium, which are used to switch the first antenna to a second antenna for communication when a first actual current of a first antenna used in a current working frequency band meets a preset condition. Because the reference current of the second antenna is less than the first actual current, the power consumption of the terminal device can be reduced.

本申请第一方面提供一种天线切换的方法,所述方法应用于射频系统,所述射频系统包括多个天线,所述方法可以包括:A first aspect of the present application provides an antenna switching method, the method being applied to a radio frequency system, the radio frequency system including a plurality of antennas, and the method may include:

检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流;Detecting a target transmission power of a first antenna used in a current working frequency band and a corresponding first actual current;

在所述第一实际电流满足预设条件的情况下,将所述第一天线切换为第二天线,使用所述第二天线进行通信,所述第二天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线;When the first actual current meets a preset condition, the first antenna is switched to a second antenna, and the second antenna is used for communication, where the second antenna is an antenna among the multiple antennas that supports the current working frequency band and uses an antenna whose reference current corresponding to the target transmit power is less than the first actual current;

其中,所述多个天线包括所述第一天线和所述第二天线。The multiple antennas include the first antenna and the second antenna.

本申请第二方面提供一种天线切换的装置,所述装置应用于射频系统,所述射频系统包括多个天线,所述装置包括:A second aspect of the present application provides an antenna switching device, the device is applied to a radio frequency system, the radio frequency system includes multiple antennas, and the device includes:

检测模块,用于检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流;A detection module, used to detect a target transmission power of a first antenna used in a current working frequency band and a corresponding first actual current;

切换模块,用于在所述第一实际电流大于第一预设电流的情况下,将所述第一天线切换为第二天线,通信模块,用于使用所述第二天线进行通信,所述第二天线使用所述目标发射功率对应的参考电流小于所述第一实际电流;a switching module, configured to switch the first antenna to a second antenna when the first actual current is greater than a first preset current, and a communication module, configured to use the second antenna for communication, wherein a reference current corresponding to the target transmit power used by the second antenna is less than the first actual current;

其中,所述多个天线包括所述第一天线和所述第二天线。The multiple antennas include the first antenna and the second antenna.

本申请第三方面提供一种终端设备,包括存储器和处理器,所述存储器存储有可在处理器上运行的计算机程序,所述终端设备执行所述程序时实现本申请第一方面所述的方法。A third aspect of the present application provides a terminal device, including a memory and a processor, wherein the memory stores a computer program that can be executed on the processor, and when the terminal device executes the program, the method described in the first aspect of the present application is implemented.

本申请第四方面提供一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现本申请第一方面所述的方法。A fourth aspect of the present application provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method described in the first aspect of the present application is implemented.

本申请第五方面提供一种芯片,包括计算机程序,所述计算机程序被处理器执行时实现如本申请第一方面所述的方法。In a fifth aspect, the present application provides a chip, comprising a computer program, which, when executed by a processor, implements the method described in the first aspect of the present application.

本申请实施例又一方面公开一种计算机程序产品,当所述计算机程序产品在计算机上运行时,使得所述计算机执行本申请第一方面所述的方法。Yet another aspect of an embodiment of the present application discloses a computer program product. When the computer program product is run on a computer, the computer is enabled to execute the method described in the first aspect of the present application.

本申请实施例又一方面公开一种应用发布平台,所述应用发布平台用于发布计算机程序产品,其中,当所述计算机程序产品在计算机上运行时,使得所述计算机执行本申请第一方面所述的方法。Another aspect of an embodiment of the present application discloses an application publishing platform, which is used to publish a computer program product. When the computer program product runs on a computer, the computer executes the method described in the first aspect of the present application.

从以上技术方案可以看出,本申请实施例具有以下优点:It can be seen from the above technical solutions that the embodiments of the present application have the following advantages:

在本申请实施例中,提供一种天线切换的方法,所述方法应用于射频系统,所述射频系统包括多个天线,所述方法可以包括:检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流;在所述第一实际电流满足预设条件的情况下,将所述第一天线切换为第二天线,使用所述第二天线进行通信,所述第二天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线;其中,所述多个天线包括所述第一天线和所述第二天线。用于可以通过检测天线的目标发射功率所对应功率放大器的电流,来切换天线,从而达到降低终端设备功耗的目的,即在当前工作频段使用的第一天线的第一实际电流满足预设条件的情况下,可以将第一天线切换为第二天线进行通信,因为第二天线的参考电流小于第一实际电流,从而可以降低终端设备的功耗。In an embodiment of the present application, a method for antenna switching is provided, the method is applied to a radio frequency system, the radio frequency system includes multiple antennas, the method may include: detecting the target transmission power and the corresponding first actual current of the first antenna used in the current working frequency band; when the first actual current meets the preset condition, switching the first antenna to the second antenna, using the second antenna for communication, the second antenna being an antenna among the multiple antennas that supports the current working frequency band and uses a reference current corresponding to the target transmission power that is less than the first actual current; wherein the multiple antennas include the first antenna and the second antenna. The method is used to switch the antenna by detecting the current of the power amplifier corresponding to the target transmission power of the antenna, thereby achieving the purpose of reducing the power consumption of the terminal device, that is, when the first actual current of the first antenna used in the current working frequency band meets the preset condition, the first antenna can be switched to the second antenna for communication, because the reference current of the second antenna is less than the first actual current, thereby reducing the power consumption of the terminal device.

附图说明BRIEF DESCRIPTION OF THE DRAWINGS

为了更清楚地说明本申请实施例技术方案,下面将对实施例和现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,还可以根据这些附图获得其它的附图。In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments and the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application, and other drawings can be obtained based on these drawings.

图1A是相关技术中终端设备中射频系统的架构图;FIG1A is an architecture diagram of a radio frequency system in a terminal device in the related art;

图1B和图1C是终端设备整机的手握场景示意图;1B and 1C are schematic diagrams of hand-held scenes of the entire terminal device;

图1D是终端设备的充电场景示意图;FIG1D is a schematic diagram of a charging scenario of a terminal device;

图2A为本申请实施例所应用的一个射频系统架构图;FIG2A is a diagram of a radio frequency system architecture used in an embodiment of the present application;

图2B为本申请实施例所应用的另一个射频系统架构图;FIG2B is another RF system architecture diagram used in an embodiment of the present application;

图3为本申请实施例中天线切换的方法的一个实施例示意图;FIG3 is a schematic diagram of an embodiment of a method for antenna switching in an embodiment of the present application;

图4为本申请实施例中天线切换的方法的另一个实施例示意图;FIG4 is a schematic diagram of another embodiment of the method for antenna switching in an embodiment of the present application;

图5为本申请实施例中天线切换的方法的一个流程示意图;FIG5 is a schematic flow chart of a method for antenna switching in an embodiment of the present application;

图6为本申请实施例中天线切换的装置的一个实施例示意图;FIG6 is a schematic diagram of an embodiment of an antenna switching device in an embodiment of the present application;

图7A为本申请实施例中终端设备的一个实施例示意图;FIG7A is a schematic diagram of an embodiment of a terminal device in an embodiment of the present application;

图7B为本申请实施例中终端设备的另一个实施例示意图。FIG. 7B is a schematic diagram of another embodiment of a terminal device in an embodiment of the present application.

具体实施方式DETAILED DESCRIPTION

本申请实施例提供了一种天线切换的方法、装置、终端设备及存储介质,用于在当前工作频段使用的第一天线的第一实际电流满足预设条件的情况下,可以将第一天线切换为第二天线进行通信,因为第二天线的参考电流小于第一实际电流,从而可以降低终端设备的功耗。An embodiment of the present application provides an antenna switching method, apparatus, terminal device and storage medium, which are used to switch the first antenna to a second antenna for communication when a first actual current of a first antenna used in a current working frequency band meets a preset condition. Because the reference current of the second antenna is less than the first actual current, the power consumption of the terminal device can be reduced.

为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行描述,显然,所描述的实施例仅仅是本申请一部分的实施例,而不是全部的实施例。基于本申请中的实施例,都应当属于本申请保护的范围。In order to make the technical personnel in the technical field better understand the scheme of the present application, the technical scheme in the embodiment of the present application will be described below in conjunction with the drawings in the embodiment of the present application. Obviously, the described embodiment is only a part of the embodiment of the present application, not all of the embodiments. Based on the embodiments in the present application, they should all fall within the scope of protection of the present application.

随着射频新技术如5G、双卡双通(dual sim dual active,DSDA)、上行多进多出(Up Link Multiple-Input Multiple-Output,UL MIMO)等功能的实现,整机的功耗越来越大,续航要求也越来越严格,同时整机天线效率由于工业设计(Industrial Design,ID)限制天线净空及天线数量剧增,从而导致天线效率下降,这样整机增加功耗,影响整机续航和整机温升,从用户的反馈体验来看,温升和续航对手机来说是非常重要的指标。目前射频技术大部分在优化传导功耗,如提高功率放大器(Power Amplifier,PA)本身效率、优化通路插损、包络跟踪(Envelope Tracking,ET)功能等方式去降低功耗;也有通过天线切换来解决,目前天线切换方案是基于信号强度,主流方案是通过测试不同天线下行信号参考信号接收功率(Reference Signal Receiving Power,RSRP),估算各支天线的上行信号性能,选择预估上行信号最好的天线进行信号发射。With the implementation of new RF technologies such as 5G, dual sim dual active (DSDA), and uplink multiple-input multiple-output (UL MIMO), the power consumption of the whole machine is increasing, and the battery life requirements are becoming more and more stringent. At the same time, the antenna efficiency of the whole machine is reduced due to the industrial design (ID) restrictions on antenna clearance and the sharp increase in the number of antennas, which leads to a decrease in antenna efficiency. This increases the power consumption of the whole machine, affects the battery life and temperature rise of the whole machine. From the user's feedback experience, temperature rise and battery life are very important indicators for mobile phones. At present, most RF technologies are optimizing the conduction power consumption, such as improving the efficiency of the power amplifier (PA), optimizing the path insertion loss, and the envelope tracking (ET) function to reduce power consumption; there are also ways to solve it through antenna switching. The current antenna switching solution is based on signal strength. The mainstream solution is to estimate the uplink signal performance of each antenna by testing the reference signal receiving power (RSRP) of the downlink signal of different antennas, and select the antenna with the best estimated uplink signal for signal transmission.

如图1A所示,是相关技术中终端设备中射频系统的架构图。它主要由基带就成电路,也可称基带芯片(Baseband integrated circuit,BB IC)、射频处理器(Transceiver)、射频前端(RF Front-end)、射频电源直流-直流转换器(DC-to-DC converter,DCDC)、电源管理芯片,也可称电源管理集成电路(Power Management Integrated Circuit,PMIC)、天线开关等几部分组合射频的发射机和接收机,完成通信功能。As shown in Figure 1A, it is the architecture diagram of the RF system in the terminal equipment in the related technology. It is mainly composed of a baseband integrated circuit, also known as a baseband chip (Baseband integrated circuit, BB IC), a radio frequency processor (Transceiver), a radio frequency front end (RF Front-end), a radio frequency power DC-to-DC converter (DC-to-DC converter, DCDC), a power management chip, also known as a power management integrated circuit (Power Management Integrated Circuit, PMIC), an antenna switch and other parts that combine the radio frequency transmitter and receiver to complete the communication function.

现有技术方案优化功耗的方案有如下几种:The existing technical solutions for optimizing power consumption are as follows:

器件选型:选用效率较高的PA和供电芯片,来降低整机功耗。Device selection: Choose more efficient PA and power supply chips to reduce the power consumption of the whole machine.

通路插损:射频(Radio Frequency,RF)前端的通路插损越小,PA输出功率低功耗相应也低;一般是通路减少天线合路形式、低插损器件、走线优化等方式,来降低通路插损。Channel insertion loss: The smaller the channel insertion loss of the RF front end, the lower the PA output power and the correspondingly lower the power consumption. Generally, the channel insertion loss is reduced by reducing the antenna combining form, low insertion loss devices, routing optimization, etc.

ET功能:采用包络跟踪方式给PA供电,相比功率跟踪(Average Power Tracking,APT)模式更节省功耗。ET function: The PA is powered by envelope tracking, which saves more power than the average power tracking (APT) mode.

上述几种方式是相关技术方案中优化功耗的常用方法。The above-mentioned methods are commonly used methods for optimizing power consumption in related technical solutions.

但是,现有优化传导技术方案对于整机功耗是没有帮助的,特别是在横屏游戏、手握、插通用串行总线(Universal Serial Bus,USB)充电等场景时终端设备的天线受到人体或其它金属物接触时会影响天线的无源位置,这个时候整机的天线性能变化剧烈,整机的功耗、性能都受到较严重的影响。如图1B和图1C所示,是终端设备整机的手握场景示意图。如图1D所示,是终端设备的充电场景示意图。However, the existing optimized conduction technology solutions are not helpful for the power consumption of the whole machine, especially when the antenna of the terminal device is touched by the human body or other metal objects in scenarios such as horizontal screen gaming, hand-held, and USB charging, which will affect the passive position of the antenna. At this time, the antenna performance of the whole machine changes dramatically, and the power consumption and performance of the whole machine are seriously affected. As shown in Figures 1B and 1C, it is a schematic diagram of the hand-held scenario of the whole terminal device. As shown in Figure 1D, it is a schematic diagram of the charging scenario of the terminal device.

表1VSWR=3:1和各频段下的电流仿真值Table 1 VSWR = 3:1 and current simulation values at each frequency band

表2整机自由空间状态和横屏手握状态下的功耗数据对比Table 2 Comparison of power consumption data of the whole machine in free space state and horizontal screen hand-held state

根据表2可以得出,在手握状态下,如果将天线切换到ANT5,此时ANT5的手握场景的功耗相比自由空间场景下会大150mA左右。According to Table 2, it can be concluded that in the hand-held state, if the antenna is switched to ANT5, the power consumption of ANT5 in the hand-held scenario will be about 150mA higher than that in the free space scenario.

由此可见,相关技术方案中,当在手握、横屏、插USB等场景下整机的电压驻波比(Voltage Standing Wave Ratio,VSWR)会发生变化,相位也会发生变化,导致整机的电流影响非常大,对整机的温升和续航产生非常不好的体验。通常这些场景下,通过使用天线切换技术,目前天线切换技术是通过测试下行信号RSRP,来决定使用哪支天线进行信号发射,这里存在如下缺点,对于频分双工(Frequency Division Duplexing,FDD)频段TX(Transmit,发射)和RX(Receive,接收)没有同频,通过RX信号估算TX信道性能存在不足,选择天线不是性能最佳,导致影响整机功耗及温升;另一方面估算是基于天线发射功率,会出现天线发射功率小,但是发射信号使用的功耗反而越大,如表2中的例子,如果手握切换到天线(ANT)5位置,反而增大整机功耗。It can be seen that in the relevant technical solutions, the voltage standing wave ratio (VSWR) of the whole machine will change when it is held in hand, in horizontal screen, plugged in USB and other scenarios, and the phase will also change, resulting in a very large impact on the current of the whole machine, which has a very bad experience on the temperature rise and battery life of the whole machine. Usually in these scenarios, by using antenna switching technology, the current antenna switching technology is to determine which antenna to use for signal transmission by testing the downlink signal RSRP. There are the following disadvantages here: for the frequency division duplexing (FDD) band TX (Transmit, transmission) and RX (Receive, reception) are not in the same frequency, and the TX channel performance is estimated by the RX signal. There are deficiencies, and the antenna selection is not the best performance, which affects the power consumption and temperature rise of the whole machine; on the other hand, the estimation is based on the antenna transmission power, and the antenna transmission power will be small, but the power consumption used for the transmission signal is greater. For example, in the example in Table 2, if the hand is switched to the antenna (ANT) 5 position, the power consumption of the whole machine will increase.

在本申请实施例中,终端设备可以是手机(Mobile Phone)、平板电脑(Pad)、带无线收发功能的电脑、虚拟现实(Virtual Reality,VR)终端设备、增强现实(AugmentedReality,AR)终端设备、工业控制(industrial control)中的无线终端设备、无人驾驶(self driving)中的无线终端设备、远程医疗(remote medical)中的无线终端设备、智能电网(smart grid)中的无线终端设备、运输安全(transportation safety)中的无线终端设备、智慧城市(smart city)中的无线终端设备或智慧家庭(smart home)中的无线终端设备等。In the embodiment of the present application, the terminal device can be a mobile phone, a tablet computer, a computer with wireless transceiver function, a virtual reality (VR) terminal device, an augmented reality (AR) terminal device, a wireless terminal device in industrial control, a wireless terminal device in self driving, a wireless terminal device in remote medical, a wireless terminal device in a smart grid, a wireless terminal device in transportation safety, a wireless terminal device in a smart city, or a wireless terminal device in a smart home, etc.

作为示例而非限定,在本申请实施例中,该终端设备还可以是具有显示界面的可穿戴设备。可穿戴设备也可以称为穿戴式智能设备,是应用穿戴式技术对日常穿戴进行智能化设计、开发出可以穿戴的设备的总称,如眼镜、手套、手表、服饰及鞋等。可穿戴设备即直接穿在身上,或是整合到用户的衣服或配件的一种便携式设备。可穿戴设备不仅仅是一种硬件设备,更是通过软件支持以及数据交互、云端交互来实现强大的功能。广义穿戴式智能设备包括功能全、尺寸大、可不依赖智能手机实现完整或者部分的功能,例如:智能手表或智能眼镜等,以及只专注于某一类应用功能,需要和其它设备如智能手机配合使用,如各类进行体征监测的智能手环、智能首饰等。As an example but not limitation, in the embodiment of the present application, the terminal device can also be a wearable device with a display interface. Wearable devices can also be called wearable smart devices, which are a general term for wearable devices that use wearable technology to intelligently design and develop wearable devices for daily wear, such as glasses, gloves, watches, clothing and shoes. A wearable device is a portable device that is worn directly on the body or integrated into the user's clothes or accessories. Wearable devices are not only hardware devices, but also powerful functions achieved through software support, data interaction, and cloud interaction. Broadly speaking, wearable smart devices include full-featured, large-sized, and independent of smartphones to achieve complete or partial functions, such as smart watches or smart glasses, as well as those that only focus on a certain type of application function and need to be used in conjunction with other devices such as smartphones, such as various types of smart bracelets and smart jewelry for vital sign monitoring.

本申请实施例中天线切换的方法,以应用于终端设备中的手机为例进行说明。The antenna switching method in the embodiment of the present application is described by taking a mobile phone used in a terminal device as an example.

基于相关技术方案中的缺陷,在本申请技术方案中,提出了基于电流检测选择合适的天线,优化整机各种场景下的功耗;当射频PA功耗剧烈增加时,切换天线,选择PA功耗较小的天线进行发射,可以时时让整机使用较小功耗的天线发射,从而改善功耗、温升方面的问题,可以大幅提高用户的体验。Based on the defects in the relevant technical solutions, the technical solution of the present application proposes to select a suitable antenna based on current detection to optimize the power consumption of the whole machine in various scenarios; when the power consumption of the RF PA increases sharply, switch the antenna and select an antenna with lower PA power consumption for transmission, so that the whole machine can always use the antenna with lower power consumption for transmission, thereby improving the problems of power consumption and temperature rise, and can greatly improve the user experience.

本申请实施例所应用的射频系统架构图,相比相关技术方案中的射频系统架构图,增加了电流检测模块,该电流检测模块可以内置在射频电源DCDC中,也可以内置在PMIC中,也可以作为独立的模块,连接在射频电源DCDC和PMIC之间,本申请不做具体限定。该电流检测模块用于检测天线使用目标发射功率对应的实际电流。如图2A所示,为本申请实施例所应用的一个射频系统架构图,在图2A中以电流检测模块连接在射频电源DCDC和PMIC之间为例进行说明。示例性的,这里的电流检测模块可以通过电流检测电阻实现,电流检测电阻还需要与基带芯片(BB IC)连接,具有模数转换器(Analog-to-Digital Converter,ADC)功能通用型输入/输出(General-purpose input/output,GPIO)。如图2B所示,为本申请实施例所应用的另一个射频系统架构图。在图2B所示中,电流检测电阻可以通过差分走线连接BB IC。The RF system architecture diagram used in the embodiment of the present application, compared with the RF system architecture diagram in the related technical solution, adds a current detection module, which can be built in the RF power supply DCDC, can be built in the PMIC, or can be used as an independent module, connected between the RF power supply DCDC and the PMIC, and this application does not make specific restrictions. The current detection module is used to detect the actual current corresponding to the target transmission power used by the antenna. As shown in Figure 2A, it is a RF system architecture diagram used in the embodiment of the present application. In Figure 2A, the current detection module is connected between the RF power supply DCDC and the PMIC as an example. Exemplarily, the current detection module here can be implemented by a current detection resistor, and the current detection resistor also needs to be connected to the baseband chip (BB IC), and has an analog-to-digital converter (ADC) function general-purpose input/output (GPIO). As shown in Figure 2B, it is another RF system architecture diagram used in the embodiment of the present application. As shown in Figure 2B, the current detection resistor can be connected to the BB IC through differential routing.

电流检测电阻就是一个贴片采样电阻,阻值较小,串联在电路中用于把电流转换为电压信号进行测量。电流检测电阻功能上就是作为参考,常用在反馈电路里,以稳压电源电路为例,为使输出的电压保持恒定状态,要从输出电压取一部分电压做参考(常用取样电阻的形式),如果输出高了,输入端就自动降低电压,使输出减少;若输出低了,则输入端就自动升高电压,使输出升高。一般使用在电源产品,或者电子,数码,机电产品的电源部分,功能强大。The current detection resistor is a chip sampling resistor with a small resistance value. It is connected in series in the circuit to convert the current into a voltage signal for measurement. The function of the current detection resistor is to serve as a reference. It is often used in feedback circuits. Taking the voltage-stabilized power supply circuit as an example, in order to keep the output voltage constant, a part of the voltage is taken from the output voltage as a reference (commonly used in the form of a sampling resistor). If the output is high, the input end automatically reduces the voltage to reduce the output; if the output is low, the input end automatically increases the voltage to increase the output. It is generally used in power supply products, or the power supply part of electronic, digital, and electromechanical products, and has powerful functions.

采样电阻一般使用的都是精密电阻,阻值低,精密度高,一般在阻值精密度在±1%以内,更高要求的用途时会采用0.01%精度的电阻。一般采样电阻的阻值会选在1欧姆以下,属于毫欧级电阻,但是部分电阻,有个采样电压等要求,必须选择大阻值电阻,但是这样电阻基数大,产生的误差大。这种情况下,需要选择高精度的电阻。Sampling resistors generally use precision resistors with low resistance and high precision. Generally, the resistance precision is within ±1%. For applications with higher requirements, resistors with 0.01% precision are used. Generally, the resistance of sampling resistors is selected below 1 ohm, which belongs to milliohm resistors. However, some resistors have requirements such as sampling voltage, so large resistance must be selected. However, the resistance base is large, resulting in large errors. In this case, high-precision resistors need to be selected.

在本申请实施例中,在终端设备使用天线发射信号的情况下,当用户的使用场景发生变化时,此时PA负载、天线的VSWR和相位会发生变化,导致PA功耗变大,这时候可以通过电流检测模块检测电流,如果检测到电流增加,说明功耗增大,可以通过尝试切换到其他天线,再检测电流是否减少,从而达到优化功耗的目的。In an embodiment of the present application, when a terminal device uses an antenna to transmit a signal, when the user's usage scenario changes, the PA load, the antenna's VSWR and phase will change, causing the PA power consumption to increase. At this time, the current can be detected by the current detection module. If an increase in current is detected, it means that the power consumption has increased. You can try to switch to other antennas and then detect whether the current has decreased, thereby achieving the purpose of optimizing power consumption.

下面以实施例的方式,对本申请技术方案做进一步的说明,如图3所示,为本申请实施例中天线切换的方法的一个实施例示意图。所述方法应用于射频系统,所述射频系统包括多个天线,该方法实施例可以包括以下步骤:The technical solution of the present application is further described below by way of an embodiment. As shown in FIG3 , it is a schematic diagram of an embodiment of a method for antenna switching in an embodiment of the present application. The method is applied to a radio frequency system, the radio frequency system includes multiple antennas, and the method embodiment may include the following steps:

301、检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流。301. Detect a target transmission power of a first antenna used in a current working frequency band and a corresponding first actual current.

在终端设备使用第一天线发射信号时,可以检测当前工作频段所使用的第一天线的目标发射功率和对应的第一实际电流。需要说明的是,这里的第一天线是默认天线,即在当前工作频段下,发射目标发射功率时第一天线的电流最小,参考功耗最低。示例性的,终端设备当前工作在ANT1 B1,目标发射功率为10dbm,对应PA的第一实际电流是95mA。When the terminal device uses the first antenna to transmit a signal, the target transmission power of the first antenna used in the current working frequency band and the corresponding first actual current can be detected. It should be noted that the first antenna here is the default antenna, that is, in the current working frequency band, the current of the first antenna is the smallest when transmitting the target transmission power, and the reference power consumption is the lowest. Exemplarily, the terminal device is currently operating at ANT1 B1, the target transmission power is 10dbm, and the corresponding first actual current of the PA is 95mA.

在一种实现方式中,所述检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流,可以包括:检测当前工作频段使用的第一天线的目标发射功率,通过电流检测模块检测所述目标发射功率对应的第一实际电流。在本技术方案中,可以通过电流检测模块检测第一天线使用目标发射功率所对应的第一实际电流,提供了电流检测的具体实现方式,提高了方案的可行性。In one implementation, the detection of the target transmission power of the first antenna used in the current working frequency band and the corresponding first actual current may include: detecting the target transmission power of the first antenna used in the current working frequency band, and detecting the first actual current corresponding to the target transmission power through a current detection module. In this technical solution, the first actual current corresponding to the target transmission power used by the first antenna can be detected through the current detection module, which provides a specific implementation method for current detection and improves the feasibility of the solution.

电流检测模块可以用于电流检测,电流检测是电子和电气系统中的一项基本任务,用于评估、控制和诊断系统的性能。以下是一些常见的电流检测方法:Current sensing modules can be used for current sensing, which is a basic task in electronic and electrical systems to evaluate, control and diagnose system performance. The following are some common current sensing methods:

电流精密检测电阻(Precision Current Sense Resistor),电流精密检测电阻是一种高精度的电阻器,用于测量较小的电流。通过测量电阻两端的电压降来检测电流,但更注重精度;而且阻值较高,以提供足够的电压降,便于测量较小电流;还具有非常低的温度系数和长期稳定性。通常用于需要高精度电流检测的场合。Precision Current Sense Resistor, precision current sense resistor is a high-precision resistor used to measure smaller currents. It detects current by measuring the voltage drop across the resistor, but pays more attention to accuracy; and has a higher resistance value to provide sufficient voltage drop for measuring smaller currents; it also has a very low temperature coefficient and long-term stability. It is usually used in situations where high-precision current detection is required.

分流电阻(Shunt Resistor):在电流路径中串联一个低阻值的精密电阻器,通过测量电阻器两端的电压降来检测电流。这种方法简单、成本较低,但会引入一定的电压降,可能影响电路的性能。Shunt Resistor: A low-resistance precision resistor is connected in series in the current path, and the current is detected by measuring the voltage drop across the resistor. This method is simple and low-cost, but it will introduce a certain voltage drop, which may affect the performance of the circuit.

霍尔效应传感器(Hall Effect Sensor):利用霍尔效应原理,通过一个半导体芯片测量磁场强度,进而推算出电流。这种方法非侵入性,可以测量交流或直流电流,且无需物理接触。Hall Effect Sensor: Utilizes the Hall Effect principle to measure magnetic field strength through a semiconductor chip and infer current. This method is non-invasive and can measure AC or DC current without physical contact.

罗氏线圈(Rogowski Coil):适用于交流电流的测量,通过一个环形线圈检测电流变化产生的磁场,进而计算电流。这种方法对电流的频率响应较好,但成本相对较高。Rogowski Coil: Suitable for measuring AC current. It detects the magnetic field generated by the current change through a circular coil and then calculates the current. This method has a good frequency response to the current, but the cost is relatively high.

电流互感器(Current Transformer,CT):通过变压器原理测量电流,适用于高电流测量,但通常只用于交流电流的检测。Current Transformer (CT): measures current through the transformer principle. It is suitable for high current measurement, but is usually only used for AC current detection.

光纤电流传感器(Optical Current Sensor):利用光在光纤中传输的特性,通过测量由电流产生的磁场对光的影响来检测电流。这种方法具有高带宽和抗电磁干扰的特点。Optical Current Sensor: Utilizes the characteristics of light transmission in optical fiber to detect current by measuring the effect of the magnetic field generated by current on light. This method has the characteristics of high bandwidth and immunity to electromagnetic interference.

磁通门(Flux Gate):使用磁通门技术测量磁场,进而推算出电流。这种方法适用于测量强磁场环境的电流。Flux Gate: Flux Gate technology is used to measure the magnetic field and then infer the current. This method is suitable for measuring current in a strong magnetic field environment.

金属-氧化物半导体场效应晶体管,简称金氧半场效晶体管(Metal-Oxide-Semiconductor Field-Effect Transistor,MOSFET)导通电阻(RDS(ON)):利用MOSFET导通时的内部电阻产生的电压降来检测电流。这种方法避免了额外的检测元件,但精度受MOSFET参数和温度的影响。Metal-Oxide-Semiconductor Field-Effect Transistor (MOSFET) on-resistance (RDS(ON)): Current is detected by using the voltage drop generated by the internal resistance of the MOSFET when it is turned on. This method avoids additional detection components, but the accuracy is affected by MOSFET parameters and temperature.

电感直流电阻(DCR):在电感元件中加入直流电阻成分,通过测量该电阻上的电压降来检测电流。这种方法无需额外元件,但精度受电感DCR参数的影响。Inductor DC resistance (DCR): A DC resistance component is added to the inductor element, and the current is detected by measuring the voltage drop across the resistance. This method does not require additional components, but the accuracy is affected by the inductor DCR parameter.

专用电流监测芯片:市面上有多种专用的电流监测集成电路,它们集成了所需的运放、电阻和其他元件,提供了高精度和高共模抑制比(Common Mode Rejection Ratio,CMRR)的电流检测方案。Dedicated current monitoring chips: There are many dedicated current monitoring integrated circuits on the market, which integrate the required op amps, resistors and other components to provide high-precision and high common mode rejection ratio (CMRR) current detection solutions.

每种电流检测方法都有其优势和局限性,选择时需要考虑测量的准确性、成本、电路复杂度、温度漂移、电磁兼容性等因素。在设计电流检测电路时,应根据具体的应用需求和环境条件选择最合适的方法。Each current sensing method has its advantages and limitations, and factors such as measurement accuracy, cost, circuit complexity, temperature drift, and electromagnetic compatibility need to be considered when selecting. When designing a current sensing circuit, the most appropriate method should be selected based on the specific application requirements and environmental conditions.

需要说明的是,在终端设备中可以预先保存每个工作频段所支持的各支天线,在终端设备处于目标状态下各个发射功率及对应的参考电流,这些信息可以以映射表的形式保存,下面可以分为不同情况进行说明:It should be noted that the terminal device may pre-store the antennas supported by each working frequency band, the transmit powers and corresponding reference currents when the terminal device is in the target state. This information may be stored in the form of a mapping table, which may be described in different situations as follows:

情况1:在终端设备中可以预先保存每个工作频段所支持的各支天线,在自由空间状态下各个发射功率及对应的参考电流。Case 1: In the terminal device, the antennas supported by each working frequency band, the transmission powers of each antenna in the free space state and the corresponding reference current can be pre-stored.

示例1:B1工作频段对应天线1和天线2。Example 1: The B1 operating frequency band corresponds to antenna 1 and antenna 2.

天线1在自由空间状态下发10dbm功率对应PA参考电流为80mA;Antenna 1 emits 10dbm power in free space, corresponding to a PA reference current of 80mA;

天线2在自由空间状态下发10dbm功率对应PA参考电流为85mA。When antenna 2 emits 10 dBm power in free space, the PA reference current is 85 mA.

示例2:B1工作频段对应天线1、天线2和天线3。Example 2: The B1 operating frequency band corresponds to antenna 1, antenna 2, and antenna 3.

天线1在自由空间状态下发10dbm功率对应PA参考电流为80mA;Antenna 1 emits 10dbm power in free space, corresponding to a PA reference current of 80mA;

天线2在自由空间状态下发10dbm功率对应PA参考电流为85mA;Antenna 2 emits 10dbm power in free space, corresponding to a PA reference current of 85mA;

天线3在自由空间状态下发10dbm功率对应PA参考电流为90mA。When antenna 3 emits 10 dBm power in free space, the corresponding PA reference current is 90 mA.

情况2:在终端设备中可以预先保存每个工作频段所支持的各支天线,在目标状态下各个发射功率及对应的参考电流,所述目标状态包括自由空间状态,手握状态,横屏状态,或,充电状态。Case 2: The terminal device may pre-store the antennas supported by each operating frequency band, the transmission powers and the corresponding reference currents in the target state, where the target state includes a free space state, a hand-held state, a horizontal screen state, or a charging state.

需要说明的是,这里的手握状态、横屏状态和充电状态其实质属于自由空间状态外的几种具体状态。如果终端设备不处于手握状态、横屏状态和充电状态,就使用自由空间状态下的默认天线进行通信。It should be noted that the hand-held state, horizontal screen state and charging state here are actually several specific states other than the free space state. If the terminal device is not in the hand-held state, horizontal screen state and charging state, the default antenna in the free space state is used for communication.

示例:B1工作频段对应天线1、天线2和天线3。Example: The B1 operating frequency band corresponds to antenna 1, antenna 2, and antenna 3.

天线1在自由空间状态下发10dbm功率对应PA参考电流为80mA;Antenna 1 emits 10dbm power in free space, corresponding to a PA reference current of 80mA;

天线1在手握状态下发10dbm功率对应PA参考电流为82mA;When antenna 1 is held in the hand, the PA reference current corresponding to 10dbm power is 82mA;

天线1在横屏状态下发10dbm功率对应PA参考电流为85mA;When antenna 1 is in landscape mode and emits 10dbm power, the PA reference current is 85mA.

天线1在充电状态下发10dbm功率对应PA参考电流为90mA;When antenna 1 is in charging state, the PA reference current corresponding to 10dbm power is 90mA;

天线2在自由空间状态下发10dbm功率对应PA参考电流为85mA;Antenna 2 emits 10dbm power in free space, corresponding to a PA reference current of 85mA;

天线2在手握状态下发10dbm功率对应PA参考电流为85mA;When antenna 2 is held in the hand, the PA reference current corresponding to 10dbm power is 85mA;

天线2在横屏状态下发10dbm功率对应PA参考电流为88mA;When antenna 2 is in landscape mode and emits 10dbm power, the PA reference current is 88mA.

天线2在充电状态下发10dbm功率对应PA参考电流为90mA;When antenna 2 is in charging state, the PA reference current corresponding to 10dbm power is 90mA;

天线3在自由空间状态下发10dbm功率对应PA参考电流为90mA;Antenna 3 emits 10dbm power in free space, corresponding to a PA reference current of 90mA;

天线3在手握状态下发10dbm功率对应PA参考电流为98mA;When antenna 3 is held in the hand, the PA reference current corresponding to 10dbm power is 98mA;

天线3在横屏状态下发10dbm功率对应PA参考电流为92mA;When antenna 3 is in landscape mode and emits 10dbm power, the PA reference current is 92mA.

天线3在充电状态下发10dbm功率对应PA参考电流为95mA。When antenna 3 is in charging state, the PA reference current corresponding to 10dbm power is 95mA.

302、在所述第一实际电流满足预设条件的情况下,将所述第一天线切换为第二天线,使用所述第二天线进行通信。302. When the first actual current meets a preset condition, switch the first antenna to a second antenna, and use the second antenna for communication.

终端设备在检测得到当前工作频段所使用的第一天线的目标发射功率和对应的第一实际电流后,可以判断第一实际电流是否满足预设条件,例如将第一实际电流(例如95mA)和预设电流进行比较,在第一实际电流大于预设电流的情况下,将第一天线切换为第二天线,或者,第一实际电流大于预设电流,且第一实际电流(例如95mA)和预设电流的差值大于第一差值阈值的情况下,将第一天线切换为第二天线。该预设电流可以是个根据大数据得到的经验值,也可以是第一天线的目标发射功率对应的参考电流(例如80mA),也可以是预存的映射表中,支持在所述当前工作频段的天线内,使用所述目标发射功率对应的任一参考电流,例如可以是预存的映射表中最大的参考电流,也可以是预存的映射表中最小的参考电流,具体此处不做限定。After detecting the target transmission power of the first antenna used in the current working frequency band and the corresponding first actual current, the terminal device can determine whether the first actual current meets the preset condition, for example, comparing the first actual current (for example, 95mA) with the preset current, and switching the first antenna to the second antenna when the first actual current is greater than the preset current, or switching the first antenna to the second antenna when the first actual current is greater than the preset current and the difference between the first actual current (for example, 95mA) and the preset current is greater than the first difference threshold. The preset current can be an empirical value obtained based on big data, or a reference current corresponding to the target transmission power of the first antenna (for example, 80mA), or a pre-stored mapping table, supporting the use of any reference current corresponding to the target transmission power in the antenna of the current working frequency band, for example, the largest reference current in the pre-stored mapping table, or the smallest reference current in the pre-stored mapping table, which is not specifically limited here.

示例性的,该预设电流为80mA,那么,第一实际电流95mA大于预设电流80mA;或者,第一差值阈值为10,第一实际电流95mA与预设电流80mA的差值为15mA,大于第一差值阈值10,可以查询是否有其他天线优于当前天线,若有则切换到更优天线,这里以更优天线为第二天线为例进行说明。Exemplarily, the preset current is 80mA, then the first actual current 95mA is greater than the preset current 80mA; or, the first difference threshold is 10, and the difference between the first actual current 95mA and the preset current 80mA is 15mA, which is greater than the first difference threshold 10. It can be checked whether there are other antennas that are better than the current antenna. If so, switch to a better antenna. Here, the example of the better antenna being the second antenna is used for explanation.

在本技术方案中,因为切换的第二天线的参考电流小于第一天线的第一实际电流,所以,理论上可以降低终端设备的功耗。In this technical solution, because the reference current of the switched second antenna is smaller than the first actual current of the first antenna, the power consumption of the terminal device can be reduced in theory.

在一种实现方式中,所述第二天线为所述多个天线中支持在所述当前工作频段的天线内,除所述第一天线外使用所述目标发射功率对应的参考电流最小的天线。在本技术方案中,因为第二天线的参考电流是除第一天线外最小的,所以,理论上终端设备的功耗也是最低的,可以最大程度上降低终端设备整机的功耗。In one implementation, the second antenna is an antenna that supports the current working frequency band among the multiple antennas and uses the smallest reference current corresponding to the target transmit power except for the first antenna. In this technical solution, because the reference current of the second antenna is the smallest except for the first antenna, theoretically, the power consumption of the terminal device is also the lowest, which can minimize the power consumption of the entire terminal device.

在一种实现方式中,所述第一天线和所述第二天线为自由空间状态下所述当前工作频段支持的天线。In one implementation, the first antenna and the second antenna are antennas supported by the current working frequency band in a free space state.

这种实现方式和上述的情况1对应,即终端设备中预先保存的是每个工作频段所支持的各支天线,在自由空间状态下各个发射功率及对应的参考电流。所以,第一天线和第二天线都为自由空间状态下当前工作频段所支持的天线。终端设备不用检测自身处于什么状态,只需要在预先保存的映射表中,选择参考电流小于第一实际电流的天线进行切换即可,从而降低终端设备的功耗。This implementation corresponds to the above-mentioned situation 1, that is, the terminal device pre-stores the antennas supported by each working frequency band, the transmission powers and the corresponding reference currents in the free space state. Therefore, the first antenna and the second antenna are both antennas supported by the current working frequency band in the free space state. The terminal device does not need to detect what state it is in, but only needs to select the antenna with a reference current less than the first actual current in the pre-stored mapping table for switching, thereby reducing the power consumption of the terminal device.

在另一种实现方式中,所述第一天线为自由空间状态下所述当前工作频段支持的天线,所述第二天线为目标状态下所述当前工作频段支持的天线,所述目标状态为自由空间状态,手握状态,横屏状态,或,充电状态。In another implementation, the first antenna is an antenna supported by the current working frequency band in a free space state, and the second antenna is an antenna supported by the current working frequency band in a target state, and the target state is a free space state, a hand-held state, a horizontal screen state, or a charging state.

这种实现方式和上述的情况2对应,即终端设备中预先保存的是每个工作频段所支持的各支天线,在目标状态下各个发射功率及对应的参考电流,所述目标状态包括自由空间状态,手握状态,横屏状态,或,充电状态。所以,第一天线和第二天线可能是相同状态下当前工作频段所支持的天线,也可能是不同状态下当前工作频段所支持的天线。终端设备需要检测自身处于什么状态,如果终端设备处于目标状态,可以在预先保存的映射表中,选择目标状态中参考电流小于第一实际电流的天线进行切换即可,从而选择的天线更佳,更有助于降低终端设备的功耗。This implementation corresponds to the above-mentioned situation 2, that is, the terminal device pre-stores the antennas supported by each working frequency band, the various transmission powers and the corresponding reference currents in the target state, and the target state includes the free space state, the hand-held state, the horizontal screen state, or the charging state. Therefore, the first antenna and the second antenna may be antennas supported by the current working frequency band in the same state, or may be antennas supported by the current working frequency band in different states. The terminal device needs to detect what state it is in. If the terminal device is in the target state, it can select the antenna whose reference current in the target state is less than the first actual current in the pre-stored mapping table for switching, so that the selected antenna is better and helps to reduce the power consumption of the terminal device.

进一步可选的,所述在所述第一实际电流满足预设条件的情况下,将所述第一天线切换为第二天线,可以包括:在所述第一实际电流满足预设条件,且当前处于目标状态的情况下,选择所述第二天线,将所述第一天线切换为所述第二天线。Further optionally, when the first actual current meets a preset condition, switching the first antenna to the second antenna may include: when the first actual current meets the preset condition and is currently in a target state, selecting the second antenna and switching the first antenna to the second antenna.

如果第一实际电流满足预设条件,还可以检测终端设备当前所处的目标状态,示例性的,可以通过终端设备中的传感器,检测终端设备当前所处的目标状态。上述传感器可以包括但不限于以下至少一种:磁感应传感器、加速度传感器、陀螺仪、声音传感器、图像传感器、指纹传感器、距离传感器、温度传感器。如果检测到终端设备当前所处的目标状态为手握状态,那么,可以在所述当前工作频段的天线内,选择手握状态下使用目标发射功率对应的参考电流小于所述第一实际电流的任一天线,即为第二天线进行切换。如果检测到终端设备当前所处的目标状态为横屏状态,那么,可以在所述当前工作频段的天线内,选择横屏状态下使用目标发射功率对应的参考电流小于所述第一实际电流的任一天线,即为第二天线进行切换。如果检测到终端设备当前所处的目标状态为充电状态,那么,可以在所述当前工作频段的天线内,选择充电状态下使用目标发射功率对应的参考电流小于所述第一实际电流的任一天线,即为第二天线进行切换。If the first actual current meets the preset conditions, the target state of the terminal device can also be detected. For example, the target state of the terminal device can be detected by the sensor in the terminal device. The above sensor may include but is not limited to at least one of the following: a magnetic induction sensor, an acceleration sensor, a gyroscope, a sound sensor, an image sensor, a fingerprint sensor, a distance sensor, and a temperature sensor. If it is detected that the target state of the terminal device is currently in a hand-held state, then any antenna whose reference current corresponding to the target transmission power is less than the first actual current can be selected from the antennas in the current working frequency band in the hand-held state, that is, the second antenna is switched. If it is detected that the target state of the terminal device is currently in a horizontal screen state, then any antenna whose reference current corresponding to the target transmission power is less than the first actual current can be selected from the antennas in the current working frequency band in the horizontal screen state, that is, the second antenna is switched. If it is detected that the target state of the terminal device is currently in a charging state, then any antenna whose reference current corresponding to the target transmission power is less than the first actual current can be selected from the antennas in the current working frequency band in the charging state, that is, the second antenna is switched.

需要说明的是,在某些情况下,终端设备可能既处于横屏状态,也处于手握状态,或者,终端设备可能既处于横屏状态,也处于充电状态,或者,终端设备可能既处于手握状态,也处于充电状态,那么,可以选择在这两种状态下,参考电流最小的天线进行切换。在某些情况下,终端设备可能既处于横屏状态,也处于手握状态,还处于充电状态,那么,可以选择在这三种状态下,参考电流最小的天线进行切换。It should be noted that in some cases, the terminal device may be in both the horizontal screen state and the hand-held state, or the terminal device may be in both the horizontal screen state and the charging state, or the terminal device may be in both the hand-held state and the charging state, then the antenna with the smallest reference current in these two states can be selected for switching. In some cases, the terminal device may be in both the horizontal screen state, the hand-held state, and the charging state, then the antenna with the smallest reference current in these three states can be selected for switching.

在本技术方案中,如果第一实际电流满足预设条件,还可以检测终端设备当前所处的目标状态,选择目标状态下使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线,所以选择的天线是针对目标状态的,更具有针对性,从而更有助于降低终端设备的功耗。In the present technical solution, if the first actual current meets the preset conditions, the current target state of the terminal device can also be detected, and an antenna whose reference current corresponding to the target transmission power in the target state is smaller than the first actual current is selected. Therefore, the selected antenna is targeted at the target state and is more targeted, thereby helping to reduce the power consumption of the terminal device.

在一种实现方式中,所述当前工作频段支持的天线包括第一天线和第二天线;在所述第一实际电流满足预设条件的情况下,将所述第一天线切换为第二天线,可以包括:在所述第一实际电流满足预设条件的情况下,通过第一开关将所述第一天线切换为第二天线。In one implementation, the antennas supported by the current working frequency band include a first antenna and a second antenna; when the first actual current meets a preset condition, switching the first antenna to the second antenna may include: when the first actual current meets the preset condition, switching the first antenna to the second antenna through a first switch.

在本技术方案中,提供了天线切换的具体实现方式,通过开关切换天线,可以有效保证天线切换的效率,提高方案的可行性。In this technical solution, a specific implementation method for antenna switching is provided. By switching the antenna through a switch, the efficiency of antenna switching can be effectively guaranteed and the feasibility of the solution can be improved.

可选的,所述第一开关为单刀双掷开关或双刀双掷开关。Optionally, the first switch is a single-pole double-throw switch or a double-pole double-throw switch.

在本技术方案中,提供了开关的具体实现方式,可以有效保证天线切换的效率,提高方案的可行性。In this technical solution, a specific implementation method of the switch is provided, which can effectively ensure the efficiency of antenna switching and improve the feasibility of the solution.

在本申请实施例中,提供一种天线切换的方法,所述方法应用于终端设备,所述终端设备包括多个天线,所述方法可以包括:检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流;在所述第一实际电流满足预设条件的情况下,将所述第一天线切换为第二天线,使用所述第二天线进行通信,所述第二天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线;其中,所述多个天线包括所述第一天线和所述第二天线。用于可以通过检测天线的目标发射功率所对应功率放大器的电流,来切换天线,从而达到降低终端设备功耗的目的,即在当前工作频段使用的第一天线的第一实际电流满足预设条件的情况下,可以将第一天线切换为第二天线进行通信,因为第二天线的参考电流小于第一实际电流,从而可以降低终端设备的功耗。In an embodiment of the present application, a method for antenna switching is provided, the method is applied to a terminal device, the terminal device includes multiple antennas, the method may include: detecting the target transmission power and the corresponding first actual current of the first antenna used in the current working frequency band; when the first actual current meets the preset condition, switching the first antenna to the second antenna, using the second antenna for communication, the second antenna being an antenna among the multiple antennas that supports the current working frequency band and uses a reference current corresponding to the target transmission power that is less than the first actual current; wherein the multiple antennas include the first antenna and the second antenna. The method is used to switch the antenna by detecting the current of the power amplifier corresponding to the target transmission power of the antenna, so as to achieve the purpose of reducing the power consumption of the terminal device, that is, when the first actual current of the first antenna used in the current working frequency band meets the preset condition, the first antenna can be switched to the second antenna for communication, because the reference current of the second antenna is less than the first actual current, thereby reducing the power consumption of the terminal device.

如图4所示,为本申请实施例中天线切换的方法的另一个实施例示意图。所述方法应用于射频系统,所述射频系统包括多个天线,该方法实施例可以包括以下步骤:As shown in Figure 4, it is a schematic diagram of another embodiment of the method for antenna switching in an embodiment of the present application. The method is applied to a radio frequency system, and the radio frequency system includes multiple antennas. The method embodiment may include the following steps:

401、检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流。401. Detect a target transmission power of a first antenna used in a current working frequency band and a corresponding first actual current.

402、在所述第一实际电流满足预设条件的情况下,将所述第一天线切换为第二天线,使用所述第二天线进行通信。402. When the first actual current meets a preset condition, switch the first antenna to a second antenna, and use the second antenna for communication.

需要说明的是,本申请实施例中的步骤401-402与上述图3所示实施例中的步骤301-302类似,此处不再赘述。It should be noted that steps 401-402 in the embodiment of the present application are similar to steps 301-302 in the embodiment shown in FIG. 3 above, and will not be described in detail here.

403、检测所述第二天线使用所述目标发射功率对应的第二实际电流。403. Detect a second actual current corresponding to the target transmit power used by the second antenna.

终端设备将第一天线切换为第二天线后,还需要检测第二天线使用目标发射功率对应的第二实际电流。示例性的,检测所述第二天线使用目标发射功率对应的第二实际电流为90mA。After the terminal device switches the first antenna to the second antenna, it is also necessary to detect the second actual current corresponding to the target transmit power used by the second antenna. Exemplarily, the second actual current corresponding to the target transmit power used by the second antenna is detected to be 90 mA.

在一种实现方式中,所述检测所述第二天线使用所述目标发射功率对应的第二实际电流,可以包括:通过电流检测模块检测所述第二天线使用所述目标发射功率对应的第二实际电流。在本技术方案中,可以通过电流检测模块检测第二天线使用目标发射功率所对应的第二实际电流,提供了电流检测的具体实现方式,提高了方案的可行性。In one implementation, the detecting the second actual current corresponding to the target transmit power used by the second antenna may include: detecting the second actual current corresponding to the target transmit power used by the second antenna through a current detection module. In this technical solution, the second actual current corresponding to the target transmit power used by the second antenna may be detected through a current detection module, which provides a specific implementation method for current detection and improves the feasibility of the solution.

404、在所述第二实际电流小于所述第一实际电流的情况下,继续使用所述第二天线进行通信;其中,所述多个天线包括所述第一天线和所述第二天线。404. When the second actual current is less than the first actual current, continue to use the second antenna for communication; wherein the multiple antennas include the first antenna and the second antenna.

示例性的,在当前工作频段所使用的第一天线的目标发射功率对应的第一实际电流为95mA,在当前工作频段所使用的第二天线的目标发射功率对应的第二实际电流为90mA,因为第二实际电流90mA小于第一实际电流95mA,所以可以继续在当前工作频段使用第二天线的目标发射功率进行通信,即发射信号。在本技术方案中,因使用第二天线的目标发射功率所对应的第二实际电流小于使用第一天线的目标发射功率所对应的第一实际电流,所以,可以继续使用第二天线进行通信,从而降低终端设备的功耗。Exemplarily, the first actual current corresponding to the target transmit power of the first antenna used in the current working frequency band is 95mA, and the second actual current corresponding to the target transmit power of the second antenna used in the current working frequency band is 90mA. Because the second actual current of 90mA is less than the first actual current of 95mA, the target transmit power of the second antenna can continue to be used in the current working frequency band for communication, i.e., transmitting signals. In the present technical solution, because the second actual current corresponding to the target transmit power of the second antenna is less than the first actual current corresponding to the target transmit power of the first antenna, the second antenna can continue to be used for communication, thereby reducing the power consumption of the terminal device.

在一种实现方式中,所述在所述第二实际电流小于所述第一实际电流的情况下,继续使用所述第二天线进行通信,可以包括:在所述第二实际电流小于所述第一实际电流,且所述第一实际电流与所述第二实际电流的差值大于第二差值阈值的情况下,继续使用第二天线进行通信。In one implementation, when the second actual current is less than the first actual current, continuing to use the second antenna for communication may include: when the second actual current is less than the first actual current and the difference between the first actual current and the second actual current is greater than a second difference threshold, continuing to use the second antenna for communication.

在本技术方案中,因为默认的第一天线是各方面性能最佳的天线,避免第二实际电流只比第一实际电流小一点点的情况下,如果继续使用第二天线的话,除了电流比第一天线小一点点,其他性能并没有优于第一天线,所以,在第二实际电流小于第一实际电流的情况下,还需要第一实际电流与第二实际电流的差值大于第二差值阈值,才继续使用第二天线进行通信,可以降低终端设备相对比较多的功耗,可以暂不考虑终端设备其他的性能。In the present technical solution, because the default first antenna is the antenna with the best performance in all aspects, it can avoid the situation where the second actual current is only slightly smaller than the first actual current. If the second antenna continues to be used, except that the current is slightly smaller than the first antenna, other performance is not better than the first antenna. Therefore, when the second actual current is less than the first actual current, the difference between the first actual current and the second actual current needs to be greater than the second difference threshold before the second antenna can continue to be used for communication, which can reduce the relatively large power consumption of the terminal device, and other performance of the terminal device can be temporarily ignored.

405、在使用所述第二天线进行通信的时长超过预设时长的情况下,将所述第二天线切换为所述第一天线,使用所述第一天线进行通信。405: When a duration of using the second antenna for communication exceeds a preset duration, switch the second antenna to the first antenna, and use the first antenna for communication.

示例性的,在终端设备使用的当前天线不是默认天线(本申请实施例以默认天线以第一天线为例进行说明)时,可以每隔预设时长,切换回默认天线,同时测试默认天线的当前实际电流,若当前实际电流大于不是默认天线的实际电流,则切换回不是默认天线进行通信,若当前实际电流小于不是默认天线的实际电流,则使用默认天线进行通信。Exemplarily, when the current antenna used by the terminal device is not the default antenna (the embodiment of the present application takes the first antenna as an example to illustrate the default antenna), it can switch back to the default antenna at preset time intervals, and test the current actual current of the default antenna at the same time. If the current actual current is greater than the actual current of the non-default antenna, switch back to the non-default antenna for communication. If the current actual current is less than the actual current of the non-default antenna, use the default antenna for communication.

在本技术方案中,因为通常情况下,默认天线是终端设备功耗最小的天线,所以,就算在某些状态下,默认天线的实际电流增大,从而切换到其他天线进行通信,但是也需要隔段时间就切换回默认天线,检测默认天线的实际电流,确定是否使用默认天线进行通信,从而,更大程度上保证终端设备使用低功耗的天线进行通信,降低终端设备整机的功耗。In the present technical solution, because under normal circumstances, the default antenna is the antenna with the lowest power consumption of the terminal device, even if the actual current of the default antenna increases in certain states, thereby switching to other antennas for communication, it is still necessary to switch back to the default antenna at intervals to detect the actual current of the default antenna and determine whether to use the default antenna for communication. In this way, it is ensured to a greater extent that the terminal device uses a low-power antenna for communication and reduces the power consumption of the entire terminal device.

406、在所述第二实际电流大于所述第一实际电流的情况下,将所述第二天线切换为所述第一天线,使用所述第一天线进行通信。406. When the second actual current is greater than the first actual current, switch the second antenna to the first antenna, and use the first antenna for communication.

示例性的,从第一天线切换为第二天线后,检测切换后的第二天线的第二实际电流,确认是否比切换前的实际电流更优,若比切换前的实际电流更优,则保持切换后的第二天线进行通信,若没有,则切换回第一天线或切换为其他天线。例如:在当前工作频段所使用的第一天线的目标发射功率对应的第一实际电流为95mA,在当前工作频段所使用的第二天线的目标发射功率对应的第二参考电流为85mA,但是检测得到的第二实际电流为100mA,因为第二实际电流100mA大于第一实际电流95mA,所以终端设备的功耗反而增大了,将第二天线在切换回第一天线进行通信,即发射信号。在本技术方案中,因使用第二天线的目标发射功率所对应的第二实际电流大于使用第一天线的目标发射功率所对应的第一实际电流,所以,需要将第二天线再切换为第一天线进行通信,从而降低终端设备的功耗。Exemplarily, after switching from the first antenna to the second antenna, the second actual current of the second antenna after switching is detected to confirm whether it is better than the actual current before switching. If it is better than the actual current before switching, the second antenna after switching is maintained for communication. If not, it is switched back to the first antenna or switched to another antenna. For example: the first actual current corresponding to the target transmission power of the first antenna used in the current working frequency band is 95mA, and the second reference current corresponding to the target transmission power of the second antenna used in the current working frequency band is 85mA, but the second actual current detected is 100mA. Because the second actual current of 100mA is greater than the first actual current of 95mA, the power consumption of the terminal device is increased instead, and the second antenna is switched back to the first antenna for communication, that is, transmitting the signal. In the present technical solution, because the second actual current corresponding to the target transmission power of the second antenna is greater than the first actual current corresponding to the target transmission power of the first antenna, it is necessary to switch the second antenna to the first antenna for communication again, thereby reducing the power consumption of the terminal device.

407、检测所述第一天线使用所述目标发射功率对应的第四实际电流;在所述第四实际电流小于所述第二实际电流的情况下,继续使用所述第一天线进行通信。407. Detect a fourth actual current corresponding to the target transmit power used by the first antenna; and continue to use the first antenna for communication when the fourth actual current is less than the second actual current.

需要说明的是,步骤407可以上接步骤405或406。It should be noted that step 407 may be followed by step 405 or 406 .

在本技术方案中,因为通常情况下,默认天线是终端设备功耗最小的天线,所以,就算在某些状态下,默认天线的实际电流增大,从而切换到其他天线进行通信,但是也需要隔段时间就切换回默认天线,检测默认天线的当前实际电流是否更优,如果更优,则使用默认天线进行通信,从而,更大程度上保证终端设备使用低功耗的天线进行通信,降低终端设备整机的功耗。In the present technical solution, because under normal circumstances, the default antenna is the antenna with the lowest power consumption of the terminal device, even if the actual current of the default antenna increases under certain conditions, thereby switching to other antennas for communication, it is still necessary to switch back to the default antenna at intervals to detect whether the current actual current of the default antenna is better. If it is better, the default antenna is used for communication, thereby ensuring to a greater extent that the terminal device uses a low-power antenna for communication and reducing the power consumption of the entire terminal device.

需要说明的是,在本申请实施例中,步骤405-407为可选的步骤。It should be noted that in the embodiment of the present application, steps 405-407 are optional steps.

在上述示例说明中,都是以支持当前工作频段的天线包括第一天线和第二天线为例进行说明的,下面以支持当前工作频段的天线包括第一天线、第二天线和第三天线为例进行说明,如下所示:In the above example description, the antenna supporting the current working frequency band includes the first antenna and the second antenna. The following example describes the antenna supporting the current working frequency band including the first antenna, the second antenna and the third antenna, as shown below:

在一种实现方式中,所述多个天线包括所述第一天线、所述第二天线和第三天线,所述方法还可以包括:在所述第二实际电流大于第一实际电流的情况下,将所述第二天线切换为所述第三天线,使用所述第三天线进行通信,所述第三天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线。In one implementation, the multiple antennas include the first antenna, the second antenna and the third antenna, and the method may also include: when the second actual current is greater than the first actual current, switching the second antenna to the third antenna, using the third antenna for communication, the third antenna being an antenna among the multiple antennas that supports the current working frequency band, and using an antenna whose reference current corresponding to the target transmit power is less than the first actual current.

示例性的,因为多个天线包括了第一天线、第二天线和第三天线。在从默认的第一天线的第一实际电流满足预设条件的情况下,将第一天线切换为第二天线进行通信时,还会检测使用第二天线的第二实际电流,在第二实际电流大于第一实际电流的情况下,还可以将第二天线切换为第三天线进行通信。Exemplarily, because the multiple antennas include a first antenna, a second antenna, and a third antenna, when the first actual current of the default first antenna meets a preset condition, when the first antenna is switched to the second antenna for communication, the second actual current using the second antenna is also detected, and when the second actual current is greater than the first actual current, the second antenna can also be switched to the third antenna for communication.

在本技术方案中,因为第三天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线,所以,在使用第一天线和第二天线进行通信的实际功耗都比较大的情况下,可以切换为第三天线进行通信,从而降低终端设备的功耗。In the present technical solution, because the third antenna is an antenna among the multiple antennas that supports the current working frequency band and uses a reference current corresponding to the target transmission power that is less than the first actual current, when the actual power consumption of using the first antenna and the second antenna for communication is relatively large, the third antenna can be switched to communicate, thereby reducing the power consumption of the terminal device.

在一种实现方式中,所述多个天线包括所述第一天线、所述第二天线和第三天线,所述方法还可以包括:在所述第二实际电流大于第一实际电流的情况下,将所述第二天线切换为所述第一天线,使用所述第一天线进行通信;检测所述第一天线使用所述目标发射功率对应的第四实际电流;在所述第四实际电流大于所述第一实际电流的情况下,将所述第一天线切换为所述第三天线,使用所述第三天线进行通信,所述第三天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线。In one implementation, the multiple antennas include the first antenna, the second antenna and the third antenna, and the method may also include: when the second actual current is greater than the first actual current, switching the second antenna to the first antenna, and using the first antenna for communication; detecting that the first antenna uses a fourth actual current corresponding to the target transmit power; when the fourth actual current is greater than the first actual current, switching the first antenna to the third antenna, and using the third antenna for communication, the third antenna being an antenna among the multiple antennas that supports the current working frequency band, and using an antenna whose reference current corresponding to the target transmit power is less than the first actual current.

本申请实施例中以默认天线为第一天线为例进行说明。在本技术方案中,因为通常情况下,默认天线是终端设备功耗最小的天线,所以,就算在某些状态下,默认天线的实际电流增大,从而切换到其他天线进行通信,但是,在其他天线的实际电流大于默认天线的实际电流的情况下,就算当前工作频段还支持其他天线,也需要先切换回默认天线,检测此时的默认天线的实际电流是否变化,如果变化的更优,则使用默认天线进行通信,如果还是没变化,或者实际电流还比较大,可以切换到第三天线进行通信,而第三天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于第一实际电流的天线,从而更大程度上保证终端设备使用低功耗的天线进行通信,降低终端设备整机的功耗。In the embodiment of the present application, the default antenna is taken as the first antenna as an example for explanation. In this technical solution, because the default antenna is usually the antenna with the lowest power consumption of the terminal device, even if the actual current of the default antenna increases in certain states, it is switched to other antennas for communication. However, when the actual current of other antennas is greater than the actual current of the default antenna, even if the current working frequency band still supports other antennas, it is necessary to switch back to the default antenna first, and detect whether the actual current of the default antenna at this time has changed. If the change is better, the default antenna is used for communication. If there is still no change, or the actual current is still relatively large, it can be switched to the third antenna for communication, and the third antenna is an antenna among the multiple antennas that supports the current working frequency band, and the reference current corresponding to the target transmit power is less than the first actual current. The antenna, thereby ensuring to a greater extent that the terminal device uses a low-power antenna for communication, reduces the power consumption of the entire terminal device.

在一种实现方式中,不管是从上述的第二天线切换到第三天线进行通信后,还是从第一天线切换到第三天线进行通信后,所述方法还可以包括:检测所述第三天线使用所述目标发射功率对应的第三实际电流;在所述第三实际电流小于所述第一实际电流的情况下,继续使用所述第三天线进行通信。In one implementation, regardless of whether it is after switching from the second antenna to the third antenna for communication, or after switching from the first antenna to the third antenna for communication, the method may also include: detecting a third actual current corresponding to the target transmit power used by the third antenna; and continuing to use the third antenna for communication when the third actual current is less than the first actual current.

在本技术方案中,在切换到第三天线进行通信后,还可以检测第三天线使用目标发射功率对应的第三实际电流,在第三天线对应的第三实际电流小于第一天线的第一实际电流的情况下,可以继续使用第三天线进行通信,从而更大程度上保证终端设备使用低功耗的天线进行通信,降低终端设备整机的功耗。In the present technical solution, after switching to the third antenna for communication, the third actual current corresponding to the target transmission power used by the third antenna can also be detected. When the third actual current corresponding to the third antenna is less than the first actual current of the first antenna, the third antenna can continue to be used for communication, thereby ensuring to a greater extent that the terminal device uses a low-power antenna for communication and reducing the power consumption of the entire terminal device.

在一种实现方式中,所述第三天线为所述多个天线中支持在所述当前工作频段的天线内,除所述第一天线和所述第二天线外使用所述目标发射功率对应的参考电流最小的天线。在本技术方案中,因为第三天线的参考电流是除第一天线和第二天线外最小的,所以,理论上终端设备的功耗也是最低的,可以最大程度上降低终端设备整机的功耗。In one implementation, the third antenna is an antenna that supports the current working frequency band among the multiple antennas and uses the smallest reference current corresponding to the target transmit power except for the first antenna and the second antenna. In this technical solution, because the reference current of the third antenna is the smallest except for the first antenna and the second antenna, theoretically, the power consumption of the terminal device is also the lowest, which can reduce the power consumption of the entire terminal device to the greatest extent.

需要说明的是,上述以支持当前工作频段的天线包括两支天线和三支天线为例进行说明的,如果支持当前工作频段的天线包括更多的天线的实现方式,还可以参考上述三支天线的切换方法,来降低终端设备的整机功耗,在此就不一一赘述了。It should be noted that the above description uses the example of supporting two antennas and three antennas for the current working frequency band. If the antenna supporting the current working frequency band includes more antennas, you can also refer to the switching method of the above three antennas to reduce the overall power consumption of the terminal device, which will not be elaborated here.

如图5所示,为本申请实施例中天线切换的方法的一个流程示意图。终端设备需要先建立网络连接,然后使用默认天线进行发射;记录使用默认天线的当前发射功率和对应PA的第一实际电流,在第一实际电流满足预设条件的情况下,切换到其他天线进行发射,检测其他天线的实际电流;再切换回默认天线,检测默认天线对应PA的第四实际电流,在其他天线的实际电流大于第四实际电流的情况下,使用默认天线进行通信,在其他天线的实际电流小于第四实际电流的情况下,切换回其他天线进行通信。As shown in Figure 5, it is a flow chart of the antenna switching method in the embodiment of the present application. The terminal device needs to establish a network connection first, and then use the default antenna for transmission; record the current transmission power of the default antenna and the first actual current of the corresponding PA, and when the first actual current meets the preset conditions, switch to other antennas for transmission and detect the actual current of other antennas; then switch back to the default antenna, detect the fourth actual current of the PA corresponding to the default antenna, and when the actual current of the other antenna is greater than the fourth actual current, use the default antenna for communication, and when the actual current of the other antenna is less than the fourth actual current, switch back to other antennas for communication.

在一种实现方式中,所述天线切换的方法应用在终端设备出厂前的测试场景中。In one implementation, the antenna switching method is applied in a test scenario of a terminal device before it leaves the factory.

在本技术方案中,天线切换的方法不局限于终端设备在功耗方面的优化应用,同样也适用于在生产线终端设备的天线装配性能测试。终端设备在出厂前需要测试整机的天线性能,目前主流测试方案是通过仪表耦合测试;在本技术方案中,还可以通过发射预定发射功率,测试终端设备当前天线的PA电流,对比预先设定的标准样机电流,可以判断天线是否装配成功,以及天线性能是否达到预定标准。使用本技术方案,终端设备可以单机完成测试,从而节约仪表测试成本,同时也无需和仪表通信,测试效率更高,减少测试时间成本。In this technical solution, the antenna switching method is not limited to the optimization application of terminal equipment in terms of power consumption, but is also applicable to the antenna assembly performance test of terminal equipment on the production line. The terminal equipment needs to test the antenna performance of the whole machine before leaving the factory. The current mainstream test solution is to test through instrument coupling; in this technical solution, it is also possible to test the PA current of the current antenna of the terminal equipment by transmitting a predetermined transmission power and comparing it with the pre-set standard prototype current to determine whether the antenna is successfully assembled and whether the antenna performance meets the predetermined standard. Using this technical solution, the terminal equipment can complete the test on a single machine, thereby saving the instrument testing cost. At the same time, there is no need to communicate with the instrument, the test efficiency is higher, and the test time cost is reduced.

在本申请实施例中,提供一种天线切换的方法,所述方法应用于终端设备,所述终端设备包括多个天线,所述方法可以包括:检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流;在所述第一实际电流满足预设条件的情况下,将所述第一天线切换为第二天线,使用所述第二天线进行通信,所述第二天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线;检测所述第二天线使用所述目标发射功率对应的第二实际电流;在所述第二实际电流小于所述第一实际电流的情况下,继续使用所述第二天线进行通信;其中,所述多个天线包括所述第一天线和所述第二天线。用于在当前工作频段使用的第一天线的第一实际电流满足预设条件的情况下,可以将第一天线切换为第二天线进行通信,因为第二天线的参考电流小于第一实际电流,从而理论上可以降低终端设备的功耗,进一步还可以检测使用第二天线对应的第二实际电流,在第二实际电流小于第一实际电流的情况下,使用第二电流进行通信可以降低终端设备的功耗。与相关技术方案相比,目前在整机这块未有比较好的优化功耗措施,使用本申请技术方案后,可以根据仿真的参考电流和测量的实际电流,在不同状态时的功耗可能会有20-150mA的差异变化,尤其是在横屏玩游戏等弱网场景体现的越发明显,可解决特殊场景下终端设备功耗、温升等方面的问题,可以大幅提升用户的体验。In an embodiment of the present application, a method for antenna switching is provided, the method is applied to a terminal device, the terminal device includes multiple antennas, the method may include: detecting the target transmission power and the corresponding first actual current of the first antenna used in the current working frequency band; when the first actual current meets the preset condition, switching the first antenna to the second antenna, using the second antenna for communication, the second antenna being an antenna among the multiple antennas that supports the current working frequency band and uses a reference current corresponding to the target transmission power that is less than the first actual current; detecting the second antenna using the second actual current corresponding to the target transmission power; when the second actual current is less than the first actual current, continuing to use the second antenna for communication; wherein the multiple antennas include the first antenna and the second antenna. When the first actual current of the first antenna used in the current working frequency band meets the preset condition, the first antenna may be switched to the second antenna for communication, because the reference current of the second antenna is less than the first actual current, thereby theoretically reducing the power consumption of the terminal device, and further detecting the second actual current corresponding to the use of the second antenna, when the second actual current is less than the first actual current, using the second current for communication can reduce the power consumption of the terminal device. Compared with related technical solutions, there are currently no better measures to optimize power consumption for the entire machine. After using the technical solution of this application, the power consumption in different states may vary by 20-150mA based on the simulated reference current and the measured actual current, especially in weak network scenarios such as playing games in horizontal mode. It can solve problems such as power consumption and temperature rise of terminal devices in special scenarios, and can greatly improve the user experience.

如图6所示,为本申请实施例中天线切换的装置的一个实施例示意图,所述装置应用于终端设备,所述终端设备包括多个天线,所述装置包括:As shown in FIG6 , it is a schematic diagram of an embodiment of an antenna switching device in an embodiment of the present application, the device is applied to a terminal device, the terminal device includes multiple antennas, and the device includes:

检测模块601,用于检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流;A detection module 601 is used to detect a target transmission power of a first antenna used in a current working frequency band and a corresponding first actual current;

切换模块602,用于在所述第一实际电流大于第一预设电流的情况下,将所述第一天线切换为第二天线,通信模块603,用于使用所述第二天线进行通信,所述第二天线使用所述目标发射功率对应的参考电流小于所述第一实际电流;其中,所述多个天线包括所述第一天线和所述第二天线。A switching module 602 is used to switch the first antenna to the second antenna when the first actual current is greater than a first preset current, and a communication module 603 is used to use the second antenna for communication, and the reference current corresponding to the target transmission power used by the second antenna is less than the first actual current; wherein the multiple antennas include the first antenna and the second antenna.

可选的,在一种实现方式中,检测模块601,还用于检测所述第二天线使用所述目标发射功率对应的第二实际电流;Optionally, in one implementation, the detection module 601 is further used to detect a second actual current corresponding to the target transmit power used by the second antenna;

通信模块603,还用于在所述第二实际电流小于所述第一实际电流的情况下,继续使用所述第二天线进行通信。The communication module 603 is further configured to continue using the second antenna for communication when the second actual current is less than the first actual current.

可选的,在一种实现方式中,所述第二天线为所述多个天线中支持在所述当前工作频段的天线内,除所述第一天线外使用所述目标发射功率对应的参考电流最小的天线。Optionally, in one implementation, the second antenna is an antenna among the multiple antennas that supports the current working frequency band and uses the smallest reference current corresponding to the target transmit power except the first antenna.

可选的,在一种实现方式中,检测模块601,具体用于检测当前工作频段使用的第一天线的目标发射功率,通过电流检测模块检测所述目标发射功率对应的第一实际电流。Optionally, in one implementation, the detection module 601 is specifically configured to detect a target transmit power of a first antenna used in a current working frequency band, and detect a first actual current corresponding to the target transmit power through a current detection module.

可选的,在一种实现方式中,所述射频系统包括射频电源、电源管理集成电路PMIC和电流检测模块,所述电流检测模块内置在所述射频电源中,或,所述电流检测模块内置在所述PMIC中,或,所述电流检测模块连接在所述射频电源和所述PMIC之间。Optionally, in one implementation, the RF system includes an RF power supply, a power management integrated circuit PMIC and a current detection module, the current detection module is built into the RF power supply, or, the current detection module is built into the PMIC, or, the current detection module is connected between the RF power supply and the PMIC.

可选的,在一种实现方式中,所述第一天线和所述第二天线为自由空间状态下所述当前工作频段支持的天线;或者,Optionally, in an implementation manner, the first antenna and the second antenna are antennas supported by the current working frequency band in a free space state; or,

所述第一天线为自由空间状态下所述当前工作频段支持的天线,所述第二天线为目标状态下所述当前工作频段支持的天线,所述目标状态为自由空间状态,手握状态,横屏状态,或,充电状态。The first antenna is an antenna supported by the current working frequency band in a free space state, and the second antenna is an antenna supported by the current working frequency band in a target state, and the target state is a free space state, a hand-held state, a horizontal screen state, or a charging state.

可选的,在一种实现方式中,切换模块602,具体用于在所述第一实际电流满足预设条件,且当前处于目标状态的情况下,选择所述第二天线,将所述第一天线切换为所述第二天线,所述第二天线为所述多个天线中支持在所述当前工作频段的天线内,所述目标状态下使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线。Optionally, in one implementation, the switching module 602 is specifically used to select the second antenna and switch the first antenna to the second antenna when the first actual current meets a preset condition and is currently in a target state, the second antenna being an antenna among the multiple antennas that supports the current working frequency band and an antenna whose reference current corresponding to the target transmission power used in the target state is less than the first actual current.

可选的,在一种实现方式中,切换模块602,还用于在所述第二实际电流大于所述第一实际电流的情况下,将所述第二天线切换为所述第一天线,通信模块603,还用于使用所述第一天线进行通信;Optionally, in one implementation, the switching module 602 is further configured to switch the second antenna to the first antenna when the second actual current is greater than the first actual current, and the communication module 603 is further configured to use the first antenna for communication;

或,or,

处理器780,还用于在使用所述第二天线进行通信的时长超过预设时长的情况下,将所述第二天线切换为所述第一天线,通信模块603,还用于使用所述第一天线进行通信。The processor 780 is further configured to switch the second antenna to the first antenna when the duration of using the second antenna for communication exceeds a preset duration. The communication module 603 is further configured to use the first antenna for communication.

可选的,在一种实现方式中,所述多个天线包括所述第一天线、所述第二天线和第三天线,Optionally, in an implementation manner, the multiple antennas include the first antenna, the second antenna, and a third antenna.

切换模块602,还用于在所述第二实际电流大于第一实际电流的情况下,将所述第二天线切换为所述第三天线,通信模块603,还用于使用所述第三天线进行通信,所述第三天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线。The switching module 602 is also used to switch the second antenna to the third antenna when the second actual current is greater than the first actual current. The communication module 603 is also used to use the third antenna for communication. The third antenna is an antenna among the multiple antennas that supports the current working frequency band and uses a reference current corresponding to the target transmission power that is less than the first actual current.

可选的,在一种实现方式中,检测模块601,还用于检测所述第三天线使用所述目标发射功率对应的第四实际电流;Optionally, in one implementation, the detection module 601 is further used to detect a fourth actual current corresponding to the target transmit power used by the third antenna;

通信模块603,还用于在所述第四实际电流小于所述第三实际电流的情况下,继续使用所述第三天线进行通信。The communication module 603 is further configured to continue using the third antenna for communication when the fourth actual current is less than the third actual current.

可选的,在一种实现方式中,所述第三天线为所述多个天线中支持在所述当前工作频段的天线内,除所述第一天线和所述第二天线外使用所述目标发射功率对应的参考电流最小的天线。Optionally, in one implementation, the third antenna is an antenna among the multiple antennas that supports the current working frequency band and uses the smallest reference current corresponding to the target transmit power except the first antenna and the second antenna.

可选的,在一种实现方式中,所述多个天线包括所述第一天线、所述第二天线和第三天线,Optionally, in an implementation manner, the multiple antennas include the first antenna, the second antenna, and a third antenna.

切换模块602,还用于在所述第二实际电流大于第一实际电流的情况下,将所述第二天线切换为所述第一天线,通信模块603,还用于使用所述第一天线进行通信;The switching module 602 is further used to switch the second antenna to the first antenna when the second actual current is greater than the first actual current, and the communication module 603 is further used to use the first antenna for communication;

检测模块601,还用于检测所述第一天线使用所述目标发射功率对应的第三实际电流;The detection module 601 is further used to detect a third actual current corresponding to the target transmit power used by the first antenna;

切换模块602,还用于在所述第三实际电流大于所述第二实际电流的情况下,将所述第一天线切换为所述第三天线,通信模块603,还用于使用所述第三天线进行通信,所述第三天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线。The switching module 602 is also used to switch the first antenna to the third antenna when the third actual current is greater than the second actual current. The communication module 603 is also used to use the third antenna for communication. The third antenna is an antenna among the multiple antennas that supports the current working frequency band and uses a reference current corresponding to the target transmission power that is less than the first actual current.

如图7A所示,为本申请实施例中终端设备的一个实施例示意图,可以包括如图6所示的天线切换的装置。As shown in FIG. 7A , it is a schematic diagram of an embodiment of a terminal device in an embodiment of the present application, which may include an antenna switching device as shown in FIG. 6 .

如图7B所示,为本申请实施例中终端设备的另一个实施例示意图。下面结合图7B对终端设备中的手机的各个构成部件进行具体的介绍:As shown in FIG7B , it is a schematic diagram of another embodiment of the terminal device in the embodiment of the present application. The following is a detailed introduction to the various components of the mobile phone in the terminal device in conjunction with FIG7B :

RF电路710可用于收发信息或通话过程中,信号的接收和发送,特别地,将基站的下行信息接收后,给处理器780处理;另外,将设计上行的数据发送给基站。通常,RF电路710包括但不限于天线、至少一个放大器、收发信机、耦合器、低噪声放大器(Low NoiseAmplifier,LNA)、双工器等。此外,RF电路710还可以通过无线通信与网络和其他设备通信。上述无线通信可以使用任一通信标准或协议,包括但不限于全球移动通讯系统(GlobalSystem of Mobile communication,GSM)、通用分组无线服务(General Packet RadioService,GPRS)、码分多址(Code Division Multiple Access,CDMA)、宽带码分多址(Wideband Code Division Multiple Access,WCDMA)、长期演进(Long Term Evolution,LTE)、电子邮件、短消息服务(Short Messaging Service,SMS)等。The RF circuit 710 can be used for receiving and sending signals during information transmission or calls. In particular, after receiving the downlink information of the base station, it is sent to the processor 780 for processing; in addition, the designed uplink data is sent to the base station. Generally, the RF circuit 710 includes but is not limited to an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier (Low Noise Amplifier, LNA), a duplexer, etc. In addition, the RF circuit 710 can also communicate with the network and other devices through wireless communication. The above wireless communication can use any communication standard or protocol, including but not limited to the Global System of Mobile communication (Global System of Mobile communication, GSM), General Packet Radio Service (General Packet Radio Service, GPRS), Code Division Multiple Access (Code Division Multiple Access, CDMA), Wideband Code Division Multiple Access (Wideband Code Division Multiple Access, WCDMA), Long Term Evolution (Long Term Evolution, LTE), email, Short Messaging Service (SMS), etc.

存储器720可用于存储软件程序以及模块,处理器780通过运行存储在存储器720的软件程序以及模块,从而执行手机的各种功能应用以及数据处理。存储器720可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据手机的使用所创建的数据(比如音频数据、电话本等)等。此外,存储器720可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。The memory 720 can be used to store software programs and modules. The processor 780 executes various functional applications and data processing of the mobile phone by running the software programs and modules stored in the memory 720. The memory 720 can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area can store data created according to the use of the mobile phone (such as audio data, a phone book, etc.), etc. In addition, the memory 720 can include a high-speed random access memory, and can also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.

输入单元730可用于接收输入的数字或字符信息,以及产生与手机的用户设置以及功能控制有关的键信号输入。具体地,输入单元730可包括触控面板731以及其他输入设备732。触控面板731,也称为触摸屏,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触控面板731上或在触控面板731附近的操作),并根据预先设定的程式驱动相应的连接装置。可选的,触控面板731可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器780,并能接收处理器780发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触控面板731。除了触控面板731,输入单元730还可以包括其他输入设备732。具体地,其他输入设备732可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆等中的一种或多种。The input unit 730 can be used to receive input digital or character information, and to generate key signal input related to the user settings and function control of the mobile phone. Specifically, the input unit 730 may include a touch panel 731 and other input devices 732. The touch panel 731, also known as a touch screen, can collect the user's touch operation on or near it (such as the user's operation on the touch panel 731 or near the touch panel 731 using any suitable object or accessory such as a finger, stylus, etc.), and drive the corresponding connection device according to a pre-set program. Optionally, the touch panel 731 may include two parts: a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch orientation, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and then sends it to the processor 780, and can receive and execute commands sent by the processor 780. In addition, the touch panel 731 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves. In addition to the touch panel 731, the input unit 730 may further include other input devices 732. Specifically, the other input devices 732 may include but are not limited to one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like.

显示单元740可用于显示由用户输入的信息或提供给用户的信息以及手机的各种菜单。显示单元740可包括显示面板741,可选的,可以采用液晶显示器(Liquid CrystalDisplay,LCD)、有机发光二极管(Organic Light-Emitting Diode,OLED)等形式来配置显示面板741。进一步的,触控面板731可覆盖显示面板741,当触控面板731检测到在其上或附近的触摸操作后,传送给处理器780以确定触摸事件的类型,随后处理器780根据触摸事件的类型在显示面板741上提供相应的视觉输出。虽然在图7B中,触控面板731与显示面板741是作为两个独立的部件来实现手机的输入和输入功能,但是在某些实施例中,可以将触控面板731与显示面板741集成而实现手机的输入和输出功能。The display unit 740 can be used to display information input by the user or information provided to the user and various menus of the mobile phone. The display unit 740 may include a display panel 741, and optionally, the display panel 741 may be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), etc. Further, the touch panel 731 may cover the display panel 741, and when the touch panel 731 detects a touch operation on or near it, it is transmitted to the processor 780 to determine the type of the touch event, and then the processor 780 provides a corresponding visual output on the display panel 741 according to the type of the touch event. Although in FIG. 7B, the touch panel 731 and the display panel 741 are used as two independent components to realize the input and output functions of the mobile phone, in some embodiments, the touch panel 731 and the display panel 741 can be integrated to realize the input and output functions of the mobile phone.

手机还可包括至少一种传感器750,比如光传感器、运动传感器以及其他传感器。具体地,光传感器可包括环境光传感器及接近传感器,其中,环境光传感器可根据环境光线的明暗来调节显示面板741的亮度,接近传感器可在手机移动到耳边时,关闭显示面板741和/或背光。作为运动传感器的一种,加速计传感器可检测各个方向上(一般为三轴)加速度的大小,静止时可检测出重力的大小及方向,可用于识别手机姿态的应用(比如横竖屏切换、相关游戏、磁力计姿态校准)、振动识别相关功能(比如计步器、敲击)等;至于手机还可配置的陀螺仪、气压计、湿度计、温度计、红外线传感器等其他传感器,在此不再赘述。The mobile phone may also include at least one sensor 750, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel 741 according to the brightness of the ambient light, and the proximity sensor may turn off the display panel 741 and/or the backlight when the mobile phone is moved to the ear. As a type of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in all directions (generally three axes), and can detect the magnitude and direction of gravity when stationary. It can be used for applications that identify the posture of the mobile phone (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer, tapping), etc.; as for other sensors that can be configured in the mobile phone, such as gyroscopes, barometers, hygrometers, thermometers, infrared sensors, etc., they will not be repeated here.

音频电路760、扬声器761,传声器762可提供用户与手机之间的音频接口。音频电路760可将接收到的音频数据转换后的电信号,传输到扬声器761,由扬声器761转换为声音信号输出;另一方面,传声器762将收集的声音信号转换为电信号,由音频电路760接收后转换为音频数据,再将音频数据输出处理器780处理后,经RF电路710以发送给比如另一手机,或者将音频数据输出至存储器720以便进一步处理。The audio circuit 760, the speaker 761, and the microphone 762 can provide an audio interface between the user and the mobile phone. The audio circuit 760 can transmit the received audio data to the speaker 761 after converting the received audio data into an electrical signal, which is converted into a sound signal for output; on the other hand, the microphone 762 converts the collected sound signal into an electrical signal, which is received by the audio circuit 760 and converted into audio data, and then the audio data is output to the processor 780 for processing, and then sent to another mobile phone through the RF circuit 710, or the audio data is output to the memory 720 for further processing.

Wi-Fi属于短距离无线传输技术,手机通过Wi-Fi模块770可以帮助用户收发电子邮件、浏览网页和访问流式媒体等,它为用户提供了无线的宽带互联网访问。虽然图7B示出了Wi-Fi模块770,但是可以理解的是,其并不属于手机的必须构成,完全可以根据需要在不改变发明的本质的范围内而省略。Wi-Fi is a short-range wireless transmission technology. The mobile phone can help users send and receive emails, browse web pages, and access streaming media through the Wi-Fi module 770, which provides users with wireless broadband Internet access. Although FIG. 7B shows the Wi-Fi module 770, it is understandable that it is not a necessary component of the mobile phone and can be omitted as needed without changing the essence of the invention.

处理器780是手机的控制中心,利用各种接口和线路连接整个手机的各个部分,通过运行或执行存储在存储器720内的软件程序和/或模块,以及调用存储在存储器720内的数据,执行手机的各种功能和处理数据,从而对手机进行整体监控。可选的,处理器780可包括一个或多个处理单元;优选的,处理器780可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器780中。The processor 780 is the control center of the mobile phone. It uses various interfaces and lines to connect various parts of the entire mobile phone. By running or executing software programs and/or modules stored in the memory 720, and calling data stored in the memory 720, it executes various functions of the mobile phone and processes data, thereby monitoring the mobile phone as a whole. Optionally, the processor 780 may include one or more processing units; preferably, the processor 780 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 780.

手机还包括给各个部件供电的电源790(比如电池),优选的,电源可以通过电源管理系统与处理器780逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。The mobile phone also includes a power supply 790 (such as a battery) for supplying power to various components. Preferably, the power supply can be logically connected to the processor 780 through a power management system, so that the power management system can manage charging, discharging, power consumption and other functions.

尽管未示出,手机还可以包括摄像头、蓝牙模块等,在此不再赘述。Although not shown, the mobile phone may also include a camera, a Bluetooth module, etc., which will not be described in detail here.

在本申请实施例中,所述终端设备包括多个天线;In an embodiment of the present application, the terminal device includes multiple antennas;

处理器780,用于检测当前工作频段使用的第一天线的目标发射功率和对应的第一实际电流;Processor 780, configured to detect a target transmit power of a first antenna used in a current working frequency band and a corresponding first actual current;

处理器780,用于在所述第一实际电流大于第一预设电流的情况下,将所述第一天线切换为第二天线,RF电路710,用于使用所述第二天线进行通信,所述第二天线使用所述目标发射功率对应的参考电流小于所述第一实际电流;其中,所述多个天线包括所述第一天线和所述第二天线。The processor 780 is used to switch the first antenna to the second antenna when the first actual current is greater than the first preset current, and the RF circuit 710 is used to use the second antenna for communication, and the reference current corresponding to the target transmission power used by the second antenna is less than the first actual current; wherein the multiple antennas include the first antenna and the second antenna.

可选的,在一种实现方式中,处理器780,还用于检测所述第二天线使用所述目标发射功率对应的第二实际电流;Optionally, in one implementation, the processor 780 is further configured to detect a second actual current corresponding to the target transmit power used by the second antenna;

RF电路710,还用于在所述第二实际电流小于所述第一实际电流的情况下,继续使用所述第二天线进行通信。The RF circuit 710 is further configured to continue using the second antenna for communication when the second actual current is less than the first actual current.

可选的,在一种实现方式中,所述第二天线为所述多个天线中支持在所述当前工作频段的天线内,除所述第一天线外使用所述目标发射功率对应的参考电流最小的天线。Optionally, in one implementation, the second antenna is an antenna among the multiple antennas that supports the current working frequency band and uses the smallest reference current corresponding to the target transmit power except the first antenna.

可选的,在一种实现方式中,处理器780,具体用于检测当前工作频段使用的第一天线的目标发射功率,通过电流检测模块检测所述目标发射功率对应的第一实际电流。Optionally, in one implementation, the processor 780 is specifically configured to detect a target transmit power of a first antenna used in a current operating frequency band, and detect a first actual current corresponding to the target transmit power through a current detection module.

可选的,在一种实现方式中,所述射频系统包括射频电源、电源管理集成电路PMIC和电流检测模块,所述电流检测模块内置在所述射频电源中,或,所述电流检测模块内置在所述PMIC中,或,所述电流检测模块连接在所述射频电源和所述PMIC之间。Optionally, in one implementation, the RF system includes an RF power supply, a power management integrated circuit PMIC and a current detection module, the current detection module is built into the RF power supply, or, the current detection module is built into the PMIC, or, the current detection module is connected between the RF power supply and the PMIC.

可选的,在一种实现方式中,所述第一天线和所述第二天线为自由空间状态下所述当前工作频段支持的天线;或者,Optionally, in an implementation manner, the first antenna and the second antenna are antennas supported by the current working frequency band in a free space state; or,

所述第一天线为自由空间状态下所述当前工作频段支持的天线,所述第二天线为目标状态下所述当前工作频段支持的天线,所述目标状态为自由空间状态,手握状态,横屏状态,或,充电状态。The first antenna is an antenna supported by the current working frequency band in a free space state, and the second antenna is an antenna supported by the current working frequency band in a target state, and the target state is a free space state, a hand-held state, a horizontal screen state, or a charging state.

可选的,在一种实现方式中,处理器780,具体用于在所述第一实际电流满足预设条件,且当前处于目标状态的情况下,选择所述第二天线,将所述第一天线切换为所述第二天线,所述第二天线为所述多个天线中支持在所述当前工作频段的天线内,所述目标状态下使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线。Optionally, in one implementation, the processor 780 is specifically used to select the second antenna and switch the first antenna to the second antenna when the first actual current meets a preset condition and is currently in a target state, the second antenna being an antenna among the multiple antennas that supports the current operating frequency band, and an antenna whose reference current corresponding to the target transmission power used in the target state is less than the first actual current.

可选的,在一种实现方式中,处理器780,还用于在所述第二实际电流大于所述第一实际电流的情况下,将所述第二天线切换为所述第一天线,RF电路710,还用于使用所述第一天线进行通信;Optionally, in one implementation, the processor 780 is further configured to switch the second antenna to the first antenna when the second actual current is greater than the first actual current, and the RF circuit 710 is further configured to use the first antenna for communication;

或,or,

处理器780,还用于在使用所述第二天线进行通信的时长超过预设时长的情况下,将所述第二天线切换为所述第一天线,使用所述第一天线进行通信。可选的,在一种实现方式中,所述多个天线包括所述第一天线、所述第二天线和第三天线,The processor 780 is further configured to switch the second antenna to the first antenna and use the first antenna for communication when the duration of using the second antenna for communication exceeds a preset duration. Optionally, in one implementation, the multiple antennas include the first antenna, the second antenna, and the third antenna.

处理器780,还用于在所述第二实际电流大于第一实际电流的情况下,将所述第二天线切换为所述第三天线,RF电路710,还用于使用所述第三天线进行通信,所述第三天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线。The processor 780 is also used to switch the second antenna to the third antenna when the second actual current is greater than the first actual current. The RF circuit 710 is also used to use the third antenna for communication. The third antenna is an antenna among the multiple antennas that supports the current operating frequency band and uses a reference current corresponding to the target transmit power that is less than the first actual current.

可选的,在一种实现方式中,处理器780,还用于检测所述第三天线使用所述目标发射功率对应的第四实际电流;Optionally, in one implementation, the processor 780 is further configured to detect a fourth actual current corresponding to the target transmit power used by the third antenna;

RF电路710,还用于在所述第四实际电流小于所述第三实际电流的情况下,继续使用所述第三天线进行通信。The RF circuit 710 is further configured to continue using the third antenna for communication when the fourth actual current is less than the third actual current.

可选的,在一种实现方式中,所述第三天线为所述多个天线中支持在所述当前工作频段的天线内,除所述第一天线和所述第二天线外使用所述目标发射功率对应的参考电流最小的天线。Optionally, in one implementation, the third antenna is an antenna among the multiple antennas that supports the current working frequency band and uses the smallest reference current corresponding to the target transmit power except the first antenna and the second antenna.

可选的,在一种实现方式中,所述多个天线包括所述第一天线、所述第二天线和第三天线,Optionally, in an implementation manner, the multiple antennas include the first antenna, the second antenna, and a third antenna.

处理器780,还用于在所述第二实际电流大于第一实际电流的情况下,将所述第二天线切换为所述第一天线,RF电路710,还用于使用所述第一天线进行通信;The processor 780 is further configured to switch the second antenna to the first antenna when the second actual current is greater than the first actual current, and the RF circuit 710 is further configured to use the first antenna for communication;

处理器780,还用于检测所述第一天线使用所述目标发射功率对应的第三实际电流;The processor 780 is further configured to detect a third actual current corresponding to the target transmit power used by the first antenna;

处理器780,还用于在所述第三实际电流大于所述第二实际电流的情况下,将所述第一天线切换为所述第三天线,RF电路710,还用于使用所述第三天线进行通信,所述第三天线为所述多个天线中支持在所述当前工作频段的天线内,使用所述目标发射功率对应的参考电流小于所述第一实际电流的天线。The processor 780 is also used to switch the first antenna to the third antenna when the third actual current is greater than the second actual current. The RF circuit 710 is also used to use the third antenna for communication. The third antenna is an antenna among the multiple antennas that supports the current operating frequency band and uses a reference current corresponding to the target transmit power that is less than the first actual current.

在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。所述计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行所述计算机程序指令时,全部或部分地产生按照本申请实施例所述的流程或功能。所述计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。所述计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一计算机可读存储介质传输,例如,所述计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线(Digital Subscriber Line,DSL))或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。所述计算机可读存储介质可以是计算机能够存储的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。所述可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如,DVD)、或者半导体介质(例如固态硬盘(Solid State Disk,SSD))等。In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions can be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (Digital Subscriber Line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium can be any available medium that a computer can store or a data storage device such as a server, data center, etc. that contains one or more available media integrated. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a DVD), or a semiconductor medium (eg, a solid state disk (SSD)).

所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-OnlyMemory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。If the integrated unit 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, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk.

以上所述,以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围。As described above, the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims (15)

1. A method of antenna switching, the method being applied to a radio frequency system, the radio frequency system comprising a plurality of antennas, the method comprising:
detecting target transmitting power and corresponding first actual current of a first antenna used in a current working frequency band;
under the condition that the first actual current meets a preset condition, switching the first antenna into a second antenna, and using the second antenna to communicate, wherein the second antenna is an antenna which is supported in the current working frequency band in the plurality of antennas, and the reference current corresponding to the target transmitting power is smaller than the first actual current;
wherein the plurality of antennas includes the first antenna and the second antenna.
2. The method according to claim 1, wherein the method further comprises:
Detecting a second actual current corresponding to the target transmitting power used by the second antenna;
and continuing to use the second antenna for communication under the condition that the second actual current is smaller than the first actual current.
3. The method according to claim 1 or 2, wherein the second antenna is an antenna, among the plurality of antennas, supported in the current operating frequency band, except for the first antenna, where a reference current corresponding to the target transmit power is the smallest.
4. The method according to claim 1 or 2, wherein detecting the target transmit power and the corresponding first actual current of the first antenna used by the current operating frequency band comprises:
And detecting the target transmitting power of the first antenna used in the current working frequency band, and detecting a first actual current corresponding to the target transmitting power through a current detection module.
5. The method of claim 4, wherein the radio frequency system comprises a radio frequency power supply, a power management integrated circuit PMIC, and a current detection module, the current detection module being built into the radio frequency power supply, or the current detection module being built into the PMIC, or the current detection module being connected between the radio frequency power supply and the PMIC.
6. The method according to claim 1 or 2, wherein the first antenna and the second antenna are antennas supported by the current operating frequency band in a free space state; or alternatively
The first antenna is an antenna supported by the current working frequency band in a free space state, the second antenna is an antenna supported by the current working frequency band in a target state, and the target state is a free space state, a holding state, a horizontal screen state or a charging state.
7. The method of claim 6, wherein switching the first antenna to a second antenna if the first actual current meets a preset condition comprises:
and under the condition that the first actual current meets a preset condition and is in a target state, selecting the second antenna, and switching the first antenna into the second antenna.
8. The method according to claim 2, wherein the method further comprises:
Switching the second antenna to the first antenna and using the first antenna for communication under the condition that the second actual current is larger than the first actual current;
Or alternatively, the first and second heat exchangers may be,
And under the condition that the duration of the communication carried out by using the second antenna exceeds the preset duration, switching the second antenna into the first antenna, and carrying out the communication by using the first antenna.
9. The method of claim 1 or 2, wherein the plurality of antennas includes the first antenna, the second antenna, and a third antenna, the method further comprising:
And under the condition that the second actual current is larger than the first actual current, switching the second antenna into the third antenna, and using the third antenna to communicate, wherein the third antenna is an antenna which is supported in the current working frequency band in the plurality of antennas, and the reference current corresponding to the target transmitting power is smaller than the first actual current.
10. The method according to claim 9, wherein the method further comprises:
detecting a third actual current corresponding to the target transmitting power used by the third antenna;
and continuing to use the third antenna for communication under the condition that the third actual current is smaller than the first actual current.
11. The method of claim 9, wherein the third antenna is an antenna of the plurality of antennas that supports a minimum reference current corresponding to the target transmit power among the antennas in the current operating frequency band, except for the first antenna and the second antenna.
12. The method of claim 1 or 2, wherein the plurality of antennas includes the first antenna, the second antenna, and a third antenna, the method further comprising:
Switching the second antenna to the first antenna under the condition that the second actual current is larger than the first actual current, and using the first antenna to communicate;
detecting a fourth actual current corresponding to the target transmitting power used by the first antenna;
and under the condition that the fourth actual current is larger than the first actual current, switching the first antenna into the third antenna, and using the third antenna to communicate, wherein the third antenna is an antenna which is supported in the current working frequency band in the plurality of antennas, and the reference current corresponding to the target transmitting power is smaller than the first actual current.
13. An apparatus for antenna switching, the apparatus being applied to a radio frequency system, the radio frequency system comprising a plurality of antennas, the apparatus comprising:
The detection module is used for detecting target transmitting power of the first antenna used in the current working frequency band and corresponding first actual current;
The switching module is used for switching the first antenna into a second antenna under the condition that the first actual current is larger than a first preset current, and the communication module is used for communicating by using the second antenna, wherein the reference current corresponding to the target transmitting power used by the second antenna is smaller than the first actual current;
wherein the plurality of antennas includes the first antenna and the second antenna.
14. A terminal device comprising a memory and a processor, the memory storing a computer program executable on the processor, the terminal device implementing the method of any of claims 1-12 when the program is executed.
15. A computer readable storage medium, on which a computer program is stored, which computer program, when being executed by a processor, implements the method according to any of claims 1-12.
CN202410922745.7A 2024-07-08 2024-07-08 Antenna switching method, device, terminal equipment and storage medium Pending CN118783981A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410922745.7A CN118783981A (en) 2024-07-08 2024-07-08 Antenna switching method, device, terminal equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410922745.7A CN118783981A (en) 2024-07-08 2024-07-08 Antenna switching method, device, terminal equipment and storage medium

Publications (1)

Publication Number Publication Date
CN118783981A true CN118783981A (en) 2024-10-15

Family

ID=92989617

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410922745.7A Pending CN118783981A (en) 2024-07-08 2024-07-08 Antenna switching method, device, terminal equipment and storage medium

Country Status (1)

Country Link
CN (1) CN118783981A (en)

Similar Documents

Publication Publication Date Title
EP2869594B1 (en) Method and device for controlling terminal by using headset wire, and apparatus
CN107947825B (en) Antenna selection circuit and mobile terminal
CN107277912B (en) Radio frequency interference processing method, device, storage medium and terminal
CN107896119B (en) Antenna sharing circuit and mobile terminal
CN112311930A (en) Terminal testing method and device, storage medium and mobile terminal
CN108599304A (en) Charging box, charging control method and related product
CN106549464A (en) A charging control method, device and computer equipment
EP3484239A1 (en) Radio frequency control circuit and mobile terminal
CN106413070B (en) Power adjustment method, mobile terminal and computer readable storage medium
WO2017161587A1 (en) Power supply circuit for load, and terminal
CN108429575A (en) antenna switching method, mobile terminal and computer readable storage medium
US20200186173A1 (en) Lte frequency band switching device and method, and mobile terminal
CN108370540A (en) Communication equipment and the method, apparatus for reducing communication equipment power consumption
CN113556427A (en) Mobile terminal radiation recording method and device, mobile terminal and storage medium
CN112040537B (en) SAR fallback method, terminal device and computer readable storage medium
CN107528958B (en) Method for controlling mobile terminal, device, readable storage medium storing program for executing and mobile terminal
CN106453909B (en) Power adjustment method and mobile terminal
CN111211421A (en) Antenna tuning circuit and mobile terminal
CN111313986B (en) Test circuit structure and antenna test method
CN118783981A (en) Antenna switching method, device, terminal equipment and storage medium
CN110620602B (en) Reverse charging and data transmission sharing system, multiplexing data line and electronic device
CN112615630B (en) Circuit and method for improving radio frequency isolation and mobile terminal
CN112486309B (en) Method for determining corresponding duration of idle state, control chip and electronic equipment
CN103618982B (en) Reduce the circuit and method, earphone detection circuit and method, earphone of distal end echo
CN111262599B (en) Method and device for adjusting transmitting power of mobile terminal and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication