Method and device for controlling starting of Wi-Fi network card and terminal equipment
Abstract
A method, device and terminal device for controlling the activation of a Wi-Fi network card of a wireless network communication technology are used to solve the problem that the terminal device in the prior art cannot realize long-distance communication through Wi-Fi service. The method is applied to a terminal device including a first interface for connecting an external WiFi network card and a built-in WiFi network card. The allowable communication distance of the external WiFi network card is greater than that of the built-in WiFi network card. The method includes detecting the first interface, the first interface is used to connect the external Wi-Fi network card, and when it is determined that the external Wi-Fi network card is connected to the first interface, the external Wi-Fi network card is activated. By detecting the first interface, it is determined that the external WiFi network card is connected to the first interface, and then the external WiFi network card is activated to ensure that the terminal device realizes long-distance communication through the WiFi service.

Term
15 yearsto projected expiry
Projected expiry 24 September 2041, counted from filing; an application has no term until it is granted.
- Priority and filed
- Published
- Today
- Projected expiry
10 claims: 2 independent, 8 dependent
- 1一种控制无线通信技术Wi-Fi网卡启动的方法,其特征在于,应用于终端设备,所述 终端设备包括用于连接外接Wi-Fi网卡的第一接□和内置Wi-Fi网卡,所述外接Wi-Fi网卡 允许的通信距离大于所述内置Wi-Fi网卡允许的通信距离; 所述方法包括: 检测所述第一接口,所述第一接口用于连接所述外接Wi -Fi网卡; 确定所述外接Wi -Fi网卡与所述第一接口连接,启动所述外接Wi -Fi网卡。
- 2如权利要求1所述的方法,其特征在于,所述确定所述外接Wi-Fi网卡与所述第一接 口连接,包括: 获取到第一事件,确定所述外接Wi -Fi网卡与所述第一接口连接,所述第一事件用于指 示所述外接Wi-Fi网卡插入所述第一接口 ; 所述启动所述外接Wi -Fi网卡之前,还包括: 关闭所述内置Wi-Fi网卡。
- 3如权利要求1或2所述的方法,其特征在于,所述终端设备还包括框架层和第一内核 层,所述第一内核层包括第一硬件抽象层、第一驱动和第一专用应用程序,所述第一内核层 与所述外接Wi-Fi网卡对应; 所述启动所述外接Wi -Fi网卡,包括: 所述框架层接收到第一事件,根据所述第一事件生成第一标记,其中,所述第一标记用 于指示开启所述外接Wi -Fi网卡对应的第一内核层; 所述框架层向所述第一硬件抽象层发送所述第一标记; 所述第一硬件抽象层根据接收到的所述第一标记启动所述第一专用应用程序,并向第 一专用应用程序发送所述第一标记; 所述第一专用应用程序根据接收到的所述第一标记加载所述第一驱动,并向所述第一 驱动发送所述第一标记; 所述第一驱动根据所述第一标记开启所述外接Wi-Fi网卡。
- 4如权利要求1所述的方法,其特征在于,所述启动所述外接Wi -Fi网卡之后,还包括: 确定所述外接Wi-Fi网卡从所述第一接口移除,启动所述内置Wi-Fi网卡。
- 5如权利要求4所述的方法,其特征在于,所述终端设备还包括框架层、第二内核层和 所述内置Wi-Fi网卡,所述第二内核层包括第二硬件抽象层、第二驱动和第二专用应用程 序,所述第二内核层与所述内置Wi-Fi网卡对应; 所述启动所述内置Wi-Fi网卡,包括: 所述框架层接收到第二事件,根据所述第二事件生成第二标记,所述第二事件用于标 识所述外接Wi-Fi网卡从所述第一接口移除,所述第二标记用于指示开启所述外接Wi-Fi网 卡对应的第二内核层; 所述框架层向所述第二硬件抽象层发送所述第二标记; 所述第二硬件抽象层根据接收到的所述第二标记启动所述第二专用应用程序,并向第 二专用应用程序发送所述第二标记; 所述第二专用应用程序根据接收到的所述第二标记加载所述第二驱动,并向所述第二 驱动发送所述第二标记; 所述第二驱动根据所述第二标记开启所述内置Wi -Fi网卡。
- 6如权利要求1所述的方法,其特征在于,所述启动所述外接Wi -Fi网卡之后,还包括: 显示第一界面,所述第一界面用于将所述外接Wi -Fi网卡切换为所述内置Wi -Fi网卡。
- 7如权利要求1或2所述的方法,其特征在于,所述第一接口通过OTG数据线连接所述外 接Wi-Fi网卡。
- 8一种控制装置,其特征在于,应用于终端设备,所述终端设备包括用于连接外接Wi Fi网卡的第一接□和内置Wi-Fi网卡,所述外接Wi-Fi网卡允许的通信距离大于所述内置 Wi-Fi网卡允许的通信距离;所述控制装置包括: 检测单元,用于检测所述第一接口,所述第一接口用于连接所述外接Wi -Fi网卡; 处理单元,用于确定所述外接Wi-Fi网卡与所述第一接口连接,并启动所述外接Wi-Fi 网卡。
- 9一种终端设备,其特征在于,包括内置Wi-Fi网卡、用于连接外接Wi-Fi网卡的第一接 □和处理器,所述外接Wi-Fi网卡允许的通信距离大于所述内置Wi-Fi网卡允许的通信距 离; 所述处理器,用于调用所述存储器中存储的计算机程序,按照获得的程序执行如权利 要求1至7任一项权利要求所述的方法。
- 10一种计算机可读存储介质,其特征在于,所述存储介质存储有程序,当所述程序在 计算机上运行时,使得计算机实现执行权利要求1至7中任一项所述的方法。
Independent claims10
106 paragraphs, as filed
A method, device and terminal equipment for controlling the startup of Wi-Fi network cardTechnical field
[0001] The present invention relates to the field of wireless communication technology, and in particular to a method, device and terminal device for controlling the startup of a Wi-Fi network card.
Background technique
[0002] With the development of technology, wireless network technology has become an indispensable part of people's lives, and it has brought people a lot of convenience in their lives. At present, the wireless communication technology (Wireless Fidelity, Wi-Fi) network card is generally solidified inside the terminal device, which is called the built-in Wi-Fi network card, and the built-in Wi-Fi network card provides Wi-Fi services for the terminal device.
[0003] However, the built-in Wi-Fi network card cannot satisfy long-distance transmission, and because the built-in Wi-Fi network card is usually not flexibly replaced, the long-distance communication of the terminal device is greatly restricted.
[0004] In summary, how to enable terminal devices to realize long-distance communication through Wi-Fi services is a technical problem that needs to be solved urgently at present.
Summary of the invention
[0005] Embodiments of the present invention provide a method, a device, and a terminal device for controlling the startup of a Wi-Fi network card, so as to solve the problem that the terminal device in the prior art cannot realize long-distance communication through Wi-Fi service.
[0006] In the first aspect, an embodiment of the present invention provides a method for controlling the startup of a Wi-Fi network card. The method can be applied to a terminal device. The terminal device includes a first interface for connecting an external Wi-Fi network card. With a built-in Wi-Fi network card, the allowable communication distance of the external Wi-Fi network card is greater than the allowable communication distance of the built-in Wi-Fi network card. The method includes detecting a first interface, the first interface being used to connect the external Wi-Fi network card; determining that the external Wi-Fi network card is connected to the first interface, and starting the external Wi-Fi network card.
[0007] In the above technical solution, it is determined by detecting the first interface that the external Wi-Fi network card is connected to the first interface, and then the external Wi-Fi network card is activated. In this way, the solution connects the external Wi-Fi network card through the first interface, so that the terminal device can start the external Wi-Fi network card when communicating over a long distance, thereby effectively ensuring that the terminal device realizes normal long-distance communication through the Wi-Fi service.
[0008] Optionally, the determining that the external Wi-Fi network card is connected to the first interface includes acquiring a first event, determining that the external Wi-Fi network card is connected to the first interface, the The first event is used to instruct the external Wi-Fi network card to be inserted into the first interface; before starting the external Wi-Fi network card, the method further includes: turning off the built-in Wi-Fi network card.
[0009] In the above technical solution, when the external Wi-Fi network card is connected to the first interface, a first event is received, and based on the first event, it can be determined that the external Wi-Fi network card is inserted into the first interface. Furthermore, if it is determined that the built-in Wi-Fi network card is turned on at this time, the built-in Wi-Fi network card needs to be turned off first, and then the external Wi-Fi network card is turned on, that is, switch to the external Wi-Fi network card.
[0010] Optionally, the terminal device further includes a framework layer and a first kernel layer. The first kernel layer includes a first hardware abstraction layer, a first driver, and a first dedicated application. The first kernel layer Corresponding to the external Wi-Fi network card; the activating the external Wi-Fi network card includes: the framework layer receives a first event, and generates a first event according to the first event
A mark, the first mark is used to indicate that the first kernel layer corresponding to the external Wi-Fi network card is turned on; the framework layer sends the first mark to the first hardware abstraction layer; the first hardware The abstraction layer starts the first dedicated application according to the received first mark, and sends the first mark to the first dedicated application; the first dedicated application according to the received first mark Load the first driver, and send the first mark to the first driver; the first driver turns on the external Wi-Fi network card according to the first mark.
[0011] In the above technical solution, the external Wi-Fi network card can be turned on through the interaction between the layers.
[0012] Optionally, after starting the external Wi-Fi network card, the method further includes: determining that the external Wi-Fi network card is removed from the first interface, and starting the built-in Wi-Fi network card.
[0013] In the above technical solution, when the external Wi-Fi network card is removed from the terminal device, the built-in Wi-Fi network card will be activated to provide Wi-Fi services for the terminal device.
[0014] Optionally, the terminal device further includes a framework layer, a second core layer, and a built-in Wi-Fi network card, and the core layer includes a second hardware abstraction layer, a second driver, and a second dedicated application. The second core layer corresponds to the built-in Wi-Fi network card. The activating the built-in Wi-Fi network card includes:
[0015] The framework layer receives a second event, generates a second mark according to the second event, and the second event is used to identify that the external Wi-Fi network card is removed from the first interface, the The second mark is used to indicate to enable the second kernel layer corresponding to the external Wi Fi network card; the framework layer sends the second mark to the second hardware abstraction layer, and the second hardware abstraction layer The second mark starts the second dedicated application, and sends the second mark to the second dedicated application; the second dedicated application loads the second driver according to the received second mark, And send the second mark to the second driver; the second driver turns on the built-in Wi-Fi network card according to the second mark.
[0016] In the above technical solution, the built-in Wi-Fi network card can be turned on through interaction between layers.
[0017] Optionally, after the activation of the external Wi-Fi network card, the method further includes: displaying a first interface, where the first interface is used to switch the external Wi-Fi network card to the built-in Wi-Fi Network card.
[0018] In the above technical solution, by selecting the built-in Wi-Fi network card on the first interface, it is possible to switch the external Wi-Fi network card to the built-in Wi-Fi network card.
[0019] Optionally, the first interface is connected to the external Wi-Fi network card through an OTG data line.
[0020] In the above technical solution, the OTG can realize the connection between the first interface and the external Wi-Fi network card through the OTG data line.
[0021] In the second aspect, an embodiment of the present invention also provides a control device, which is applied to a terminal device, and the terminal device includes a first interface for connecting an external Wi-Fi network card and a built-in Wi-Fi network card, so The communication distance allowed by the external Wi-Fi network card is greater than the communication distance allowed by the built-in Wi-Fi network card. The control device includes: a detection unit for detecting a first interface, the first interface for connecting to the external Wi-Fi network card; a processing unit for determining that the external Wi-Fi network card is connected to the first interface , And start the external Wi-Fi network card.
[0022] Optionally, the processing unit is specifically configured to: obtain a first event, and determine that the external Wi-Fi network card is connected to the first interface, and the first event is used to indicate the external Wi-Fi The Fi network card is inserted into the first interface; the processing unit is also used to turn off the built-in Wi-Fi network card; the processing unit is also used to start the external Wi-Fi network card, including: the framework layer receives At the first event, a first mark is generated according to the first event, and the first mark is used to indicate to turn on the first kernel layer corresponding to the external Wi-Fi network card; the framework layer abstracts to the first hardware Layer sends the first mark; the first hardware abstraction layer sends the first mark to a first dedicated application, wherein the first hardware abstraction layer starts the first mark according to the received first mark Dedicated application; said first dedicated application
Send the first mark to the first driver, wherein the first dedicated application loads the first driver according to the received first mark; the first driver turns on the external connection according to the first mark Wi-Fi network card.
[0023] Optionally, the device further includes a determining unit and a starting unit, wherein the determining unit is used to determine that the external Wi-Fi network card is removed from the first interface; the starting unit is used to start the built-in Wi-Fi Fi network card.
[0024] Optionally, the activation unit is configured to activate the built-in Wi-Fi network card, including: the framework layer receives a second event, generates a second mark according to the second event, the second event It is used to identify that the external Wi-Fi network card is removed from the first interface, and the second mark is used to indicate that the second core layer corresponding to the external Wi-Fi network card is turned on; the frame layer is directed to the The second hardware abstraction layer sends the second mark; the second hardware abstraction layer starts the second dedicated application according to the received second mark, and sends the second mark to the second dedicated application The second dedicated application loads the second driver according to the received second mark, and sends the second mark to the second driver; the second driver turns on the second drive according to the second mark Built-in Wi-Fi network card.
[0025] Embodiments of the present invention also provide a terminal device, which may include a built-in Wi-Fi network card, a first interface for connecting an external Wi-Fi network card, and a processor, the external Wi-Fi network card The allowable communication distance is greater than the allowable communication distance of the built-in Wi-Fi network card; the processor is used to call a computer program stored in the memory, and execute the method for controlling the startup of the Wi-Fi network card according to the obtained program.
[0026] The embodiment of the present invention also provides a computer-readable storage medium, the storage medium stores a program, and when the program runs on a computer, the computer executes a method for controlling the startup of a Wi-Fi network card.
Description of the drawings
[0027] In order to more clearly describe the technical solutions in the embodiments of the present invention, the following will briefly introduce the drawings needed in the description of the embodiments. Obviously, the drawings in the following description are only some implementations of the present invention. For example, for those of ordinary skill in the art, without creative labor, other drawings can be obtained from these drawings.
[0028] FIG. 1 is a schematic diagram of a possible application scenario provided by an embodiment of the present invention;
[0029] FIG. 2 is a schematic diagram of a Wi-Fi system architecture provided by an embodiment of the present invention;
[0030] FIG. 3a is a schematic diagram of a Wi-Fi system architecture provided by an embodiment of the present invention;
[0031] FIG. 3b is a schematic diagram of a Wi-Fi system architecture provided by an embodiment of the present invention;
[0032] FIG. 4 is a schematic flowchart of a method for controlling the startup of a Wi-Fi network card according to an embodiment of the present invention;
[0033] FIG. 5 is a schematic flowchart of a method for starting an external Wi-Fi network card according to an embodiment of the present invention;
[0034] FIG. 6 is a schematic flowchart of a method for starting a built-in Wi-Fi network card according to an embodiment of the present invention;
[0035] FIG. 7 is a schematic diagram of a first interface provided by an embodiment of the present invention;
[0036] FIG. 8 is a schematic structural diagram of a control device provided by an embodiment of the present invention;
[0037] FIG. 9 is a schematic structural diagram of a terminal device according to an embodiment of the present invention.
detailed description
[0038] In order to make the objectives, technical solutions, and advantages of the present invention clearer, the present invention will be further described in detail below in conjunction with the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of them. example. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative work shall fall within the protection scope of the present invention.
[0039] As shown in FIG. 1, it is a schematic diagram of a possible application scenario provided by an embodiment of the present invention. The application scenario may include at least two terminal devices. FIG. 1 uses two terminal devices (ie, the first terminal device 101 and the second terminal device 102 as an example). The terminal device in FIG. 1 is an example of a smart phone. Generally, the first terminal device 101 and the second terminal device 102 can communicate in a wireless manner. The operating system of the first terminal device 101 may be an Android system, and the operating system of the second terminal device 102 may be an iPhone Operating System (iOS); or, the operating system of the first terminal device 101 may be iOS. System, the operating system of the second terminal device 102 is the Android system; or, the operating systems of the first terminal device 101 and the second terminal device 102 are both iOS systems; or, the operations of the first terminal device 101 and the second terminal device 102 The systems are all Android systems.
[0040] In a specific application scenario, the distance between the first terminal device 101 and the second terminal device 102 is relatively short, and the first terminal device 101 and the second terminal device 102 can both communicate through their respective built-in Wi-Fi network cards. .
[0041] In another specific application scenario, the distance between the first terminal device 101 and the second terminal device 102 is relatively long, but the information exchanged between the first terminal device 101 and the second terminal device 102 has a real-time effect. The requirements are low, and the first terminal device 101 and the second terminal device 102 can also communicate through their respective built-in Wi-Fi network cards.
[0042] In another specific application scenario, the distance between the first terminal device 101 and the second terminal device 102 is relatively long, and communication cannot be achieved through the built-in Wi-Fi network card; or, the first terminal device 101 and the second terminal device 101 The terminal devices 102 are far apart, and the information exchanged between the first terminal device 101 and the second terminal device 102 requires real-time performance. Based on this, at least one of the first terminal device 101 and the second terminal device 102 activates the external Wi-Fi network card.
[0043] Illustratively, the first terminal device 101 may be a mobile phone, and the second terminal device 102 may be a drone. For example, drones can be used to record scenery on the road in the air, and drones need to send videos to mobile phones in real time. However, due to the long distance between the mobile phone and the drone, timely communication may not be achieved through the built-in Wi-Fi network card. In order to ensure that the mobile phone does not freeze when playing the video sent by the drone, at least one of the mobile phone and the drone uses an external Wi-Fi network card (or dedicated Wi-Fi) with a longer transmission distance (or called a wider coverage). Fi network card). It should be understood that the built-in Wi-Fi network card is an ordinary Wi-Fi network card and cannot achieve long-distance transmission. Moreover, the built-in Wi-Fi network card is usually solidified inside the terminal device and cannot be flexibly replaced.
[0044] In order to facilitate the understanding of the embodiments of the present application, as shown in FIG. 2, it is a schematic diagram of a common WiFi system architecture provided by an embodiment of the present invention. The system includes: Wi-Fi network card, kernel layer, framework layer (Framework) and application layer (application, App). Among them, the kernel layer includes a driver layer (driver), a dedicated application (wpa_supplicant) and a hardware abstraction layer (Hal). The role of each component of the Wi-Fi system architecture is: Wi-Fi network card is physical hardware. The driver layer is responsible for controlling the physical hardware (such as a Wi-Fi network card) and providing a control interface to the upper layer (such as a dedicated application). The dedicated application is mainly responsible for controlling the driver to search for hotspots, connect, etc. The hardware abstraction layer is mainly responsible for loading the Wi-Fi driver, starting the dedicated application, and connecting with the dedicated application, and sending commands such as hotspot scanning and connection to the dedicated application. The Wi-Fi service runs on the framework layer. The framework layer is mainly responsible for calling the hardware abstraction layer to communicate with wpa_supplicant, and at the same time providing Wi-Fi services to the upper layer (application layer); the application layer is mainly responsible for interacting with users, such as the Wi-Fi interface of Android set up.
[0045] If the terminal device uses the built-in Wi-Fi network card to communicate, it may be unable to communicate with other terminal devices. Combining the above application scenarios, when the first terminal device 101 and the second terminal device 102 both use the built-in Wi-Fi network card to communicate, it may cause the video received by the first terminal device 101 to freeze, that is, the first terminal device 101 displays The video of is not synchronized with the video captured by the second terminal device 102.
[0046] In view of this, an embodiment of the present invention provides a method for controlling Wi-Fi startup. This method can use an external Wi-Fi network card to meet the needs of long-distance transmission when the built-in WiFi network card cannot meet the long-distance transmission.
[0047] As shown in FIG. 3a, it is a schematic diagram of a Wi-Fi system architecture provided by an embodiment of the present invention. The system architecture includes a built-in Wi-Fi system, an external Wi-Fi system and the first connection. Among them, the built-in Wi-Fi system and the external Wi-Fi system share the framework layer and the application layer. The built-in Wi-Fi system also includes the second core layer, and the external Wi-Fi system also includes the first core layer. Among them, the first interface is an interface of the terminal device.
[0048] Further, optionally, an external Wi-Fi network card can be connected to the first interface of the terminal device through a (On The Go, OTG) data line, where the OTG data line refers to a data line based on OTG technology, OTG technology allows data transmission between devices (such as terminal devices and external Wi-Fi network cards) without a host.
[0049] As shown in FIG. 3b, it is a schematic diagram of another Wi-Fi system architecture provided by an embodiment of the present invention. The system architecture includes a built-in Wi-Fi system, an external Wi-Fi system, a first interface and a converter.
[0050] Further, optionally, the converter can be connected to the first interface of the terminal device through at least one OTG data line, and at least one external Wi-Fi network card is connected to the converter. For example, three external Wi-Fi network cards are connected to the converter, and the three external Wi-Fi network cards are suitable for different scenarios. For example, the first external Wi-Fi network card is suitable for long-distance transmission scenarios, and the second The external Wi-Fi network card is suitable for scenarios with low latency, and the third external Wi-Fi network card is suitable for scenarios with faster transmission speeds.
[0051] Optionally, when the terminal device is connected to the converter, and three external Wi-Fi network cards are inserted into the converter, when the terminal device needs to meet the requirements of long-distance transmission, the user can choose to close the current loading on the application layer Wi-Fi network card, turn on the first external Wi-Fi network card, so that the terminal device can communicate with the first external Wi-Fi network card.
[0052] Optionally, when the terminal device needs to meet the lower latency requirement, the user can choose to turn off the currently loaded Wi-Fi network card on the application layer and turn on the second external Wi-Fi network card, so that the terminal device is The second external Wi-Fi network card can be used for communication;
[0053] Optionally, when the terminal device needs to meet the requirement of faster transmission speed, the user can choose to turn off the currently loaded Wi-Fi network card on the application layer and turn on the third external Wi-Fi network card, so that the terminal device is A third external Wi-Fi network card can be used for communication.
[0054] In this case, by inserting at least one external Wi-Fi network card into the converter, it can be satisfied that the terminal device switches the external Wi-Fi network card in different scenarios.
[0055] As shown in FIG. 4, it is a schematic flowchart of a method for controlling the startup of a Wi-Fi network card according to an embodiment of the present invention. The method includes the following steps:
[0056] Step 401: Detect the first interface.
[0057] In the embodiment of the present invention, the first interface in the terminal device is used to connect an external Wi-Fi network card. Specifically, the first driver will report the first event after detecting that the external Wi-Fi network card is connected to the first interface. For the framework layer, if the first driver does not detect that the external Wi-Fi network card is connected to the first interface, it will continue to detect, and the first event will not be reported to the framework layer until the external Wi-Fi network card is connected to the first interface.
[0058] Step 402, if it is determined that the external Wi-Fi network card is connected to the first interface, start the external Wi-Fi network card.
[0059] In the embodiment of the present invention, if the external Wi-Fi network card is connected to the first interface, that is, the external Wi-Fi network card has been inserted into the first interface, then the terminal device will use the external Wi-Fi network card to communicate . It should be understood that the external Wi-Fi network card is not connected to the first interface, that is, if there is no external network card and the first interface is inserted, the terminal device can continue to use the current built-in Wi-Fi network card, in other words, the terminal device maintains the current state.
[0060] It can be seen from the above steps 401 to 402 that when the external Wi-Fi network card is connected to the first interface, and the external Wi-Fi interface is activated, the terminal device can perform long-distance communication through the external Wi-Fi network card. Specifically, built-in Wi-Fi
The network card is suitable for short-distance transmission, and the external Wi-Fi network card is suitable for long-distance transmission. When the terminal device does not need long-distance communication, the built-in Wi-Fi network card of the terminal device can meet the communication requirements. When the terminal device needs long-distance communication, the WiFi network card needs to meet the requirements of long-distance transmission, but the built-in Wi-Fi network card cannot meet the long-distance communication requirements. At this time, in order to meet the long-distance communication requirements, the terminal device will start the external Wi-Fi network card Realize long-distance communication. Therefore, the terminal device can switch to use different Wi-Fi network cards in different scenarios to meet different communication requirements.
[0061] As shown in FIG. 5, it is a schematic flowchart of a method for starting an external Wi-Fi network card according to an embodiment of the present invention. [0062] Step 501: The first driver detects that the external Wi-Fi network card is connected to the first interface, and reports the first event to the framework layer.
[0063] In the embodiment of the present invention, the first event is used to indicate that the external Wi-Fi network card is inserted into the first interface. When the first driver detects that the external Wi-Fi network card is connected to the first interface, the first event is generated and Report the first event to the framework layer.
[0064] Step 502, the framework layer generates a first mark according to the received first event and sends it to the first hardware abstraction layer.
[0065] In the embodiment of the present invention, the first mark is used to indicate that the first core layer corresponding to the external Wi-Fi network card is turned on. Therefore, the framework layer generates the first mark and sends the first mark to the first core layer in the first core layer. A hardware abstraction layer.
[0066] Step 503, the first hardware abstraction layer starts the first dedicated application according to the received first mark, and sends the first mark to the first dedicated application.
[0067] In the embodiment of the present invention, the first tag carries information for enabling the first kernel layer. After the first hardware abstraction layer receives the first tag, it will start the first dedicated application according to the information carried by the first tag. Program, and send the first mark to the first dedicated application.
[0068] Step 504, the first dedicated application sends a first mark to the first driver, and loads the first driver according to the received first mark.
[0069] Step 505: The first driver turns on the external Wi-Fi network card according to the first flag.
[0070] Through the above steps 501 to step 505, it can be seen that when the first driver detects that the external Wi-Fi network card is connected to the first connection, it will generate a first event and report it to the framework layer, and then the framework layer according to the first event The generated first mark is sent to the first kernel layer to implement the process of turning on the external Wi-Fi network card.
[0071] As shown in FIG. 6, a schematic flowchart of a method for starting a built-in Wi-Fi network card provided by an embodiment of the present invention.
[0072] Step 601, the second driver detects that the external Wi-Fi network card is removed from the first interface, and reports the second event to the framework layer.
[0073] In the embodiment of the present invention, the second event is used to identify that the external Wi-Fi network card is removed from the first interface, and the second driver detects that the external Wi-Fi network card is removed from the first interface. Second event and report the second event to the framework layer.
[0074] Step 602, the framework layer generates a second mark according to the received second event and sends it to the second hardware abstraction layer, where the framework layer will first close the terminal device Wi-Fi service after receiving the second event, and then turn it on Wi-Fi service for terminal equipment.
[0075] In the embodiment of the present invention, the second mark is used to indicate that the second core layer corresponding to the built-in Wi-Fi network card is turned on. Therefore, the framework layer generates the second mark and sends the second mark to the second core layer in the second core layer. 2. Hardware abstraction layer.
[0076] Step 603, the second hardware abstraction layer sends a second mark to the second dedicated application, and starts the second dedicated application according to the received second mark.
[0077] In the embodiment of the present invention, the second mark carries the information for enabling the second kernel layer, so the second hardware abstraction layer will start the second dedicated application according to the second mark, and send the second mark to the second Dedicated application.
[0078] Step 604, a second dedicated application program loads the second driver according to the received second mark, and sends the second mark to the second driver.
[0079] Step 605: The second driver turns on the built-in Wi-Fi network card according to the second mark.
[0080] It can be seen from the above steps 601 to 605 that when the second driver detects that the external Wi-Fi network card is removed from the first interface, it will generate a second event and report it to the framework layer, and then the framework layer according to the second event The generated second mark is sent to the second kernel layer to implement the process of turning on the built-in Wi-Fi network card.
[0081] Based on the schematic flow chart of the method for starting the built-in Wi-Fi network card shown in FIG. 6, when the terminal device needs to switch the external Wi-Fi network card to the built-in Wi-Fi network card, in a possible implementation manner, you can The external Wi-Fi network card is removed from the terminal device to achieve the purpose of turning off the external Wi-Fi network card and turning on the built-in Wi-Fi network card. Specifically, when the external Wi-Fi network card is removed from the terminal device, the second event is reported to the framework layer, and the framework layer generates a second mark according to the received second event, where the second mark is used to indicate that the built-in The second core layer corresponding to the Wi-Fi network card. First, when the framework layer receives the second event, it will first close the external Wi-Fi network card that is being loaded. After closing the external Wi-Fi network card, the framework layer sends the second mark to the second corresponding to the built-in Wi-Fi network card. At the kernel layer, finally start the built-in Wi-Fi network card. In this possible implementation, the application layer is only used to display the name of the Wi-Fi network card currently being loaded on the application interface.
[0082] In another possible implementation manner, the terminal device may not remove the external Wi-Fi network card from the terminal device, and only requires the user to switch the external Wi-Fi network card on the first interface (such as the application interface) To the built-in Wi-Fi network card, the terminal device can switch the external Wi-Fi network card to the built-in Wi-Fi network card. As shown in FIG. 7, it is a schematic diagram of a first interface provided by an embodiment of the present invention. The first interface includes an option for turning on the external Wi-Fi network card and a strobe for turning on the built-in Wi-Fi network card. Specifically, when the user turns off the external Wi-Fi network card on the first interface, the application layer sends a first instruction to the framework layer, where the first instruction is used to instruct to turn off the external Wi-Fi network card and turn on the built-in Wi-Fi network card. After the framework layer receives the first instruction, the framework layer generates a second mark according to the first instruction, and then the framework layer first closes the external Wi-Fi network card being loaded, and then sends the second mark to the second kernel layer, and finally Turn on the built-in Wi-Fi network card. In this possible way, the application layer not only sees the name of the currently loaded Wi-Fi network card on the first interface, but can also switch between the built-in Wi-Fi network card and the external Wi-Fi network card, because this The switching method does not remove the external Wi-Fi network card from the terminal device, so when the terminal device again needs to meet the requirements of long transmission distance, it can be directly on the first interface Select an external Wi-Fi network card to switch.
[0083] Based on the same technical concept as described above, an embodiment of the present invention also provides a control device that can execute the method in the foregoing method embodiment. The structure of the control device provided by the embodiment of the present invention can be seen in FIG. 8. The control device 800 includes: a detection unit 801 for detecting a first interface, and the first interface is used for connecting the external Wi-Fi network card; a processing unit 802 It is used to determine that the external Wi-Fi network card is connected to the first interface, and to activate the external Wi-Fi network card. [0084] In some exemplary embodiments, the processing unit 802 is specifically configured to obtain a first event, determine that the external Wi-Fi network card is connected to the first interface, and the first event is used to indicate The external Wi-Fi network card is inserted into the first interface. The processing unit 802 is further configured to activate the external Wi-Fi network card, including: the framework layer receives a second event, generates a second mark according to the second event, and the second event is used to identify the The external Wi-Fi network card is removed from the first interface, and the second mark is used to indicate that the second core layer corresponding to the external Wi-Fi network card is turned on; the framework layer is directed to the second hardware abstraction layer Sending the second mark; the second hardware abstraction layer starts the second dedicated application according to the received second mark, and sends the second mark to the second dedicated application; the first Second, the dedicated application loads the second driver according to the received second mark, and sends the second mark to the second driver; the second driver turns on the built-in Wi-Fi according to the second mark Network card.
[0085] Optionally, the control device 800 further includes: a determining unit for determining that the external Wi-Fi network card is
An interface is removed; the activation unit is used to activate the built-in Wi-Fi network card.
[0086] In some exemplary embodiments, the activation unit is specifically configured to activate the built-in Wi-Fi network card, including: the framework layer receives a second event, and generates a second event according to the second event. Two marks, the second event is used to identify that the external Wi-Fi network card is removed from the first interface, and the second mark is used to indicate that the second core layer corresponding to the external Wi-Fi network card is turned on; The framework layer sends the second mark to the second hardware abstraction layer; the second hardware abstraction layer starts the second dedicated application according to the received second mark, and sends it to the second dedicated application Sending the second mark; the second dedicated application loads the second driver according to the received second mark, and sends the second mark to the second driver; the second driver according to the The second mark turns on the built-in Wi Fi network card.
[0087] Based on the same technical concept as described above, an embodiment of the present invention also provides a terminal device. As shown in FIG. 9, the terminal device 900 includes at least one processor 901, a built-in Wi-Fi network card 902, and an external Wi-Fi -The first interface 903 of the Fi network card. Further, optionally, the terminal device may further include a memory 904.
[0088] In the embodiment of the present application, the memory 904 stores instructions that can be executed by at least one processor 901. By executing the instructions stored in the memory 904, the at least one processor 901 can execute the aforementioned method for controlling and starting a Wi-Fi network card. The steps included in.
[0089] Among them, the processor 901 is the control center of the terminal device, which can use various interfaces and lines to connect to various parts of the terminal device, by running or executing instructions stored in the memory 904 and calling data stored in the memory 904, So as to realize data processing. Optionally, the processor 901 may include one or more processing units, and the processor 901 may integrate an application processor and a modem processor. The application processor mainly processes the operating system, user interface, and application programs, etc. The modem The adjustment processor mainly handles issuing instructions. It can be understood that the foregoing modem processor may not be integrated into the processor 901. In some embodiments, the processor 901 and the memory 904 may be implemented on the same chip, and in some embodiments, they may also be implemented on separate chips.
[0090] The processor 901 may be a general-purpose processor, such as a central processing unit (CPU), a digital signal processor, an application specific integrated circuit (Application Specific Integrated Circuit, ASIC), a field programmable gate array or other programmable logic devices, discrete Gates or transistor logic devices and discrete hardware components can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of the present application. The general-purpose processor may be a microprocessor or any conventional processor or the like. The steps of the method disclosed in the above-mentioned method embodiments for controlling Wi-Fi startup can be directly embodied as being executed and completed by a hardware processor, or executed and completed by a combination of hardware and software modules in the processor.
[0091] As a non-volatile computer-readable storage medium, the memory 904 can be used to store non-volatile software programs, non-volatile computer-executable programs, and modules. The memory 904 may include at least one type of storage medium, for example, may include flash memory, hard disk, multimedia card, card-type memory, random access memory (Random Access Memory, RAM), static random access memory (Static Random Access Memory, SRAM), Programmable Read Only Memory (PROM), Read Only Memory (Read Only Memory, ROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), magnetic memory, magnetic disk , CD, etc. The memory 904 is any other medium that can be used to carry or store desired program codes in the form of instructions or data structures and that can be accessed by a computer, but is not limited thereto. The memory 904 in the embodiment of the present application may also be a circuit or any other device capable of realizing a storage function for storing program instructions and/or data.
[0092] Based on the same technical concept as described above, an embodiment of the present application also provides a computer-readable storage medium, which
A computer program executable by the terminal device is stored, and when the program runs on the terminal device, the terminal device executes the steps of the method for controlling the activation of the Wi-Fi network card.
[0093] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, this application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, this application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
[0094] This application is described with reference to the flowcharts and/or block diagrams of the methods, devices (systems), and computer program products according to the application. It should be understood that each process and/or block in the flowchart and/or block diagram, and the combination of processes and/or blocks in the flowchart and/or block diagram can be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing equipment to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing equipment are used to generate It is a device that realizes the functions specified in one process or multiple processes in the flowchart and/or one block or multiple blocks in the block diagram.
[0095] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing equipment to work in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture including the instruction device , The instruction device realizes the functions specified in one process or multiple processes in the flowchart and/or one block or multiple blocks in the block diagram.
[0096] These computer program instructions can also be loaded on a computer or other programmable data processing equipment, so that a series of operation steps are executed on the computer or other programmable equipment to produce computer-implemented processing, so that the computer or other programmable equipment The instructions executed above provide steps for implementing functions specified in a flow or multiple flows in the flowchart and/or a block or multiple blocks in the block diagram.
[0097] Although the preferred embodiments of the present application have been described, those skilled in the art can make additional changes and modifications to these embodiments once they learn the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present application.
[0098] Obviously, those skilled in the art can make various changes and modifications to the application without departing from the spirit and scope of the application. In this way, if these modifications and variations of this application fall within the scope of the claims of this application and their equivalent technologies, this application also intends to include these modifications and variations.
1 sheet
Sheet 1
Every citation, both waysCites: the store holds 10 of 11
| Document | Relation | Office | Category | Cited during | Relevant claims |
|---|---|---|---|---|---|
| CN104918272A | Cites | China | Y | Search report | 1-10 |
| CN105025183A | Cites | China | A | Search report | 1-10 |
| CN106445516A | Cites | China | A | Search report | 1-10 |
| CN108966302A | Cites | China | A | Search report | 1-10 |
| CN109412830A | Cites | China | A | Search report | 1-10 |
| CN111629412A | Cites | China | Y | Search report | 1-10 |
| CN112540801A | Cites | China | Y | Search report | 3、5 |
| CN113037737A | Cites | China | A | Search report | 1-10 |
| US2009204725A1 | Cites | United States of America | A | Search report | 1-10 |
| US2015055562A1 | Cites | United States of America | A | Search report | 1-10 |
| 陈强编著: "《Android底层接口与驱动开发技术详解》", 31 August 2012, 中国铁道出版社, pages: 480 - 491 | Non-patent | – | – | Search report | – |
1 member in 1 office
Priority claims2
| Document | Office | Kind | Date |
|---|---|---|---|
| 202111119650 | China | A | |
| CN202111119650 | – | – | – |
Members1
| Document | Office | Kind | |
|---|---|---|---|
| CN113835783AThis record | China | A |
4 legal events, as the office reported them to INPADOC
Over the term
Point at a mark for the eventEvents
| Event | Code | |
|---|---|---|
| Rejection of invention patent application after publicationRJ01 | RJ01 | |
| Change of applicant informationCB02 | CB02 | |
| Entry into force of request for substantive examinationSE01 | SE01 | |
| PublicationPB01 | PB01 |
Numbers
- Publication
- 113835783
- Publication, DOCDB
- 113835783
- Publication, EPODOC
- CN113835783
- Application
- 111196504
- Application, DOCDB
- 202111119650
- Application, EPODOC
- CN202111119650
Titles2
- Chinese
- 一种控制Wi-Fi网卡启动的方法、装置及终端设备
- English
- Method, device and terminal equipment for controlling the startup of Wi-Fi network card
Classification
- CPC, 2
- G06F9/44505
- H04W84/12
- IPC, 2
- G06F9 445
- H04W84 12