[go: up one dir, main page]

CN106506862B - Mobile terminal working mode switching method and mobile terminal - Google Patents

Mobile terminal working mode switching method and mobile terminal Download PDF

Info

Publication number
CN106506862B
CN106506862B CN201611116922.4A CN201611116922A CN106506862B CN 106506862 B CN106506862 B CN 106506862B CN 201611116922 A CN201611116922 A CN 201611116922A CN 106506862 B CN106506862 B CN 106506862B
Authority
CN
China
Prior art keywords
mode
wifi
mobile terminal
working mode
working
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.)
Active
Application number
CN201611116922.4A
Other languages
Chinese (zh)
Other versions
CN106506862A (en
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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp 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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201611116922.4A priority Critical patent/CN106506862B/en
Publication of CN106506862A publication Critical patent/CN106506862A/en
Application granted granted Critical
Publication of CN106506862B publication Critical patent/CN106506862B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality

Landscapes

  • Engineering & Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Telephone Function (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

本发明实施例公开了一种移动终端工作模式切换方法及移动终端,其中的方法包括:加载预设驱动,并运行第一应用服务以开启第一工作模式;检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式;在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。本发明实施例还公开了相应的移动终端。本发明实施例有利于加快移动终端的WiFi工作站模式和WiFi接入点模式两种工作模式之间的切换速度。

The embodiment of the present invention discloses a method for switching working modes of a mobile terminal and a mobile terminal, wherein the method comprises: loading a preset driver and running a first application service to start a first working mode; detecting whether a working mode switching instruction is received, wherein the working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode; when the working mode switching instruction is detected, based on the loaded preset driver, running a second application service to switch the mobile terminal from the first working mode to the second working mode. The embodiment of the present invention also discloses a corresponding mobile terminal. The embodiment of the present invention is conducive to accelerating the switching speed between the two working modes of the mobile terminal, the WiFi workstation mode and the WiFi access point mode.

Description

一种移动终端工作模式切换方法及移动终端A mobile terminal working mode switching method and mobile terminal

技术领域technical field

本发明涉及通信技术领域,具体涉及一种移动终端工作模式切换方法及移动终端。The present invention relates to the field of communication technologies, in particular to a method for switching a working mode of a mobile terminal and a mobile terminal.

背景技术Background technique

WiFi(Wireless Fidelity)是IEEE定义的一个无线网络通信的工业标准(IEEE802.11)。现有技术中具有WiFi功能的移动通信终端(例如手机),其WiFi功能即可以作为WiFi STA(Wireless Fidelity Station,WiFi工作站)来实现,即该移动通信终端工作在WiFi工作站模式下,作为终端连接路由器上网,也可以作为WiFi AP(Wireless FidelityAccess Point,WiFi接入点)来接入其他WiFi STA,即作为接入点为周边设备提供网络接入服务。WiFi (Wireless Fidelity) is an industry standard for wireless network communication (IEEE802.11) defined by IEEE. A mobile communication terminal (such as a mobile phone) with a WiFi function in the prior art, its WiFi function can be implemented as a WiFi STA (Wireless Fidelity Station, WiFi workstation), that is, the mobile communication terminal works in the WiFi workstation mode, and is connected as a terminal. When accessing the Internet, the router can also be used as a WiFi AP (Wireless Fidelity Access Point, WiFi access point) to access other WiFi STAs, that is, as an access point to provide network access services for peripheral devices.

虽然WiFi工作站模式和WiFi接入点模式是两种不同的工作模式,但是WiFi工作站模式和WiFi接入点模式两种工作模式使用的驱动是一样的。目前,移动终端在WiFi工作站模式和WiFi接入点模式两种工作模式之间互相切换时,存在切换速度慢的问题。Although WiFi workstation mode and WiFi access point mode are two different working modes, the drivers used in WiFi workstation mode and WiFi access point mode are the same. At present, when the mobile terminal switches between the two working modes of the WiFi workstation mode and the WiFi access point mode, there is a problem of slow switching speed.

发明内容SUMMARY OF THE INVENTION

本发明实施例提供了一种移动终端工作模式切换方法及移动终端,以期加快移动终端的WiFi工作站模式和WiFi接入点模式两种工作模式之间的切换速度。Embodiments of the present invention provide a method for switching a working mode of a mobile terminal and a mobile terminal, so as to speed up the switching speed between the two working modes of the mobile terminal, the WiFi workstation mode and the WiFi access point mode.

第一方面,本发明实施例提供一种移动终端工作模式切换方法,包括:In a first aspect, an embodiment of the present invention provides a method for switching a working mode of a mobile terminal, including:

加载预设驱动,并运行第一应用服务以开启第一工作模式;Load the default driver, and run the first application service to enable the first working mode;

检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式;Detecting whether a working mode switching instruction is received, where the working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode;

在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。When it is detected that the working mode switching instruction is received, based on the loaded preset driver, a second application service is executed to switch the mobile terminal from the first working mode to the second working mode.

第二方面,本发明实施例提供了一种移动终端,包括:In a second aspect, an embodiment of the present invention provides a mobile terminal, including:

加载单元,用于加载预设驱动,并运行第一应用服务以开启第一工作模式;a loading unit for loading a preset driver and running the first application service to enable the first working mode;

检测单元,用于检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示所述移动终端由所述第一工作模式切换为第二工作模式;a detection unit, configured to detect whether a working mode switching instruction is received, where the working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode;

切换单元,用于在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。a switching unit, configured to run a second application service based on the loaded preset drive to switch the mobile terminal from the first working mode to the first working mode when the working mode switching instruction is detected and received Two working modes.

第三方面,本发明实施例提供了一种移动终端,包括:In a third aspect, an embodiment of the present invention provides a mobile terminal, including:

处理器、存储器、通信接口和通信总线,所述处理器、所述存储器和所述通信接口通过所述通信总线连接并完成相互间的通信;a processor, a memory, a communication interface and a communication bus, the processor, the memory and the communication interface are connected through the communication bus and complete mutual communication;

所述存储器存储有可执行程序代码,所述通信接口用于无线通信;The memory stores executable program codes, and the communication interface is used for wireless communication;

所述处理器用于调用所述存储器中的所述可执行程序代码,执行本发明实施例第一方面任一方法中所描述的部分或全部步骤。The processor is configured to call the executable program code in the memory to execute part or all of the steps described in any method in the first aspect of the embodiments of the present invention.

可以看出,本发明实施例提供的移动终端工作模式切换方法中,移动终端首先加载预设驱动,并运行第一应用服务以开启第一工作模式,然后检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式,在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。可见,由于移动终端工作在两种工作模式时使用的驱动是一样的,移动终端通过实施本发明中的方法能够保证在两种工作模式切换的时候,无需卸载驱动再重新加载驱动,进而加快了移动终端的WiFi工作站模式和WiFi接入点模式两种工作模式之间的切换速度。It can be seen that, in the method for switching the working mode of the mobile terminal provided by the embodiment of the present invention, the mobile terminal first loads the preset driver, runs the first application service to enable the first working mode, and then detects whether the working mode switching instruction is received, so The working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode, and when it is detected that the working mode switching instruction is received, based on the loaded preset drive, and run the second application The service is to make the mobile terminal switch from the first working mode to the second working mode. It can be seen that since the mobile terminal uses the same driver when working in the two working modes, by implementing the method in the present invention, the mobile terminal can ensure that the driver does not need to be unloaded and then reloaded when the two working modes are switched, thereby speeding up the The switching speed between the WiFi workstation mode and WiFi access point mode of the mobile terminal.

附图说明Description of drawings

为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to explain the embodiments of the present invention or the technical solutions in the prior art more clearly, the following briefly introduces the accompanying drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only These are some embodiments of the present invention. For those of ordinary skill in the art, other drawings can also be obtained according to these drawings without creative efforts.

图1是本发明实施例公开的一种移动终端工作模式切换方法的流程示意图;1 is a schematic flowchart of a method for switching a working mode of a mobile terminal disclosed in an embodiment of the present invention;

图2是本发明实施例公开的另一种移动终端工作模式切换方法的流程示意图;2 is a schematic flowchart of another method for switching a working mode of a mobile terminal disclosed in an embodiment of the present invention;

图3是本发明实施例公开的另一种移动终端工作模式切换方法的流程示意图;3 is a schematic flowchart of another method for switching a working mode of a mobile terminal disclosed in an embodiment of the present invention;

图4是本发明实施例公开的另一种移动终端工作模式切换方法的流程示意图;4 is a schematic flowchart of another method for switching a working mode of a mobile terminal disclosed in an embodiment of the present invention;

图5-1是本发明实施例公开的一种移动终端的单元组成框图;FIG. 5-1 is a block diagram of the unit composition of a mobile terminal disclosed in an embodiment of the present invention;

图5-2是本发明实施例公开的另一种移动终端的单元组成框图;FIG. 5-2 is a block diagram of the unit composition of another mobile terminal disclosed in an embodiment of the present invention;

图6是本发明实施例公开的一种移动终端的结构示意图;6 is a schematic structural diagram of a mobile terminal disclosed in an embodiment of the present invention;

图7是本发明实施例公开的另一种移动终端的结构示意图。FIG. 7 is a schematic structural diagram of another mobile terminal disclosed in an embodiment of the present invention.

具体实施方式Detailed ways

为了使本技术领域的人员更好地理解本发明方案,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。In order to make those skilled in the art better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only These are some embodiments of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

本发明的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别不同对象,而不是用于描述特定顺序。此外,术语“包括”和“具有”以及它们任何变形,意图在于覆盖不排他的包含。例如包含了一系列步骤或单元的过程、方法、系统、产品或设备没有限定于已列出的步骤或单元,而是可选地还包括没有列出的步骤或单元,或可选地还包括对于这些过程、方法、产品或设备固有的其他步骤或单元。The terms "first", "second" and the like in the description and claims of the present invention and the above drawings are used to distinguish different objects, rather than to describe a specific order. Furthermore, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or units is not limited to the listed steps or units, but optionally also includes unlisted steps or units, or optionally also includes For other steps or units inherent to these processes, methods, products or devices.

在本文中提及“实施例”意味着,结合实施例描述的特定特征、结构或特性可以包含在本发明的至少一个实施例中。在说明书中的各个位置出现该短语并不一定均是指相同的实施例,也不是与其它实施例互斥的独立的或备选的实施例。本领域技术人员显式地和隐式地理解的是,本文所描述的实施例可以与其它实施例相结合。Reference herein to an "embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the present invention. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor a separate or alternative embodiment that is mutually exclusive of other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.

为了更好理解本发明实施例公开的一种移动终端工作模式切换方法及移动终端,下面对本发明实施例进行详细介绍。In order to better understand a method for switching a working mode of a mobile terminal and a mobile terminal disclosed in the embodiments of the present invention, the embodiments of the present invention are described in detail below.

请参阅图1,图1是本发明实施例提供了一种移动终端工作模式切换方法,如图1所示,本移动终端工作模式切换方法包括:Please refer to FIG. 1. FIG. 1 shows a method for switching a working mode of a mobile terminal according to an embodiment of the present invention. As shown in FIG. 1, the method for switching working modes of a mobile terminal includes:

S101、移动终端加载预设驱动,并运行第一应用服务以开启第一工作模式。S101. The mobile terminal loads a preset driver, and runs a first application service to enable a first working mode.

其中,所述第一工作模式为WiFi工作站模式,所述第二工作模式为WiFi接入点模式;或者,所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式。Wherein, the first working mode is WiFi workstation mode, and the second working mode is WiFi access point mode; or, the first working mode is WiFi access point mode, and the second working mode is WiFi workstation model.

具体地,所述移动终端包括但不限于智能手机(Smart Phone)、平板电脑、笔记本电脑、个人数字助理等便携式电子设备。本移动终端工作模式切换方法也可以应用于包括台式计算机等非移动终端。Specifically, the mobile terminal includes but is not limited to portable electronic devices such as a smart phone (Smart Phone), a tablet computer, a notebook computer, and a personal digital assistant. The method for switching the working mode of a mobile terminal can also be applied to non-mobile terminals such as desktop computers.

其中,工作模式包括WiFi工作站模式或者WiFi接入点模式,WiFi工作站模式指作为客户端连接路由器上网,本领域技术人员可以理解打开WiFi工作站模式是指打开所述终端的WiFi STA(工作站)功能,或者简称为打开WiFi;WiFi接入点模式指作为WiFi接入点(WiFi热点)供其他终端接入,本领域技术人员可以理解打开WiFi接入点模式是指打开所述终端的WiFi AP(接入点)功能,或者简称为打开热点。Wherein, the working mode includes WiFi workstation mode or WiFi access point mode, WiFi workstation mode refers to connecting to the router as a client to surf the Internet, and those skilled in the art can understand that turning on WiFi workstation mode refers to turning on the WiFi STA (workstation) function of the terminal, Or simply turn on WiFi; the WiFi access point mode refers to serving as a WiFi access point (WiFi hotspot) for other terminals to access, and those skilled in the art can understand that opening the WiFi access point mode means opening the WiFi AP (access point) of the terminal. In Point) feature, or simply turn on hotspot.

所述终端在WiFi工作站模式下,具有WiFi STA功能,可以通过其WiFi芯片接入到其他WiFi AP(例如:无线路由器、移动路由器或个人路由器),并向该WiFi AP申请IP地址,以通过WiFi网络访问企业网、因特网或运营商的网络等。所述终端在WiFi接入点模式下,具有WiFi AP功能,其WiFi芯片作为接入点为周边的至少一个WiFi工作站设备提供无线宽带接入服务,以将上述至少一个WiFi工作站设备接入到企业网、因特网或运营商的网络等。In the WiFi workstation mode, the terminal has the WiFi STA function, and can access other WiFi APs (for example: wireless routers, mobile routers or personal routers) through its WiFi chip, and apply for an IP address to the WiFi AP to pass the WiFi The network accesses the corporate network, the Internet, or the operator's network, etc. In the WiFi access point mode, the terminal has a WiFi AP function, and its WiFi chip acts as an access point to provide wireless broadband access services for at least one surrounding WiFi workstation device, so as to access the above at least one WiFi workstation device to the enterprise network, the Internet, or the operator's network, etc.

其中,当所述第一工作模式为WiFi接入点模式时,上述第一应用服务部分参考如下:通过enableSoftAp()配置WiFi热点,Wifi热点首先需要绑定端口信息,再以接入点模式通过NetworkManagementService在wlan0端口下加载固件,同时热点功能也需要HAL层的支持。setWifiApState()会发送广播WifiManager.WIFI_AP_STATE_CHANGED_ACTION,告知当前热点打开的过程信息,可以通过监听广播知晓当前热点打开的过程进行到什么阶段。最后状态切换到SoftApStartingState,如果流程有误,则会重新进入InitialState。首先会判断打开热点时传入的WifiConfiguration对象是否为null;如果为空,则会向WifiApConfigStore发送CMD_REQUEST_AP_CONFIG消息,请求一个热点配置信息。在创建完mWifiApConfigStore对象后,会调用mWifiApConfigStore.loadApConfiguration()加载热点配置信息:主要是从/misc/wifi/softap.conf文件中读取其中的信息,并赋给WifiApConfigStore的成员变量mWifiApConfig,这个变量保存的就是当前SoftAp的配置信息。该文件一开始会有默认的信息保存其中,如果从没配置过热点,拿到的就是系统默认的信息;如果,上层配置了热点,也会将新的配置信息更新到softap.conf中,以供下载再次加载。向WifiStateMachine回复CMD_RESPONSE_AP_CONFIG消息,并附带mWifiApConfig对象。在SoftApStartingState::enter()中,如果config不为空,我们直接去调用startSoftApWithConfig()启动SoftAP;如果一开始config为null,通过处理CMD_RESPONSE_AP_CONFIG,获取到新的config对象,也应该去开启SoftAP了:如果一开始的config对象不为空,从代码可知会先发送CMD_SET_AP_CONFIG消息,通知WifiApConfigStore更新配置信息首先将传入的配置对象保存到mWifiApConfigenter()函数中,会调用writeApConfiguration()将mWifiApConfig的信息更新到/misc/wifi/softap.conf文件中,供下次加载使用,接着给自己发送CMD_SET_AP_CONFIG_COMPLETED消息,告知配置信息更新已经完毕,并重新进入InactiveState,重新等待下次配置信息的更新处理。再返回到WifiStateMachine::SoftApStartingState处理CMD_RESPONSE_AP_CONFIG,如果再次获取后的config依然为null,则通知热点打开失败。Wherein, when the first working mode is the WiFi access point mode, the above-mentioned first application service part refers to the following: configure the WiFi hotspot through enableSoftAp(), the WiFi hotspot first needs to bind the port information, and then pass through the access point mode. The NetworkManagementService loads the firmware under the wlan0 port, and the hotspot function also needs the support of the HAL layer. setWifiApState() will send the broadcast WifiManager.WIFI_AP_STATE_CHANGED_ACTION to inform the current hotspot opening process information. You can know what stage the current hotspot opening process is in by listening to the broadcast. The final state switches to SoftApStartingState, and if the process is wrong, it will re-enter InitialState. First, it will determine whether the WifiConfiguration object passed in when opening the hotspot is null; if it is null, it will send a CMD_REQUEST_AP_CONFIG message to WifiApConfigStore to request a hotspot configuration information. After the mWifiApConfigStore object is created, mWifiApConfigStore.loadApConfiguration() will be called to load the hotspot configuration information: mainly read the information from the /misc/wifi/softap.conf file, and assign it to the member variable mWifiApConfig of WifiApConfigStore, this variable saves is the configuration information of the current SoftAp. The file will have default information stored in it at the beginning. If you have never configured a hotspot, you will get the default information of the system; if a hotspot is configured in the upper layer, the new configuration information will also be updated to softap. for download to load again. Reply CMD_RESPONSE_AP_CONFIG message to WifiStateMachine with mWifiApConfig object. In SoftApStartingState::enter(), if config is not empty, we directly call startSoftApWithConfig() to start SoftAP; if config is null at the beginning, by processing CMD_RESPONSE_AP_CONFIG to obtain a new config object, we should also start SoftAP: If the config object at the beginning is not empty, it can be seen from the code that the CMD_SET_AP_CONFIG message will be sent first to notify the WifiApConfigStore to update the configuration information. First, the incoming configuration object will be saved to the mWifiApConfigenter() function, and writeApConfiguration() will be called to update the mWifiApConfig information to In the /misc/wifi/softap.conf file, it is used for the next loading, and then sends the CMD_SET_AP_CONFIG_COMPLETED message to itself to inform that the configuration information update has been completed, and re-enters the InactiveState to wait for the next configuration information update processing. Then return to WifiStateMachine::SoftApStartingState to process CMD_RESPONSE_AP_CONFIG. If the config obtained again is still null, it will notify the hotspot that it failed to open.

其中,当所述第一工作模式为WiFi工作站模式时,上述第一应用服务部分参考如下:通过private WifiManager mWifiManager函数定义WifiManager对象,通过privateWifiInfo mWifiInf o函数定义WifiInfo对象,通过private List<ScanResult>mWifiList函数扫描出的网络连接列表,取得WifiManager对象以及WifiInfo对象,通过public voidOpenWifi()函数打开WiFi,通过public List<WifiConfiguration>GetConfiguration()函数得到配置好的网络,并通过public void ConnectConfiguration(int index)函数指定配置好的网络进行连接,连接配置好的指定ID的网络。Wherein, when the first working mode is the WiFi workstation mode, the above-mentioned first application service part refers to the following: the WifiManager object is defined by the private WifiManager mWifiManager function, the WifiInfo object is defined by the privateWifiInfo mWifiInfo function, and the WifiInfo object is defined by the private List<ScanResult>mWifiList function From the scanned network connection list, get the WifiManager object and WifiInfo object, open the WiFi through the public voidOpenWifi() function, get the configured network through the public List<WifiConfiguration>GetConfiguration() function, and specify it through the public void ConnectConfiguration(int index) function Connect to the configured network, and connect to the configured network with the specified ID.

S102、移动终端检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式。S102. The mobile terminal detects whether a working mode switching instruction is received, where the working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode.

这里,所述工作模式切换指令可以是本地指令,也可以是远程遥控指令。当所述工作模式切换指令是本地指令时,可以通过人机交互界面接收由用户触发的工作模式切换指令。Here, the working mode switching instruction may be a local instruction or a remote control instruction. When the working mode switching instruction is a local instruction, the working mode switching instruction triggered by the user can be received through the human-computer interaction interface.

S103、移动终端在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。S103. When the mobile terminal detects and receives the working mode switching instruction, it runs a second application service based on the loaded preset driver, so that the mobile terminal is switched from the first working mode to the second working mode Operating mode.

其中,所述在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式的具体实现方式可以是:Wherein, when it is detected that the working mode switching instruction is received, based on the loaded preset driver, a second application service is executed to switch the mobile terminal from the first working mode to the second working mode The specific implementation of the working mode can be:

在检测接收到所述工作模式切换指令时,设置用于指示不卸载所述预设驱动的标记信息;When detecting that the operating mode switching instruction is received, setting flag information for indicating not to uninstall the preset driver;

识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。Identifying the tag information, running a second application service based on the loaded preset driver, so that the mobile terminal is switched from the first working mode to the second working mode.

可以看出,本发明实施例提供的移动终端工作模式切换方法中,移动终端首先加载预设驱动,并运行第一应用服务以开启第一工作模式,然后检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式,在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。可见,由于移动终端工作在两种工作模式时使用的驱动是一样的,移动终端通过实施本发明中的方法能够保证在两种工作模式切换的时候,无需卸载驱动再重新加载驱动,进而加快了移动终端的WiFi工作站模式和WiFi接入点模式两种工作模式之间的切换速度。It can be seen that, in the method for switching the working mode of the mobile terminal provided by the embodiment of the present invention, the mobile terminal first loads the preset driver, runs the first application service to enable the first working mode, and then detects whether the working mode switching instruction is received, so The working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode, and when it is detected that the working mode switching instruction is received, based on the loaded preset drive, and run the second application The service is to make the mobile terminal switch from the first working mode to the second working mode. It can be seen that since the mobile terminal uses the same driver when working in the two working modes, by implementing the method in the present invention, the mobile terminal can ensure that the driver does not need to be unloaded and then reloaded when the two working modes are switched, thereby speeding up the The switching speed between the WiFi workstation mode and WiFi access point mode of the mobile terminal.

可选的,当所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式时,所述移动终端还可以执行以下操作:Optionally, when the first working mode is a WiFi access point mode and the second working mode is a WiFi workstation mode, the mobile terminal may further perform the following operations:

检测当前环境存在的WiFi标识中是否存在目标WiFi标识与预存的历史连接记录中的WiFi标识匹配;若检测到当前环境存在的WiFi标识中存在目标WiFi标识与预存的历史连接记录中的WiFi标识匹配,检测是否接收到关闭WiFi接入点模式的指令;在检测接收到所述关闭WiFi接入点模式的指令时,设置所述用于指示不卸载所述预设驱动的标记信息,以使所述移动终端在检测接收到开启WiFi工作站模式的指令时,识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以开启所述WiFi工作站模式。Detect whether there is a target WiFi identification in the WiFi identification existing in the current environment that matches the WiFi identification in the pre-stored historical connection record; , to detect whether an instruction to turn off the WiFi access point mode is received; when it is detected that the command to turn off the WiFi access point mode is received, set the flag information for instructing not to uninstall the preset driver, so that all When the mobile terminal detects and receives an instruction to enable the WiFi workstation mode, it identifies the flag information, and based on the loaded preset driver, runs a second application service to enable the WiFi workstation mode.

可选的,当所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式时,所述移动终端还可以执行以下操作:Optionally, when the first working mode is a WiFi access point mode and the second working mode is a WiFi workstation mode, the mobile terminal may further perform the following operations:

获取预存的WiFi使用时间集合;检测当前的时间是否属于所述WiFi使用时间集合;若检测到当前的时间属于所述WiFi使用时间集合,检测是否接收到关闭WiFi接入点模式的指令;在检测接收到所述关闭WiFi接入点模式的指令时,设置所述用于指示不卸载所述预设驱动的标记信息,以使所述移动终端在检测接收到开启WiFi工作站模式的指令时,识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以开启所述WiFi工作站模式。Obtain a pre-stored set of WiFi usage time; detect whether the current time belongs to the WiFi usage time set; if it is detected that the current time belongs to the WiFi usage time set, detect whether an instruction to turn off the WiFi access point mode is received; When receiving the instruction to turn off the WiFi access point mode, set the flag information for instructing not to uninstall the preset driver, so that the mobile terminal recognizes that the mobile terminal receives the instruction to turn on the WiFi workstation mode. The flag information is based on the loaded preset driver and runs a second application service to enable the WiFi workstation mode.

与上述图1所示的实施例一致的,请参阅图2,图2是本发明实施例提供的另一种移动终端工作模式切换方法的流程示意图。如图所示,本移动终端工作模式切换方法包括:Consistent with the embodiment shown in FIG. 1 above, please refer to FIG. 2 , which is a schematic flowchart of another method for switching a working mode of a mobile terminal according to an embodiment of the present invention. As shown in the figure, the method for switching the working mode of the mobile terminal includes:

S201、移动终端加载预设驱动,并运行第一应用服务以开启第一工作模式。S201. The mobile terminal loads a preset driver, and runs a first application service to enable a first working mode.

其中,所述第一工作模式为WiFi工作站模式,所述第二工作模式为WiFi接入点模式;或者,所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式。Wherein, the first working mode is WiFi workstation mode, and the second working mode is WiFi access point mode; or, the first working mode is WiFi access point mode, and the second working mode is WiFi workstation model.

S202、移动终端检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式。S202. The mobile terminal detects whether a working mode switching instruction is received, where the working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode.

S203、在检测接收到所述工作模式切换指令时,移动终端设置用于指示不卸载所述预设驱动的标记信息。S203. When detecting that the working mode switching instruction is received, the mobile terminal sets flag information for indicating that the preset driver is not to be uninstalled.

S204、移动终端识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。S204 . The mobile terminal identifies the flag information, runs a second application service based on the loaded preset driver, so that the mobile terminal switches from the first working mode to the second working mode.

可以看出,本发明实施例提供的移动终端工作模式切换方法中,移动终端首先加载预设驱动,并运行第一应用服务以开启第一工作模式,然后检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式,在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。可见,由于移动终端工作在两种工作模式时使用的驱动是一样的,移动终端通过实施本发明中的方法能够保证在两种工作模式切换的时候,无需卸载驱动再重新加载驱动,进而加快了移动终端的WiFi工作站模式和WiFi接入点模式两种工作模式之间的切换速度。It can be seen that, in the method for switching the working mode of the mobile terminal provided by the embodiment of the present invention, the mobile terminal first loads the preset driver, runs the first application service to enable the first working mode, and then detects whether the working mode switching instruction is received, so The working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode, and when it is detected that the working mode switching instruction is received, based on the loaded preset drive, and run the second application The service is to make the mobile terminal switch from the first working mode to the second working mode. It can be seen that since the mobile terminal uses the same driver when working in the two working modes, by implementing the method in the present invention, the mobile terminal can ensure that the driver does not need to be unloaded and then reloaded when the two working modes are switched, thereby speeding up the The switching speed between the WiFi workstation mode and WiFi access point mode of the mobile terminal.

与上述图1所示的实施例一致的,请参阅图3,图3是本发明实施例提供的另一种移动终端工作模式切换方法的流程示意图。如图3所示,本移动终端工作模式切换方法包括:Consistent with the embodiment shown in FIG. 1 above, please refer to FIG. 3 , which is a schematic flowchart of another method for switching a working mode of a mobile terminal according to an embodiment of the present invention. As shown in Figure 3, the method for switching the working mode of the mobile terminal includes:

S301、移动终端加载预设驱动,并运行第一应用服务以开启WiFi接入点模式。S301. The mobile terminal loads a preset driver, and runs a first application service to enable the WiFi access point mode.

可选的,当所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式时,所述移动终端还可以执行以下操作:Optionally, when the first working mode is a WiFi access point mode and the second working mode is a WiFi workstation mode, the mobile terminal may further perform the following operations:

S302、移动终端检测当前环境存在的WiFi标识中是否存在目标WiFi标识与预存的历史连接记录中的WiFi标识匹配。S302: The mobile terminal detects whether there is a target WiFi identifier in the WiFi identifiers existing in the current environment that matches the WiFi identifier in the pre-stored historical connection record.

具体地,所述预存的历史连接记录中包括移动终端连接过的至少一个WiFi标识。Specifically, the pre-stored historical connection record includes at least one WiFi identifier to which the mobile terminal has been connected.

S303、移动终端若检测到当前环境存在的WiFi标识中存在目标WiFi标识与预存的历史连接记录中的WiFi标识匹配,检测是否接收到关闭WiFi接入点模式的指令。S303: If the mobile terminal detects that the target WiFi identifier in the WiFi identifier existing in the current environment matches the WiFi identifier in the pre-stored historical connection record, the mobile terminal detects whether an instruction to disable the WiFi access point mode is received.

S304、移动终端在检测接收到所述关闭WiFi接入点模式的指令时,设置所述用于指示不卸载所述预设驱动的标记信息,以使所述移动终端在检测接收到开启WiFi工作站模式的指令时,识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以开启所述WiFi工作站模式。S304. When the mobile terminal detects and receives the instruction for turning off the WiFi access point mode, the mobile terminal sets the flag information for indicating that the preset driver is not to be uninstalled, so that the mobile terminal detects and receives the turn-on WiFi workstation When the instruction of the mode is received, the flag information is identified, the second application service is executed based on the loaded preset driver to enable the WiFi workstation mode.

具体地,当检测到当前环境存在的WiFi标识中存在目标WiFi标识与预存的历史连接记录中的WiFi标识匹配时,可以理解为移动终端的用户在关闭WiFi接入点模式后,要开启WiFi工作站模式。Specifically, when it is detected that the target WiFi identification in the WiFi identification existing in the current environment matches the WiFi identification in the pre-stored historical connection record, it can be understood that the user of the mobile terminal needs to open the WiFi workstation after turning off the WiFi access point mode. model.

可以看出,本发明实施例提供的移动终端工作模式切换方法中,移动终端首先加载预设驱动,并运行第一应用服务以开启第一工作模式,然后检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式,在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。可见,由于移动终端工作在两种工作模式时使用的驱动是一样的,移动终端通过实施本发明中的方法能够保证在两种工作模式切换的时候,无需卸载驱动再重新加载驱动,进而加快了移动终端的WiFi工作站模式和WiFi接入点模式两种工作模式之间的切换速度。It can be seen that, in the method for switching the working mode of the mobile terminal provided by the embodiment of the present invention, the mobile terminal first loads the preset driver, runs the first application service to enable the first working mode, and then detects whether the working mode switching instruction is received, so The working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode, and when it is detected that the working mode switching instruction is received, based on the loaded preset drive, and run the second application The service is to make the mobile terminal switch from the first working mode to the second working mode. It can be seen that since the mobile terminal uses the same driver when working in the two working modes, by implementing the method in the present invention, the mobile terminal can ensure that the driver does not need to be unloaded and then reloaded when the two working modes are switched, thereby speeding up the The switching speed between the WiFi workstation mode and WiFi access point mode of the mobile terminal.

与上述图1所示的实施例一致的,请参阅图4,图4是本发明实施例提供的另一种移动终端工作模式切换方法的流程示意图。如图4所示,本移动终端工作模式切换方法包括:Consistent with the embodiment shown in FIG. 1 above, please refer to FIG. 4 . FIG. 4 is a schematic flowchart of another method for switching a working mode of a mobile terminal according to an embodiment of the present invention. As shown in Figure 4, the method for switching the working mode of the mobile terminal includes:

S401、移动终端加载预设驱动,并运行第一应用服务以开启WiFi接入点模式。S401. The mobile terminal loads a preset driver, and runs a first application service to enable the WiFi access point mode.

S402、移动终端获取预存的WiFi使用时间集合。S402. The mobile terminal acquires a pre-stored WiFi usage time set.

具体地,所述预存的WiFi使用时间集合是基于移动终端基于在预设时间段内的WiFi使用记录学习得到的。例如,预存的WiFi使用时间集合可以是{(6;00~7:00),(11:45~1:45),(17:30~19:00),(21:00~23:30)}。Specifically, the pre-stored WiFi usage time set is obtained based on learning by the mobile terminal based on WiFi usage records within a preset time period. For example, the pre-stored WiFi usage time set can be {(6; 00~7:00), (11:45~1:45), (17:30~19:00), (21:00~23:30) }.

S403、移动终端检测当前的时间是否属于所述WiFi使用时间集合。S403. The mobile terminal detects whether the current time belongs to the WiFi usage time set.

具体地,举例来说,若移动终端获取到当期的时间为11:08,该时间不属于上述预存的WiFi使用时间集合;若移动终端获取到当期的时间为17:45,该时间不属于上述预存的WiFi使用时间集合。当当前的时间属于所述WiFi使用时间集合时,根据在预设时间段内的WiFi使用记录,可以理解为移动终端的用户在关闭WiFi接入点模式后,要开启WiFi工作站模式。Specifically, for example, if the current time obtained by the mobile terminal is 11:08, the time does not belong to the above-mentioned pre-stored WiFi usage time set; if the current time obtained by the mobile terminal is 17:45, the time does not belong to the above Pre-stored WiFi usage time collection. When the current time belongs to the WiFi usage time set, according to the WiFi usage records within the preset time period, it can be understood that the user of the mobile terminal needs to enable the WiFi workstation mode after disabling the WiFi access point mode.

S404、移动终端若检测到当前的时间属于所述WiFi使用时间集合,检测是否接收到关闭WiFi接入点模式的指令。S404. If the mobile terminal detects that the current time belongs to the WiFi usage time set, it detects whether an instruction to disable the WiFi access point mode is received.

S405、移动终端在检测接收到所述关闭WiFi接入点模式的指令时,设置所述用于指示不卸载所述预设驱动的标记信息,以使所述移动终端在检测接收到开启WiFi工作站模式的指令时,识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以开启所述WiFi工作站模式。S405. When the mobile terminal detects and receives the instruction to turn off the WiFi access point mode, sets the flag information for indicating not to uninstall the preset driver, so that the mobile terminal detects and receives the turn-on WiFi workstation When the instruction of the mode is received, the flag information is identified, the second application service is executed based on the loaded preset driver to enable the WiFi workstation mode.

可以看出,本发明实施例提供的移动终端工作模式切换方法中,移动终端首先加载预设驱动,并运行第一应用服务以开启第一工作模式,然后检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式,在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。可见,由于移动终端工作在两种工作模式时使用的驱动是一样的,移动终端通过实施本发明中的方法能够保证在两种工作模式切换的时候,无需卸载驱动再重新加载驱动,进而加快了移动终端的WiFi工作站模式和WiFi接入点模式两种工作模式之间的切换速度。It can be seen that, in the method for switching the working mode of the mobile terminal provided by the embodiment of the present invention, the mobile terminal first loads the preset driver, runs the first application service to enable the first working mode, and then detects whether the working mode switching instruction is received, so The working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode, and when it is detected that the working mode switching instruction is received, based on the loaded preset drive, and run the second application The service is to make the mobile terminal switch from the first working mode to the second working mode. It can be seen that since the mobile terminal uses the same driver when working in the two working modes, by implementing the method in the present invention, the mobile terminal can ensure that the driver does not need to be unloaded and then reloaded when the two working modes are switched, thereby speeding up the The switching speed between the WiFi workstation mode and WiFi access point mode of the mobile terminal.

下面为本发明装置实施例,本发明装置实施例用于执行本发明方法实施例所实现的方法。如图5-1所示,该移动终端可以包括加载单元501、检测单元502、切换单元503,其中:The following are apparatus embodiments of the present invention, and the apparatus embodiments of the present invention are used to execute the methods implemented by the method embodiments of the present invention. As shown in Figure 5-1, the mobile terminal may include a loading unit 501, a detection unit 502, and a switching unit 503, wherein:

所述加载单元501,用于加载预设驱动,并运行第一应用服务以开启第一工作模式;The loading unit 501 is configured to load a preset driver and run a first application service to enable a first working mode;

所述检测单元502,用于检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示所述移动终端由所述第一工作模式切换为第二工作模式;The detection unit 502 is configured to detect whether a working mode switching instruction is received, where the working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode;

所述切换单元503,用于在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。The switching unit 503 is configured to run a second application service based on the loaded preset drive to make the mobile terminal switch from the first working mode to the second working mode.

如图5-2所示,该移动终端包括如图5-1所对应的实施例中的加载单元501、检测单元502、切换单元503。As shown in FIG. 5-2, the mobile terminal includes a loading unit 501, a detection unit 502, and a switching unit 503 in the embodiment corresponding to FIG. 5-1.

可选的,所述切换单元503,还可以进一步包括:Optionally, the switching unit 503 may further include:

设置子单元5031,用于在检测接收到所述工作模式切换指令时,设置用于指示不卸载所述预设驱动的标记信息;A setting subunit 5031, configured to set flag information for indicating that the preset driver is not to be uninstalled when it is detected that the operating mode switching instruction is received;

切换子单元5032,用于识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。The switching subunit 5032 is configured to identify the flag information, run a second application service based on the loaded preset driver, so that the mobile terminal is switched from the first working mode to the second working mode.

可选的,所述第一工作模式为WiFi工作站模式,所述第二工作模式为WiFi接入点模式;Optionally, the first working mode is a WiFi workstation mode, and the second working mode is a WiFi access point mode;

或者,所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式。Alternatively, the first working mode is a WiFi access point mode, and the second working mode is a WiFi workstation mode.

可选的,当所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式时,Optionally, when the first working mode is the WiFi access point mode and the second working mode is the WiFi workstation mode,

所述检测单元502,还用于检测当前环境存在的WiFi标识中是否存在目标WiFi标识与预存的历史连接记录中的WiFi标识匹配;The detection unit 502 is further configured to detect whether there is a target WiFi identification in the WiFi identification existing in the current environment that matches the WiFi identification in the pre-stored historical connection record;

所述检测单元502,还用于若检测到当前环境存在的WiFi标识中存在目标WiFi标识与预存的历史连接记录中的WiFi标识匹配,检测是否接收到关闭WiFi接入点模式的指令;The detection unit 502 is further configured to detect whether an instruction to turn off the WiFi access point mode is received if it is detected that the target WiFi identifier in the WiFi identifier existing in the current environment matches the WiFi identifier in the pre-stored historical connection record;

所述移动终端还包括:The mobile terminal also includes:

第一设置单元504,用于在检测接收到所述关闭WiFi接入点模式的指令时,设置所述用于指示不卸载所述预设驱动的标记信息,以使所述移动终端在检测接收到开启WiFi工作站模式的指令时,识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以开启所述WiFi工作站模式。The first setting unit 504 is configured to set the flag information for indicating that the preset driver is not to be uninstalled when the instruction for turning off the WiFi access point mode is detected and received, so that the mobile terminal detects and receives the When the instruction to turn on the WiFi workstation mode is reached, the flag information is identified, based on the loaded preset driver, and a second application service is run to turn on the WiFi workstation mode.

可选的,当所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式时,所述移动终端还包括:Optionally, when the first working mode is a WiFi access point mode and the second working mode is a WiFi workstation mode, the mobile terminal further includes:

获取单元505,用于获取预存的WiFi使用时间集合;an obtaining unit 505, configured to obtain a pre-stored WiFi usage time set;

所述检测单元502,还用于检测当前的时间是否属于所述WiFi使用时间集合;The detection unit 502 is further configured to detect whether the current time belongs to the WiFi usage time set;

所述检测单元502,还用于若检测到当前的时间属于所述WiFi使用时间集合,检测是否接收到关闭WiFi接入点模式的指令;The detection unit 502 is further configured to detect whether an instruction to turn off the WiFi access point mode is received if it is detected that the current time belongs to the WiFi usage time set;

第二设置单元506,用于在检测接收到所述关闭WiFi接入点模式的指令时,设置所述用于指示不卸载所述预设驱动的标记信息,以使所述移动终端在检测接收到开启WiFi工作站模式的指令时,识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以开启所述WiFi工作站模式。The second setting unit 506 is configured to set the flag information for indicating that the preset driver is not to be uninstalled when the instruction for turning off the WiFi access point mode is detected and received, so that the mobile terminal detects and receives When the instruction to turn on the WiFi workstation mode is reached, the flag information is identified, based on the loaded preset driver, and a second application service is run to turn on the WiFi workstation mode.

需要注意的是,本发明装置实施例所描述的移动终端是以功能单元的形式呈现。这里所使用的术语“单元”应当理解为尽可能最宽的含义,用于实现各个“单元”所描述功能的对象例如可以是集成电路ASIC,单个电路,用于执行一个或多个软件或固件程序的处理器(共享的、专用的或芯片组)和存储器,组合逻辑电路,和/或提供实现上述功能的其他合适的组件。It should be noted that the mobile terminal described in the apparatus embodiment of the present invention is presented in the form of functional units. The term "unit" as used herein should be understood in the broadest possible sense, and the object used to implement the functions described by each "unit" may be, for example, an integrated circuit ASIC, a single circuit for executing one or more software or firmware Program processors (shared, dedicated, or chipset) and memory, combinational logic circuits, and/or other suitable components that provide the functions described above.

举例来说,上述加载单元501加载预设驱动,并运行第一应用服务以开启第一工作模式的功能可以由图6所示的移动终端来实现,具体可以通过处理器101通过调用存储器102中的可执行程序代码,加载预设驱动,并运行第一应用服务以开启第一工作模式。For example, the above-mentioned loading unit 501 loads the preset driver and runs the first application service to enable the first working mode. The function of the mobile terminal shown in FIG. 6 can be implemented. Specifically, the processor 101 can call the The executable program code, loads the default driver, and runs the first application service to enable the first working mode.

可以看出,本发明实施例提供的移动终端工作模式切换方法中,移动终端首先加载预设驱动,并运行第一应用服务以开启第一工作模式,然后检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式,在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。可见,由于移动终端工作在两种工作模式时使用的驱动是一样的,移动终端通过实施本发明中的方法能够保证在两种工作模式切换的时候,无需卸载驱动再重新加载驱动,进而加快了移动终端的WiFi工作站模式和WiFi接入点模式两种工作模式之间的切换速度。It can be seen that, in the method for switching the working mode of the mobile terminal provided by the embodiment of the present invention, the mobile terminal first loads the preset driver, runs the first application service to enable the first working mode, and then detects whether the working mode switching instruction is received, so The working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode, and when it is detected that the working mode switching instruction is received, based on the loaded preset drive, and run the second application The service is to make the mobile terminal switch from the first working mode to the second working mode. It can be seen that since the mobile terminal uses the same driver when working in the two working modes, by implementing the method in the present invention, the mobile terminal can ensure that the driver does not need to be unloaded and then reloaded when the two working modes are switched, thereby speeding up the The switching speed between the WiFi workstation mode and WiFi access point mode of the mobile terminal.

本发明实施例还提供了另一种移动终端,如图6所示,包括:处理器101,存储器102,通信接口103和通信总线104;其中,处理器101、存储器102和通信接口103通过通信总线104连接并完成相互间的通信;处理器101通过通信接口103控制与外部蜂窝网的无线通信;通信接口103包括但不限于天线、放大器、收发信机、耦合器、LNA(Low NoiseAmplifier,低噪声放大器)、双工器等。存储器102包括以下至少一种:随机存取存贮器、非易失性存储器以及外部存储器,存储器102中存储有可执行程序代码,该可执行程序代码能够引导处理器101执行本发明方法实施例中具体披露的移动终端工作模式切换方法。An embodiment of the present invention also provides another mobile terminal, as shown in FIG. 6 , including: a processor 101, a memory 102, a communication interface 103 and a communication bus 104; wherein the processor 101, the memory 102 and the communication interface 103 communicate through The bus 104 is connected and completes mutual communication; the processor 101 controls the wireless communication with the external cellular network through the communication interface 103; the communication interface 103 includes but is not limited to antennas, amplifiers, transceivers, couplers, LNA (Low Noise Amplifier, low noise amplifiers), duplexers, etc. The memory 102 includes at least one of the following: random access memory, non-volatile memory and external memory, and the memory 102 stores executable program codes, the executable program codes can guide the processor 101 to execute the method embodiments of the present invention The mobile terminal working mode switching method specifically disclosed in .

所述处理器101,用于加载预设驱动,并运行第一应用服务以开启第一工作模式;检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式;在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。The processor 101 is configured to load a preset driver and run a first application service to enable a first working mode; detect whether a working mode switching instruction is received, and the working mode switching instruction is used to instruct the mobile terminal to be operated by the first working mode. A working mode is switched to a second working mode; when detecting and receiving the working mode switching instruction, based on the loaded preset driver, run a second application service to make the mobile terminal switch from the first working mode Switch to the second working mode.

可选的,所述处理器101在用于在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式时,具体用于在检测接收到所述工作模式切换指令时,设置用于指示不卸载所述预设驱动的标记信息;识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。Optionally, the processor 101 is configured to run a second application service based on the loaded preset driver when detecting that the working mode switching instruction is received, so that the mobile terminal is operated by the first application service. When the working mode is switched to the second working mode, it is specifically used to set flag information for indicating that the preset driver is not to be uninstalled when it is detected that the work mode switching instruction is received; the flag information is identified based on the The loaded preset driver is executed, and a second application service is executed to make the mobile terminal switch from the first working mode to the second working mode.

可选的,所述第一工作模式为WiFi工作站模式,所述第二工作模式为WiFi接入点模式;Optionally, the first working mode is a WiFi workstation mode, and the second working mode is a WiFi access point mode;

或者,所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式。Alternatively, the first working mode is a WiFi access point mode, and the second working mode is a WiFi workstation mode.

可选的,当所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式时,所述处理器101还可以用于检测当前环境存在的WiFi标识中是否存在目标WiFi标识与预存的历史连接记录中的WiFi标识匹配;若检测到当前环境存在的WiFi标识中存在目标WiFi标识与预存的历史连接记录中的WiFi标识匹配,检测是否接收到关闭WiFi接入点模式的指令;在检测接收到所述关闭WiFi接入点模式的指令时,设置所述用于指示不卸载所述预设驱动的标记信息,以使所述移动终端在检测接收到开启WiFi工作站模式的指令时,识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以开启所述WiFi工作站模式。Optionally, when the first working mode is the WiFi access point mode and the second working mode is the WiFi workstation mode, the processor 101 can also be used to detect whether there is a target in the WiFi identifier existing in the current environment. The WiFi identifier matches the WiFi identifier in the pre-stored historical connection record; if it is detected that the target WiFi identifier in the WiFi identifier existing in the current environment matches the WiFi identifier in the pre-stored historical connection record, it is detected whether the shutdown WiFi access point mode is received. the instruction; when detecting and receiving the instruction to turn off the WiFi access point mode, set the flag information for indicating not to uninstall the preset driver, so that the mobile terminal detects and receives the turn on the WiFi workstation mode When the instruction is given, the flag information is identified, based on the loaded preset driver, and a second application service is executed to enable the WiFi workstation mode.

可选的,当所述第一工作模式为WiFi接入点模式,所述第二工作模式为WiFi工作站模式时,所述处理器101还可以用于获取预存的WiFi使用时间集合;检测当前的时间是否属于所述WiFi使用时间集合;若检测到当前的时间属于所述WiFi使用时间集合,检测是否接收到关闭WiFi接入点模式的指令;在检测接收到所述关闭WiFi接入点模式的指令时,设置所述用于指示不卸载所述预设驱动的标记信息,以使所述移动终端在检测接收到开启WiFi工作站模式的指令时,识别所述标记信息,基于所述加载的预设驱动,并运行第二应用服务以开启所述WiFi工作站模式。Optionally, when the first working mode is the WiFi access point mode and the second working mode is the WiFi workstation mode, the processor 101 may also be used to obtain a pre-stored set of WiFi usage times; Whether the time belongs to the WiFi use time set; if it is detected that the current time belongs to the WiFi use time set, it is detected whether an instruction to close the WiFi access point mode is received; When instructing, the flag information for indicating not to uninstall the preset driver is set, so that the mobile terminal recognizes the flag information when detecting and receives an instruction to turn on the WiFi workstation mode, and based on the loaded preset driver, the mobile terminal identifies the flag information. Set the driver, and run the second application service to enable the WiFi workstation mode.

可以看出,本发明实施例提供的移动终端工作模式切换方法中,移动终端首先加载预设驱动,并运行第一应用服务以开启第一工作模式,然后检测是否接收到工作模式切换指令,所述工作模式切换指令用于指示移动终端由所述第一工作模式切换为第二工作模式,在检测接收到所述工作模式切换指令时,基于所述加载的预设驱动,并运行第二应用服务以使所述移动终端由所述第一工作模式切换为所述第二工作模式。可见,由于移动终端工作在两种工作模式时使用的驱动是一样的,移动终端通过实施本发明中的方法能够保证在两种工作模式切换的时候,无需卸载驱动再重新加载驱动,进而加快了移动终端的WiFi工作站模式和WiFi接入点模式两种工作模式之间的切换速度。It can be seen that, in the method for switching the working mode of the mobile terminal provided by the embodiment of the present invention, the mobile terminal first loads the preset driver, runs the first application service to enable the first working mode, and then detects whether the working mode switching instruction is received, so The working mode switching instruction is used to instruct the mobile terminal to switch from the first working mode to the second working mode, and when it is detected that the working mode switching instruction is received, based on the loaded preset drive, and run the second application The service is to make the mobile terminal switch from the first working mode to the second working mode. It can be seen that since the mobile terminal uses the same driver when working in the two working modes, by implementing the method in the present invention, the mobile terminal can ensure that the driver does not need to be unloaded and then reloaded when the two working modes are switched, thereby speeding up the The switching speed between the WiFi workstation mode and WiFi access point mode of the mobile terminal.

本发明实施例还提供了另一种移动终端,如图7所示,为了便于说明,仅示出了与本发明实施例相关的部分,具体技术细节未揭示的,请参照本发明实施例方法部分。该移动终端可以为包括手机、平板电脑、PDA(Personal Digital Assistant,个人数字助理)、POS(Point of Sales,销售终端)、车载电脑等任意终端设备,以移动终端为手机为例:An embodiment of the present invention also provides another mobile terminal, as shown in FIG. 7 . For convenience of description, only the part related to the embodiment of the present invention is shown. If the specific technical details are not disclosed, please refer to the method of the embodiment of the present invention. part. The mobile terminal can be any terminal device including a mobile phone, a tablet computer, a PDA (Personal Digital Assistant, personal digital assistant), a POS (Point of Sales, a sales terminal), a vehicle-mounted computer, etc. The mobile terminal is a mobile phone as an example:

图7示出的是与本发明实施例提供的移动终端相关的手机的部分结构的框图。参考图7,手机包括:射频(Radio Frequency,RF)电路910、存储器920、输入单元930、显示单元940、传感器950、音频电路960、无线保真(wireless fidelity,WiFi)模块970、处理器980、以及电源990等部件。本领域技术人员可以理解,图7中示出的手机结构并不构成对手机的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。FIG. 7 is a block diagram showing a partial structure of a mobile phone related to a mobile terminal provided by an embodiment of the present invention. Referring to FIG. 7 , the mobile phone includes: a radio frequency (RF) circuit 910 , a memory 920 , an input unit 930 , a display unit 940 , a sensor 950 , an audio circuit 960 , a wireless fidelity (WiFi) module 970 , and a processor 980 , and power supply 990 and other components. Those skilled in the art can understand that the structure of the mobile phone shown in FIG. 7 does not constitute a limitation on the mobile phone, and may include more or less components than the one shown, or combine some components, or arrange different components.

下面结合图7对手机的各个构成部件进行具体的介绍:Below in conjunction with Figure 7, the various components of the mobile phone are introduced in detail:

RF电路910可用于信息的接收和发送。通常,RF电路910包括但不限于天线、至少一个放大器、收发信机、耦合器、低噪声放大器(Low Noise Amplifier,LNA)、双工器等。此外,RF电路910还可以通过无线通信与网络和其他设备通信。上述无线通信可以使用任一通信标准或协议,包括但不限于全球移动通讯系统(Global System of Mobilecommunication,GSM)、通用分组无线服务(General Packet Radio Service,GPRS)、码分多址(Code Division Multiple Access,CDMA)、宽带码分多址(Wideband Code DivisionMultiple Access,WCDMA)、长期演进(Long Term Evolution,LTE)、电子邮件、短消息服务(Short Messaging Service,SMS)等。RF circuitry 910 may be used for the reception and transmission of information. Typically, the RF circuit 910 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a Low Noise Amplifier (LNA), a duplexer, and the like. In addition, RF circuitry 910 may communicate with networks and other devices via wireless communications. The above-mentioned wireless communication can use any communication standard or protocol, including but not limited to Global System of Mobile communication (GSM), General Packet Radio Service (General Packet Radio Service, GPRS), Code Division Multiple Access (Code Division Multiple Access) Access, CDMA), Wideband Code Division Multiple Access (Wideband Code Division Multiple Access, WCDMA), Long Term Evolution (Long Term Evolution, LTE), email, Short Messaging Service (Short Messaging Service, SMS) and the like.

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

输入单元930可用于接收输入的数字或字符信息,以及生成与手机的用户设置以及功能控制有关的键信号输入。具体地,输入单元930可包括指纹识别模组931以及其他输入设备932。指纹识别模组931,可采集用户在其上的指纹数据。可选的,指纹识别模组931可包括光学式指纹模块、电容式指纹模块以及射频式指纹模块。以指纹识别模组931为电容式指纹识别模组为例,具体包括感应电极(异常感应电极和正常感应电极)和与所述感应电极连接的信号处理电路(如放大电路、噪声抑制电路、模数转化电路,等等)。除了指纹识别模组931,输入单元930还可以包括其他输入设备932。具体地,其他输入设备932可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆等中的一种或多种。The input unit 930 can be used to receive inputted numerical or character information, and generate key signal input related to user setting and function control of the mobile phone. Specifically, the input unit 930 may include a fingerprint recognition module 931 and other input devices 932 . The fingerprint identification module 931 can collect the fingerprint data of the user on it. Optionally, the fingerprint identification module 931 may include an optical fingerprint module, a capacitive fingerprint module and a radio frequency fingerprint module. Taking the fingerprint identification module 931 as a capacitive fingerprint identification module as an example, it specifically includes sensing electrodes (abnormal sensing electrodes and normal sensing electrodes) and signal processing circuits (such as amplifying circuits, noise suppression circuits, modules) connected to the sensing electrodes. digital conversion circuits, etc.). Besides the fingerprint recognition module 931 , the input unit 930 may also include other input devices 932 . Specifically, other input devices 932 may include, but are not limited to, one or more of physical keyboards, function keys (such as volume control keys, switch keys, etc.), trackballs, mice, joysticks, and the like.

显示单元940可用于显示由用户输入的信息或提供给用户的信息以及手机的各种菜单。显示单元940可包括显示屏941,可选的,可以采用液晶显示器(Liquid CrystalDisplay,LCD)、有机发光二极管(Organic Light-Emitting Diode,OLED)等形式来配置显示屏941。虽然在图7中,指纹识别模组931与显示屏941是作为两个独立的部件来实现手机的输入和输入功能,但是在某些实施例中,可以将指纹识别模组931与显示屏941集成而实现手机的输入和输出功能。The display unit 940 may 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 940 may include a display screen 941. Optionally, the display screen 941 may be configured in the form of a liquid crystal display (Liquid Crystal Display, LCD), an organic light-emitting diode (Organic Light-Emitting Diode, OLED) or the like. Although in FIG. 7 , the fingerprint identification module 931 and the display screen 941 are used as two independent components to realize the input and input functions of the mobile phone, but in some embodiments, the fingerprint identification module 931 and the display screen 941 can be combined Integrated to realize the input and output functions of the mobile phone.

手机还可包括至少一种传感器950,比如光传感器、运动传感器以及其他传感器。具体地,光传感器可包括环境光传感器及接近传感器,其中,环境光传感器可根据环境光线的明暗来调节显示屏941的亮度,接近传感器可在手机移动到耳边时,关闭显示屏941和/或背光。作为运动传感器的一种,加速计传感器可检测各个方向上(一般为三轴)加速度的大小,静止时可检测出重力的大小及方向,可用于识别手机姿态的应用(比如横竖屏切换、相关游戏、磁力计姿态校准)、振动识别相关功能(比如计步器、敲击)等;至于手机还可配置的陀螺仪、气压计、湿度计、温度计、红外线传感器等其他传感器,在此不再赘述。The cell phone may also include at least one sensor 950, 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 screen 941 according to the brightness of the ambient light, and the proximity sensor may turn off the display screen 941 and/or when the mobile phone is moved to the ear. or backlight. As a kind of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in all directions (usually three axes), and can detect the magnitude and direction of gravity when it is stationary. games, magnetometer attitude calibration), vibration recognition related functions (such as pedometer, tapping), etc.; as for other sensors such as gyroscope, barometer, hygrometer, thermometer, infrared sensor, etc. Repeat.

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

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

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

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

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

前述图1、图2、图3和图4所示的实施例中,各步骤方法流程可以基于该手机的结构实现。In the foregoing embodiments shown in FIG. 1 , FIG. 2 , FIG. 3 and FIG. 4 , the method flow of each step can be implemented based on the structure of the mobile phone.

前述图5-1、图5-2所示的实施例中,各单元功能可以基于该手机的结构实现。In the foregoing embodiments shown in FIG. 5-1 and FIG. 5-2, the functions of each unit can be implemented based on the structure of the mobile phone.

本发明实施例还提供一种计算机存储介质,其中,该计算机存储介质可存储有程序,该程序执行时包括上述方法实施例中记载的任何一种移动终端工作模式切换方法的部分或全部步骤。Embodiments of the present invention further provide a computer storage medium, wherein the computer storage medium may store a program, and when the program is executed, the program includes part or all of the steps of any of the methods for switching the working mode of a mobile terminal described in the above method embodiments.

需要说明的是,对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本发明并不受所描述的动作顺序的限制,因为依据本发明,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本发明所必须的。It should be noted that, for the sake of simple description, the foregoing method embodiments are all expressed as a series of action combinations, but those skilled in the art should know that the present invention is not limited by the described action sequence. As in accordance with the present invention, certain steps may be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.

在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。In the above-mentioned embodiments, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference may be made to the relevant descriptions of other embodiments.

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

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

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

所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储器中。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储器中,包括若干指令用以使得一台计算机设备(可为个人计算机、服务器或者网络设备等)执行本发明各个实施例所述方法的全部或部分步骤。而前述的存储器包括:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介质。The integrated unit, if implemented as a software functional unit and sold or used as a stand-alone product, may be stored in a computer-readable memory. Based on such understanding, the technical solution of the present invention 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 memory, Several instructions are included to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned memory includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes.

本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储器中,存储器可以包括:闪存盘、只读存储器(英文:Read-Only Memory,简称:ROM)、随机存取器(英文:Random Access Memory,简称:RAM)、磁盘或光盘等。Those skilled in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing relevant hardware through a program, and the program can be stored in a computer-readable memory, and the memory can include: a flash disk , Read-only memory (English: Read-Only Memory, referred to as: ROM), random access device (English: Random Access Memory, referred to as: RAM), magnetic disk or optical disk, etc.

以上对本发明实施例进行了详细介绍,本文中应用了具体个例对本发明的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本发明的方法及其核心思想;同时,对于本领域的一般技术人员,依据本发明的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本发明的限制。The embodiments of the present invention have been introduced in detail above, and specific examples are used to illustrate the principles and implementations of the present invention. The descriptions of the above embodiments are only used to help understand the methods and core ideas of the present invention; at the same time, for Persons of ordinary skill in the art, according to the idea of the present invention, will have changes in the specific embodiments and application scope. To sum up, the contents of this specification should not be construed as limiting the present invention.

Claims (8)

1. A method for switching working modes of a mobile terminal is characterized by comprising the following steps:
loading a preset drive, and running a first application service to start a first working mode;
detecting whether a working mode switching instruction is received, wherein the working mode switching instruction is used for indicating the mobile terminal to be switched from the first working mode to a second working mode;
when the working mode switching instruction is detected to be received, based on the loaded preset drive, running a second application service to enable the mobile terminal to be switched from the first working mode to the second working mode;
when the working mode switching instruction is detected to be received, based on the loaded preset driver, and a second application service is run to switch the mobile terminal from the first working mode to the second working mode, including:
when the working mode switching instruction is detected to be received, setting mark information for indicating not to unload the preset drive;
identifying the mark information, based on the loaded preset drive, and running a second application service to enable the mobile terminal to be switched from the first working mode to the second working mode;
wherein,
the first working mode is a WiFi working station mode, and the second working mode is a WiFi access point mode;
or, the first operating mode is a WiFi access point mode, and the second operating mode is a WiFi workstation mode.
2. The method of claim 1, wherein when the first mode of operation is a WiFi access point mode and the second mode of operation is a WiFi station mode, the method further comprises:
detecting whether a target WiFi mark exists in WiFi marks existing in the current environment and is matched with a WiFi mark in a prestored historical connection record;
if the target WiFi identification in the WiFi identifications existing in the current environment is matched with the WiFi identification in the prestored historical connection record, whether an instruction for closing the WiFi access point mode is received is detected;
when the command for closing the WiFi access point mode is detected and received, the mark information for indicating not to unload the preset drive is set, so that when the mobile terminal detects and receives the command for opening the WiFi work station mode, the mark information is identified, the loaded preset drive is based on, and a second application service is operated to open the WiFi work station mode.
3. The method of claim 1, wherein when the first mode of operation is a WiFi access point mode and the second mode of operation is a WiFi station mode, the method further comprises:
acquiring a pre-stored WiFi use time set;
detecting whether the current time belongs to the WiFi use time set;
if the current time is detected to belong to the WiFi service time set, whether an instruction for closing a WiFi access point mode is received or not is detected;
when the command for closing the WiFi access point mode is detected and received, the mark information for indicating not to unload the preset drive is set, so that when the mobile terminal detects and receives the command for opening the WiFi work station mode, the mark information is identified, the loaded preset drive is based on, and a second application service is operated to open the WiFi work station mode.
4. A mobile terminal, comprising:
the loading unit is used for loading the preset drive and running the first application service to start a first working mode;
the mobile terminal comprises a detection unit, a processing unit and a processing unit, wherein the detection unit is used for detecting whether a working mode switching instruction is received or not, and the working mode switching instruction is used for indicating the mobile terminal to be switched from the first working mode to a second working mode;
the switching unit is used for operating a second application service based on the loaded preset drive when the working mode switching instruction is detected to be received, so that the mobile terminal is switched from the first working mode to the second working mode;
wherein the switching unit includes:
the setting subunit is used for setting the mark information for indicating not to unload the preset drive when detecting that the working mode switching instruction is received;
the switching subunit is used for identifying the mark information, based on the loaded preset drive, and running a second application service to switch the mobile terminal from the first working mode to the second working mode;
wherein,
the first working mode is a WiFi working station mode, and the second working mode is a WiFi access point mode;
or, the first operating mode is a WiFi access point mode, and the second operating mode is a WiFi workstation mode.
5. The mobile terminal of claim 4, wherein when the first mode of operation is a WiFi access point mode, the second mode of operation is a WiFi station mode,
the detection unit is also used for detecting whether a target WiFi mark exists in the WiFi marks existing in the current environment and is matched with a WiFi mark in a pre-stored historical connection record;
the detection unit is further used for detecting whether an instruction for closing the WiFi access point mode is received or not if the target WiFi identification in the WiFi identifications existing in the current environment is detected to be matched with the WiFi identification in the pre-stored historical connection record;
the first setting unit is used for setting the mark information used for indicating not to unload the preset drive when detecting and receiving the command of closing the WiFi access point mode, so that the mobile terminal identifies the mark information when detecting and receiving the command of opening the WiFi workstation mode, and runs a second application service in the WiFi workstation mode based on the loaded preset drive.
6. The mobile terminal of claim 4, wherein when the first operating mode is a WiFi access point mode and the second operating mode is a WiFi station mode, the mobile terminal further comprises:
the acquisition unit is used for acquiring a pre-stored WiFi use time set;
the detection unit is further configured to detect whether the current time belongs to the WiFi use time set;
the detection unit is further configured to detect whether an instruction to close a WiFi access point mode is received if it is detected that the current time belongs to the WiFi use time set;
and the second setting unit is used for setting the mark information for indicating not to unload the preset drive when detecting and receiving the command for closing the WiFi access point mode, so that the mark information is identified when the mobile terminal detects and receives the command for opening the WiFi workstation mode, the loaded preset drive is based on the mark information, and a second application service is operated to open the WiFi workstation mode.
7. A mobile terminal, comprising:
the system comprises a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface are connected through the communication bus and complete mutual communication;
the memory stores executable program code, the communication interface is for wireless communication;
the processor is configured to call the executable program code in the memory to perform the method as described in any of claims 1-3.
8. A computer-readable storage medium, characterized in that it stores a computer program for instructing associated hardware to perform the method as described in any one of claims 1 to 3.
CN201611116922.4A 2016-12-07 2016-12-07 Mobile terminal working mode switching method and mobile terminal Active CN106506862B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611116922.4A CN106506862B (en) 2016-12-07 2016-12-07 Mobile terminal working mode switching method and mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611116922.4A CN106506862B (en) 2016-12-07 2016-12-07 Mobile terminal working mode switching method and mobile terminal

Publications (2)

Publication Number Publication Date
CN106506862A CN106506862A (en) 2017-03-15
CN106506862B true CN106506862B (en) 2019-05-10

Family

ID=58329820

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611116922.4A Active CN106506862B (en) 2016-12-07 2016-12-07 Mobile terminal working mode switching method and mobile terminal

Country Status (1)

Country Link
CN (1) CN106506862B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107370646B (en) * 2017-07-19 2021-03-12 深圳Tcl数字技术有限公司 Network sharing method, television and computer readable storage medium
CN107479934B (en) * 2017-08-22 2020-08-11 四川长虹电器股份有限公司 Method for rapidly switching on and off Wi-Fi of Android equipment
TWI757550B (en) * 2017-10-10 2022-03-11 日商村田機械股份有限公司 Communication method and communication system
CN108521506A (en) * 2018-03-29 2018-09-11 四川斐讯信息技术有限公司 A kind of communication means and device of mobile terminal
CN114158136B (en) * 2020-08-17 2023-06-09 Oppo(重庆)智能科技有限公司 WiFi mode configuration method and device and computer-readable storage medium
CN112256335B (en) * 2020-09-25 2023-06-27 宇龙计算机通信科技(深圳)有限公司 Method and device for loading drive file, storage medium and electronic equipment
CN112565680A (en) * 2020-11-09 2021-03-26 天擎集成电路股份有限公司 Radio frequency/wireless network device with multi-workstation mode, image monitoring equipment and wireless communication system
CN113329198A (en) * 2021-02-07 2021-08-31 浪潮云信息技术股份公司 Mobile law enforcement method and system based on 4G technology and individual law enforcement recorder

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102098761A (en) * 2009-12-10 2011-06-15 华为终端有限公司 Mobile communication terminal and network access method thereof
CN103139876A (en) * 2011-11-24 2013-06-05 北京千橡网景科技发展有限公司 Method and device selecting wireless access mode for mobile terminal adaptively
CN103945499A (en) * 2014-04-17 2014-07-23 美的集团股份有限公司 Switching method and device of working modes of WIFI module
US20140219148A1 (en) * 2013-02-04 2014-08-07 Huawei Device Co., Ltd. Method and Apparatus for Waking Up a Device
WO2016095186A1 (en) * 2014-12-19 2016-06-23 Thomson Licensing Method and device for device configuration
CN106027294A (en) * 2016-05-13 2016-10-12 广东欧珀移动通信有限公司 Firmware loading method and system for terminal network access

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102098761A (en) * 2009-12-10 2011-06-15 华为终端有限公司 Mobile communication terminal and network access method thereof
CN103139876A (en) * 2011-11-24 2013-06-05 北京千橡网景科技发展有限公司 Method and device selecting wireless access mode for mobile terminal adaptively
US20140219148A1 (en) * 2013-02-04 2014-08-07 Huawei Device Co., Ltd. Method and Apparatus for Waking Up a Device
CN103945499A (en) * 2014-04-17 2014-07-23 美的集团股份有限公司 Switching method and device of working modes of WIFI module
WO2016095186A1 (en) * 2014-12-19 2016-06-23 Thomson Licensing Method and device for device configuration
CN106027294A (en) * 2016-05-13 2016-10-12 广东欧珀移动通信有限公司 Firmware loading method and system for terminal network access

Also Published As

Publication number Publication date
CN106506862A (en) 2017-03-15

Similar Documents

Publication Publication Date Title
CN106506862B (en) Mobile terminal working mode switching method and mobile terminal
US10069818B2 (en) Method, system, device, and terminal for network initialization of multimedia playback device
EP3468255B1 (en) Method for accessing wireless network, and mobile terminal
WO2018219119A1 (en) Application function control method and relevant product
CN106681860B (en) A kind of data back up method and data backup device
CN106446111B (en) Data migration method and terminal
WO2018103443A1 (en) Network positioning method and terminal device
WO2018049885A1 (en) Data migration method and device
WO2019011324A1 (en) Method for determining access method of mobile terminal, storage medium, and mobile terminal
CN106604277B (en) Wireless network access method and mobile terminal
WO2018049884A1 (en) Data migration method and device
CN114565070B (en) Label binding method and device and mobile terminal
WO2018103381A1 (en) Method for accelerating switch-off of wi-fi station mode of terminal, and mobile terminal
CN107291327A (en) Application control method and related product
CN106507447A (en) A Wi-Fi hotspot connection method and mobile terminal
CN106686704B (en) Terminal monitoring method and mobile terminal
CN106658705B (en) Network positioning method and terminal equipment
WO2018219117A1 (en) Component display method and related product
CN111314900B (en) Wireless connection method, wireless connection device and mobile terminal
CN110602766B (en) Personal hotspot identification method and method for determining association relationship between terminals
CN106535229B (en) WiFi signal receiving sensitivity testing method and mobile terminal
CN106775856B (en) Mobile terminal working mode switching method and mobile terminal
CN110891262A (en) Bluetooth pairing method, system and terminal equipment
CN106933626B (en) Application association method and device
CN112261634B (en) Bluetooth transmission control method and device, terminal equipment and storage medium

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 523860 No. 18, Wu Sha Beach Road, Changan Town, Dongguan, Guangdong

Applicant after: OPPO Guangdong Mobile Communications Co., Ltd.

Address before: 523860 No. 18, Wu Sha Beach Road, Changan Town, Dongguan, Guangdong

Applicant before: Guangdong OPPO Mobile Communications Co., Ltd.

GR01 Patent grant
GR01 Patent grant