Icon Display Method, Electronic Device, Chip System and Storage Medium
By setting the first sign in the electronic device to record the access status of the charger, the problem of the charging icon still being displayed after the device is disconnected is solved, and the user experience improvement of the icon display consistent with the actual situation is achieved.
Patent Information
- Application Number
- CN202411001989.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-24
- Publication Date
- 2025-07-04
- Estimated Expiration
- 2044-07-24
AI Technical Summary
In electronic devices, when multiple external devices connected through docks are disconnected, the charging icon cannot disappear correctly, resulting in poor user experience.
During the process of the external device and the charger accessing the electronic device interface through the dock, a first flag is additionally set to record the access status of the charger, so that the display of the charging icon is controlled by detecting the first flag when the device is disconnected.
Make sure the icon display is consistent with the actual situation, improve the user experience, and avoid the problem that the charging icon still displays after the device is disconnected.
Smart Images

Figure CN119071384B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of electronic devices, and in particular, to an icon display method and an electronic device. Background Art
[0002] Due to structural dimensions and hardware costs, electronic devices generally do not have many reserved interfaces. Therefore, in order to improve the compatibility of external devices, it is necessary to use a docking station to expand a single communication serial bus (universal serial bus, USB) interface into multiple interfaces of various types and quantities.
[0003] In an application scenario, the USB interface expands to at least two interfaces. One interface is plugged into a first external device (such as an analog headset) that does not supply power to the electronic device mutually, and the other interface is plugged into a charger. At this time, the electronic device will normally display the icon corresponding to the first external device and the charging icon. However, when the first external device and the charger are unplugged, only the icon corresponding to the first external device disappears, while the charging icon does not disappear. Summary of the Invention
[0004] This application provides an icon display method and an electronic device, which can solve the problem of icon display when disconnecting multiple external devices connected through a docking station.
[0005] In a first aspect, an embodiment of this application provides an icon display method. This method is applied to an electronic device, which is provided with an electronic device interface for accessing external devices. The icon display method includes: when it is detected that a first external device and a charger are disconnected from the electronic device interface, not displaying a first icon, and when it is detected that a first flag exists, not displaying a charging icon, where the first external device and the charger are connected to the electronic device interface through a docking station, the first external device and the electronic device do not supply power to each other, and the first flag is set during the process of the first external device and the charger accessing the electronic device interface through the docking station and is used to record the access status of the charger.
[0006] In the technical solution of this application, mainly by additionally setting a first flag for recording the access status of the charger during the process of the first external device and the charger accessing the electronic device interface through the docking station, when the first external device and the charger are disconnected, the problem that the charging icon is still displayed when the charger is disconnected can be solved by detecting the first flag, so that the display of the icon is consistent with the actual situation and the user experience is improved.
[0007] Wherein, the first external device may be an analog headset.
[0008] It should be noted that the traditional display logic of the charging icon is whether there is a valid power bus (Vbus) signal when it is inserted, and the disappearance logic is to decide whether to disappear according to the type of external device recognized by the electronic device when it is unplugged. However, no matter how many interfaces the electronic device interface expands, the electronic device can only recognize one type of external device at the same time, so the analog headset and charger are connected to the electronic device through the expansion dock, and the analog headset type is usually stored as the external device type. In this way, when the analog headset and charger are unplugged, the charger will not be able to notify the disappearance of the charging icon according to the type of external device. Under normal circumstances, analog headsets will not power electronic devices, and electronic devices will not power analog headsets, so they will not notify the disappearance of the charging icon. The above situation will cause the charging icon to be displayed on the screen of the electronic device all the time, but in fact the charger has been disconnected, which seriously affects the user experience.
[0009] Optionally, in a possible implementation of the first aspect, the icon display method further includes: when it is detected that the first external device and the charger are connected to the electronic device interface, displaying the first icon and displaying the charging icon. After the first external device is connected, the external device type can be detected to determine whether the first external device is successfully connected, and then the driver is notified to display the first icon. After the charger is connected, the Vbus signal can be detected to determine whether the charger is successfully connected, and then the charging icon is displayed.
[0010] Optionally, in another possible implementation of the first aspect, the displaying of the first icon includes: detecting and obtaining the type of the external device; and displaying the first icon when the type of the external device is a first type corresponding to the first external device.
[0011] Since there are many possibilities for external devices to be connected through the expansion dock, the following introduces several scenarios that may exist in the process of external device type detection. The first scenario is to first connect the first external device and the charger to the expansion dock, and then connect the expansion dock as a whole to the electronic device interface. At this time, due to the internal timing of the electronic device or the priority of the external device, the first type corresponding to the first external device is usually determined as the external device type; the second scenario is to first connect an empty expansion dock that is not connected to any external device to the electronic device interface, then connect the first external device to the expansion dock, and finally connect the charger to the expansion dock. At this time, the first type corresponding to the first external device that was connected first will be determined as the external device type; the third scenario is to first connect an empty expansion dock that is not connected to any external device to the electronic device interface, and then connect the charger to the expansion dock. At this time, the second type corresponding to the charger that was connected first will be determined as the external device type. If the first external device is then connected to the expansion dock, the external device type will be switched from the second type to the first type corresponding to the first external device.
[0012] In addition, when the first external device is an analog headset, correspondingly, the first icon can be a headset icon.
[0013] Optionally, in another possible implementation of the first aspect, the above method for detecting the type of the external device includes: determining the connection state of the external device by detecting the configuration channel (CC) pins of the electronic device interface; when the connection state is that an external device is connected, identifying the type of the external device by detecting the signal output by the CC pins. Among them, in the USB Type-C interface, the CC pins are used for connection and configuration between devices. That is to say, when the electronic device interface is a USB Type-C interface, the connection state of the external device can be determined by detecting whether the CC pins are valid, ensuring a correct connection is established between the external device and the electronic device, and the type of the external device can be correctly identified by detecting the signal output by the CC pins.
[0014] Optionally, in yet another possible implementation of the first aspect, the above method for icon display further includes: when it is detected that the signal output by the CC pins disappears, determining that the first external device is disconnected from the electronic device interface. Among them, the electronic device determines which type of external device is disconnected by detecting the change in the signal output by the CC pins. Specifically, when the signal output by the CC pins disappears, according to the recorded first type (i.e., the type of the external device corresponding to the first external device), it is determined that the disconnected device is the first external device.
[0015] Optionally, in still another possible implementation of the first aspect, the above method for icon display further includes: when the type of the external device is the second type corresponding to a charger, detecting the signal of the power bus Vbus; when there is a signal on the Vbus, displaying a charging icon and setting a first flag. Different from external devices such as analog headsets that do not supply power to each other with the electronic device, the electronic device determines whether it is connected to a charger by detecting whether the signal on the Vbus is valid. When the type of the external device is the second type corresponding to a charger, according to the display logic of the charging icon, the signal of the power bus Vbus is further detected. By detecting whether there is a signal on the Vbus, if there is a signal, it means that the charger is providing power, and a charging icon will be displayed on the electronic device. If the connection of the first external device has not been detected before the charger is disconnected, the charger will not display the charging icon according to the previously identified second type (i.e., the type of the external device corresponding to the charger) of the electronic device.
[0016] Optionally, in another possible implementation of the first aspect, the above icon display method further includes: after determining that the external device type is the second type, if it is detected again that the first external device is connected to the electronic device interface through the docking station and the charger is not disconnected from the electronic device interface, the external device type is updated from the second type to the first type. This is also the third scenario in the above process of detecting the external device type, that is, first connect the empty docking station without any external device to the electronic device interface, and then connect the charger to the docking station. At this time, the second type corresponding to the previously connected charger is determined as the external device type. After that, if the first external device is also connected to the docking station, the external device type will be switched from the second type to the first type corresponding to the first external device.
[0017] Optionally, in yet another possible implementation of the first aspect, the above display of the charging icon includes: detecting the signal of Vbus; when there is a signal on Vbus, displaying the charging icon and setting a first flag. After the charger is connected to the electronic device through the docking station, the electronic device detects whether there is a signal on Vbus. If there is a signal, it means that the charger is providing power, and the charging icon will be displayed on the electronic device. In addition, to avoid the charging icon still being displayed when the charger is unplugged later, when it is determined that the charger is connected to the electronic device through the docking station, it is necessary to add a setting of the first flag, so that when it is detected that the first external device and the charger are disconnected from the electronic device interface later, it can be determined that the charging icon is not displayed by detecting the first flag.
[0018] In a second aspect, an embodiment of the present application provides an icon display device, which includes a unit composed of software and / or hardware for executing the icon display method of the first aspect.
[0019] In a third aspect, an embodiment of the present application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the electronic device can implement any of the methods of the first aspect above.
[0020] In a fourth aspect, an embodiment of the present application provides a chip system, which is applied to an electronic device. The chip system includes one or more processors, and the one or more processors are used to call computer instructions so that the electronic device can execute any of the methods of the first aspect above.
[0021] Optionally, the chip system further includes a memory, and the memory is electrically connected to the processor.
[0022] Optionally, the chip system may further include a communication interface.
[0023] Fifth aspect, an embodiment of the present application provides a computer-readable storage medium, which includes instructions that enable an electronic device to execute any method of the first aspect when the instructions run on the electronic device.
[0024] Sixth aspect, an embodiment of the present application provides a computer program product, which includes a computer program that enables an electronic device to implement any method of the first aspect when the computer program is executed by the electronic device. Description of the Drawings
[0025] To more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0026] Figure 1 It is a schematic diagram of a scenario where an external device is connected to an electronic device through a docking station;
[0027] Figure 2 It is a schematic flowchart of an icon display method provided by an embodiment of the present application;
[0028] Figure 3 It is an example flowchart of an icon display method provided by an embodiment of the present application;
[0029] Figure 4 It is a block diagram of a software system of an electronic device provided by an embodiment of the present application;
[0030] Figure 5 It is a timing interaction diagram of an icon display method provided by an embodiment of the present application;
[0031] Figure 6 It is a schematic diagram of an interface display of a traditional solution and an embodiment of the present application;
[0032] Figure 7 It is a schematic structural diagram of an icon display device provided by an embodiment of the present application;
[0033] Figure 8 It is a schematic diagram of the hardware structure of an electronic device provided by an embodiment of the present application. Detailed Embodiments
[0034] To make the objectives, technical solutions, and advantages of the embodiments of the present application clearer, the following will further describe the embodiments of the present application in detail with reference to the drawings.
[0035] Refer to Figure 1, is a schematic diagram of a scenario where an external device is connected to an electronic device through a docking station. As Figure 1 shown, the electronic device is provided with a USB interface (an example of an electronic device interface) for connecting an external device. The USB interface is inserted into a docking station (hub, also known as a hub), which expands at least two interfaces. At least one of the expanded interfaces is adapted to a first external device (taking the first external device as an analog headphone as an example, the docking station needs to include at least a 3.5mm audio interface). At least one interface is adapted to a charger. One of the interfaces is inserted into the first external device, and the other interface is inserted into the charger. The first external device is an external device that does not supply power to each other with the electronic device. The types of the expanded interfaces can be USB TYPE-C interfaces, USB TYPE-A interfaces, TRS interfaces, RJ45 (registered jack 45) network ports, asynchronous transmission (RS232) standard interfaces, HDMI interfaces, and other interfaces.
[0036] Figure 1 Taking the electronic device in it as a mobile phone as an example, it should be understood that in the embodiments of the present application, the electronic device can be a mobile phone, a tablet computer, a wearable device, a vehicle-mounted device, an augmented reality (AR) / virtual reality (VR) device, a laptop computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), and so on. Exemplary embodiments of the electronic device include, but are not limited to, electronic devices equipped with an MTK platform. The specific type of the electronic device in the embodiments of the present application is not limited.
[0037] Figure 1 Taking the first external device in it as an analog headphone as an example, it should be understood that in the embodiments of the present application, the first external device can also be other external devices, as long as it does not supply power to each other with the electronic device when connected to the electronic device. For the convenience of understanding, an analog headphone is used to replace the first external device for description below. An analog headphone refers to a headphone that transmits audio through an analog signal. Different from a digital headphone, an analog headphone directly receives an analog signal from an audio source (such as a 3.5mm plug or other types of audio plugs), and converts it into sound waves for the user to listen to. The analog headphone does not supply power to the electronic device, and the electronic device should not supply power to the analog headphone either.
[0038] Figure 1 The type of the charger in it can be a normal charger, a fast charger, and a power delivery (PD) charger. The PD charger can be understood as a charger that uses the PD fast charging protocol.
[0039] In an application scenario, when an electronic device detects that an analog headset and a charger are connected to a USB interface (an example of an electronic device interface) through a docking station, the electronic device will normally display the headset icon (an example of the first icon) and the charging icon, but when the analog headset is disconnected from the charger, only the headset icon disappears, while the charging icon does not disappear. The reason for this is that the traditional display logic of the charging icon is whether there is a valid Vbus signal when inserted, and the disappearance logic is to determine whether to disappear according to the type of external device recognized by the electronic device when unplugged. However, no matter how many interfaces are extended from the electronic device interface, the electronic device can only recognize one type of external device at the same time, so the analog headset and the charger are connected to the electronic device through the docking station, and the analog headset type (an example of the first type) is usually stored as the external device type. In this way, when the analog headset and the charger are unplugged, the charger cannot notify the disappearance of the charging icon according to the type of external device. Under normal circumstances, the analog headset will not power the electronic device, and the electronic device will not power the analog headset, so it will not notify the disappearance of the charging icon. The above situation will cause the charging icon to be displayed on the screen of the electronic device all the time, but in fact the charger has been disconnected, which seriously affects the user experience.
[0040] In view of this, an embodiment of the present application provides an icon display method, which mainly sets a first flag for recording the access status of the charger during the process of the first external device and the charger being connected to the electronic device interface through the expansion dock. In this way, when the first external device and the charger are disconnected, the problem that the charging icon is still displayed when the charger is disconnected can be solved by detecting the first flag, so that the display of the icon is consistent with the actual situation, thereby improving the user experience.
[0041] Reference Figure 2 , shows a schematic diagram of a flow chart of an icon display method provided by an embodiment of the present application. Figure 2 Each step is described below.
[0042] Step 201: When it is detected that the simulated earphone and the charger are connected to the interface of the electronic device, the earphone icon and the charging icon are displayed.
[0043] It should be noted that since there are a wide variety of external devices connected to the interface of the electronic device, and different types of external devices need to start different functions after being connected to the interface of the electronic device. Therefore, when an external device is connected to the interface of the electronic device, the electronic device needs to identify the type of the external device. That is to say, among them, after the analog headset is connected, the type of the external device can be detected to determine that the analog headset is successfully connected, and then the driver is notified to display the headset icon. Then, based on the display logic of the charging icon, that is, after the charger is connected, the Vbus signal can be detected. If there is a signal, it means that the charger is providing power, and it is determined that the charger is successfully connected, and then the charging icon is displayed.
[0044] In the embodiment of the present application, since there are multiple possibilities for the external device to be connected through the docking station, several possible scenarios in the process of detecting the type of the external device will be introduced below.
[0045] In the first scenario, the analog headset and the charger are first connected to the docking station, and then the entire docking station is connected to the interface of the electronic device. At this time, due to the internal timing of the electronic device or the priority of the external device, the analog headset type corresponding to the analog headset is usually determined as the type of the external device.
[0046] In the second scenario, the empty docking station without connecting any external device is first connected to the interface of the electronic device, then the analog headset is connected to the docking station, and finally the charger is connected to the docking station. At this time, the analog headset type corresponding to the first-connected analog headset is determined as the type of the external device.
[0047] In the third scenario, the empty docking station without connecting any external device is first connected to the interface of the electronic device, and then the charger is connected to the docking station. At this time, the charger type corresponding to the first-connected charger (an example of the second type, specifically a PD charger, etc.) is determined as the type of the external device. If the analog headset is then connected to the docking station, the type of the external device will be switched from the second type to the analog headset type.
[0048] In an embodiment, regardless of which of the above scenarios the process of detecting the type of the external device is, if the type of the external device detected by detecting the type of the external device is the analog headset type, the headset icon is displayed.
[0049] In a possible implementation, in a USB Type-C interface, the CC pins are used for connection and configuration between devices. That is to say, when the interface of an electronic device is a USB Type-C interface, the connection status of an external device can be determined by detecting whether the CC pins are valid, ensuring a correct connection is established between the external device and the electronic device. The type of the external device can also be correctly identified by detecting the signals output by the CC pins. That is to say, the connection status of the external device can be determined first by detecting the CC pins of the electronic device interface, and then when an external device is detected to be connected, the type of the external device can be identified by detecting the signals output by the CC pins.
[0050] It should be noted that a USB Type-C interface has two CC pins (CC1 and CC2). The CC pins can be used to determine the connection direction because USB Type-C is reversible. The CC pins can be used to identify which device is the electronic device and which device is the external device. The CC pins can also be used to negotiate PD, including the charging capacity and the direction of current flow. The CC pins can also be used for the configuration of data transmission and signal detection. In addition, for different types of external devices, the connection methods of the CC pins of their USB Type-C interfaces are different. Therefore, the connection status of the external device and the type of the external device can be determined by detecting the CC pins.
[0051] In one embodiment, when an external device is connected to the interface of an electronic device, the CC pins of the USB Type-C interface of the external device are connected to the CC pins of the electronic device interface, and different voltage values will be formed at the CC pins of the electronic device interface. In the unconnected state, this voltage will disappear. Thus, based on the voltage value of the CC pins of the electronic device interface, it can be determined whether the CC pins are valid, and thereby whether the connection of the external device is valid. Further, the type of the external device can be judged by the voltage value of the CC pins.
[0052] In another embodiment, when a USB Type-C interface is connected, resistance detection is performed through the CC pins. The external device will apply a specific resistance value (such as 5.1 kΩ or 10 kΩ) to the CC pins, and the electronic device can judge the connection status and the type of the external device by measuring the resistance value of the CC pins.
[0053] In yet another embodiment, in some scenarios, the external device will send specific signals (such as pulse signals) through the CC pins to confirm the connection, and the electronic device can detect these signals to judge whether the CC pins are valid and determine the type of the external device.
[0054] In yet another embodiment, a PD controller can also be employed to monitor the status of the CC pin. Among them, the PD controller can have built-in functions for monitoring and managing the CC pin. Through the status register of the controller, real-time monitoring of the status of the CC pin is achieved.
[0055] In another embodiment, the USB Type-C protocol usually implements a state machine to manage the connection status, which can include the validity of the CC pin. The current connection status can be determined through the state transition of the state machine.
[0056] In the embodiments of the present application, the electronic device can also determine which type of external device has been disconnected by detecting changes in the output signal of the CC pin. Specifically, if the type of external device recognized when the analog headset and charger were previously connected was an analog headset, then when the output signal of the CC pin disappears, the disconnected device can be determined as the analog headset based on the recorded type of the analog headset.
[0057] It should be noted that if there is no intervention during the process of the analog headset and charger being connected through the docking station, then when disconnecting, the charger cannot notify the charging icon to disappear according to the type of external device, resulting in the charging icon always being displayed on the screen of the electronic device. Therefore, in the embodiments of the present application, the signal of Vbus can be detected first to determine that the charger has been connected, and then the charging icon is displayed and the first flag is set. The first flag is used to record the connection status of the charger.
[0058] Step 202, when it is detected that the analog headset and the charger are disconnected from the electronic device interface, the headset icon corresponding to the analog headset is not displayed, and when the first flag is detected, the charging icon corresponding to the charger is not displayed.
[0059] In the embodiments of the present application, by additionally setting the first flag for recording the connection status of the charger during the process of the analog headset and the charger being connected to the electronic device interface through the docking station, when the analog headset and the charger are disconnected, the problem that the charging icon is still displayed when the charger is disconnected can be solved by detecting the first flag, making the display of the icon consistent with the actual situation and improving the user experience.
[0060] In one embodiment, the first flag can be the Audio with Vbus flag, which is used to indicate that while the recognized type of external device is an analog headset, the signal of Vbus is detected, that is, both the analog headset and the charger are connected to the electronic device. Subsequently, when it is detected that the analog headset is disconnected, it is further determined whether the Audio with Vbus flag is recorded. If so, it means that the charger has also been disconnected, and it is notified not to display the charging icon.
[0061] The processing method when the external device type is an analog headphone type was introduced in the foregoing embodiments. Next, another embodiment will be further introduced, that is, the detected external device type is the second type corresponding to a charger.
[0062] In one embodiment, different from external devices such as analog headphones that do not supply power to each other with the electronic device, the electronic device determines whether it has established a connection with the charger by detecting whether the signal of Vbus is valid. When the external device type is the second type corresponding to the charger, according to the display logic of the charging icon, the signal of the power bus Vbus is further detected. By detecting whether there is a signal on Vbus, if there is a signal, it means that the charger is providing power, and a charging icon will be displayed on the electronic device. That is to say, when the external device type is the second type corresponding to the charger, the signal of the power bus Vbus is detected; when there is a signal on Vbus, the charging icon is displayed and the first flag is set.
[0063] Among them, if the connection of the analog headphone has not been detected before the charger is disconnected, the charger does not need to detect the first flag and can directly not display the charging icon according to the second type previously recognized by the electronic device (that is, the external device type corresponding to the charger). Of course, the step of detecting the first flag can also be added to reduce the possibility of incorrect icon display.
[0064] In one embodiment, after determining that the external device type is the second type, if it is detected again that the analog headphone is connected to the electronic device interface through the docking station and the charger is not disconnected from the electronic device interface, the external device type is updated from the second type to the first type. This is also the third scenario existing in the foregoing process of detecting the external device type, that is, first connect the empty docking station without connecting any external devices to the electronic device interface, and then connect the charger to the docking station. At this time, the second type corresponding to the previously connected charger is determined as the external device type. After that, if the analog headphone is also connected to the docking station, the external device type will be switched from the second type to the analog headphone type. When the external device type is switched to the analog headphone type, the subsequent steps are the same as those introduced in the foregoing embodiments and will not be elaborated here.
[0065] An icon display method provided in the above embodiments of the present application is applied to an electronic device. The electronic device is provided with an electronic device interface for accessing an external device. A first external device and a charger are connected to the electronic device interface through a docking station. The icon display method includes: when it is detected that the first external device and the charger are disconnected from the electronic device interface, not displaying a first icon, and when it is detected that a first flag exists, not displaying a charging icon, where the first external device and the electronic device do not supply power to each other, and the first flag is set during the process of connecting the first external device and the charger to the electronic device interface through the docking station for recording the access status of the charger. Thus, by additionally setting a first flag for recording the access status of the charger during the process of connecting the first external device and the charger to the electronic device interface through the docking station, when the first external device and the charger are disconnected, the problem that the charging icon is still displayed when the charger is disconnected can be solved by detecting the first flag, making the display situation of the icon consistent with the actual situation and improving the user experience.
[0066] To facilitate the understanding of the above embodiments, the following uses a specific example to elaborate on the execution steps of the electronic device when a complete docking station is inserted and removed.
[0067] Refer to Figure 3 , which shows a flowchart example of an icon display method provided in an embodiment of the present application. Figure 3 In (a) is a flowchart example when the docking station is accessed, Figure 3 and in (b) is a schematic flowchart when the docking station is removed. The following introduces the Figure 3 shown steps.
[0068] Step 311, insert the docking station.
[0069] It should be noted that before executing the Figure 3 shown process, it is simulated that the earphone and the charger have been connected to the docking station, that is, corresponding to the first scenario of the docking station access in the foregoing embodiments. In this case, it is simulated that the earphone and the charger are simultaneously connected to the electronic device through the docking station.
[0070] Step 312, detect whether the signal output by the CC pin is valid.
[0071] Specifically, it is possible to determine whether the signal output by the CC pin is valid by detecting the voltage, resistance, specific signal (such as a pulse signal), PD controller, and state machine state of the CC pin.
[0072] Among them, if it is determined that the signal output by the CC pin is valid, step 313 is executed; if it is invalid, step 315 is executed.
[0073] For example, when an external device is connected to an electronic device interface, the CC pin of the USB Type-C interface of the external device is connected to the CC pin of the electronic device interface, which will form a voltage of different values at the CC pin of the electronic device interface. When not connected, this voltage disappears. In this way, based on the voltage value of the CC pin of the electronic device interface, it can be determined whether the CC pin is valid, thereby determining whether the external device is connected effectively. Furthermore, the type of external device can be determined by the voltage value of the CC pin.
[0074] Step 313: Identify the CC type (an example of an external device type) based on the signal output by the CC pin, and notify the driver to prepare the corresponding function.
[0075] As mentioned above, the CC type can also be determined by detecting the voltage, resistance, etc. at the CC pin. Then the driver is notified to prepare the corresponding function. Assuming that the external device type is identified as a charger, the driver will activate the charging function and adjust the charging current and voltage.
[0076] In this embodiment, the type of the analog earphone is identified.
[0077] Step 314, the notification displays the earphone icon.
[0078] If the external device type detected is an analog headset type, it is determined that the analog headset is successfully connected, and a headset icon is displayed.
[0079] Step 315, check whether Vbus is valid.
[0080] The traditional display logic of the charging icon is whether there is a valid Vbus signal when plugged in, and the disappearance logic is to determine whether to disappear according to the type of external device recognized by the electronic device when unplugged. Therefore, by detecting whether Vbus is valid, it can be determined whether the charger is successfully connected. If Vbus is detected to be valid, step 316 is executed; if not, step 317 is executed to end the process.
[0081] Step 316, record the Audio with Vbus status.
[0082] Among them, Audio with Vbus is used to indicate that when the identified external device type is an analog headset, a Vbus signal is detected, that is, both the analog headset and the charger are connected to the electronic device.
[0083] Step 317, end.
[0084] The above steps are for when the expansion dock is connected. The following steps are for when the expansion dock is unplugged.
[0085] Step 321, the docking station is unplugged.
[0086] Step 322, detect whether the signal output by the CC pin disappears.
[0087] In this embodiment, if the signal output by the CC pin disappears, then execute Step 323; if not, then return to Step 322.
[0088] Step 323, notify the driver according to the CC type recorded during insertion.
[0089] Among them, the analog headphone type is identified through Step 313. If the signal output by the CC pin disappears, then the disconnected analog headphone can be determined according to the recorded analog headphone type. At this time, the driver can be notified to turn off the corresponding function.
[0090] Step 324, notify not to display the headphone icon.
[0091] When it is determined that the analog headphone is disconnected from the electronic device interface, notify not to display the headphone icon.
[0092] Step 325, determine whether there is an Audio with Vbus state.
[0093] In this embodiment, if it is detected that there is an Audio with Vbus state, it means that the charger has been connected to the electronic device through the docking station. Then, when unplugging, it is necessary to notify not to display the charging icon, that is, execute Step 326; if the Audio with Vbus state is not detected, it means that the charger is not inserted. At this time, execute Step 327 to end the process.
[0094] Step 326, notify not to display the charging icon.
[0095] Step 327, end.
[0096] Thus, by additionally setting the Audio with Vbus flag for recording the access state of the charger during the process of the analog headphone and the charger accessing the electronic device through the docking station, when the analog headphone and the charger are disconnected, the problem that the charging icon is still displayed when the charger is disconnected can be solved by detecting the Audio with Vbus flag, making the display situation of the charging icon consistent with the actual situation and improving the user experience.
[0097] In some embodiments, the above icon display method can be applied to an electronic device including Figure 4 the software system shown, see Figure 4, the layered architecture of an electronic device divides software into several layers, each with a clear role and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: the application layer, the application framework layer, the Android runtime and the system layer, and the kernel layer.
[0098] The application layer may include a series of application packages. As Figure 4 shown, the application packages may include third-party applications, cameras, galleries, calendars, calls, maps, navigation, WLAN, Bluetooth, music, videos, text messages and other applications.
[0099] The application framework layer provides application programming interfaces (APIs) and programming frameworks for the applications in the application layer. The application framework layer includes some predefined functions. As Figure 4 shown, the application framework layer may include the system user interface (SystemUI). SystemUI can be used to build a display interface, and the display interface can be composed of one or more views. For example, it includes views that display headphone icons, views that display charging icons, views that display text, and views that display pictures. SystemUI includes visual controls, such as controls that display text and controls that display pictures.
[0100] In addition, the application framework layer may also include a window manager, a content provider, a telephone manager, a resource manager, a notification manager, etc. The window manager is used to manage window programs. The window manager can obtain the display screen size, determine whether there is a status bar, lock the screen, capture the screen, etc. The content provider is used to store and obtain data, and make this data accessible to application programs. This data may include videos, images, audio, dialed and received calls, browsing history and bookmarks, phone books, etc. The telephone manager is used to provide the communication functions of the electronic device, such as the management of call status (including connection, disconnection, etc.). The resource manager provides various resources for application programs, such as localized strings, icons, pictures, layout files, video files, etc. The notification manager enables application programs to display notification information in the status bar. It can be used to convey notification-type messages, which can automatically disappear after a short stay without user interaction. For example, the notification manager is used to inform that the download is completed, message reminders, etc. The notification manager can also be a notification that appears in the system top status bar in the form of a chart or scroll bar text, such as the notification of a background-running application program. The notification manager can also be a notification that appears on the screen in the form of a dialogue window, such as prompting text information in the status bar, emitting a prompt tone, vibrating the electronic device, flashing the indicator light, etc.
[0101] The Android runtime includes a core library and a virtual machine. The Android runtime is responsible for the scheduling and management of the Android system. The core library consists of two parts: one part is the functional functions that the Java language needs to call, and the other part is the core library of Android. The application layer and the application framework layer run in the virtual machine. The virtual machine executes the Java files of the application layer and the application framework layer as binary files. The virtual machine is used to perform functions such as the management of object life cycles, stack management, thread management, security and exception management, and garbage collection.
[0102] The system library may include multiple functional modules, such as: surface manager, media libraries, 3D graphics processing library (such as: OpenGL ES), 2D graphics engine (such as: SGL), etc. The surface manager is used to manage the display subsystem and provides the fusion of 2D and 3D layers for multiple application programs. The media libraries support the playback and recording of multiple common audio and video formats, as well as static image files, etc. The media libraries can support multiple audio and video coding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc. The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, synthesis, and layer processing, etc. The 2D graphics engine is the drawing engine for 2D drawing.
[0103] The kernel layer is the layer between hardware and software. The kernel layer contains functional modules such as PD, USB, audio (AUDIO), and charging. Among them, PD is a protocol for managing power transmission between USB devices. PD allows power negotiation between devices to support higher power transmission and can dynamically adjust voltage and current. The USB module is responsible for managing the connection and communication of all USB devices, including data transmission, device identification, and driver loading. The AUDIO module is responsible for managing audio input and output, including audio playback, recording, and audio effect processing. The charging module is responsible for managing the charging process of the device, including battery charging status monitoring and charging strategy implementation.
[0104] In addition, the kernel layer at least further contains a display driver, a camera driver, and a sensor driver ( Figure 4 not shown in the figure).
[0105] Based on the software architecture shown above, Figure 4 a timing interaction diagram of an icon display method provided by an embodiment of the present application is shown. The following Figure 5 will be introduced. Figure 5 will be introduced.
[0106] Among them, before executing the Figure 5 shown process, the simulated headset and charger have been connected to the docking station, that is, corresponding to the first scenario of the docking station access in the foregoing embodiment. In this case, the simulated headset and charger are simultaneously connected to the electronic device through the docking station. Specifically, the simulated headset and charger are first connected to the docking station, and then the entire docking station is connected to the electronic device interface. At this time, due to the internal timing of the electronic device or the priority of the external device, the simulated headset type corresponding to the simulated headset is usually determined as the external device type.
[0107] The following Figure 5 shown steps will be introduced.
[0108] Step 501, when the docking station is connected to the electronic device, PD detects changes in the CC pin and Vbus.
[0109] Step 502, PD reports the CC pin status to the USB module.
[0110] Step 503, the USB module determines that the external device is AUDIO according to the CC pin.
[0111] Step 504, the USB module notifies the AUDIO module that an audio device is inserted.
[0112] Step 505, the AUDIO module notifies the UI to display the headset icon.
[0113] Step 506, PD reports the Vbus status to the USB module.
[0114] Step 507, the USB module indicates the existence of power supply externally according to Vbus.
[0115] Step 508, the USB module notifies the charging module that the charger is plugged in.
[0116] Step 509, the USB module records the Audio with Vbus flag.
[0117] Step 510, the charging module notifies the UI to display the charging icon.
[0118] It should be noted that in the above steps, when the electronic device is plugged into the docking station, PD detects the changes of the CC pins (such as detecting the changes of parameters such as voltage, resistance, and pulse signal of the CC pins) and the changes of Vbus (such as detecting whether there is a voltage signal on Vbus). After that, PD reports to the USB module after obtaining the status of the CC pins. If it is determined that the external device is AUDIO by detecting the signal at the CC pins, the USB module notifies the AUDIO module that the audio device (analog headphone) is connected. Finally, the AUDIO module notifies SystemUI to display the headphone icon. In addition, PD also reports to the USB module after obtaining the status of Vbus. If it is determined that there is a valid Vbus signal after detecting the Vbus status, that is, there is external power supply, the USB module notifies the charging module that the charging device is connected, and additionally sets the Audio with Vbus flag for recording the access status of the charger. Finally, the charging module notifies SystemUI to display the charging icon.
[0119] It should be noted that in addition to the first scenario, two other scenarios are also described in the foregoing embodiments. The second scenario is to first connect the empty docking station without any external devices to the electronic device interface, then connect the analog headphone to the docking station, and finally connect the charger to the docking station. At this time, the analog headphone type corresponding to the first-connected analog headphone is determined as the external device type. The third scenario is to first connect the empty docking station without any external devices to the electronic device interface, then connect the charger to the docking station. At this time, the charger type corresponding to the first-connected charger is determined as the external device type. After that, if the analog headphone is connected to the docking station, the external device type is switched from the second type to the first type corresponding to the analog headphone.
[0120] It can be seen from this that as long as it is a scenario where both the analog headphone and the charger are connected to the electronic device interface through the docking station, the finally recognized CC type is the analog headphone type, and all are within the scope covered by the foregoing steps. In the second scenario and the third scenario, Figure 5 the shown process is equally applicable.
[0121] Step 511, when the docking station is unplugged from the electronic device, the PD detects changes in the CC pins and Vbus.
[0122] Step 512, the PD reports the status of the CC pins to the USB module.
[0123] Step 513, the USB module indicates that the external device has been unplugged according to the CC pins.
[0124] Step 514, the USB module determines that the CC type recorded is for an audio device and notifies the AUDIO module that the audio device has been unplugged.
[0125] Step 515, the AUDIO module notifies the UI not to display the headphone icon.
[0126] Step 516, the USB module detects the presence of the Audio with Vbus flag.
[0127] Step 517, the USB module notifies the charging module that the charger has been unplugged.
[0128] Step 518, the charging module notifies the UI not to display the charging icon.
[0129] It should be noted that when unplugging the docking station, the PD detects changes in the CC pins (such as changes in parameters such as the voltage, resistance, and pulse signal of the CC pins) and changes in Vbus (such as detecting whether there is a voltage signal on Vbus). After that, the PD reports the status of the CC pins to the USB module. If it detects that the signal at the CC pins disappears, it determines that the external device has been unplugged. The USB module determines that the external device is an audio device according to the CC type recorded when the docking station was inserted and notifies the AUDIO module that the audio device (analog headphone) has been unplugged. Finally, the AUDIO module notifies SystemUI not to display the headphone icon. Additionally, when it is determined that the analog headphone has been unplugged, the USB module detects whether the Audio with Vbus flag exists. If it exists, it notifies the charging module that the charger has been unplugged. Finally, the charging module notifies SystemUI not to display the charging icon.
[0130] Thus, by additionally setting the Audio with Vbus flag for recording the access status of the charger during the process of the analog headphone and charger accessing the electronic device through the docking station, when the analog headphone and charger are disconnected, the problem that the charging icon still remains displayed when the charger is disconnected can be solved by detecting the Audio with Vbus flag, making the display situation of the charging icon consistent with the actual situation and improving the user experience.
[0131] To make the effects of the embodiments of this application more intuitive, the following is combined with Figure 6 for illustration.
[0132] Figure 6 shows a schematic diagram of the interface display of a traditional solution and an embodiment of the present application, Figure 6 wherein (a) is the schematic diagram of the interface display of the traditional solution, Figure 6 and (b) is the schematic diagram of the interface display of the embodiment of the present application.
[0133] As Figure 6 shown in (a), when the electronic device is inserted into the docking station, the headphone icon and the charging icon are displayed normally. When the docking station is unplugged, only the headphone icon disappears, while the charging icon does not disappear. The reason for this problem is that the traditional display logic of the charging icon is whether there is a valid power bus (Vbus) signal when inserted, and the disappearance logic is to determine whether to disappear according to the type of external device recognized by the electronic device when unplugged. However, no matter how many interfaces are extended from the electronic device interface, the electronic device can only recognize one type of external device at the same time. Therefore, when both the analog headphone and the charger are connected to the electronic device through the docking station, the analog headphone type is usually stored as the type of external device. In this way, when the analog headphone and the charger are unplugged, the charger cannot notify the charging icon to disappear according to the type of external device. Usually, the analog headphone does not supply power to the electronic device, and the electronic device does not supply power to the analog headphone either, so it does not notify the charging icon to disappear. The above situation will cause the charging icon to always be displayed on the screen of the electronic device, while in fact the charger has been disconnected, seriously affecting the user experience.
[0134] In the embodiment of the present application, mainly by additionally setting a first flag for recording the access state of the charger during the process of the first external device and the charger being connected to the electronic device interface through the docking station, when the first external device and the charger are disconnected, the problem that the charging icon is still displayed when the charger is disconnected can be solved by detecting the first flag, so that the display situation of the icon is consistent with the actual situation and the user experience is improved. After adopting the solution described in the embodiment of the present application, the interface display situation when the docking station is inserted and unplugged is as Figure 6 shown in (b). When the electronic device is inserted into the docking station, the headphone icon and the charging icon are displayed normally. When the docking station is unplugged, both the headphone icon and the charging icon disappear, and the display situation of the icon is consistent with the actual situation, which can improve the user experience.
[0135] The method of the embodiments of the present application has been mainly introduced with reference to the accompanying drawings. It should be understood that although the steps in the flowcharts involved in the above-described embodiments are shown in sequence, these steps are not necessarily executed in the order shown in the figures. Unless there is a clear description in this article, the execution of these steps has no strict order limitation, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-described embodiments may include multiple steps or multiple stages. These steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be executed alternately or in turn with at least a part of other steps or steps or stages in other steps. The device of the embodiments of the present application will be introduced below with reference to the accompanying drawings.
[0136] Referring to Figure 7 , which is a schematic structural diagram of an icon display device provided by an embodiment of the present application. For the sake of convenience of description, only the parts related to the embodiments of the present application are shown. As Figure 7 shown, the icon display device 700 includes a processing unit 701. The icon display device 700 can be integrated in an electronic device that adapts multiple types of external devices through any interface. For another example, the icon display device 700 can also be used to execute Figure 2 , Figure 3 and Figure 4 the processes shown.
[0137] The icon display device 700 can be used to execute any of the above icon display methods. For example, the processing unit 701 can be used to execute steps 201-202.
[0138] The icon display device provided by the embodiments of the present application mainly sets a first flag for recording the access state of the charger during the process of the first external device and the charger accessing the electronic device interface through the docking station. In this way, when the first external device and the charger are disconnected, the problem that the charging icon still remains displayed when the charger is disconnected can be solved by detecting the first flag, so that the display situation of the icon is consistent with the actual situation and the user experience is improved.
[0139] It should be noted that the foregoing explanation of the embodiments of the icon display method also applies to the icon display device 700 of this embodiment, and will not be repeated here.
[0140] Those skilled in the art can clearly understand that, for the convenience and conciseness of description, only the above division of each functional unit and module is used as an example. In practical applications, the above functions can be allocated to different functional units and modules according to needs, that is, the internal structure of the device is divided into different functional units or modules to complete all or part of the functions described above. Each functional unit and module in the embodiment can be integrated into a processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above integrated unit can be implemented in the form of hardware or in the form of a software functional unit. In addition, the specific names of each functional unit and module are only for the convenience of mutual distinction and do not limit the protection scope of this application. The specific working processes of the units and modules in the above system can refer to the corresponding processes in the foregoing method embodiments and will not be elaborated here.
[0141] Figure 8 is a schematic diagram of the hardware structure of an electronic device according to an embodiment of the present application. As Figure 8 shown, the electronic device 800 may include a processor (central processing unit, CPU) 810, an external memory interface 820, an internal memory 821, a universal serial bus (USB) interface 830, a charging management module 840, a power management module 841, a battery 842, an antenna 1, an antenna 2, a mobile communication module 850, a wireless communication module 860, an audio module 870, a speaker 870A, a receiver 870B, a microphone 870C, a headphone interface 870D, a sensor module 880, a button 890, a motor 891, an indicator 892, a camera 893, a display screen 894, and a subscriber identification module (SIM) card interface 895, etc. Among them, the sensor module 880 may include a pressure sensor 880A, a gyroscope sensor 880B, a barometric pressure sensor 880C, a magnetic sensor 880D, an acceleration sensor 880E, a distance sensor 880F, a proximity light sensor 880G, a fingerprint sensor 880H, a temperature sensor 880J, a touch sensor 880K, an ambient light sensor 880L, a bone conduction sensor 880M, etc. It should be understood that the steps in the foregoing method embodiments are executed by the processor 810 of the electronic device.
[0142] It can be understood that the structure illustrated in the embodiments of the present application does not constitute a specific limitation on the electronic device 800. In some other embodiments of the present application, the electronic device 800 may include more or fewer components than shown in the figures, or combine certain components, or split certain components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
[0143] Exemplarily, Figure 8 The illustrated processor 810 may include one or more processing units. For example, the processor 810 may include an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Among them, different processing units may be independent devices or integrated in one or more processors.
[0144] Among them, the controller may be the nerve center and command center of the electronic device 800. The controller can generate operation control signals according to the instruction operation code and timing signals to complete the control of fetching and executing instructions.
[0145] A memory may also be provided in the processor 810 for storing instructions and data. In some embodiments, the memory in the processor 810 is a cache memory. This memory can save the instructions or data that the processor 810 has just used or recycled. If the processor 810 needs to use the instruction or data again, it can be directly called from the memory. This avoids repeated accesses, reduces the waiting time of the processor 810, and thus improves the efficiency of the system.
[0146] In some embodiments, the MIPI interface may be used to connect the processor 810 to peripheral devices such as the display screen 894 and the camera 893. The MIPI interface includes a camera serial interface (CSI), a display serial interface (DSI), etc. The processor 810 and the display screen 894 communicate through the DSI interface to implement the display function of the electronic device 800.
[0147] In some embodiments, the GPIO interface can be configured by software. The GPIO interface can be configured as a control signal or as a data signal. The GPIO interface can be used to connect the processor 810 to the camera 893, the display screen 894, the wireless communication module 860, the audio module 870, the sensor module 880, etc. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface, a MIPI interface, etc.
[0148] It can be understood that the interface connection relationships shown among the various modules in the embodiments of the present application are only illustrative descriptions and do not constitute a structural limitation on the electronic device 800. In other embodiments of the present application, the electronic device 800 can also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.
[0149] The electronic device 800 implements the display function through the GPU, the display screen 894, and the application processor, etc. The GPU is a microprocessor for image processing, and is connected to the display screen 894 and the application processor. The GPU is used to execute mathematical and geometric calculations for graphics rendering. The processor 810 may include one or more GPUs, which execute program instructions to generate or change the display information.
[0150] The display screen 894 is used to display images, videos, etc. The display screen 894 includes a display panel. In some embodiments, the electronic device 800 may include 1 or N display screens 894, where N is a positive integer greater than 1.
[0151] The internal memory 821 can be used to store computer-executable program code, and the executable program code includes instructions. The processor 810 executes various functional applications and data processing of the electronic device 800 by running the instructions stored in the internal memory 821. The internal memory 821 may include a program storage area and a data storage area. Among them, the program storage area can store the operating system, application programs required for at least one function (such as the sound playback function, the image playback function, etc.). The data storage area can store the data created during the use of the electronic device 800 (such as audio data, phone book, etc.). In addition, the internal memory 821 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc.
[0152] The pressure sensor 880A is used to sense pressure signals and can convert pressure signals into electrical signals. In some embodiments, the pressure sensor 880A may be disposed on the display screen 894. There are many types of pressure sensors 880A, such as resistive pressure sensors, inductive pressure sensors, capacitive pressure sensors, etc. The capacitive pressure sensor may include at least two parallel plates having conductive materials. When a force acts on the pressure sensor 880A, the capacitance between the electrodes changes. The electronic device 800 determines the intensity of the pressure based on the change in capacitance. When a touch operation acts on the display screen 894, the electronic device 800 detects the intensity of the touch operation according to the pressure sensor 880A. The electronic device 800 can also calculate the position of the touch based on the detection signal of the pressure sensor 880A. In some embodiments, touch operations with the same touch position but different touch operation intensities may correspond to different operation instructions. For example, when a touch operation with a touch operation intensity less than the first pressure threshold acts on the short message application icon, the instruction to view the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, the instruction to create a new short message is executed.
[0153] The touch sensor 880K, also known as the "touch panel". The touch sensor 880K may be disposed on the display screen 894, and the touch sensor 880K and the display screen 894 form a touch screen, also known as the "touch display screen". The touch sensor 880K is used to detect touch operations acting thereon or nearby. The touch sensor can transmit the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through the display screen 894. In other embodiments, the touch sensor 880K may also be disposed on the surface of the electronic device 800, at a different position from the display screen 894.
[0154] It should be noted that the information interaction, execution process, etc. between the above-mentioned devices / units, due to being based on the same concept as the method embodiments of the present application, for their specific functions and the technical effects brought, please refer to the method embodiment part for details, and will not be elaborated here.
[0155] The embodiments of the present application also provide an electronic device, which includes: one or more processors, a memory, and a computer program stored in the memory and executable on the one or more processors. When the one or more processors execute the computer program, the electronic device can implement the steps in any of the above methods. The embodiments of the present application also provide a computer-readable storage medium, which stores a computer program. When the computer program is executed by the electronic device, the steps in each of the above method embodiments can be implemented.
[0156] The computer-readable medium may at least include: any entity or device capable of carrying computer program code to the photographing device / electronic device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium. For example, a USB flash drive, a portable hard disk, a magnetic disk, or an optical disc, etc. In certain jurisdictions, according to legislation and patent practice, the computer-readable medium may not be an electrical carrier signal and a telecommunication signal.
[0157] An embodiment of the present application provides a computer program product, which includes a computer program that can implement the steps in the above method embodiments when executed by an electronic device. The computer program includes computer program code, and the computer program code can be in the form of source code, object code, an executable file, or some intermediate form, etc.
[0158] In the above embodiments, the descriptions of the respective embodiments have their own focuses. For parts not detailed or recorded in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0159] Those of ordinary skill in the art can realize that the units and algorithm steps of the examples described in combination with the embodiments disclosed herein can be implemented by electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present application.
[0160] In the embodiments provided in the present application, it should be understood that the disclosed device / equipment and method can be implemented in other ways. For example, the device / equipment embodiments described above are merely illustrative. For example, the division of the modules or units is only a logical function division, and there may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed coupling or direct coupling or communication connection to each other can be through some interfaces, and the indirect coupling or communication connection of the device or unit can be in an electrical, mechanical, or other form.
[0161] The unit described as a separation component may or may not be physically separated. The component shown as a unit may or may not be a physical unit, that is, it may be located in one place, or it may be distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0162] It should be understood that when used in the description of this application specification and the appended claims, the term "comprising" indicates the presence of the described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or their combinations.
[0163] It should also be understood that the term "and / or" used in the description of this application specification and the appended claims refers to any combination and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0164] In addition, in the description of this application specification and the appended claims, the terms "first", "second", "third", etc. are only used for distinguishing descriptions, and cannot be understood as indicating or implying relative importance.
[0165] The reference to "one embodiment" or "some embodiments" etc. described in this application specification means that a specific feature, structure or characteristic described in combination with the embodiment is included in one or more embodiments of this application. Thus, the statements "in one embodiment", "in some embodiments", "in other some embodiments", "in still other embodiments" etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "comprising", "including", "having" and their variants all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0166] The above-described embodiments are only used to illustrate the technical solutions of this application, rather than to limit them; although this application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements on some of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.
Claims
1. An icon display method, characterized in that, Applied to an electronic device, the electronic device is provided with an electronic device interface for connecting an external device, and the icon display method includes: When it is detected that a first external device and a charger are disconnected from the electronic device interface, the first icon corresponding to the first external device is not displayed, and when it is detected that a first flag exists, the charging icon corresponding to the charger is not displayed, where the first external device and the charger are connected to the electronic device interface through a docking station, the first external device and the electronic device do not supply power to each other, and the first flag is set when a signal of a power bus Vbus is detected during the process of the first external device and the charger accessing the electronic device interface through the docking station, and is used to record the access state of the charger.
2. The icon display method according to claim 1, wherein The icon display method further includes: When it is detected that the first external device and the charger are connected to the electronic device interface, the first icon is displayed, and the charging icon is displayed.
3. The icon display method according to claim 2, wherein The displaying of the first icon includes: Detecting the type of the external device; When the type of the external device is the first type corresponding to the first external device, the first icon is displayed.
4. The icon display method according to claim 3, wherein The detecting of the type of the external device includes: Determining the connection state of the external device by detecting the configuration channel CC pins of the electronic device interface; When the connection state is that an external device is connected, identifying the type of the external device by detecting the signal output by the CC pins.
5. The icon display method according to claim 4, characterized in that The icon display method further includes: When it is detected that the signal output by the CC pins disappears, it is determined that the first external device is disconnected from the electronic device interface.
6. The icon display method according to claim 3, wherein The icon display method further includes: When the type of the external device is the second type corresponding to the charger, detecting the signal of the power bus Vbus; When there is a signal on the Vbus, displaying the charging icon and setting the first flag.
7. The icon display method according to claim 6, wherein The icon display method further includes: After determining that the type of the external device is the second type, if it is detected again that the first external device is connected to the electronic device interface through the docking station and the charger is not disconnected from the electronic device interface, then updating the type of the external device from the second type to the first type.
8. The icon display method according to claim 2, wherein The displaying of the charging icon includes: Detecting the signal of the power bus Vbus; When there is a signal on the Vbus, displaying the charging icon and setting the first flag.
9. The icon display method according to any one of claims 1-8, characterized in that, The first external device is an analog headphone, and the first icon is a headphone icon.
10. An electronic device, characterized in that, The electronic device includes: one or more processors, and a memory; The memory is coupled to the one or more processors, the memory is used to store computer program code, the computer program code includes computer instructions, and the one or more processors call the computer instructions to cause the electronic device to execute the method according to any one of claims 1 to 9.
11. A chip system, characterized in that, The chip system is applied to an electronic device, and the chip system includes one or more processors, and the one or more processors are configured to call computer instructions to cause the electronic device to execute the method according to any one of claims 1 to 9.
12. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes instructions that, when running on an electronic device, cause the electronic device to execute the method according to any one of claims 1 to 9.
Citation Information
Patent Citations
Processing method of access equipment and mobile terminal
CN108268396A
Charging method, mobile terminal and storage medium
CN115622177A