Device interconnection and interaction methods, electronic devices and computer-readable storage media

By adaptively adjusting the positions of the service ball and service capsule, the problem of the device ball going beyond the screen boundary when rotating was solved, enabling the service ball to move smoothly within the interface and improving the user experience.

CN120335694BActive Publication Date: 2026-03-13HONOR DEVICE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-01-10
Publication Date
2026-03-13

AI Technical Summary

Technical Problem

In device interconnection applications, the service ball mounted on the device ball may extend beyond the screen boundary when it rotates to the edge of the screen, affecting user operation and resulting in a poor user experience.

Method used

By adaptively adjusting the positions of the service ball and service capsule, and determining the initial angle and avoidance angle of the service ball based on the size and rotation angle of the device ball, the service ball avoids obstacles during rotation, reducing the area that exceeds the screen boundary and ensuring that the service ball moves smoothly within the interface.

Benefits of technology

It improves the ease of use and user experience, ensuring that the service ball rotates smoothly and continuously within the interface, and reducing instances where it extends beyond the screen boundaries.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120335694B_ABST
    Figure CN120335694B_ABST
Patent Text Reader

Abstract

This application provides a device interconnection and interaction method, device, and computer-readable storage medium, relating to the field of smart device application technology. It enables a service ball to rotate smoothly and continuously following a device ball, and reduces the occurrence of the service ball exceeding the display screen boundary, facilitating the operation of the service ball. The method includes: in response to a first operation, acquiring first information about the device ball, first information about the service ball, and first information about the service capsule at the current moment in the interface; determining the target position of the device ball, the initial angle and avoidance angle of each service ball mounted on the second device ball based on the first information about the device ball and the service ball; determining the target position of each service ball based on the initial angle and avoidance angle of each service ball; determining the target position of the service capsule based on the first information about the device ball and the service capsule; and moving the second device ball, each service ball, and the service capsule according to their respective target positions.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of smart device application technology, and in particular to a device interconnection and interaction method, an electronic device, and a computer-readable storage medium. Background Technology

[0002] In the internet age, smart devices are becoming increasingly widespread. Commonly used smart devices in daily life include smartphones, tablets (portable Android devices, PADs), smartwatches, televisions, and computers, each with its own strengths. Users frequently need to switch between these devices, leading to the development of device interconnection applications in related technologies. These applications enable services switching and data exchange between different devices. However, in these applications, the service ball mounted on the device sphere is in a fixed position. When the device sphere rotates to the edge of the screen, the service ball may extend beyond the screen boundary, interfering with user operation and resulting in a poor user experience. Summary of the Invention

[0003] This application provides a device interconnection and interaction method, an electronic device, and a computer-readable storage medium, which can adaptively adjust the position of the service ball and service capsule, reduce the area exceeding the boundary of the display screen, provide users with a user-friendly interaction method, facilitate user operation, and improve user experience.

[0004] To achieve the above objectives, the embodiments of this application adopt the following technical solutions:

[0005] In a first aspect, embodiments of this application provide a device interconnection and interaction method applied to an electronic device. The method includes: responding to a received first operation for dragging a first device ball in an interface, acquiring first device ball information, first service ball information, and first service capsule information corresponding to the second device ball at the current moment; determining the target position of the device ball, the initial angle and avoidance angle of each service ball mounted on the second device ball based on the first device ball information and the first service ball information; determining the target position of each service ball based on the initial angle and avoidance angle of each service ball; determining the target position of the service capsule mounted on the second device ball based on the first device ball information and the first service capsule information; and moving the second device ball, each service ball mounted on the second device ball, and the service capsule according to the target position of the device ball, the target position of each service ball, and the target position of the service capsule.

[0006] Based on the technical solution provided in this application, when a user drags the device ball, the position of the device ball, the initial angle and avoidance angle of each service ball attached to the device ball are obtained. Based on the position of the device ball, the initial angle and avoidance angle of each service ball, it is determined that each service ball needs to avoid an obstacle. During the rotation of the device ball, each service ball and service capsule attached to the device ball rotates smoothly and continuously with it. Moreover, it can reduce the occurrence of service balls exceeding the boundaries of the electronic device, and ensure that the service balls move within the interface as much as possible, making it convenient for users to use the service balls on the electronic device and improving the user experience.

[0007] In one possible implementation of the first aspect, determining the target position of the device ball, the initial angle of each service ball mounted on the second device ball, and the avoidance angle based on the first information of the device ball and the first information of the service ball includes: determining the target position of the device ball based on the size of the second device ball and its current rotation angle as included in the first information of the device ball; determining the initial angle of each service ball based on the number of service balls mounted on the second device ball as included in the first information of the service ball; and determining the avoidance angle based on the current rotation angle and the number of service balls mounted on the second device ball.

[0008] Based on the above possible implementation methods, during the user's dragging of the device ball, the electronic device determines the real-time position of the device ball based on its size and current rotation angle, allowing the device ball to move synchronously to the position corresponding to the user's first input operation. Furthermore, the initial angle and avoidance angle of each service ball are determined according to the number of service balls attached to the device ball; different numbers of service balls attached to a device ball result in different initial angles and avoidance angles, thus achieving flexible avoidance.

[0009] In one possible implementation of the first aspect, determining the target position of the device ball based on the size and current rotation angle of the second device ball, which are included in the first information of the device ball, includes: determining the current center coordinates of the second device ball based on the size of the second device ball and the current rotation angle; and determining the target position of the device ball based on the current center coordinates of the second device ball and the size of the second device ball.

[0010] Based on the above possible implementation methods, the electronic device determines the current center coordinates of the device ball by the size of the device ball and the current rotation angle, and then determines the current target position, providing data support for the device ball to move synchronously to the position corresponding to the first operation input by the user.

[0011] In one possible implementation of the first aspect, determining the avoidance angle based on the current rotation angle and the number of service balls mounted on the second device ball includes: determining a maximum avoidance angle based on the number of service balls mounted on the second device ball; and determining the avoidance angle based on the current rotation angle, the maximum avoidance angle, and a preset rule.

[0012] Based on the aforementioned possible implementation methods, the electronic device determines the maximum avoidance angle according to the number of service balls. By considering the current rotation angle of the device balls, the maximum avoidance angle, and preset rules, a suitable avoidance angle is determined. This avoidance angle changes in real-time based on the current rotation angle, supporting the smooth and continuous rotation of the service balls and service capsules following the device balls. Furthermore, based on the avoidance angle, the occurrence of service balls exceeding the boundaries of the electronic device can be reduced, ensuring that the service balls move within the interface as much as possible, facilitating user access to the service balls on the electronic device, and improving the user experience.

[0013] In one possible implementation of the first aspect, determining the target position of each service ball based on its initial angle and avoidance angle includes: determining the current angle of each service ball based on its initial angle and avoidance angle; determining the current center coordinates of each service ball based on the size of the second device ball, the current center coordinates of the second device ball, the current angle of each service ball, and the size of the service ball included in the first information of the service ball; and determining the target position of each service ball based on its current center coordinates and its size.

[0014] Based on the above possible implementation methods, the electronic device determines the size and current angle of the service ball, determines the current center coordinates of the service ball based on the size and current angle of the service ball, and then determines the current target position, thereby realizing the real-time position determination of each service ball on the device ball, providing data support for the service balls to follow the device ball to rotate synchronously and avoid obstacles.

[0015] In one possible implementation of the first aspect, the method further includes: in response to a received second operation for dragging a first service ball in the interface, determining the position information of a third device ball attached to the first service ball and a fourth device ball in the interface; controlling the first service ball to move to the position indicated by the second operation; obtaining the current position information of the first service ball at the current moment; and determining, based on the current position information of the first service ball and the position information of the fourth device ball, under the condition of satisfying service interconnection, attaching the first service ball from the third device ball to the fourth device ball.

[0016] Based on the above possible implementation methods, when a user drags the service ball, the control system moves the service ball according to the position indicated by the second operation, so that the service ball moves synchronously with the user's operation. During the movement, if it collides with other device balls, and the service interconnection requirement is met, it is attached to the collided device ball, thus realizing cross-device service sharing among multiple devices.

[0017] In one possible implementation of the first aspect, determining, based on the current position information of the first service ball and the position information of the fourth device ball, that the conditions for service interconnection are met, and then attaching the first service ball from the third device ball to the fourth device ball, includes: determining, based on the current position information of the first service ball and the position information of the fourth device ball, that if the first service ball collides with the fourth device ball and the user stops inputting the second operation, obtaining the number of service balls attached to the fourth device ball; and if the number of service balls attached to the fourth device ball is less than a preset attachment upper limit, determining that the conditions for service interconnection are met, sharing the service corresponding to the first service ball to the electronic device corresponding to the third device ball, and attaching the first service ball from the third device ball to the fourth device ball.

[0018] Based on the above possible implementation methods, if a user collides with another device ball while moving the service ball, and the user stops inputting the second operation, and it is determined that the collided device ball can accept the service ball, then the service ball is attached to the collided device ball, thus realizing cross-device service sharing among multiple devices.

[0019] In one possible implementation of the first aspect, the method further includes: obtaining initial position information of the first service ball before it moves to the position indicated by the second operation; and moving the first service ball according to the initial position information if the first service ball does not collide with the fourth device ball, or the user stops inputting the second operation, or the number of service balls mounted on the fourth device ball is equal to the preset mounting limit value.

[0020] Based on the above possible implementation methods, if the user does not collide with other device balls during the process of moving the service ball, or if the other device balls collided with during the process of moving the service ball cannot connect to more service balls, the service ball will be restored to its initial position to ensure that the service that has been transferred will not be interrupted.

[0021] Secondly, embodiments of this application also provide a device interconnection and interaction apparatus, which can be applied to electronic devices. The functions of this apparatus can be implemented through hardware or through hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the aforementioned functions, such as an acquisition module, a first determination module, a second determination module, a third determination module, and a movement module.

[0022] The acquisition module can be used to respond to a received first operation for dragging the first device ball in the interface, and to acquire the device ball first information of the second device ball in the interface at the current time, the service ball first information and the service capsule first information corresponding to the second device ball;

[0023] The first determining module can be used to determine the target position of the equipment ball, the initial angle and avoidance angle of each service ball mounted on the second equipment ball, based on the first information of the equipment ball and the first information of the service ball.

[0024] The second determining module can be used to determine the target position of each service ball based on the initial angle and avoidance angle of each service ball;

[0025] The third determining module can be used to determine the target location of the service capsule mounted on the second device sphere based on the first information of the device sphere and the first information of the service capsule.

[0026] The moving module can be used to move the second device ball, the service balls mounted on the second device ball, and the service capsule according to the target position of the device ball, the target position of each of the service balls, and the target position of the service capsule.

[0027] Thirdly, this application provides an electronic device including a display screen, a memory, and one or more processors; the display screen, the memory, and the processors are coupled; wherein the memory stores computer program code, the computer program code including computer instructions, which, when executed by the processor, cause the electronic device to perform the device interconnection and interaction method provided by the first aspect and any possible design of the present invention.

[0028] Fourthly, this application provides a computer-readable storage medium including computer instructions that, when executed on an electronic device, cause the electronic device to perform the device interconnection and interaction method provided by the first aspect and any possible design of the present application.

[0029] Fifthly, this application provides a computer program product that, when run on an electronic device, causes the electronic device to perform the device interconnection and interaction method provided by the first aspect and any possible design method thereof.

[0030] Understandably, the beneficial effects that the technical solutions provided in the second to fifth aspects described above can be achieved can be referred to the beneficial effects in the first aspect and any of its possible design methods, which will not be repeated here. Attached Figure Description

[0031] Figure 1 An interface design diagram for device interconnection applications provided by existing technologies;

[0032] Figure 2 Another interface design diagram for device interconnection applications provided by existing technologies;

[0033] Figure 3 Another interface design diagram for device interconnection applications provided by existing technologies;

[0034] Figure 4 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of this application;

[0035] Figure 5 A flowchart illustrating a device interconnection and interaction method provided in an embodiment of this application;

[0036] Figure 6 An interface design diagram for a device interconnection application provided in this application embodiment;

[0037] Figure 7 An interface design diagram for mounting a service ball on a device ball in a device interconnection application provided in this application embodiment;

[0038] Figure 8 This is another schematic diagram of an interface in a device interconnection application provided in the embodiments of this application;

[0039] Figure 9 Another schematic diagram of an interface provided in the device interconnection application of this application;

[0040] Figure 10 A flowchart illustrating another device interconnection and interaction method provided in an embodiment of this application;

[0041] Figure 11 A flowchart illustrating another device interconnection and interaction method provided in an embodiment of this application;

[0042] Figure 12 A flowchart illustrating yet another device interconnection and interaction method provided in an embodiment of this application;

[0043] Figure 13 This is a schematic diagram of the structure of a device interconnection and interaction device provided in an embodiment of this application. Detailed Implementation

[0044] The terminology used in the following embodiments of this application is for the purpose of describing particular embodiments only and is not intended to be limiting of this application. As used in the specification and appended claims of this application, the singular expressions “a,” “an,” “the,” “the,” “the,” and “this” are intended to include the plural expressions as well, unless the context clearly indicates otherwise. It should also be understood that “ / ” means “or,” for example, A / B can mean A or B; “and / or” in the text is merely a description of the relationship between related objects, indicating that three relationships can exist, for example, A and / or B can mean: A alone, A and B simultaneously, and B alone.

[0045] In this application, the reference to "embodiment" means that a specific feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a mutually exclusive, independent, or alternative embodiment. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described in this application can be combined with other embodiments.

[0046] The terms "first" and "second" in the following embodiments of this application are for descriptive purposes only and should not be construed as implying relative importance or implicitly indicating the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature, and in the description of the embodiments of this application, unless otherwise stated, "multiple" means two or more.

[0047] In the internet age, smart devices are becoming increasingly widespread. Commonly used smart devices in daily life include mobile phones, tablets, smartwatches, televisions, and computers, each with its own strengths and functions. Users frequently need to switch between these devices. For example, if a user is on a voice call on their mobile phone and wants to switch to their computer to continue the call, the traditional method is to first disconnect from the mobile phone and then re-establish the call connection on the computer. This traditional method is cumbersome and inconvenient for users.

[0048] To facilitate users switching between different devices, related technologies provide device interconnection applications (also known as smart interconnection applications) in electronic devices. These applications connect different electronic devices and / or systems, enabling interconnection functions such as switching services and exchanging data between different electronic devices.

[0049] Figure 1 An interface design diagram for device interconnection applications provided by existing technologies. For example... Figure 1As shown, this interface design diagram illustrates the interface design when the device interconnection application uses the "call sharing" service.

[0050] like Figure 1 As shown in (a) of the diagram, the user avatar 101 of the currently logged-in user account is displayed at the center of the interface design. This user image 101 can be used to represent the user's identity. The dashed ring displayed outside the user avatar 101 is called the trust ring 102, which represents a trust circle or network. Information such as services / tasks flowing within the trust ring is trustworthy information.

[0051] At least one device ball 103 is arranged on the trust ring 102. Each device ball represents a trust ring device that has logged into the user account (i.e., the user account corresponding to the user avatar 101 displayed in the center), such as a mobile phone, PAD, wristband, television, computer, or other electronic device. For example, Figure 1 The image shows three device balls, which correspond to the following electronic devices: the local device, device 1, and device 2. Figure 1 In the design, each device sphere 103 is presented in the form of a sphere. In practice, the shape, pattern, and color of each device sphere 103 can be customized according to the specific type, status, or function of the device. Figure 1 This is an illustrative diagram and is not intended to limit the device sphere 103.

[0052] For the device ball 103 on the trust ring 102, users can interact with the device ball 103 by clicking, dragging, or other interactive methods to control and operate the electronic device. For example, users can click the device ball 103 to turn the electronic device on or off, adjust the settings of the electronic device, and view the status information of the device.

[0053] In some examples, such as Figure 1 As shown in (a), a service ball 104 can be attached to the device ball 103, representing a service that has been transferred to the folded state of the electronic device (such as device 1) corresponding to the device ball 103. This service can be transferred between devices within the trust ring 102. The shape, pattern, and color of the service ball 104 can be customized according to the type, status, or function of the specific service. A device ball 103 may not have any service balls 104 attached, or it may have one or more service balls 104 attached. Figure 1 The service sphere 104 is an exemplary illustration and is not intended to limit the scope of the service sphere 104.

[0054] For the service ball 104 attached to the device ball 103, users can interact with the service ball 104 through clicking, dragging, or other interactive methods to manage and operate the services. For example, users can expand the service ball 104 by clicking, changing its form to a circulating service capsule 106 to view the specific services offered by the service ball 104. For instance, when a user clicks the service ball 104, it can expand into a circulating service capsule in the shape of a capsule card, displaying the specific content of the service, such as "screen sharing" or "call sharing." As another example, users can drag the service ball 104, detaching it from the device 1 and moving it along the trajectory of their finger.

[0055] In some examples, such as Figure 1 As shown in (a), a service capsule 105 can also be mounted on the device sphere 103. This service represents a service created by the electronic device (such as the local device) corresponding to the device sphere 103 that is ready to be transferred but has not yet been transferred. This service can be transferred between electronic devices within the trust ring 102. The shape, pattern, and color of the service capsule 105 can be customized according to the type, status, or function of the specific service. A device sphere 103 may or may not have any service capsules 105 mounted on it, or it may have one service capsule 105 mounted on it. Figure 1 The uncirculated service capsule 105 in (a) is an exemplary illustration and is not intended to limit the scope of the uncirculated service capsule 105.

[0056] For the uncirculated service capsule 105 mounted on the device sphere 103, users can interact with the uncirculated service capsule 105 through clicking, dragging, or other interactive methods to manage and operate the service. For example, users can click the close icon on the uncirculated service capsule 105 (e.g., ...). Figure 1 The operation indicated by "x" in (a) closes the uncirculated service capsule 105, thus stopping the circulation of the service corresponding to the uncirculated service capsule 105. For example, a user can move the uncirculated service capsule 105 by dragging it to attach it to another device sphere. For instance, a user drags the uncirculated service capsule 105 attached to their device to the vicinity of device 1 and touches it. The service corresponding to the uncirculated service capsule 105 attempts to establish a connection with device 1. After a successful connection, the uncirculated service capsule 105 changes its form to a service sphere and is attached to device 1.

[0057] In some examples, such as Figure 1As shown in (b), a service capsule 106 can also be mounted on the device sphere 103, representing a service that has been transferred to the deployed state of the electronic device (such as device 2) corresponding to the device sphere 103. This service can continue to be transferred between electronic devices within the trust ring 102. The shape, pattern, and color of the service capsule 106 can be customized according to the specific service type, status, or function. A device sphere 103 may or may not have a service capsule 106 mounted on it. Figure 1 The service capsule 106 in (b) is an exemplary illustration and is not intended to limit the scope of the service capsule 106.

[0058] For the service capsule 106 mounted on the device sphere 103, users can interact with the service capsule 106 through clicking, dragging, or other interactive methods to manage and operate the service. For example, users can click the close icon on the service capsule 106 (e.g., ...). Figure 1 (b) The operation marked "x" closes the transferred service capsule 106, thereby disconnecting the service corresponding to the transferred service capsule 106 from the device 2. For example, the user can collapse the transferred service capsule 106 by clicking on any position other than the close mark, thus hiding the specific content of the service displayed by the transferred service capsule 106 and changing its form to a service sphere. Furthermore, the user can move the transferred service capsule 106 by dragging it, transferring the service corresponding to the transferred service capsule 106 to the electronic device corresponding to another device sphere.

[0059] In some examples, uncirculated service capsule 105 and circulated service capsule 106 can be mounted at the same location on the device sphere 103, for example, both can be mounted on the upper part of the device sphere 103. Uncirculated service capsule 105 and circulated service capsule 106 can also be mounted at different locations on the device sphere 103, for example, uncirculated service capsule 105 can be mounted on the lower part of the device sphere 103, and circulated service capsule 106 can be mounted on the upper part of the device sphere 103. In practice, the shape, pattern, color, and mounting position of uncirculated service capsule 105 and circulated service capsule 106 on the device sphere 103 can be customized according to the specific service type, status, or function. Figure 1 This is an illustrative image and not a specific limitation.

[0060] As can be seen from the above description, the services provided by device sphere 103 can include three states: one is an unprocessed state, displayed as follows... Figure 1In (a) above, the uncirculated service capsule 105 mounted on the local machine represents a service created by the electronic device (i.e., the local machine) corresponding to device ball 103 that is ready for circulation but has not yet been circulated. Another approach is to expand the circulation status, displayed as follows: Figure 1 The service capsule 106 mounted on device 2, shown in (b), represents the expanded state of the service that has been transferred to the electronic device (i.e., device 2) corresponding to device sphere 103. Another type is the collapsed transfer state, displayed as follows: Figure 1 The service ball 104 that has been transferred on the device 1 shown represents the service that has been transferred to the folded state of the electronic device (i.e., device 1) corresponding to the device ball 103.

[0061] The service sphere 104 (service in folded state) and the service capsule 106 (service in expanded state) can be switched back and forth by clicking. The un-circulated service capsule 105 (service in uncirculated state) can be moved to the service sphere 104, and its form can be switched by dragging it to another device sphere to attempt to establish a connection with the corresponding electronic device (e.g., device 1). The form can be switched from the service capsule 106 to the un-circulated service capsule 105 by clicking the close button on the service capsule 106.

[0062] Taking call sharing as an example, using the "call sharing" service of a smart interconnected application, when a user is making a voice call on their own device (such as a mobile phone) and wants to switch to device 2 (such as a computer) to continue the call, they can establish a connection on their own device while maintaining the connection on their own device. Figure 1 The "Call Sharing" service capsule 105 shown in (a) is dragged and dropped, and then follows the user's finger. When moved to another device ball, the service corresponding to the untransferred service capsule 105 attempts to establish a connection with the electronic device (such as device 2) corresponding to the device ball. After a successful connection, the untransferred service capsule 105 switches to the transferred service capsule 106, and the "Call Sharing" service is transferred, that is, the local call is transferred to device 2, and the user can continue the call using device 2.

[0063] Smart interconnected applications can achieve cross-device service flow without cumbersome operations on multiple electronic devices, providing more convenient and flexible services. This allows users to continue using services across different electronic devices without having to restart or configure services on each device, thus improving user experience satisfaction.

[0064] In other words, the intuitive graphical interface of the aforementioned device interconnection application enables users to easily manage and control multiple electronic devices logged into the same account, and realize service flow between multiple electronic devices, making it convenient for users to manage and use the services on each electronic device.

[0065] Based on the interface design diagram of the above device interconnection application, there are two main interaction methods between users and device spheres, service spheres, and service capsules (including uncirculated and circulated service capsules): one is direct interaction, where users directly drag and drop service spheres and service capsules to interact, such as... Figure 2 As shown in (a), the user drags the un-transferred service capsule, detaching it from the electronic device (i.e., the local device) corresponding to the previously attached device ball. During the dragging process, it moves in real-time following the trajectory of the finger's touch point and performs collision detection with other device balls. When the un-transferred service capsule touches any other device ball, it attempts to perform a service transfer operation. When the service corresponding to the un-transferred service capsule successfully connects with the electronic device corresponding to the touched device ball, as shown... Figure 2 As shown in (b), the un-circulated service capsule switches to a service sphere and is attached to the touched device sphere. Another type is indirect interaction, such as... Figure 3 As shown in (a), the user drags the device ball, causing it to rotate around the user's avatar along the trust ring. When a service ball or service capsule is attached to the device ball, the service ball or service capsule attached to it rotates synchronously with the device ball as the device ball rotates.

[0066] In related technologies, the mounting positions of service balls and service capsules on the equipment sphere are fixed. When the number of service balls mounted on the equipment sphere is large, such as... Figure 3 When three service balls are mounted on the device ball shown in (b), due to the small horizontal length of the electronic device in the vertical screen scene, when the device ball rotates to the left and right edges of the screen, the service balls at the edges will exceed the screen display boundary, resulting in incomplete display of the service balls, affecting user operation and causing a poor user experience.

[0067] To address this, this application provides a device interconnection and interaction method. In this method, the position of the service ball mounted on the device ball is rotatable. While the service ball rotates with the device ball, the service ball rotates or changes the interval angle between the service balls to rotate and avoid the screen edge when it is close to the edge. This ensures that the obscured service ball is displayed on the screen as much as possible, reducing the area that exceeds the screen display boundary, facilitating user operation. Furthermore, the rotation and avoidance process ensures that the service ball moves smoothly and continuously, avoiding abrupt movements and further improving the user experience.

[0068] The electronic devices described in this application include, but are not limited to, mobile phones, laptops, tablets, laptop computers, personal computers (PCs), personal digital assistants (PDAs), or wearable devices (such as smartwatches or wristbands). Furthermore, the aforementioned electronic devices include, but are not limited to, those running Apple (iOS), Android, Microsoft, or other operating systems.

[0069] In this embodiment of the application, electronic devices can communicate with each other via a network. This network includes, but is not limited to, Wireless Local Area Network (WLAN), Global System for Mobile Communications (GSM), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), General Packet Radio Service (GPRS), Long Term Evolution (LTE), LTE Frequency Division Duplex (FDD), LTE Time Division Duplex (TDD), Universal Mobile Telecommunications System (UMTS), Worldwide Interoperability for Microwave Access (WiMAX), and future 5th generation (5G) systems or new radio (NR), etc.

[0070] The method provided in the embodiments of this application will be described below with reference to the apparatus for implementing the embodiments of this application.

[0071] The technical solutions provided in this application can be applied to electronic devices. In some embodiments, the electronic device may be a mobile phone, tablet computer, handheld computer, personal computer (PC), ultra-mobile personal computer (UMPC), netbook, as well as cellular phone, personal digital assistant (PDA), augmented reality (AR) device, virtual reality (VR) device, artificial intelligence (AI) device, wearable device, in-vehicle device, smart home device and / or smart city device, etc. The embodiments of this application do not impose any special limitations on the specific type of electronic device.

[0072] For example, taking a mobile phone as an electronic device, Figure 4 A schematic diagram of the structure of an electronic device provided in an embodiment of this application is shown.

[0073] Reference Figure 4 As shown, the electronic device may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, a sensor module 180, buttons 190, a motor 191, an indicator 192, a display screen 193, a subscriber identification module (SIM) card interface 194, and a camera 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an accelerometer sensor 180E, a distance sensor 180F, a proximity sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0074] Processor 110 may include one or more processing units, such as: application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, memory, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.

[0075] A controller can be the nerve center and command center of an electronic device. Based on the instruction opcode and timing signals, the controller generates operation control signals to control the fetching and execution of instructions.

[0076] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can store instructions or data that the processor 110 has just used or that are used repeatedly. If the processor 110 needs to use the instruction or data again, it can retrieve it directly from the memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.

[0077] Digital signal processors (DSPs) are used to process digital signals. Besides digital image signals, they can also process other digital signals. For example, when an electronic device is selecting a frequency, a DSP can perform a Fourier transform on the frequency energy.

[0078] In some embodiments, the processor 110 may include one or more interfaces. Interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.

[0079] The external memory interface 120 can be used to connect to external non-volatile memory, thereby expanding the storage capacity of the electronic device. The external non-volatile memory communicates with the processor 110 through the external memory interface 120 to perform data storage functions. For example, music, video, and other files can be stored in the external non-volatile memory.

[0080] Internal memory 121 may include one or more random access memory (RAM) and one or more non-volatile memory (NVM). The RAM can be directly read and written by the processor 110 and can be used to store executable programs (e.g., machine instructions) of the operating system or other running programs, as well as user and application data. The NVM can also store executable programs and user and application data, and can be pre-loaded into the RAM for direct read and write operations by the processor 110.

[0081] USB port 130 is a USB standard compliant interface, which can be a Mini USB port, Micro USB port, USB Type-C port, etc. USB port 130 can be used to connect a charger to charge electronic devices, and can also be used for data transfer between electronic devices and peripheral devices. It can also be used to connect headphones for audio playback. This interface can also be used to connect other electronic devices, such as AR devices.

[0082] The charging management module 140 is used to receive charging input from a power supply device (such as a charger, laptop power supply, etc.). The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 can receive charging input from the wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 can receive wireless charging input via the wireless charging coil of the electronic device.

[0083] While charging the battery 142, the charging management module 140 can also supply power to the electronic device through the power management module 141. Specifically, the battery 142 can be composed of multiple batteries connected in series. The power management module 141 is used to connect the battery 142, the charging management module 140, and the processor 110.

[0084] The power management module 141 connects the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, providing power to the processor 110, internal memory 121, display screen 193, camera 195, and wireless communication module 160, etc. The power management module 141 can also monitor parameters such as battery voltage, current, battery cycle count, and battery health status (leakage current, impedance). In some other embodiments, the power management module 141 may also be located within the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be located in the same device.

[0085] The wireless communication function of electronic devices can be realized through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem, and baseband processor.

[0086] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in the electronic device can be used to cover one or more communication frequency bands. Different antennas can also be reused to improve antenna utilization. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antennas can be used in conjunction with a tuning switch.

[0087] The mobile communication module 150 can provide wireless communication solutions, including 2G / 3G / 4G / 5G, for use in electronic devices. The mobile communication module 150 can receive electromagnetic waves via antenna 1, and perform filtering, amplification, and other processing on the received electromagnetic waves before transmitting them to a modem processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modem processor and convert it into electromagnetic waves for radiation via antenna 1. In some embodiments, at least some functional modules of the mobile communication module 150 can be housed in the processor 110. In some embodiments, at least some functional modules of the mobile communication module 150 and at least some modules of the processor 110 can be housed in the same device.

[0088] The modem processor may include a modulator and a demodulator. The modulator modulates the low-frequency baseband signal to be transmitted into a mid-to-high frequency signal. The demodulator demodulates the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After processing by the baseband processor, the low-frequency baseband signal is transmitted to the application processor. The application processor outputs sound signals through audio devices (not limited to speaker 170A, receiver 170B, etc.) or displays images or videos through the display screen 193. In some embodiments, the modem processor may be a separate device. In other embodiments, the modem processor may be independent of the processor 110 and may be housed in the same device as the mobile communication module 150 or other functional modules.

[0089] The wireless communication module 160 can provide solutions for wireless communication applications in electronic devices, including wireless local area networks (WLANs) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared (IR) technologies. The wireless communication module 160 can be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via antenna 2, performs frequency modulation and filtering of the electromagnetic wave signals, and sends the processed signal to processor 110. The wireless communication module 160 can also receive signals to be transmitted from processor 110, perform frequency modulation and amplification, and convert them into electromagnetic waves for radiation via antenna 2.

[0090] Electronic devices can implement audio functions such as music playback and recording through audio modules 170, speakers 170A, receivers 170B, microphones 170C, headphone jacks 170D, and application processors.

[0091] Pressure sensor 180A is used to sense pressure signals and convert them into electrical signals. In some embodiments, pressure sensor 180A can be disposed on display screen 193. There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, and capacitive pressure sensors. When a touch operation is applied to display screen 193, the electronic device detects the intensity of the touch operation based on pressure sensor 180A. The electronic device can also calculate the touch position based on the detection signal from pressure sensor 180A. In some embodiments, touch operations applied to the same touch position but with different intensities can correspond to different operation commands. For example, when a touch operation with an intensity less than a first pressure threshold is applied to the SMS application icon, a command to view an SMS message is executed. When a touch operation with an intensity greater than or equal to the first pressure threshold is applied to the SMS application icon, a command to create a new SMS message is executed.

[0092] The gyroscope sensor 180B can be used to determine the motion attitude of an electronic device. In some embodiments, the angular velocity of the electronic device about three axes (i.e., the x, y, and z axes) can be determined by the gyroscope sensor 180B.

[0093] The barometric pressure sensor 180C is used to measure air pressure. In some embodiments, the electronic device calculates altitude using the air pressure value measured by the barometric pressure sensor 180C to assist in positioning and navigation.

[0094] The magnetic sensor 180D includes a Hall effect sensor. The electronic device can use the magnetic sensor 180D to detect the opening and closing of a flip case. In some embodiments, when the electronic device is a foldable phone, the electronic device can detect the opening and closing of the foldable phone based on the magnetic sensor 180D.

[0095] The 180E accelerometer can detect the magnitude of acceleration in various directions (typically three axes) of electronic devices. When the electronic device is stationary, it can detect the magnitude and direction of gravity.

[0096] The 180F distance sensor is used to measure distance. Electronic devices can measure distance using infrared or laser.

[0097] The proximity sensor 180G may include, for example, a light-emitting diode (LED) and a light detector, such as a photodiode. The LED may be an infrared LED. The electronic device emits infrared light outward through the LED. The electronic device uses the photodiode to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that an object is near the electronic device. When insufficient reflected light is detected, the electronic device can determine that no object is near the electronic device.

[0098] The fingerprint sensor 180H is used to collect fingerprints. Electronic devices can utilize the characteristics of the collected fingerprints to achieve fingerprint unlocking, app access locks, fingerprint photography, fingerprint answering of calls, etc.

[0099] Temperature sensor 180J is used to detect temperature. In some embodiments, the electronic device uses the temperature detected by temperature sensor 180J to execute a temperature processing strategy.

[0100] Touch sensor 180K, also known as a "touch device," can be located on display screen 193. The touch sensor 180K and display screen 193 together form a touchscreen, also known as a "touchscreen." Touch sensor 180K is used to detect touch operations applied to or near it. Touch sensor 180K 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 display screen 193. In other embodiments, touch sensor 180K may also be located on the surface of the electronic device, in a different position than display screen 193.

[0101] The ambient light sensor 180L is used to sense ambient light brightness. For example, the ambient light sensor 180L can measure the light intensity of four channels of ambient light. The ambient light sensor 180L outputs the measured light intensity of the four channels of ambient light to the processor 110. The processor 110 can process the light intensity of the four channels of ambient light output by the ambient light sensor 180L to obtain the ambient light intensity. In the screen-on state, the electronic device can adaptively adjust the display brightness according to the obtained ambient light intensity. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also be used in conjunction with the proximity sensor 180G to detect whether the electronic device is in a pocket to prevent accidental touches.

[0102] The bone conduction sensor 180M can acquire vibration signals. In some embodiments, the bone conduction sensor 180M can acquire vibration signals from the vibrating bone segments of the human vocal cords. The bone conduction sensor 180M can also contact the human pulse to receive blood pressure signals. In some embodiments, the bone conduction sensor 180M can also be incorporated into headphones to form bone conduction headphones. The audio module 170 can analyze the voice signals based on the vibration signals from the vibrating bone segments of the vocal cords acquired by the bone conduction sensor 180M to realize voice functionality.

[0103] Buttons 190 include a power button, volume buttons, etc. Buttons 190 can be mechanical buttons or touch-sensitive buttons. The electronic device can receive button input and generate key signal inputs related to user settings and function control of the electronic device.

[0104] Motor 191 can generate vibration alerts. Motor 191 can be used for incoming call vibration alerts or for touch vibration feedback. For example, different vibration feedback effects can be corresponding to touch operations performed on different applications (such as taking photos, playing audio, etc.). Motor 191 can also correspond to different vibration feedback effects for touch operations performed on different areas of the display screen 194.

[0105] Indicator 192 can be an indicator light, used to indicate charging status, power changes, or to indicate messages, missed calls, notifications, etc.

[0106] In some embodiments, an electronic device may include one or N cameras 195, where N is a positive integer greater than 1. In this application embodiment, the type of camera 195 can be distinguished based on hardware configuration and physical location. For example, a camera located on the side of the electronic device's display screen 193 can be called a front-facing camera, and a camera located on the side of the electronic device's back cover can be called a rear-facing camera; another example is that a camera with a short focal length and a wide field of view can be called a wide-angle camera, while a camera with a long focal length and a narrow field of view can be called a regular camera. Here, focal length and field of view are relative concepts and are not specifically limited by parameters. Therefore, wide-angle cameras and regular cameras are also relative concepts, and can be specifically distinguished based on physical parameters such as focal length and field of view.

[0107] The electronic device implements display functions through a GPU, a display screen 193, and an application processor. The GPU is a microprocessor for image editing, connected to the display screen 193 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.

[0108] Electronic devices can achieve shooting functions through ISP, camera 195, video codec, GPU, display 193, and application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. Processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information. In this embodiment, the GPU's functions are used during the frame rendering process of each image frame to achieve better display effects and performance in the final displayed image.

[0109] The Information Service Provider (ISP) is used to process data fed back from the camera 195. For example, when taking a picture, the shutter is opened, and light is transmitted through the lens to the camera's photosensitive element. The light signal is converted into an electrical signal, and the camera's photosensitive element transmits the electrical signal to the ISP for processing, transforming it into an image visible to the naked eye. The ISP can also perform algorithmic optimization on image noise and brightness. The ISP can also optimize parameters such as exposure and color temperature of the shooting scene. In some embodiments, the ISP can be integrated into the camera 195. The camera 195 is used to capture still images or videos.

[0110] Display screen 193 is used to display images, videos, etc. Display screen 193 includes a display panel. The display panel may be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a sub-millimeter light-emitting diode (MiniLED), a micro light-emitting diode (MicroLED), a micro-OLED, a quantum dot light-emitting diode (QLED), etc. In some embodiments, the electronic device may include one or N displays 193, where N is a positive integer greater than 1.

[0111] In this embodiment, the display screen 193 can be used to display the interface required by the electronic device (e.g., the interface of a device interconnection application, a wizard interface (including a recommendation page and an external module access page), etc.), and can also display images captured by any one or more cameras 195 in the interface.

[0112] The SIM card interface 194 is used to connect a SIM card. The SIM card can be inserted into or removed from the SIM card interface 194 to make contact with and detach from the electronic device. The electronic device can support one or more SIM card interfaces. The SIM card interface 194 supports Nano SIM cards, Micro SIM cards, and other SIM cards. Multiple cards can be inserted into the same SIM card interface 194 simultaneously. The SIM card interface 194 is also compatible with external memory cards. The electronic device interacts with the network through the SIM card to achieve functions such as calls and data communication. One SIM card corresponds to one user number.

[0113] It is understood that the interface connection relationships between the modules illustrated in the embodiments of this application are merely illustrative and do not constitute a limitation on the structure of the electronic device. In other embodiments of this application, the electronic device may also employ different interface connection methods or combinations of multiple interface connection methods as described in the above embodiments.

[0114] Of course, this is understandable. Figure 4 The illustration shown is merely an example when the electronic device is in the form of a mobile phone. If the electronic device is in the form of a tablet, handheld computer, PC, PDA, wearable device (such as a smartwatch, smart bracelet), or other similar device, the structure of the electronic device may include more advanced features. Figure 4 The fewer structures shown can also include more than Figure 4 The structures shown are not limited here.

[0115] It is understandable that, generally speaking, the implementation of electronic device functions requires not only hardware support but also software cooperation. The software system of electronic devices can adopt a layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture. This application's embodiment uses a layered architecture... Taking the system as an example, the software structure of the electronic device is illustrated.

[0116] The technical solutions provided in the embodiments of this application can all be implemented in electronic devices with the above-described hardware or software architecture.

[0117] Based on the above Figure 4 The hardware architecture shown below, combined with Figure 5 The present application will introduce the device interconnection and interaction method provided in the embodiments. Figure 5 This is a flowchart illustrating a device interconnection and interaction method provided in an embodiment of this application. The method is applied to electronic devices, such as... Figure 5 As shown, the device interconnection and interaction method may include steps S501 to S541:

[0118] Step S501: The electronic device receives the interactive operation input by the user in the interface of the device interconnection application.

[0119] The center of the device interconnection application's interface displays the currently logged-in user's information, specifically the user's avatar. Surrounding the avatar is a trust ring, upon which at least one device sphere is arranged. Each device sphere represents an electronic device logged into that user's account, such as a mobile phone, tablet, smartwatch, TV, or computer. When the interface includes only one device sphere, the device corresponding to that sphere is the electronic device, i.e., the local device. When the interface includes multiple device spheres, one of the device spheres corresponds to the local device, and the local device interconnects with the devices corresponding to the other device spheres.

[0120] The embodiments of this application are as follows: Figure 6 The interface of the device interconnection application shown is illustrated as an example. Figure 6 As shown, the interface includes three device spheres, corresponding to the local device, device 1, and device 2, respectively. The local device has the uncirculated service capsule "Call Sharing" installed, device 1 has three service spheres installed, and device 2 has the circulated service capsule "Screen Sharing" and four service spheres installed.

[0121] For ease of description, in this embodiment, the top-left corner of the electronic device's display screen is defined as the origin (0, 0), with the x-axis pointing to the right and the y-axis pointing downwards. The center point of the user's avatar is the center of the trust ring, and its coordinates are represented as (x, y). o y o The center of the trust ring is 0° to the right. Clockwise rotation is defined as positive rotation; therefore, the center of the trust ring is 90° downwards, 180° to the left, and 270° upwards. In the initialization interface, the local device sphere is displayed at 270° on the trust ring.

[0122] It should be noted that, Figure 6 The location, shape, size, pattern, logo, and color of the user avatar, trust ring, device sphere, service sphere, and service capsule are merely examples. In this application embodiment, the location, shape, size, pattern, logo, and color of the user avatar, trust ring, device sphere, service sphere, and service capsule are not limited.

[0123] Users Figure 6 The interface of the device interconnection application shown allows for various interactive operations, such as clicking the device ball, clicking the service ball, clicking the service capsule, clicking a blank area (the area in the interface other than the displayed object), dragging the device ball, dragging the service ball, and dragging the service capsule.

[0124] In this embodiment, the interactive operation can be input by the user touching the screen of the electronic device with their finger, or it can be input through an input device, such as a mouse or keyboard connected to the electronic device. In practical applications, users can also input interactive operations in other ways, which are not limited in this embodiment.

[0125] Step S502: Determine whether the interactive operation is a first operation used to drag the first device ball in the interface.

[0126] If the user's input interaction is the first operation, that is, the user's current input interaction is a continuous operation of dragging a device ball on the interface, then proceed to step S503. If the user's input interaction is not the first operation, proceed to step S514.

[0127] For ease of distinction, the device sphere currently being dragged by the user will be referred to as the first device sphere. This first device sphere can be... Figure 6 The local machine in the context can be either device 1 or device 2.

[0128] Step S503: In response to the first operation, obtain the device ball first information of the second device ball at the current time, the service ball first information of the service ball attached to the second device ball, and the service capsule first information of the service capsule attached to the second device ball in the interface.

[0129] The second device sphere can be any device sphere in the interface. The first information about the device sphere may include its size and current rotation angle. For example... Figure 6 As shown, in this embodiment, the second device sphere is circular, and its size can be the radius, denoted as r1. In other embodiments, the second device sphere can be rectangular, and its size can refer to its length and width. The current rotation angle of the second device sphere refers to the angle of clockwise rotation between the line connecting the center point (i.e., the center of the circle) of the second device sphere and the center of the trust ring, and the axis to the right of the center of the trust ring. The current rotation angle ranges from [0°, 360°].

[0130] The first information about the service spheres may include the size and quantity of the service spheres mounted on the second device sphere. For example... Figure 6As shown, in this embodiment, the service sphere is circular, and its size can be the radius, denoted as r2. In other embodiments, the service sphere can be rhomboid, and its size can refer to the length of the two diagonals. The number of service spheres mounted on the second device sphere is denoted as count, and count is a natural number. Mounting one service sphere on a device sphere represents one service provided by the electronic device corresponding to the device sphere. Generally, the number of services shared by electronic devices in device interconnection applications is limited. Based on this, in this embodiment, count can be set to 0, 1, 2, 3, 4, 5, or 6, meaning that a device sphere can have a minimum of 0 service spheres and a maximum of 6 service spheres mounted, avoiding excessive service connections on electronic devices.

[0131] The first information about the service capsules may include the size, quantity, and type of the service capsules mounted on the second device sphere. For example... Figure 6 As shown, in this embodiment, the service capsule is a rounded rectangle, and its dimensions can be the width and height of the smallest bounding rectangle of the rounded rectangle. The width of the service capsule is represented by `width`, and the height by `height`. Service capsules are categorized into transferred and non-transferred types. A transferred service capsule represents a service transferred from other devices to the device corresponding to the second device sphere, while a non-transferred service capsule represents a service created by the device corresponding to the second device sphere but not transferred. In this embodiment, a transferred service capsule can be mounted on the upper end of the device sphere, and a non-transferred service capsule can be mounted on the lower end of the device sphere.

[0132] The number of service capsules can be 0, 1, or 2, meaning that the second equipment sphere can carry 0, 1, or 2 service capsules. When the second equipment sphere carries 2 service capsules, the two service capsules are of different types: one is a service capsule that has been circulated and is carried at the top of the second equipment sphere, and the other is a service capsule that has not been circulated and is carried at the bottom of the second equipment sphere.

[0133] Step S504: Determine the initial angle of each service ball based on the number of service balls.

[0134] The angle of the service sphere refers to the clockwise rotation between the line connecting the center point (i.e., the center of the circle) of the service sphere and the center of the device sphere it is attached to, and the axis pointing to the right from the center of the trust ring. The initial angle of the service sphere is the angle corresponding to its initial position; this angle can be a predefined angle. For example, all service spheres are defined to be symmetrical about the vertical axis of the user's avatar, and the angle between any two spheres is 60°. Based on this, the two-dimensional array of initial angles for the service spheres can be: SERVICE_BALL_RING_ANGLE_ARRAY = {

[0135] {270°},

[0136] {240°, 300°},

[0137] {210°, 270°, 330°},

[0138] {180°, 240°, 300°, 0°},

[0139] {150°, 210°, 270°, 330°, 30°},

[0140] {120°, 180°, 240°, 300°, 0°, 60°}}.

[0141] Determine the initial angle of each service ball based on the number of service balls. For example... Figure 6 Three service spheres are mounted on device 1. The initial angles of these three service spheres are 210°, 270°, and 330°, respectively. The included angle of these three service spheres at the interface is as follows: Figure 7 As shown in (a) in the figure. Figure 6 Four service spheres are mounted on device 2. The initial angles of these four service spheres are 180°, 240°, 300°, and 0°, respectively. The included angle of these four service spheres at the interface is as follows: Figure 7 As shown in (b) of the diagram.

[0142] Step S505: Determine the avoidance angle based on the current rotation angle and the number of service balls.

[0143] During the rotation of the ball in the second device, as... Figure 8 As shown in (a), when rotating to a non-edge area of ​​the electronic device's display screen, regardless of the number of service balls mounted thereon, they will not exceed the display screen boundary, and the service balls do not need to avoid this area; Figure 8 As shown in (b), when rotating to the edge area of ​​the electronic device screen, if there are few service balls mounted on it (e.g., 1 or 2), the service balls will not exceed the boundary of the display screen, and the service balls do not need to avoid the edge. Figure 9 As shown in (a), when rotating to the edge area of ​​the electronic device screen, if there are many service balls (e.g., 3, 4, 5) mounted on it, the service balls will extend beyond the display boundary. This can be prevented by rotating the service balls. Figure 9 As shown in (b), when rotating to the edge area of ​​the electronic device screen, if the number of service balls mounted on it reaches the maximum (e.g., 6), the service balls will exceed the boundary of the display screen. Since there is no extra clearance, even if the service balls are rotated, they cannot avoid exceeding the boundary, and in this case, the service balls do not make clearance. Based on this, in this embodiment of the application, the clearance angle of the service balls is determined according to the current rotation angle of the second device ball and the number of service balls mounted on it.

[0144] In one implementation, the avoidance angle can be determined according to the following steps:

[0145] Step S5051: Determine the maximum avoidance angle based on the number of service balls.

[0146] The number of service balls, count, ranges from 0 to 6. When the number of service balls is 0, the second device ball has no service balls attached, and no avoidance is required. When the number of service balls is 1 or 2, the service balls attached to the second device ball will not exceed the boundary during rotation, so no avoidance is required, and the maximum avoidance angle is set to 0°. When the number of service balls is 3, 4, or 5, the service balls attached to the second device ball may exceed the boundary of the electronic device during rotation, but rotation can prevent the service balls from exceeding the boundary, and the maximum avoidance angles are set to 60°, 90°, and 120° respectively. When the number of service balls is 6, there is no space for avoidance, and even rotation cannot prevent the service balls from exceeding the boundary, so no avoidance is required, and the maximum avoidance angle is set to 0°. The predefined maximum avoidance angles for different numbers of service balls can be represented by an array as SERVICE_BALL_RING_AVOID_ANGLE_ARRAY = {0°, 0°, 60°, 90°, 120°, 0°}.

[0147] In this embodiment of the application, after determining the number of service balls mounted on the second device ball, the maximum avoidance angle can be obtained according to the predefined array described above. For example... Figure 6 Equipment 1 has 3 service spheres mounted on it, so the maximum avoidance angle for each service sphere on Equipment 1 is 60°. Equipment 2 has 4 service spheres mounted on it, so the maximum avoidance angle for each service sphere on Equipment 2 is 90°.

[0148] Step S5052: Calculate the avoidance angle based on the current rotation angle and the maximum avoidance angle.

[0149] If the rotation angle of the second device ball is within the preset angle range, it indicates that the second device ball has rotated to the edge area of ​​the electronic device's display screen. To prevent the service ball mounted on it from exceeding the boundary, avoidance measures need to be taken. If the rotation angle of the second device ball is not within the preset angle range, it indicates that the second device ball has rotated to the non-edge area of ​​the electronic device's display screen. The service ball mounted on it will not exceed the boundary, and no avoidance measures are required.

[0150] In this embodiment of the application, the preset angle range can be {[0°, 40°], [140°, 220°], [320°, 360°)}.

[0151] For example, the current rotation angle of the second device ball is represented as deviceBallAngle, the number of service balls is represented as count, and the avoidance angle can be calculated as follows:

[0152] When the current rotation angle of the second device ball is within the range of [320°, 335°], the avoidance angle avoidAngle = -(deviceBallAngle - 320°) * SERVICE_BALL_RING_AVOID_ANGLE_ARRAY[count] / 15;

[0153] When the current rotation angle of the second device ball is within the range of (335°, 360°) or [0°, 25°), the avoidance angle avoidAngle = -SERVICE_BALL_RING_AVOID_ANGLE_ARRAY[count];

[0154] When the current rotation angle of the second device ball is within the range of [25°, 40°], the avoidance angle avoidAngle = (deviceBallAngle - 40°) * SERVICE_BALL_RING_AVOID_ANGLE_ARRAY[count] / 15;

[0155] When the current rotation angle of the second device ball is within the range of [140°, 155°], the avoidance angle avoidAngle = (deviceBallAngle - 140°) * SERVICE_BALL_RING_AVOID_ANGLE_ARRAY[count] / 15;

[0156] When the current rotation angle of the second device ball is within the range of (155°, 205°), the avoidance angle avoidAngle = SERVICE_BALL_RING_AVOID_ANGLE_ARRAY[count];

[0157] When the current rotation angle of the second device ball is within the range of [205°, 220°], the avoidance angle avoidAngle = -(deviceBallAngle - 220°) * SERVICE_BALL_RING_AVOID_ANGLE_ARRAY[count] / 15;

[0158] When the current rotation angle of the second device ball is within the range of (40°, 140°) or (220°, 320°), the avoidance angle is 0°.

[0159] Based on the above formula, the avoidance angle of the service ball is calculated. In the above calculation formula, if the calculated avoidance angle is less than 0, it indicates that the service ball rotates counterclockwise relative to the second equipment ball to avoid it; if the calculated avoidance angle is greater than 0, it indicates that the service ball rotates clockwise relative to the second equipment ball to avoid it.

[0160] Since the relative positions of multiple service balls on the same equipment sphere remain unchanged, when avoidance is required, the multiple service balls avoid the obstacle synchronously, so the avoidance angles of the multiple service balls are the same. After this step is completed, proceed to step S506.

[0161] Step S506: Determine the current angle of each service ball based on the avoidance angle and the initial angle of each service ball.

[0162] In step S504, the initial angle of each service ball is obtained based on the number of service balls (count) mounted on the second device ball and the predefined array SERVICE_BALL_RING_ANGLE_ARRAY. For example... Figure 6 The initial angles of the three service spheres mounted on device 1 are 210°, 270° and 330°, respectively, and the initial angles of the four service spheres mounted on device 2 are 180°, 240°, 300° and 0°, respectively.

[0163] Based on the avoidance angle avoidedAngle determined in step S505 and the initial angle of each service ball, the current angle of the i-th service ball is calculated as svcAngle(i) = SERVICE_BALL_RING_ANGLE_ARRAY[count][i] + avoidAngle.

[0164] Step S507: Determine the current center coordinates of the second device ball based on its current rotation angle and radius.

[0165] The center coordinates of the trust ring determined by the above steps are (x... o y o The current rotation angle of the second device sphere is deviceBallAngle, and the radius of the second device sphere is r1. Using the sine and cosine laws, the current center coordinates (x, y) of the second device sphere are calculated. dev y dev ), where x dev =x o +r1*cos(deviceBallAngle), y dev =y o +r1*sin(deviceBallAngle).

[0166] Step S508: Determine the current center coordinates of each service ball based on the current center coordinates and radius of the second device ball, and the current angle and radius of each service ball.

[0167] Based on the above steps, the current center coordinates (x, y) of the second device sphere are determined. dev y devThe radius of the second device sphere is r1, the current angle of each service sphere is svcAngle(i), and the radius of each service sphere is r2. Using the sine and cosine laws, the current center coordinates (x, y) of each service sphere are calculated. svc(i) y svc(i) ), where x svc(i) =x dev +(r1+r2)*cos(svcAngle(i)), y svc(i) =y dev +(r1+r2)*sin(svcAngle(i)).

[0168] Step S509: Determine the current coordinates of the target point of the second device sphere based on the current center coordinates and radius of the second device sphere.

[0169] Since electronic devices typically determine an object's position on a display screen using the coordinates of its top-left corner, after determining the current center coordinates of the second device sphere, it is necessary to determine the coordinates of its target point. In this embodiment, the target point of the second device sphere can be the top-left vertex of its smallest bounding rectangle. Based on the current center coordinates (x...) of the second device sphere... dev y dev Given the radius r1, the current coordinates (x, y) of the target point of the second device sphere are calculated. leftdev y topdev ), where x leftdev =x dev –r1,y topdev =y dev –r1.

[0170] Step S510: Determine the current coordinates of the target point of each service sphere based on the current center coordinates and radius of each service sphere.

[0171] Similar to the second device sphere, after determining the current center coordinates and radius of each service sphere, it is necessary to determine the current coordinates of the target point of each service sphere. In this embodiment, the target point of each service sphere can be the upper left vertex of the smallest bounding rectangle of that service sphere. Based on the current center coordinates (x...) of each service sphere... svc(i) y svc(i) Given the radius r2, the current coordinates (x, y) of the target point of each service sphere are calculated. leftsvc(i) y topsvc(i) ), where x leftsvc(i) =x svc(i) –r2,y topsvc(i) =y svc(i) –r2.

[0172] Step S511: Determine the current coordinates of the target point of the service capsule based on the current center coordinates and radius of the second device sphere and the size of the service capsule.

[0173] In this embodiment of the application, if the second device sphere is equipped with a service capsule, the service capsule also needs to be moved synchronously.

[0174] If the second device sphere carries a service capsule that has already been transferred, it is attached to the upper part of the second device sphere. This is based on the current center coordinates (x, y) of the second device sphere. dev y dev Using the radius r1 and the dimensions (width, height) of the service capsule, the coordinates (x, y) of the center point of the transferred service capsule are determined. capy y capy ), where x capy =x dev y capy =y dev –r1-height / 2.

[0175] Similar to the second device sphere, after determining the coordinates of the center point of the already transferred service capsule, it is necessary to determine the current coordinates of the target point of the already transferred service capsule. In this embodiment, the target point of the already transferred service capsule can be the upper left vertex of the smallest bounding rectangle of the service capsule. Based on the coordinates of the center point of the already transferred service capsule (x... capy y capy Given the dimensions (width, height), the current coordinates (x, y) of the target point of the transferred service capsule are calculated. leftcapy y topcapy ), where x leftcapy =x capy –width / 2, y topcapy =y capy –height / 2.

[0176] If the second equipment sphere carries an uncirculated service capsule, it is attached to the lower end of the second equipment sphere. This is based on the current center coordinates (x, y) of the second equipment sphere. dev y dev Using the radius r1 and the dimensions (width, height) of the service capsule, the coordinates (x, y) of the center point of the uncirculated service capsule are determined. capn y capn ), where x capn =x dev y capn =y dev +r1+height / 2.

[0177] Similarly, after determining the coordinates of the center point of the uncirculated service capsule, it is necessary to determine the current coordinates of the target point of the uncirculated service capsule. In this embodiment, the target point of the uncirculated service capsule can be the top-left vertex of the smallest bounding rectangle of the service capsule. Based on the coordinates of the center point of the uncirculated service capsule (x... capn y capn Given the dimensions (width, height), the current coordinates (x, y) of the target point of the untransferred service capsule are calculated. leftcapn y topcapn ), where x leftcapn =x capn –width / 2, y topcapn =y capn –height / 2.

[0178] Step S512: Move the second device ball, each service ball, and the service capsule according to the current coordinates of the target point of the second device ball, the current coordinates of the target points of each service ball, and the current coordinates of the target point of the service capsule.

[0179] In this embodiment of the application, after determining the current coordinates of the target point of the second device ball, the current coordinates of the target points of each service ball, and the current coordinates of the target point of the service capsule, the layout function layout(x,y) can be called to move the second device ball, each service ball, and the service capsule to the target position.

[0180] Step S513: Determine whether the first operation has ended.

[0181] The first operation is a continuous dragging of the first device ball. When the user continues to input the first operation, such as continuing to drag the first device ball, it is determined that the first operation is not yet finished. The process returns to step S503 to continue controlling the second device ball to move synchronously with the finger, and controlling the service balls and service capsules attached to the second device ball to move accordingly. When the user finishes inputting the first operation, such as removing the finger from the first device ball, it is determined that the first operation is finished. The second device ball no longer moves synchronously with the finger, and the service balls and service capsules attached to the second device ball also stop moving, proceeding to step S541.

[0182] Step S514: Determine whether the interactive operation is a second operation used to drag the first service ball in the interface.

[0183] If the user's input interaction is the second operation, that is, the user's current input interaction is a continuous operation of dragging a service ball on the interface, then proceed to step S515. If the user's input interaction is not the second operation, proceed to step S523.

[0184] For ease of distinction, the service sphere currently being dragged by the user will be referred to as the first service sphere. This first service sphere can... Figure 6 It can be any one of the multiple service spheres mounted on device 1, or any one of the multiple service spheres mounted on device 2.

[0185] In step S515, in response to the second operation, the initial information of the first service ball, the second information of the device ball of the third device ball attached to the first service ball, and the third information of the device ball of the fourth device ball are obtained.

[0186] The first service sphere is the currently dragged service sphere. Its initial information includes its initial coordinates. The third device sphere is the device sphere to which the first service sphere is attached. Its second information may include its size and current center coordinates. It should be noted that "attachment" here includes both direct and indirect attachment. Before dragging, the first service sphere is directly attached to the third device sphere (i.e., they are in contact); after dragging, it is indirectly attached (i.e., they are not currently in contact but were in contact before dragging).

[0187] The fourth device sphere is any device sphere on the interface other than the third device sphere. The third device sphere information of the fourth device sphere may include the size of the fourth device sphere and the current center coordinates.

[0188] Step S516: Control the first service ball to move to the position indicated by the second operation.

[0189] For example, if the second operation is input by the user through sliding the display screen of the electronic device, the first service ball is controlled to move to the position indicated by the second operation, that is, the first service ball is controlled to move to the position touched by the user's finger. If the second operation is input by the user through pressing and sliding the mouse, the first service ball is controlled to move to follow the movement of the mouse.

[0190] Step S517: Obtain the second service ball information of the first service ball at the current moment.

[0191] The second information of the first service sphere may include the size of the first service sphere and the current center coordinates.

[0192] Step S518: Based on the second information of the service ball and the third information of the device ball, detect whether the first service ball collides with the fourth device ball.

[0193] Based on the size and current center coordinates of the first service ball and the size and current center coordinates of the fourth device ball, determine whether the first service ball collides with the fourth device ball. If the first service ball collides with the fourth device ball, proceed to step S519; if the first service ball does not collide with the fourth device ball, proceed to step S521.

[0194] Step S519: The device corresponding to the fourth device ball attempts to establish a connection with the service corresponding to the first service ball, and determines whether the connection is successful.

[0195] Before connecting, determine whether the fourth device sphere can add a service sphere. If there is still a spare space, it is considered that a new sphere can be added and the process proceeds to step S519. If there is no spare space, that is, 6 device spheres are already mounted on the fourth device sphere, then proceed to step S521.

[0196] If the device corresponding to the fourth device ball successfully establishes a connection with the service corresponding to the first service ball, proceed to step S520; if the connection fails, proceed to step S522.

[0197] Step S520: Mount the first service ball to the fourth device ball, and update the third service ball information of the service ball mounted on the third device ball and the fourth service ball information of the service ball mounted on the fourth service ball.

[0198] The third information of the service ball may include the number of service balls mounted on the third device ball, and the fourth information of the service ball may include the number of service balls mounted on the fourth device ball.

[0199] Since the first service ball is dragged from the third device ball to the fourth device ball, it is no longer attached to the third device ball. Therefore, the number of service balls attached to the third device ball is reduced by 1, and the sequence numbers of all service balls following the first service ball in the service ball sequence corresponding to the third device ball are shifted forward by 1. The first service ball is then inserted at the end of the service ball sequence corresponding to the fourth device ball, and the number of service balls attached to the fourth device ball is increased by 1.

[0200] In this embodiment of the application, when adjusting the positions of the service balls mounted on the third and fourth device balls, the angle of each service ball can be determined according to the SERVICE_BALL_RING_ANGLE_ARRAY array defined in step S504 above, which will not be elaborated here.

[0201] After step S520 is completed, proceed to step S541.

[0202] Step S521: Determine whether the second operation has ended.

[0203] The second operation is a continuous dragging of the first service ball. When the user continues to input the second operation, such as continuing to drag the first service ball, it is determined that the second operation is not yet finished, and the process returns to step S516 to continue controlling the first service ball to move synchronously with the finger. When the user finishes inputting the second operation, such as removing the first service ball, it is determined that the second operation is finished, the first service ball no longer moves synchronously with the finger, and the process proceeds to step S522.

[0204] Step S522: Based on the initial information of the first service ball, restore the mounting of the first service ball in the third device ball row.

[0205] If the second operation ends before the user connects to another device ball while dragging the first service ball, or if the connection with another device ball fails, the user restores the initial position of the first service ball on the third device ball based on the initial information before the first service ball was dragged.

[0206] After step S522 is completed, proceed to step S541.

[0207] Step S523: Determine whether the interactive operation is a third operation used to drag the first service capsule in the interface.

[0208] If the user's input interaction is a third operation, that is, the user's current input interaction is a continuous operation of dragging a service capsule in the interface, then proceed to step S524. If the user's input interaction is not a third operation, proceed to step S532.

[0209] For ease of distinction, the service capsule currently being dragged by the user will be referred to as the first service capsule. This first service capsule can provide... Figure 6 The uncirculated service capsule mounted on the first machine can also be the circulated service capsule mounted on the second machine.

[0210] Step S524, in response to the third operation, obtain the initial information of the first service capsule and the fourth information of the fifth device ball and the fifth information of the sixth device ball mounted on the first service capsule.

[0211] Here, the first service capsule is the currently dragged service capsule. The fifth device sphere is the device sphere to which the first service capsule is attached. The fourth information of the fifth device sphere may include its size and current center coordinates. It should be noted that attachment here includes direct attachment and indirect attachment. Due to user dragging, the first service capsule is directly attached to the fifth device sphere before dragging, that is, the first service capsule and the fifth device sphere are connected; after dragging, it is indirectly attached to the fifth device sphere, that is, the first service capsule and the fifth device sphere are not currently connected but were connected before dragging.

[0212] The sixth device sphere is any device sphere on the interface other than the fifth device sphere. The fifth device sphere information for the sixth device sphere may include the size of the sixth device sphere and the current center coordinates.

[0213] Step S525: Control the first service capsule to move to the position indicated by the third operation.

[0214] For example, if the third operation is input by the user through sliding the display screen of the electronic device, the first service capsule is controlled to move to the position indicated by the third operation, that is, the first service capsule is controlled to move to the position touched by the user's finger. If the third operation is input by the user through pressing and sliding the mouse, the first service capsule is controlled to move to follow the movement of the mouse.

[0215] Step S526: Obtain the second information of the first service capsule at the current moment.

[0216] The second information of the first service capsule may include the size of the first service capsule and the current center coordinates.

[0217] Step S527: Based on the second information of the service capsule and the fifth information of the device ball, detect whether the first service capsule collides with the sixth device ball.

[0218] Based on the size and current center coordinates of the first service capsule, and the size and current center coordinates of the sixth device sphere, determine whether the first service capsule collides with the sixth device sphere. If the first service capsule collides with the sixth device sphere, proceed to step S528; if the first service capsule does not collide with the sixth device sphere, proceed to step S530.

[0219] Step S528: The device corresponding to the sixth device ball attempts to establish a connection with the service corresponding to the first service capsule, and determines whether the connection is successful.

[0220] Before connecting, determine whether the sixth device sphere can be used to attach a new service sphere. If there is still a spare space, it is considered that a new sphere can be attached and the process proceeds to step S528. If there is no spare space, that is, 6 device spheres are already attached to the sixth device sphere, then proceed to step S530.

[0221] If the device corresponding to the sixth device ball successfully establishes a connection with the service corresponding to the first service capsule, proceed to step S529; if the connection fails, proceed to step S531.

[0222] Step S529: Mount the first service capsule to the sixth device sphere, and update the third service capsule information of the service capsule mounted on the fifth device sphere and the fifth service sphere information of the service sphere mounted on the sixth service sphere.

[0223] The third information of the service capsule may include the number of service capsules mounted on the fifth device sphere, and the fifth information of the service sphere may include the number of service spheres mounted on the sixth device sphere.

[0224] Since the first service capsule is dragged from the fifth device sphere to the sixth device sphere, it is no longer attached to the fifth device sphere, thus reducing the number of service capsules attached to the fifth device sphere by 1. The service sphere corresponding to the folded first service capsule is inserted at the end of the service sphere sequence on the sixth device sphere, and the number of service spheres attached to the sixth device sphere is increased by 1.

[0225] In this embodiment of the application, when adjusting the position of each service ball mounted on the sixth device ball, the angle of each service ball can be determined according to the SERVICE_BALL_RING_ANGLE_ARRAY array defined in step S504 above, which will not be elaborated here.

[0226] After step S529 is completed, proceed to step S541.

[0227] Step S530: Determine whether the third operation has ended.

[0228] The third operation is a continuous dragging of the first service capsule. When the user continues to input the third operation, such as continuing to drag the first service capsule, it is determined that the third operation is not yet finished, and the process returns to step S525 to continue controlling the first service capsule to move synchronously with the finger. When the user finishes inputting the third operation, such as removing the first service capsule, it is determined that the third operation is finished, and the first service capsule no longer moves synchronously with the finger, proceeding to step S531.

[0229] Step S531: Based on the initial information of the first service capsule, restore the mounting of the first service capsule on the fifth device sphere.

[0230] If the third operation ends before the user connects to another device ball while dragging the first service capsule, or if the connection with another device ball fails, the user restores the initial position of the first service capsule on the fifth device ball based on the initial information before dragging the first service capsule.

[0231] After step S531 is completed, proceed to step S541.

[0232] Step S532: Determine whether the interactive operation is the fourth operation used to expand the seventh device ball in the interface.

[0233] The fourth operation can be a click operation. If the user clicks on a device ball in the device interconnection interface, it is assumed that the user wants to view the content of the services provided by that device ball, and proceeds to step S533; if the user's input operation is not the fourth operation, proceeds to step S534.

[0234] In step S533, in response to the fourth operation, expand the device corresponding to the seventh device ball in the interface.

[0235] The seventh device ball is the currently clicked device ball.

[0236] During deployment, it is determined whether the device corresponding to the seventh device sphere is the local machine. If the device corresponding to the seventh service sphere is the local machine, the local machine is deployed at the 270° position of the trust ring, and the window of the local machine displays the content of the service currently provided by the local machine. Other information may also be displayed, which is not limited in this embodiment. If the device corresponding to the seventh service sphere is not the local machine, other devices are deployed at the 90° position of the trust ring, and the window of the other device displays the content of the service currently provided by that device.

[0237] After step S533 is completed, proceed to step S541.

[0238] Step S534: Determine whether the interactive operation is the fifth operation used to expand the second service ball in the interface.

[0239] The fifth operation can be a click operation. If the user clicks the second service ball in the device interconnection interface, it is assumed that the user wants to view the content of the service ball, and the process proceeds to step S535; if the user's input operation is not the fifth operation, the process proceeds to step S537.

[0240] Step S535, in response to the fifth operation, obtain the sixth information of the device ball of the eighth device ball attached to the second service ball.

[0241] The second service sphere is the currently clicked service sphere. The eighth device sphere is the device sphere attached to the second service sphere. The sixth piece of information for the device sphere may include the size of the eighth device sphere and its current center coordinates.

[0242] Step S536: Based on the preset specifications of the service capsule, the size of the eighth device sphere, and the current center coordinates, unfold the service capsule corresponding to the second device sphere at the upper end of the eighth device sphere.

[0243] The preset specifications of the service capsule may include a preset shape and preset dimensions. In this embodiment, the preset shape of the service capsule may be a rounded rectangle, and its preset dimensions may be the width and height of the smallest bounding rectangle of the rounded rectangle, where the width of the service capsule is represented by the width and the height by the height. The service capsule corresponding to the second device sphere is unfolded at the top of the eighth device sphere, and its unfolding form can be found in [reference needed]. Figure 6 The service capsule mounted on the upper part of device 2.

[0244] After step S536 is completed, proceed to step S541.

[0245] Step S537: Determine whether the interactive operation is the sixth operation used to click the second service capsule in the interface.

[0246] The sixth operation can be a click operation. If the user clicks the second service capsule in the device interconnection interface, proceed to step S538; if the user's input operation is not the sixth operation, proceed to step S541.

[0247] Step S538: Determine whether the second service capsule is a service capsule that has already been transferred.

[0248] The second service capsule is the currently clicked service capsule. If the second service capsule is a transferred service capsule, it is assumed that the user wants to collapse the service capsule, and the process proceeds to step S539. If the second service capsule is an untransferred service capsule, the process proceeds to step S540.

[0249] Step S539, in response to the sixth operation, folds the transferred service capsule.

[0250] If the second service capsule is a service capsule that has already been transferred, the service capsule that has already been transferred will be folded, that is, folded into the corresponding service sphere. The top of the equipment sphere on which the second equipment capsule is attached will no longer display the service capsule that has already been transferred.

[0251] After step S539 is completed, proceed to step S541.

[0252] Step S540, in response to the sixth operation, close the uncirculated service capsule.

[0253] If the second service capsule is an uncirculated service capsule, the uncirculated service capsule is folded. Since it is uncirculated, the uncirculated service capsule is folded into the corresponding device, that is, the uncirculated service capsule is closed. The uncirculated service capsule is no longer displayed at the bottom of the device ball attached to the second device capsule.

[0254] After step S540 is completed, proceed to step S541.

[0255] Step S541, End.

[0256] The method provided in this application embodiment obtains the position of the device ball, the initial angle and avoidance angle of each service ball attached to the device ball when the user drags the device ball. Based on the position of the device ball, the initial angle and avoidance angle of each service ball, it determines when each service ball needs to avoid an obstacle and performs avoidance accordingly. During the rotation of the device ball, the service balls and service capsules attached to the device ball rotate smoothly and continuously with it. Moreover, it can reduce the occurrence of service balls exceeding the boundaries of the electronic device and ensure that the service balls move within the interface as much as possible, making it convenient for users to use the service balls on the electronic device and improving the user experience.

[0257] Based on the above embodiments, this application further provides a device interconnection and interaction method applied to electronic devices, such as... Figure 10 As shown, the device interconnection and interaction method includes the following steps:

[0258] Step S1001: In response to the received first operation for dragging the first device ball in the interface, obtain the device ball first information of the second device ball in the interface at the current time, the service ball first information and the service capsule first information corresponding to the second device ball.

[0259] The second device sphere is any device sphere in the interface. The first information about the device sphere may include its size and current rotation angle. The size of the second device sphere can be its radius. The current rotation angle of the second device sphere refers to the angle of clockwise rotation between the line connecting the center point (i.e., the center of the circle) of the second device sphere and the center of the trust ring, and the axis pointing to the right from the center of the trust ring. The current rotation angle ranges from [0°, 360°].

[0260] The first information about the service spheres can include the size and number of service spheres mounted on the second device sphere. The size of the service sphere can be its radius. The number of service spheres mounted on the second device sphere is denoted as count, and can take values ​​of 0, 1, 2, 3, 4, 5, and 6. That is, a device sphere can have a minimum of 0 service spheres and a maximum of 6 service spheres, to avoid connecting too many services on the electronic device.

[0261] The first information about the service capsules may include the size, quantity, and type of the service capsules mounted on the second device sphere. The service capsule can be a rounded rectangle, and its size can be the width and height of the smallest bounding rectangle of the rounded rectangle, where the width is represented by `width` and the height by `height`. The type of service capsule includes transferred and non-transferred. A transferred service capsule represents a service transferred from other devices to the device corresponding to the second device sphere, while a non-transferred service capsule represents a service created by the device corresponding to the second device sphere but not transferred. In this embodiment, transferred service capsules can be mounted on the upper end of the device sphere, and non-transferred service capsules can be mounted on the lower end of the device sphere. The quantity of service capsules can be 0, 1, or 2, meaning that 0, 1, or 2 service capsules can be mounted on the second device sphere. When 2 service capsules are mounted on the second device sphere, the two service capsules are of different types: one is a transferred service capsule mounted on the upper end of the second device sphere, and the other is a non-transferred service capsule mounted on the lower end of the second device sphere.

[0262] Step S1002: Based on the first information of the equipment ball and the first information of the service ball, determine the target position of the equipment ball, the initial angle and avoidance angle of each service ball mounted on the second equipment ball.

[0263] In some embodiments, the target position of the device ball can be determined based on the size of the second device ball and its current rotation angle, which are included in the first information of the device ball. First, the current center coordinates of the second device ball are determined based on its size and current rotation angle; then, the target position of the device ball is determined based on its current center coordinates and its size.

[0264] It is understood that the target position of the device sphere in this embodiment can be the current coordinates of the target point of the second device sphere in the above embodiment. The method for determining the target position of the device sphere will not be described in detail here; please refer to steps S507 to S509 above.

[0265] In some embodiments, the initial angle of each service ball mounted on the second device ball can be determined based on the number of service balls mounted on the second device ball included in the first information of the service balls.

[0266] It is understood that the method for determining the initial angle of each service ball in this application embodiment will not be described in detail, but can be referred to the aforementioned step S504.

[0267] In some embodiments, the avoidance angle of each service ball mounted on the second device ball can be determined based on the current rotation angle and the number of service balls mounted on the second device ball. First, the maximum avoidance angle is determined based on the number of service balls mounted on the second device ball; then, the avoidance angle is determined based on the current rotation angle, the maximum avoidance angle, and a preset rule.

[0268] It is understood that the method for determining the avoidance angle of each service ball in this application embodiment will not be described in detail. For details, please refer to the aforementioned step S505.

[0269] Step S1003: Determine the target position of each service ball based on its initial angle and avoidance angle.

[0270] In some embodiments, the target position of each service ball can be determined according to the following steps: determining the current angle of each service ball based on the initial angle and avoidance angle of each service ball; determining the current center coordinates of each service ball based on the size of the second device ball, the current center coordinates of the second device ball, the current angle of each service ball, and the size of the service ball included in the first information of the service ball; and determining the target position of each service ball based on the current center coordinates of each service ball and the size of the service ball.

[0271] It is understood that the method for determining the target position of the service ball in this embodiment will not be described in detail. For details, please refer to the aforementioned steps S506 to S510.

[0272] Step S1004: Determine the target location of the service capsule mounted on the second device sphere based on the first information of the device sphere and the first information of the service capsule.

[0273] It is understood that the method for determining the target location of the service capsule in this application embodiment will not be described in detail. For details, please refer to the aforementioned step S511.

[0274] Step S1005: Move the second equipment ball, the service balls and service capsules mounted on the second equipment ball according to the target position of the equipment ball, the target position of each service ball and the target position of the service capsule.

[0275] In this embodiment of the application, after determining the current coordinates of the target point of the second device ball, the current coordinates of the target points of each service ball, and the current coordinates of the target point of the service capsule, the layout function layout(x,y) can be called to move the second device ball, each service ball, and the service capsule to the target position.

[0276] The device interconnection and interaction method provided in this application embodiment obtains the position of the device ball, the initial angle and avoidance angle of each service ball attached to the device ball when the user drags the device ball. Based on the position of the device ball, the initial angle and avoidance angle of each service ball, it determines when each service ball needs to avoid an obstacle and performs avoidance accordingly. During the rotation of the device ball, the service balls and service capsules attached to the device ball rotate smoothly and continuously with it. Moreover, it can reduce the occurrence of service balls exceeding the boundaries of the electronic device and ensure that the service balls move within the interface as much as possible, making it convenient for users to use the service balls on the electronic device and improving the user experience.

[0277] Based on the above embodiments, this application further provides a device interconnection and interaction method applied to electronic devices, such as... Figure 11 As shown, the device interconnection and interaction method includes the following steps:

[0278] Step S1101: In response to the received second operation for dragging the first service ball in the interface, determine the position information of the third device ball attached to the first service ball and the fourth device ball in the interface.

[0279] Step S1102: Control the first service ball to move to the position indicated by the second operation.

[0280] Step S1103: Obtain the current position information of the first service ball at the current moment.

[0281] Step S1104: Based on the current location information of the first service ball and the location information of the fourth device ball, determine the conditions for service interconnection, and then mount the first service ball from the third device ball to the fourth device ball.

[0282] Based on the above embodiments, this application further provides a device interconnection and interaction method applied to electronic devices, such as... Figure 12 As shown, the device interconnection and interaction method includes the following steps:

[0283] Step S1201: In response to the received second operation for dragging the first service ball in the interface, determine the position information of the third device ball attached to the first service ball and the fourth device ball in the interface.

[0284] Step S1202: Obtain the initial position information of the first service ball before it moves to the position indicated by the second operation.

[0285] Step S1203: Control the first service ball to move to the position indicated by the second operation.

[0286] Step S1204: Obtain the current position information of the first service ball at the current moment.

[0287] Step S1205: Based on the current position information of the first service ball and the position information of the fourth device ball, if it is determined that the first service ball has collided with the fourth device ball and the user has stopped inputting the second operation, the number of service balls mounted on the fourth device ball is obtained.

[0288] Step S1206: If the number of service balls mounted on the fourth device ball is less than the preset mounting limit, it is determined that the service interconnection condition is met, the service corresponding to the first service ball is shared to the electronic device corresponding to the third device ball, and the first service ball is mounted from the third device ball to the fourth device ball.

[0289] In step S1207, if the first service ball does not collide with the fourth device ball, or the user stops inputting the second operation, or the number of service balls mounted on the fourth device ball is equal to the preset mounting limit, the first service ball is moved according to the initial position information.

[0290] It is understood that the interaction method of dragging the service ball will not be described in detail in this embodiment of the application. For details, please refer to the aforementioned steps S514 to S522.

[0291] The device interconnection and interaction method provided in this application embodiment controls the service ball to move based on the position indicated by a second operation instruction when the user drags it, so that the service ball moves synchronously with the user's operation. During the movement, if it collides with other device balls, it is attached to the collided device ball if service interconnection is satisfied, thus realizing cross-device service sharing among multiple devices. If the user does not collide with other device balls during the movement of the service ball, or if the collided device balls cannot connect to more service balls, the service ball is restored to its initial position to ensure that the already flowing service is not interrupted.

[0292] It is understood that, in order to achieve the aforementioned functions, the electronic device includes corresponding hardware structures and / or software modules for performing each function. Those skilled in the art should readily recognize that, based on the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein, the embodiments of the present invention can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed in a hardware-driven or software-driven manner depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of the embodiments of this application.

[0293] This application embodiment can divide the above-described electronic device into functional modules based on the method example described above. For example, each function can be divided into its own functional modules, or two or more functions can be integrated into one processing module. The integrated modules can be implemented in hardware or as software functional modules. It should be noted that the module division in this embodiment is illustrative and only represents one logical functional division; in actual implementation, there may be other division methods.

[0294] When dividing each function into modules according to its corresponding function, refer to Figure 13 As shown in the figure, this application embodiment also provides a device interconnection and interaction device applied in an electronic device. The device interconnection and interaction device 1300 may include: an acquisition module 1301, a first determination module 1302, a second determination module 1303, a third determination module 1304, and a movement module 1305.

[0295] The acquisition module 1301 can be used to respond to the received first operation for dragging the first device ball in the interface, and acquire the first device ball information of the second device ball in the interface at the current time, the first service ball information and the first service capsule information corresponding to the second device ball;

[0296] The first determining module 1302 can be used to determine the target position of the equipment ball, the initial angle and avoidance angle of each service ball mounted on the second equipment ball, based on the first information of the equipment ball and the first information of the service ball.

[0297] The second determining module 1303 can be used to determine the target position of each service ball based on the initial angle and avoidance angle of each service ball;

[0298] The third determining module 1304 can be used to determine the target location of the service capsule mounted on the second equipment sphere based on the first information of the equipment sphere and the first information of the service capsule.

[0299] The moving module 1305 can be used to move the second equipment ball, the service balls and service capsules mounted on the second equipment ball according to the target position of the equipment ball, the target position of each service ball and the target position of the service capsule.

[0300] In some embodiments, the first determining module 1302 may be specifically used for:

[0301] The target position of the equipment ball is determined based on the size of the second equipment ball and its current rotation angle, which are included in the first information of the equipment ball.

[0302] Based on the number of service balls mounted on the second equipment ball included in the first information of the service ball, determine the initial angle of each service ball;

[0303] The avoidance angle is determined based on the current rotation angle and the number of service balls mounted on the second device ball. In some embodiments, the first determining module 1302 may also be specifically used for:

[0304] Determine the current center coordinates of the second device sphere based on its size and current rotation angle.

[0305] Determine the target position of the second device sphere based on its current center coordinates and dimensions.

[0306] In some embodiments, the first determining module 1302 may also be specifically used for:

[0307] The maximum avoidance angle is determined based on the number of service balls mounted on the second equipment ball;

[0308] Determine the avoidance angle based on the current rotation angle, the maximum avoidance angle, and the preset rules.

[0309] In some embodiments, the second determining module 1303 may be specifically used for:

[0310] Determine the current angle of each service ball based on its initial angle and avoidance angle;

[0311] Based on the size of the second device sphere, the current center coordinates of the second device sphere, the current angle of each service sphere, and the size of the service sphere included in the first information of the service sphere, determine the current center coordinates of each service sphere.

[0312] The target position of each service sphere is determined based on its current center coordinates and size.

[0313] In some embodiments, the device interconnection and interaction device 1300 may include: a fourth determining module, a control module, and a fifth determining module;

[0314] The fourth determining module can be used to determine the position information of the third device ball attached to the first service ball and the fourth device ball in the interface in response to the received second operation for dragging the first service ball in the interface.

[0315] The control module can be used to control the first service ball to move in accordance with the position indicated by the second operation.

[0316] The acquisition module 1301 can also be used to acquire the current position information of the first service ball at the current moment;

[0317] The fifth determining module can be used to determine, based on the current location information of the first service ball and the location information of the fourth device ball, the conditions for service interconnection are met, and then mount the first service ball from the third device ball to the fourth device ball.

[0318] In some embodiments, the fifth determining module may be specifically used for:

[0319] Based on the current position information of the first service ball and the position information of the fourth device ball, if it is determined that the first service ball collides with the fourth device ball and the user stops inputting the second operation, the number of service balls attached to the fourth device ball is obtained.

[0320] If the number of service balls mounted on the fourth device ball is less than the preset mounting limit, it is determined that the conditions for service interconnection are met. The service corresponding to the first service ball is shared to the electronic device corresponding to the third device ball, and the first service ball is mounted from the third device ball to the fourth device ball.

[0321] In some embodiments, the acquisition module 1301 can also be used to acquire the initial position information of the first service ball before it moves to the position indicated by the second operation.

[0322] The moving module 1305 can also be used to move the first service ball according to the initial position information when the first service ball does not collide with the fourth device ball, or the user stops inputting the second operation, or the number of service balls mounted on the fourth device ball is equal to the preset mounting limit value.

[0323] Regarding the device interconnection and interaction apparatus in the above embodiments, the specific methods by which each module performs its operations have been described in detail in the embodiments of the device interconnection and interaction method described above, and will not be elaborated here. The related beneficial effects can also be referred to the related beneficial effects of the aforementioned device interconnection and interaction method, and will not be repeated here.

[0324] This application also provides an electronic device, which includes: a display screen, a memory, and one or more processors; the display screen, the memory, and the processors are coupled; wherein, the memory stores computer program code, which includes computer instructions, and when the computer instructions are executed by the processor, the electronic device performs the device interconnection and interaction method provided in the foregoing embodiments. The specific structure of this electronic device can be referred to... Figure 4 The structure of the electronic device shown is illustrated.

[0325] This application also provides a computer-readable storage medium including computer instructions that, when executed on an electronic device, cause the electronic device to perform the device interconnection and interaction method provided in the foregoing embodiments.

[0326] This application also provides a computer program product containing executable instructions that, when run on an electronic device, cause the electronic device to perform the device interconnection and interaction method provided in the foregoing embodiments.

[0327] Through the above description of the embodiments, those skilled in the art can clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0328] In the several embodiments provided in this application, it should be understood that the disclosed apparatus / device and method can be implemented in other ways. For example, the apparatus / device embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another device, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0329] The units described as separate components may or may not be physically separate. A component shown as a unit can be one or more physical units; that is, it can be located in one place or distributed in multiple different locations. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0330] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0331] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, essentially or in other words, the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0332] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A device interconnection and interaction method, applied to electronic devices, characterized in that, The method includes: The interface displays at least one device ball control, wherein each device ball control supports mounting a corresponding service ball control, and / or a service capsule control; In response to a first drag operation on a first target device ball control in at least one device ball control, the system acquires device ball first information, service ball first information, and service capsule first information for each device ball control at the current time. The device ball first information includes the size and current rotation angle of the device ball control. The service ball first information includes the size and number of service ball controls attached to the device ball control. The service capsule first information includes the size, number, and type of service capsule controls attached to the device ball control. Based on the first information of the device ball and the first information of the service ball, determine the target position of each device ball control, the initial angle and avoidance angle corresponding to the service ball control attached to each device ball control; The target position of each service ball control is determined based on the initial angle and the avoidance angle corresponding to each service ball control; Based on the first information of the service ball and the first information of the service capsule, determine the target position of the service capsule control attached to each of the device ball controls; Based on the target position of the device ball control, the target position of the service ball control, and the target position of the service capsule control, each device ball control, and the service ball control and / or service capsule control attached to each device ball control are moved.

2. The method according to claim 1, characterized in that, The step of determining the target position of each device ball control, the initial angle and avoidance angle corresponding to the service ball control attached to each device ball control, based on the first information of the device ball and the first information of the service ball, includes: Based on the size and current rotation angle of the device ball control included in the first information of the device ball, determine the target position of each device ball control; Based on the number of service ball controls attached to the device ball control, as included in the first information of the service ball, determine the initial angle of each service ball control; The avoidance angle is determined based on the current rotation angle and the number of service ball controls mounted on the device ball control.

3. The method according to claim 2, characterized in that, The step of determining the target position of each device ball control based on the size and current rotation angle of the device ball control, including the first information of the device ball, includes: Based on the size of the device ball control and the current rotation angle, determine the current center coordinates of the device ball control; The target position of each device ball control is determined based on the current center coordinates of the device ball control and the size of the device ball control.

4. The method according to claim 2, characterized in that, Determining the avoidance angle based on the current rotation angle and the number of service ball controls mounted on the device ball control includes: The maximum avoidance angle is determined based on the number of service ball controls attached to the device ball control. The avoidance angle is determined based on the current rotation angle, the maximum avoidance angle, and the preset rules.

5. The method according to claim 3, characterized in that, The step of determining the target position of each service ball control based on the initial angle and the avoidance angle corresponding to each service ball control includes: The current angle of each service ball control is determined based on the initial angle and the avoidance angle of each service ball control; Based on the size of the device ball control, the current center coordinates of the device ball control, the current angle of each service ball control, and the size of the service ball control included in the first information of the service ball, determine the current center coordinates of each service ball control. The target position of each service ball control is determined based on the current center coordinates of each service ball control and the size of each service ball control.

6. The method according to claim 1, characterized in that, The method further includes: In response to a second drag operation on a target service ball control in the service ball control, the position information of a second target device ball control attached to the target service ball control and the position information of a third target device ball control are obtained, wherein the third target device ball control is any device ball control other than the second target device ball control among the at least one device ball controls; The target service ball control is controlled to move to the position indicated by the second drag operation; Obtain the current position information of the target service ball control at the current moment; Based on the current location information of the target service ball control and the location information of the third target device ball control, and after determining that the service interconnection condition is met, the target service ball control is mounted from the second target device ball control to the third target device ball control.

7. The method according to claim 6, characterized in that, The step of determining, based on the current location information of the target service ball control and the location information of the third target device ball control, that under the condition of satisfying service interconnection, the target service ball control is mounted from the second target device ball control to the third target device ball control includes: Based on the current position information of the target service ball control and the position information of the third target device ball control, if it is determined that the target service ball control collides with the third target device ball control and the user stops the second drag operation, the number of service ball controls attached to the third target device ball control is obtained. If the number of service ball controls mounted on the third target device ball control is less than a preset mounting limit, it is determined that the service interconnection condition is met. The service corresponding to the target service ball control is shared to the electronic device corresponding to the second target device ball control, and the target service ball control is mounted from the second target device ball control to the third target device ball control.

8. The method according to claim 7, characterized in that, The method further includes: Obtain the initial position information of the target service ball control before it moves to the position indicated by the second drag operation; If the target service ball control does not collide with the third target device ball control, or the user stops the second drag operation, or the number of service ball controls attached to the third target device ball control is equal to the preset attachment limit value, the target service ball control is moved according to the initial position information.

9. An electronic device, characterized in that, include: A display screen, a memory, and one or more processors; the display screen, the memory, and the processors are coupled; wherein the memory stores computer program code, the computer program code including computer instructions, which, when executed by the processor, cause the electronic device to perform the device interconnection and interaction method as described in any one of claims 1-8.

10. A computer-readable storage medium, characterized in that, It includes computer instructions that, when executed on an electronic device, cause the electronic device to perform the device interconnection and interaction method as described in any one of claims 1-8.

Citation Information

Patent Citations

  • Application navigation method of user interaction interfaces and intelligent equipment

    CN105278819A

  • Window position adjusting method and device, and electronic equipment

    CN111638818A