Patent Description:
In a mobile communications system, there may be the following two connection modes between a terminal and a network device (for example, a base station).

Connection mode <NUM>: The terminal is directly connected to the network device for data communication. Such a mode may be referred to as a direct communication mode. In this communication mode, a communication link between the terminal and the network device may be referred to as a direct link.

Connection mode <NUM>: The terminal is connected to the network device by using another terminal, for data communication. Such a mode may be referred to as an indirect communication mode. In this case, the terminal may be referred to as, for example, a remote terminal (remote user equipment, remote UE), and the another terminal may be referred to as, for example, a relay terminal (relay user equipment, relay UE). In this communication mode, a communication link between the terminal and the network device may be referred to as an indirect link.

As shown in <FIG>, the remote terminal may switch between the foregoing two connection modes or communication links. For example, as shown in <FIG>, when quality of a link between UE and a base station is relatively poor, the UE may select nearby relay UE to connect to the base station. In this case, switching from the direct communication mode to the indirect communication mode is required. For another example, as shown in <FIG>, when relay UE connected to remote UE moves, a connection between the remote UE and the relay UE may no longer be maintained. In this case, switching from the indirect communication mode to the direct communication mode is required.

For switching from an indirect connection path to a direct connection path, a basic path switching procedure currently discussed in the 3GPP is as follows:.

However, the currently discussed path switching method is applicable to limited scenarios, and this is unconducive to expansion to more relay application scenarios.

<CIT> describes layer <NUM> relaying and mobility using a sidelink interface. A remote user equipment (UE) for use in a wireless communication network comprises: a device to network (D2N) entity, a device to device (D2D) entity, and control logic to: receive a service data unit derived from an IP packet direct the service data unit to the D2N entity for communication with an eNB using a Uu interface in a first mode of operation, and direct the service data unit to the D2D entity for communication with the eNB via a first relay UE using a sidelink interface in a second, relay, mode of operation. <CIT> describes an information processing method, which is applied in a first device-to-device UE. The method comprises receiving bearer control information sent by a first base station; according to the bearer control information, changing to a second access node to perform communication data transmission.

Embodiments of the present invention provide a path switching method, and a related computer-readable storage medium storing program code for implementing it and a terminal implementing the method, so that a relay terminal can trigger link switching of a remote device, to adapt to a relay scenario more flexibly.

The described embodiments are not to be regarded as defining the invention unless they fall within the scope of the appended claims. Embodiments not falling within the terms of the claims are to be understood as background art or examples useful for understanding the invention.

Terms used in the implementation part of the present invention are merely intended to explain specific embodiments of the present invention, but are not intended to limit the present invention.

<FIG> shows a wireless communications system according to this application. The wireless communications system may be a long term evolution (Long Term Evolution, LTE) system, a future evolved 5th generation (the 5th Generation, <NUM>) mobile communications system, a future evolved new radio (NR) system, a machine-to-machine (Machine to Machine, M2M) communications system, or the like. As shown in <FIG>, the wireless communications system <NUM> may include a network device <NUM>, a remote terminal <NUM>, and a relay device <NUM>. One relay device <NUM> may be connected to one or more remote terminals <NUM>.

The network device <NUM> may be a base station. The base station may be configured to communicate with one or more terminals, or may be configured to communicate with one or more base stations that have some terminal functions (for example, communication between a macro base station and a micro base station such as an access point). The base station may be a base transceiver station (Base Transceiver Station, BTS) in a time division synchronous code division multiple access (Time Division Synchronous Code Division Multiple Access, TD-SCDMA) system, an evolutional NodeB (Evolutional NodeB, eNB) in an LTE system, or a base station gNB in a <NUM> system or in a new radio (NR) system. Alternatively, the base station may be an access point (Access Point, AP), a transmission node (Trans TRP), a central unit (Central Unit, CU), or another network entity, and may include some or all functions of the foregoing network entities.

The remote terminal <NUM> may be distributed across the entire wireless communications system <NUM>, and may be static or mobile. In some embodiments of this application, the remote terminal <NUM> may be an intelligent wearable device, a mobile device, a mobile station (mobile station), a mobile unit (mobile unit), an M2M terminal, a radio unit, a remote unit, a user agent, a mobile client, or the like.

The relay device <NUM> (also referred to as relay node) may include two physical layer entities. One entity is configured to communicate with a subordinate user of the relay device <NUM> (that is, the remote terminal <NUM> that is connected to the relay device <NUM>). The other entity has a user function (that is, a terminal function), and is configured to communicate with the network device <NUM>. In a specific implementation, the relay device <NUM> may be a relay terminal. The relay device <NUM> may alternatively be a communications entity such as a relay transmission/reception point (TRP), customer premise equipment (Customer Premise Equipment, CPE), a relay transceiver, or a relay agent.

In the wireless communications system <NUM>, a sidelink (sidelink) is a short-distance link between the relay device <NUM> and the remote terminal <NUM>, and includes an uplink (Uplink, UL) sidelink or a downlink (Downlink, DL) sidelink. A backhaul link (backhaul link) is a radio link between the network device <NUM> and the relay device <NUM>, and includes an uplink (Uplink, UL) backhaul link or a downlink (Downlink, DL) backhaul link. In addition to a sidelink technology, a link between the relay device <NUM> and the remote terminal <NUM> may alternatively be a short-distance link in another form, for example, any one of links such as a WLAN link or a Bluetooth link.

In the wireless communications system <NUM>, the relay device <NUM> between the network device <NUM> and the remote terminal <NUM> may be configured to forward a radio signal between the network device <NUM> and the remote terminal <NUM>. Specifically, during downlink transmission, the relay device <NUM> is responsible for forwarding a radio signal transmitted by the network device <NUM>, to finally transmit the radio signal to the remote terminal <NUM>. During uplink transmission, the relay device <NUM> is responsible for forwarding a radio signal transmitted by the remote terminal <NUM>, to finally transmit the radio signal to the network device <NUM>.

In some possible scenarios, the relay device <NUM> needs to actively trigger the remote terminal <NUM> to perform path switching, that is, switch the remote terminal <NUM> from an indirect connection path for communicating with the network device <NUM> by using the relay device <NUM> to a direct connection path for communicating with the network device <NUM>. For example, when the relay device <NUM> needs to initiate a call in a circuit switched (Circuit Switch, CS) domain, the relay device <NUM> needs to perform a circuit switched fallback (Circuit Switch Fallback, CSFB) to access a <NUM> or <NUM> network. After accessing the <NUM> or <NUM> network, the relay device <NUM> becomes unable to continue to provide a relay service for the remote terminal <NUM>. For another example, when the relay device <NUM> has insufficient power supply, the relay device <NUM> may, again, become unable to provide a relay service for the remote terminal <NUM>. Not limited to the scenarios described in the examples, in other scenarios, the relay device <NUM> also needs to actively trigger the remote terminal <NUM> to perform the path switching.

It should be noted that the wireless communications system <NUM> shown in <FIG> is merely intended to more clearly describe technical solutions in this application, but is not intended to limit this application. A person of ordinary skill in the art may know that as a network architecture evolves and a new service scenario emerges, the technical solutions provided in this application are further applicable to a similar technical problem.

<FIG> shows a terminal <NUM> according to some embodiments of this application. The terminal <NUM> may be implemented as a remote terminal (for example, the remote terminal <NUM> in <FIG>) in this application, or a relay device (for example, the relay device <NUM> in <FIG>) in this application. As shown in <FIG>, the terminal <NUM> may include: one or more terminal processors <NUM>, a memory <NUM>, a communications interface <NUM>, a receiver <NUM>, a transmitter <NUM>, a coupler <NUM>, an antenna <NUM>, a user interface <NUM>, and an input/output module (including an audio input/output module <NUM>, a key input module <NUM>, a display <NUM>, and the like). These components may be connected by using a bus <NUM> or in another manner. In <FIG>, for example, the components are connected by using the bus.

The communications interface <NUM> may be configured for communication between the terminal <NUM> and another communications device, for example, another terminal or a network device. Specifically, the communications interface <NUM> may be a long term evolution (LTE) (<NUM>) communications interface, or a <NUM> or future new radio communications interface. Not limited to a wireless communications interface, the terminal <NUM> may be further provided with a wired communications interface <NUM>, for example, a local access network (Local Access Network, LAN) interface.

The transmitter <NUM> may be configured to perform transmission processing, for example, signal modulation, on a signal output by the terminal processor <NUM>. The receiver <NUM> may be configured to perform reception processing, for example, signal demodulation, on a mobile communication signal received by the antenna <NUM>. In some embodiments of this application, the transmitter <NUM> and the receiver <NUM> may be considered as a wireless modem. The terminal <NUM> may have one or more transmitters <NUM> and one or more receivers <NUM>. The antenna <NUM> may be configured to convert electromagnetic energy in a transmission line into an electromagnetic wave in free space, or convert an electromagnetic wave in free space into electromagnetic energy in a transmission line. The coupler <NUM> is configured to divide the mobile communication signal received by the antenna <NUM> into a plurality of signals and distribute the plurality of signals to a plurality of receivers <NUM>.

When the terminal <NUM> is implemented as a relay device, the terminal <NUM> may be provided with two transceiver apparatuses. One transceiver apparatus is configured to allow a remote terminal (for example, the remote terminal <NUM> in <FIG>) to be connected to a link of the terminal <NUM>, and the other transceiver apparatus is configured to allow the terminal <NUM> to be connected to a link of a network device (for example, the network device <NUM> in <FIG>). Specifically, the two transceiver apparatuses may have a same transmit/receive characteristic or different transmit/receive characteristics. For example, antenna ports respectively corresponding to the two transceiver apparatuses have or do not have a quasi co-location (Quasi Co-location, QCL) characteristic.

In addition to the transmitter <NUM> and the receiver <NUM> shown in <FIG>, the terminal <NUM> may further include another communications component, for example, a GPS module, a Bluetooth (Bluetooth) module, a wireless fidelity (Wireless Fidelity, Wi-Fi) module, and the like. Not limited to the foregoing described wireless communication signal, the terminal <NUM> may further support another wireless communication signal, for example, a satellite signal and a short-wave signal. Not limited to wireless communication, the terminal <NUM> may be further provided with a wired network interface (for example, a LAN interface) to support wired communication.

The input/output module may be configured to implement interaction between the terminal <NUM> and a user or an external environment. The input/output module may mainly include: the audio input/output module <NUM>, the key input module <NUM>, the display <NUM>, and the like. Specifically, the input/output module may further include: a camera, a touchscreen, a sensor, and the like. Each input/output module communicates with the terminal processor <NUM> through the user interface <NUM>.

The memory <NUM> is coupled to the terminal processor <NUM>, and is configured to store various software programs and/or a plurality of sets of instructions. Specifically, the memory <NUM> may include a high-speed random access memory, and may further include a non-volatile memory, for example, one or more disk storage devices, a flash device, or another non-volatile solid-state storage device. The memory <NUM> may store an operating system (referred to as a system hereinafter), for example, an embedded operating system such as ANDROID, iOS, WINDOWS, or LINUX. The memory <NUM> may further store a network communications program. The network communications program may be used for communicating with one or more additional devices, one or more terminal devices, or one or more network devices. The memory <NUM> may further store a user interface program. The user interface program may vividly display content of an application program by using a graphical user interface, and receive, by using an input control such as a menu, a dialog box, and a key, a control operation performed by a user on the application program.

In some embodiments of this application, the memory <NUM> may be configured to store a program for implementing, on a terminal <NUM> side, the path switching method according to one or more embodiments of this application. For implementation of the path switching method according to the one or more embodiments of this application, refer to subsequent embodiments.

The terminal processor <NUM> may be configured to read and execute a computer-readable instruction. Specifically, the terminal processor <NUM> may be configured to: invoke a program stored in the memory <NUM>, for example, the program for implementing, on the terminal <NUM> side, the resource allocation method according to the one or more embodiments of this application; and execute an instruction included in the program.

It can be understood that the terminal <NUM> may be the terminal <NUM> in the wireless communications system <NUM> shown in <FIG>, and may be implemented as a mobile device, a mobile station (mobile station), a mobile unit (mobile unit), a radio unit, a remote unit, a user agent, a mobile client, or the like.

It should be noted that the terminal <NUM> shown in <FIG> is merely an implementation of the embodiments of this application. In actual application, the terminal <NUM> may include more or fewer components, and this is not limited herein.

<FIG> shows a network device <NUM> according to some embodiments of this application. As shown in <FIG>, the network device <NUM> may include: one or more network device processors <NUM>, a memory <NUM>, a communications interface <NUM>, a transmitter <NUM>, a receiver <NUM>, a coupler <NUM>, and an antenna <NUM>. These components may be connected by using a bus <NUM> or in another manner. In <FIG>, for example, the components are connected by using the bus.

The communications interface <NUM> may be configured for communication between the network device <NUM> and another communications device, for example, a terminal device or another network device. Specifically, the communications interface <NUM> may be a long term evolution (LTE) (<NUM>) communications interface, or a <NUM> or future new radio communications interface. Not limited to a wireless communications interface, the network device <NUM> may be further provided with a wired communications interface <NUM> to support wired communication. For example, a backhaul connection between the network device <NUM> and another network device <NUM> may be a wired communication connection.

The transmitter <NUM> may be configured to perform transmission processing, for example, signal modulation, on a signal output by the network device processor <NUM>. The receiver <NUM> may be configured to perform reception processing, for example, signal demodulation, on a mobile communication signal received by the antenna <NUM>. In some embodiments of this application, the transmitter <NUM> and the receiver <NUM> may be considered as a wireless modem. The network device <NUM> may have one or more transmitters <NUM> and one or more receivers <NUM>. The antenna <NUM> may be configured to convert electromagnetic energy in a transmission line into an electromagnetic wave in free space, or convert an electromagnetic wave in free space into electromagnetic energy in a transmission line. The coupler <NUM> may be configured to divide the mobile communication signal into a plurality of signals and distribute the plurality of signals to a plurality of receivers <NUM>.

The memory <NUM> is coupled to the network device processor <NUM>, and is configured to store various software programs and/or a plurality of sets of instructions. Specifically, the memory <NUM> may include a high-speed random access memory, and may further include a non-volatile memory, for example, one or more disk storage devices, a flash device, or another non-volatile solid-state storage device. The memory <NUM> may store an operating system (referred to as a system hereinafter), for example, an embedded operating system such as uCOS, VxWorks, or RTLinux. The memory <NUM> may further store a network communications program. The network communications program may be used for communicating with one or more additional devices, one or more terminal devices, or one or more network devices.

The network device processor <NUM> may be configured to, for example, manage a radio channel, establish and disconnect a call and a communication link, and provide cell handover control for a user within a local control area. Specifically, the network device processor <NUM> may include: an administration module/communication module (Administration Module/Communication Module, AM/CM) (a center for speech channel switching and information exchange), a basic module (Basic Module, BM) (configured to implement call processing, signaling processing, radio resource management, radio link management, and circuit maintenance functions), a transcoder and sub-multiplexer (Transcoder and SubMultiplexer, TCSM) (configured to implement multiplexing/demultiplexing and transcoding functions), and the like.

In the embodiments of this application, the network device processor <NUM> may be configured to read and execute a computer-readable instruction. Specifically, the network device processor <NUM> may be configured to: invoke a program stored in the memory <NUM>, for example, a program for implementing, on the network device <NUM> side, the path switching method according to one or more embodiments of this application; and execute an instruction included in the program.

It can be understood that the network device <NUM> may be a base station <NUM> in the wireless communications system <NUM> shown in <FIG>, and may be implemented as a base transceiver station, a wireless transceiver, a basic service set (BSS), an extended service set (ESS), a NodeB, an eNodeB, an access point, a TRP, or the like.

It should be noted that the network device <NUM> shown in <FIG> is merely an implementation of the embodiments of this application. In actual application, the network device <NUM> may include more or fewer components, and this is not limited herein.

Based on the wireless communications system <NUM>, the terminal <NUM>, and the network device <NUM> described in the foregoing embodiments, this application provides a path switching method.

A main inventive principle in this application may include the following. In relay communication, when a relay device becomes unable to provide a relay service for a remote terminal, the relay device may trigger switching of the remote terminal from an indirect connection path for communicating with a network device by using the relay device to a direct connection path for directly communicating with the network device, and release a short-distance link between the relay terminal and the remote terminal. In this way, the relay device can quickly trigger path switching of the remote terminal based on a status of the relay device in a timely manner, and even can implement the path switching without interrupting data communication over a sidelink, thereby ensuring that data communication between the remote terminal and the network device is not interrupted.

That the relay device becomes unable to provide a relay service for a remote terminal may include but is not limited to a scenario described in the following examples. For example, when the relay device <NUM> needs to initiate a call in a circuit switched (Circuit Switch, CS) domain, the relay device <NUM> needs to perform a circuit switched fallback (CSFB) to access a <NUM> or <NUM> network. After accessing the <NUM> or <NUM> network, the relay device <NUM> becomes unable to continue to provide the relay service for the remote terminal <NUM>. For another example, when the relay device <NUM> has insufficient power supply, the relay device <NUM> may, again, become unable to provide the relay service for the remote terminal <NUM>.

This application mainly provides the following two solutions about how a relay device (referred to as Relay hereinafter) triggers path switching of a remote terminal (referred to as Remote hereinafter).

Solution <NUM>: The Relay requests a network device to trigger the Remote to perform the path switching, and the network device configures for the path switching.

Solution <NUM>: The Relay directly instructs the Remote to perform the path switching.

In Solution <NUM>, the Relay may release a short-distance link after the Remote switches to a direct connection path, so that service continuity can be ensured when the Remote switches from an indirect connection path to the direct connection path. In Solution <NUM>, the Relay directly instructs the Remote to perform the path switching, so that a time required by the Relay to release a short-distance link can be reduced. The foregoing two solutions are subsequently described by using embodiments, and details are not described herein.

In this application, the Relay may be referred to as a first terminal, and the Remote may be referred to as a second terminal. Not limited to a relay terminal, in this application, the Relay may alternatively be a relay micro base station, a relay transceiver, or the like.

First, Solution <NUM> provided in this application is described in detail with reference to embodiments in <FIG>.

<FIG> is a schematic flowchart of a path switching method according to this application. Details are provided in the following.

S100: An upper layer of a relay terminal triggers release of a short-distance link between the relay terminal and a remote terminal. In addition to a sidelink technology, a link between the relay device and the remote terminal may alternatively be a short-distance link in another form, for example, any one of links such as a WLAN link or a Bluetooth link.

S101: The relay terminal sends a first message to a network device, where the first message may be used to request the network device to switch the remote terminal from an indirect connection path to a direct connection path, or request to release a short-distance link connection between the relay terminal and the remote terminal.

Specifically, the requesting to release a link between the first terminal and the second terminal may include the following two manners:.

Specifically, the first message may be an RRC message. Optionally, the first message may include a reason for releasing the short-distance link by the relay terminal. For example, the relay terminal needs to perform a circuit switched fallback (CSFB), or the relay terminal has insufficient power supply. The examples are merely some embodiments provided in this application, and in actual application, another reason for releasing the short-distance link by the relay terminal may alternatively be included. This is not limited herein.

S102: The network device sends a second message to the remote terminal that is connected to the relay terminal, where the second message may be used to configure the remote terminal to switch from the indirect connection path to the direct connection path.

Specifically, the second message may be an RRC connection reconfiguration (RRC connection reconfiguration) message. The second message includes at least one of the following: a cell identity, random access configuration information, first instruction information, or a first time value.

The cell identity may be an identity of a cell accessed by the remote terminal after the remote terminal switches to the direct connection path. The cell identity may be a physical cell identity (physical Cell Identity, PCI) of the cell, a cell identity (cell identity) that can uniquely identify the cell in a public land mobile network (public land mobile network, PLMN), or a cell global identity (cell global identity, CGI) of the cell.

The random access (Random Access, RA) configuration information may be resource configuration information for the remote terminal to initiate random access to the cell, and may include a random access preamble configuration and a physical random access channel configuration.

The first instruction information may be used to instruct the remote terminal whether to perform, before disconnecting from the relay terminal, downlink synchronization with the cell corresponding to the cell identity.

The first time value is a longest time allowed for the remote terminal to access the cell corresponding to the cell identity. If the time is exceeded, it may be considered that the remote terminal fails to access the cell.

S103: After receiving the second message, the remote terminal may switch from the indirect connection path to the direct connection path. In addition, the remote terminal may alternatively start a first timer, where a time length of the first timer is equal to the first time value in the second message, and is used to limit the longest time allowed for the remote terminal to access the cell corresponding to the cell identity. If the remote terminal has not accessed the cell when the first timer expires, it may be considered that cell access fails. In this case, the remote terminal needs to trigger a radio resource control connection reestablishment process.

In this embodiment, the remote terminal may switch from the indirect connection path to the direct connection path in the following three manners:.

Manner <NUM>: Regardless of whether the second message includes the first instruction information, when performing the downlink synchronization with the cell corresponding to the cell identity, the remote terminal may continue to maintain a connection to the relay terminal, that is, continue to use the relay terminal to perform data communication with the network device. After completing the downlink synchronization with the cell corresponding to the cell identity, the remote terminal may disconnect from the relay terminal, terminate the data communication with the network device by using the relay terminal, and switch to the direct connection path to send/receive data to/from the network device.

Manner <NUM>: Regardless of whether the second message includes the first instruction information, after receiving the second message, the remote terminal may directly disconnect from the relay terminal, and terminate data communication with the network device by using the relay terminal. Then, the remote terminal may start the downlink synchronization with the cell corresponding to the cell identity, and start a random access process.

Manner <NUM>: If the first message includes the first instruction information, and the first instruction information instructs the remote terminal to perform, before disconnecting from the relay terminal, the downlink synchronization with the cell corresponding to the cell identity, the remote terminal may perform path switching in Manner <NUM>. If the second message includes the first instruction information, but the first instruction information does not instruct the remote terminal to perform, before disconnecting from the relay terminal, the downlink synchronization with the cell corresponding to the cell identity, the remote terminal may perform the path switching in Manner <NUM>.

It can be understood that Manner <NUM> can ensure service continuity when the remote terminal switches from the indirect connection path to the direct connection path.

In a possible special case, before the remote terminal receives the second message, the relay terminal is disconnected from the link between the relay terminal and the remote terminal. In this case, when the remote terminal detects no discovery message sent by the relay terminal, the remote terminal determines that a failure occurs over the link between the remote terminal and the relay terminal, and the remote terminal triggers the radio resource control connection reestablishment process.

S104: The remote terminal may access the cell corresponding to the cell identity by using the random access process, and send an RRC connection reconfiguration complete message to the network device after the accessing succeeds.

S105: The network device may send a third message to the relay terminal, where the third message may be used to instruct the relay terminal to release the short-distance link. Specifically, the third message may be specifically implemented as follows:.

Specifically, in the following two scenarios, the network device may trigger the relay terminal to release the short-distance link, that is, send the third message to the relay terminal.

Trigger scenario <NUM>: The network device determines that each remote terminal served by the relay terminal successfully receives the second message.

Herein, determining a condition that the remote terminal successfully receives the second message may include any one of the following several manners:.

Trigger scenario <NUM>: The network device determines that the remote terminal fails to access the cell.

Herein, a judgment condition for determining that the remote terminal fails to access the cell may include the following: Within a time limited by the first time value in the second message, the network device receives no RRC connection reconfiguration complete message sent by the remote terminal.

S106: After receiving the third message sent by the network device, the relay terminal may release the short-distance link.

Herein, a specific implementation of releasing the short-distance link may include the following several aspects:.

It can be understood that, in the embodiment in <FIG>, the relay terminal requests (by using the first message) the network device to trigger the path switching of the remote terminal, and the network device configures (for example, the cell identity and the random access configuration in the second message) for the path switching of the remote terminal. In the embodiment in <FIG>, the release of the short-distance link between the relay terminal and the remote terminal is triggered by the network device (by using the third message).

<FIG> is a schematic flowchart of another path switching method according to this application. Details are provided in the following.

S200: An upper layer of a relay terminal triggers release of a short-distance link between the relay terminal and a remote terminal. In addition to a sidelink technology, a link between the relay device and the remote terminal may alternatively be a short-distance link in another form, for example, any one of links such as a WLAN link or a Bluetooth link.

S201: The relay terminal sends a first message to a network device, where the first message may be used to request the network device to switch the remote terminal from an indirect connection path to a direct connection path, or request to release a short-distance link connection between the relay terminal and the remote terminal.

S202: The network device sends a second message to the remote terminal that is connected to the relay terminal, where the second message may be used to configure the remote terminal to switch from the indirect connection path to the direct connection path.

The first instruction information may be used to instruct the remote terminal whether to perform, before disconnecting from the relay terminal, downlink synchronization with a cell corresponding to the cell identity.

S203: After receiving the second message, the remote terminal may switch from the indirect connection path to the direct connection path, and send a third message to the relay terminal. The third message may be used to instruct the relay terminal to release the short-distance link between the relay terminal and the remote terminal. After receiving the second message, the remote terminal may alternatively start a first timer, where a time length of the first timer is equal to the first time value in the second message, and is used to limit the longest time allowed for the remote terminal to access the cell corresponding to the cell identity. If the remote terminal has not accessed the cell when the first timer expires, it may be considered that cell access fails. In this case, the remote terminal triggers a radio resource control connection reestablishment process.

In this embodiment, a time sequence in which the remote terminal triggers the relay terminal to release the short-distance link (that is, the remote terminal sends the third message) and the remote terminal switches from the indirect connection path to the direct connection path includes the following three manners:.

S204: The remote terminal performs the downlink synchronization with the cell corresponding to the cell identity.

S205: After receiving the third message sent by the remote terminal, the relay terminal releases the short-distance link between the relay terminal and the remote terminal.

S206: The remote terminal performs the random access process on the cell corresponding to the cell identity, and sends an RRC connection reconfiguration complete message to the network device after completing cell access.

It can be understood that, in the embodiment in <FIG>, the relay terminal requests (by using the first message) the network device to trigger the path switching of the remote terminal, and the network device configures (for example, the cell identity and the random access configuration in the second message) for the path switching of the remote terminal. In the embodiment in <FIG>, the release of the short-distance link between the relay terminal and the remote terminal is triggered by the remote terminal (by using the third message).

<FIG> is a schematic flowchart of still another path switching method according to this application. Details are provided in the following.

S300: An upper layer of a relay terminal triggers release of a short-distance link between the relay terminal and a remote terminal. In addition to a sidelink technology, a link between the relay device and the remote terminal may alternatively be a short-distance link in another form, for example, any one of links such as a WLAN link or a Bluetooth link.

S301: The relay terminal sends a first message to a network device, where the first message may be used to request the network device to switch the remote terminal from an indirect connection path to a direct connection path, or request to release a short-distance link connection between the relay terminal and the remote terminal.

S302: The network device sends a second message to the remote terminal that is connected to the relay terminal, where the second message may be used to configure the remote terminal to switch from the indirect connection path to the direct connection path.

Specifically, the second message may be an RRC connection reconfiguration (RRC connection reconfiguration) message. The second message includes at least one of the following: a cell identity, random access configuration information, first instruction information, or a first time value. For specific definitions and explanations of content of the second message, refer to related content in the embodiment in <FIG> or <FIG>.

S303: After receiving the second message sent by the network device, the relay terminal may start a first timer, where a time length of the first timer is equal to the first time value in the second message, and is used to indicate a time of releasing the short-distance link by the relay terminal. In this way, the relay terminal may release the short-distance link when the first timer expires.

S304: The remote terminal performs downlink synchronization with a cell corresponding to the cell identity.

There is no time sequence between step <NUM> and step <NUM>.

S305: When the first timer expires, the relay terminal releases the short-distance link between the relay terminal and the remote terminal.

S306: The remote terminal performs a random access process on the cell corresponding to the cell identity, and sends an RRC connection reconfiguration complete message to the network device after completing cell access.

Specifically, S306 may occur before S305, or S306 may occur after S305. A sequence between the two steps may specifically depend on a time required by the remote terminal to perform cell synchronization and the first time value. This is not limited herein. In actual application, to ensure service continuity when the remote terminal performs the path switching, the first time value may be properly set to a relatively large value, so that the remote terminal can successfully access the cell and complete an RRC reconfiguration process before the first timer expires.

In a possible special case, before the remote terminal receives the second message, the relay terminal is disconnected from the link between the relay terminal and the remote terminal. In this case, when the remote terminal detects no discovery message sent by the relay terminal, the remote terminal determines that a failure occurs over the link between the remote terminal and the relay terminal, and the remote terminal triggers a radio resource control connection reestablishment process.

It can be understood that, in the embodiment in <FIG>, the relay terminal requests (by using the first message) the network device to trigger the path switching of the remote terminal, and the network device configures (for example, the cell identity and the random access configuration in the second message) for the path switching of the remote terminal. In the embodiment in <FIG>, the release of the short-distance link between the relay terminal and the remote terminal is triggered by the relay terminal (by using the first timer).

Then, Solution <NUM> provided in this application is described in detail with reference to embodiments in <FIG>.

S400: An upper layer of a relay terminal triggers release of a short-distance link between the relay terminal and a remote terminal. In addition to a sidelink technology, a link between the relay device and the remote terminal may alternatively be a short-distance link in another form, for example, any one of links such as a WLAN link or a Bluetooth link.

S401: The relay terminal sends a fourth message to the remote terminal, where the fourth message may be used to notify that the short-distance link is to be released by the relay terminal, to instruct the remote terminal to switch from an indirect connection path to a direct connection path.

Specifically, the fourth message may be implemented as, but is not limited to, PC5 signaling. Optionally, the fourth message may include a reason for releasing the short-distance link by the relay terminal. For example, the relay terminal needs to perform a circuit switched fallback (CSFB), or the relay terminal has insufficient power supply. The examples are merely some embodiments provided in this application, and in actual application, another reason for releasing the short-distance link by the relay terminal may alternatively be included. This is not limited herein.

S402: After receiving the fourth message, the remote terminal triggers switching from the indirect connection path to the direct connection path.

S403: The remote terminal sends a fifth message to a network device, where the fifth message may be used to request to switch from the indirect connection path to the direct connection path.

Optionally, the fifth message may include the reason for releasing the short-distance link by the relay terminal. Further, the fifth message may include link quality of the short-distance link between the remote terminal and the relay terminal.

S404: The network device sends a sixth message to the remote terminal, where the sixth message may be used to configure the remote terminal to switch from the indirect connection path to the direct connection path.

Specifically, the sixth message may be an RRC connection reconfiguration (RRC connection reconfiguration) message. The sixth message includes at least one of the following: a cell identity, random access configuration information, first instruction information, or a first time value. Herein, the sixth message is equivalent to the second message in the embodiments in <FIG>. For specific definitions and explanations of content of the sixth message, refer to related content of the second message in the embodiments in <FIG>.

S405: After receiving the sixth message, the remote terminal may switch from the indirect connection path to the direct connection path, and send a seventh message to the relay terminal. Herein, the seventh message is equivalent to the third message in the embodiment in <FIG>, and may be used to instruct the relay terminal to release the short-distance link between the relay terminal and the remote terminal. After receiving the seventh message, the remote terminal may alternatively start a first timer, where a time length of the first timer is equal to the first time value in the second message, and is used to limit a longest time allowed for the remote terminal to access a cell corresponding to the cell identity. If the remote terminal has not accessed the cell when the first timer expires, it may be considered that cell access fails. In this case, the remote terminal triggers a radio resource control connection reestablishment process.

In this embodiment, a time sequence in which the remote terminal triggers the relay terminal to release the short-distance link (that is, the remote terminal sends the seventh message) and the remote terminal switches from the indirect connection path to the direct connection path includes the following three manners:.

S406: The remote terminal performs the downlink synchronization with the cell corresponding to the cell identity.

S407: After receiving the seventh message sent by the remote terminal, the relay terminal releases the short-distance link between the relay terminal and the remote terminal.

S408: The remote terminal performs the random access process on the cell corresponding to the cell identity, and sends an RRC connection reconfiguration complete message to the network device after completing cell access.

It can be understood that, in the embodiment in <FIG>, the relay terminal instructs (by using the fourth message) the remote terminal to perform the path switching. The remote terminal requests (by using the fifth message) the network device to configure the path switching (by using the sixth message). In the embodiment in <FIG>, the release of the short-distance link between the relay terminal and the remote terminal is triggered by the remote terminal (by using the seventh message).

<FIG> is a schematic flowchart of still another path switching method according to this application. In the embodiment in <FIG>, in a cell in which a network device is located, a remote terminal side has no cell radio network temporary identifier (Cell Radio Network Temporary Identifier, C-RNTI). Details are provided in the following.

S500: An upper layer of a relay terminal triggers release of a short-distance link between the relay terminal and the remote terminal. In addition to a sidelink technology, a link between the relay device and the remote terminal may alternatively be a short-distance link in another form, for example, any one of links such as a WLAN link or a Bluetooth link.

S501: The relay terminal sends a fourth message to the remote terminal, where the fourth message may be used to notify the remote terminal that the short-distance link is to be released by the relay terminal, to instruct the remote terminal to switch from an indirect connection path to a direct connection path.

Specifically, the fourth message may be implemented as, but is not limited to, PC5 signaling. The fourth message may include: a C-RNTI of the relay terminal, a local identifier (local ID) of the remote terminal, common radio resource configuration information of a serving cell of the relay terminal, and a cell identity of the serving cell of the relay terminal. Herein, the C-RNTI of the relay terminal and the local ID of the remote terminal may be used to identify a temporary identity of the remote terminal on a network side.

Optionally, the fourth message may further include a reason for releasing the short-distance link by the relay terminal. For example, the relay terminal needs to perform a circuit switched fallback (CSFB), or the relay terminal has insufficient power supply. The examples are merely some embodiments provided in this application, and in actual application, another reason for releasing the short-distance link by the relay terminal may alternatively be included. This is not limited herein.

S502: After sending the fourth message to the remote terminal, the relay terminal may release the short-distance link between the relay terminal and the remote terminal.

S503: After receiving the fourth message, the remote terminal triggers switching from the indirect connection path to the direct connection path, performs downlink synchronization with a cell corresponding to the cell identity in the fourth message, and triggers a random access process.

After receiving the fourth message, the remote terminal may alternatively start a first timer. A time length value of the first timer may be indicated by the relay device by using the fourth message, or may be a predefined value, and is used to limit a longest time allowed for the remote terminal to access the cell corresponding to the cell identity. If the remote terminal has not accessed the cell when the first timer expires, it may be considered that cell access fails. In this case, the remote terminal triggers a radio resource control connection reestablishment process.

In a possible special case, before the remote terminal receives the fourth message, the relay terminal is disconnected from the link between the relay terminal and the remote terminal. In this case, when the remote terminal detects no discovery message sent by the relay terminal, the remote terminal determines that a failure occurs over the link between the remote terminal and the relay terminal, and the remote terminal triggers a radio resource control connection reestablishment process.

S504 and S505: The remote terminal and the network device perform the first step and the second step of random access. To be specific, the remote terminal sends a random access preamble (preamble) to the network device, and the network device feeds back a random access response to the remote terminal.

S506: The remote terminal sends a random access message <NUM> (MSG <NUM>) to the network device. The message <NUM> may include a C-RNTI of the relay terminal and a local identifier (local ID) of the remote terminal. Specifically, the message <NUM> may be an RRC message or an MAC control entity (MAC control element, MAC CE).

S507: The network device returns a random access message <NUM> (MSG <NUM>) to the remote terminal. The message <NUM> may include same content as that in the random access message <NUM> sent by the remote terminal. The message <NUM> may be an RRC message or an MAC CE.

S508: An RRC connection reconfiguration process is performed between the remote terminal and the network device to establish the direct connection path.

It can be understood that, in the embodiment in <FIG>, in the cell in which the network device is located, the remote terminal has no C-RNTI. The relay terminal instructs (by using the fourth message) the remote terminal to perform path switching, and configures (for example, the C-RNTI of the relay terminal, the local ID of the remote terminal, the cell ID, and the radio resource configuration information) for the path switching of the remote terminal. In the embodiment in <FIG>, the relay terminal releases the short-distance link after sending the fourth message to the remote device, without requiring a trigger condition.

<FIG> is a schematic flowchart of still another path switching method according to this application. In the embodiment in <FIG>, in a cell in which a network device is located, a remote terminal side has a cell radio network temporary identifier (Cell Radio Network Temporary Identifier, C-RNTI). The C-RNTI of the remote terminal may be sent to the remote terminal by the network device by using a relay terminal when the remote terminal establishes a short-distance communication connection to the relay terminal, or may be directly obtained by the remote terminal from the network device when a direct connection path is being established. Details are provided in the following.

S600: An upper layer of the relay terminal triggers release of a short-distance link between the relay terminal and the remote terminal. In addition to a sidelink technology, a link between the relay device and the remote terminal may alternatively be a short-distance link in another form, for example, any one of links such as a WLAN link or a Bluetooth link.

S601: The relay terminal sends a fourth message to the remote terminal, where the fourth message may be used to notify that the short-distance link is to be released by the relay terminal, to instruct the remote terminal to switch from an indirect connection path to a direct connection path.

Specifically, the fourth message may be implemented as, but is not limited to, PC5 signaling. The fourth message may include common radio resource configuration information of a serving cell of the relay terminal, and a cell identity of the serving cell of the relay terminal. Optionally, the fourth message may further include a reason for releasing the short-distance link by the relay terminal. For example, the relay terminal needs to perform a circuit switched fallback (CSFB), or the relay terminal has insufficient power supply. The examples are merely some embodiments provided in this application, and the fourth message may alternatively include another reason for releasing the short-distance link by the relay terminal. This is not limited herein.

S602: After sending the fourth message to the remote terminal, the relay terminal releases the short-distance link between the relay terminal and the remote terminal.

S603: After receiving the fourth message sent by the relay terminal, the remote terminal triggers switching from the indirect connection path to the direct connection path, and performs downlink synchronization with a cell corresponding to the cell identity in the fourth message.

In a possible special case, before the remote terminal receives the fourth message, the relay terminal is disconnected from the link between the relay terminal and the remote terminal. In this case, when the remote terminal detects no discovery message sent by the relay terminal, the remote terminal determines that a failure occurs over the link between the remote terminal and the relay terminal, and the remote terminal triggers the radio resource control connection reestablishment process.

S604: The remote terminal performs a random access process.

S605: An RRC connection reconfiguration process is performed between the remote terminal and the network device to establish the direct connection path.

It can be understood that, in the embodiment in <FIG>, in the cell in which the network device is located, the remote terminal has a C-RNTI. The relay terminal instructs (by using the fourth message) the remote terminal to perform path switching, and configures (for example, the cell ID and the radio resource configuration information) for the path switching of the remote terminal. In the embodiment in <FIG>, the relay terminal releases the short-distance link after sending the fourth message to the remote terminal, without requiring a trigger condition.

S700: An upper layer of the relay terminal triggers release of a short-distance link between the relay terminal and the remote terminal. In addition to a sidelink technology, a link between the relay device and the remote terminal may alternatively be a short-distance link in another form, for example, any one of links such as a WLAN link or a Bluetooth link.

S701: The relay terminal sends a fourth message to the remote terminal, where the fourth message may be used to notify that the short-distance link is to be released by the relay terminal, to instruct the remote terminal to switch from an indirect connection path to a direct connection path.

Specifically, the fourth message may be implemented as, but is not limited to, PC5 signaling. Optionally, the fourth message may include a reason for releasing the short-distance link by the relay terminal. For example, the relay terminal needs to perform a circuit switched fallback (CSFB), or the relay terminal has insufficient power supply. The examples are merely some embodiments provided in this application, and the fourth message may alternatively include another reason for releasing the short-distance link by the relay terminal. This is not limited herein.

S702: After sending the fourth message to the remote terminal, the relay terminal releases the short-distance link between the relay terminal and the remote terminal.

S703: After receiving the fourth message sent by the relay terminal, the remote terminal initiates an RRC reestablishment process.

S704: An RRC connection reconfiguration process is performed between the remote terminal and the network device to establish the direct connection path.

It can be understood that, in the embodiment in <FIG>, the relay terminal only instructs (by using the fourth message) the remote terminal to perform path switching, and does not configure for the path switching. After receiving the fourth message, the remote terminal triggers the RRC connection reestablishment, and performs RRC reconfiguration based on the reestablished RRC connection (the direct connection path).

In the embodiments (the embodiments in <FIG>) in Solution <NUM>, the releasing the short-distance link between the relay terminal and the remote terminal may include the following several implementations.

Implementation <NUM>: The release of the short-distance link between the relay terminal and the remote terminal is triggered by the network device. Refer to <FIG>.

Specifically, after the network device configures for link switching of the remote terminal (that is, after the network device sends the second message to the remote terminal), the network device sends the third message to the relay terminal, to trigger the relay terminal to release the short-distance link.

Implementation <NUM>: The release of the short-distance link between the relay terminal and the remote terminal is triggered by the remote terminal. Refer to <FIG>.

Specifically, after the remote terminal receives link switching configuration information sent by the network device (that is, after the remote terminal receives the second message sent by the network device), the remote terminal sends the third message to the relay terminal, to trigger the relay terminal to release the short-distance link.

Implementation <NUM>: After the relay terminal requests to release the short-distance communication link (that is, after the relay terminal sends the first message to the network device) and when the time for maintaining the short-distance link by the relay terminal exceeds the first time length, the relay terminal releases the short-distance link. Refer to <FIG>.

In this application, the several implementations of releasing the short-distance link between the relay terminal and the remote terminal in Solution <NUM> may also be applicable to the embodiments in Solution <NUM>.

Implementation <NUM>: The release of the short-distance link between the relay terminal and the remote terminal is triggered by the network device.

Specifically, after the network device configures for link switching of the remote terminal (that is, after the network device sends the sixth message to the remote terminal), the network device sends the seventh message to the relay terminal, to trigger the relay terminal to release the short-distance link.

Implementation <NUM>: The release of the short-distance link between the relay terminal and the remote terminal is triggered by the remote terminal, as shown in <FIG>.

Specifically, after the remote terminal receives the link switching configuration information sent by the network device (that is, after the remote terminal receives the sixth message sent by the network device), the remote terminal sends the seventh message to the relay terminal, to trigger the relay terminal to release the short-distance link.

Implementation <NUM>: After the relay terminal instructs to release the short-distance communication link (that is, after the relay terminal sends the fourth message to the remote terminal), when the time for maintaining the short-distance link by the relay terminal exceeds a specified time threshold, the relay terminal releases the short-distance link. The specified time threshold may be set by the relay terminal according to an actual requirement. This is not limited herein.

In addition, in Solution <NUM>, the relay terminal may alternatively directly release the short-distance link after instructing to release the short-distance link, without requiring a trigger condition. For details, refer to the embodiments in <FIG>.

In addition, the path switching method provided in this application may further be applicable to a cell handover scenario. In the cell handover scenario, a remote terminal may alternatively switch from an indirect connection path to another network device (which may be referred to as a second network device) that is different from a network device (which may be referred to as a first network device) connected to a relay terminal.

The following uses the embodiments in <FIG> and <FIG> as examples, to describe a path switching method in the cell handover scenario.

Based on the embodiment in <FIG>, <FIG> shows a path switching method in a cell handover scenario according to this application.

A difference from the embodiment in <FIG> lies in that, in the embodiment in <FIG>, a handover preparation process needs to be performed between the first network device and the second network device, and reference may be made to S102'. In addition, a time point at which a third message is sent by the first network device may be either of the following:.

Based on the embodiment in <FIG>, <FIG> shows another path switching method in a cell handover scenario according to this application.

A difference from the embodiment in <FIG> lies in that, in the embodiment in <FIG>, a handover preparation process needs to be performed between the first network device and the second network device, and reference may be made to S404'.

It can be learned from the examples in <FIG> and <FIG> that, based on the embodiments in <FIG> provided in this application, the path switching method in the cell handover scenario further needs to include the cell handover preparation process between the first network device and the second network device.

<FIG> shows a wireless communications system, a terminal, and a network device according to this application. The wireless communications system <NUM> may include: a first terminal <NUM>, a second terminal <NUM>, and a first network device <NUM>. Optionally, the wireless communications system <NUM> may further include a second network device <NUM>. The first terminal <NUM> or the second terminal <NUM> may be the terminal <NUM> in the embodiments in <FIG>. The first network device <NUM> or the second network device <NUM> may be the network device <NUM> in the embodiments in <FIG>. The wireless communications system <NUM> may be the wireless communications system <NUM> shown in <FIG>. In this application, the wireless communications system <NUM> may use two different path switching solutions. The following separately describes the two solutions.

Solution <NUM>: The first terminal <NUM> requests the network device <NUM> to trigger the second terminal <NUM> to perform path switching, and the network device <NUM> configures for the path switching. Optionally, the second terminal <NUM> may switch from an indirect connection path to a network device that is different from the first network device <NUM> connected to the first terminal <NUM>, that is, switch to the second network device <NUM>. The following separately describes implementations of the first terminal <NUM>, the second terminal <NUM>, the first network device <NUM>, and the second network device <NUM>.

As shown in <FIG>, the first terminal <NUM> may include a processing unit <NUM> and a communications unit <NUM>.

The communications unit <NUM> may be configured to send a first message to the first network device <NUM>.

The first message herein may be used to request to switch the second terminal <NUM> from an indirect connection path for communicating with the first network device <NUM> by using the first terminal <NUM> to a direct connection path for communicating with the first network device <NUM> or the second network device <NUM>. Alternatively, the first message may be used to request to release a link between the first terminal <NUM> and the second terminal <NUM>.

The processing unit <NUM> may be configured to release the link between the first terminal <NUM> and the second terminal <NUM>.

Specifically, the processing unit <NUM> may be configured to release the link between the first terminal <NUM> and the second terminal <NUM> in the following several manners.

The third message herein may be sent by the first network device <NUM> or the second terminal <NUM> after the first network device <NUM> sends a second message to the second terminal <NUM>, and is used to instruct the first terminal <NUM> to release the link.

The second message may include at least one of the following: a cell identity, random access configuration information, first instruction information, or a first time value, and is used to configure the second terminal <NUM> to switch from the indirect connection path to the direct connection path.

The first instruction information may be used to instruct the second terminal <NUM> whether to perform, before disconnecting from the first terminal <NUM>, downlink synchronization with a cell corresponding to the cell identity. The first time value may be a longest time allowed for the second terminal <NUM> to access the cell corresponding to the cell identity.

(<NUM>) The processing unit <NUM> may be configured to release the link when a time length for maintaining the link after the communications unit <NUM> sends the first message exceeds a first time length.

As shown in <FIG>, the first network device <NUM> may include a first communications unit <NUM> and a second communications unit <NUM>.

The communications unit <NUM> may be configured to receive the first message sent by the first terminal <NUM>.

Herein, the first message may be used to request to switch the second terminal <NUM> from the indirect connection path for communicating with the first network device <NUM> by using the first terminal <NUM> to the direct connection path for communicating with the first network device <NUM> or the second network device <NUM>. Alternatively, the first message is used to request to release the link between the first terminal <NUM> and the second terminal <NUM>. The first network device <NUM> is different from the second network device <NUM>.

The communications unit <NUM> may be further configured to send the second message to the second terminal <NUM>, where the second message may be used to configure the second terminal <NUM> to switch from the indirect connection path to the direct connection path.

Specifically, the second message may include at least one of the following: the cell identity, the random access configuration information, the first instruction information, or the first time value. The first instruction information may be used to instruct the second terminal <NUM> whether to perform, before disconnecting from the relay terminal <NUM>, the downlink synchronization with the cell corresponding to the cell identity. The first time value may be the longest time allowed for the second terminal <NUM> to access the cell corresponding to the cell identity.

As shown in <FIG>, the second terminal <NUM> may include a processing unit <NUM> and a communications unit <NUM>.

The communications unit <NUM> may be configured to receive the second message sent by the first network device <NUM>. The second message may be used to configure the second terminal <NUM> to switch from the indirect connection path for communicating with the first network device <NUM> by using the first terminal <NUM> to the direct connection path for communicating with the first network device <NUM> or the second network device <NUM>.

The processing unit <NUM> may be configured to switch from the indirect connection path to the direct connection path according to the second message.

Specifically, the second message may include at least one of the following: the cell identity, the random access configuration information, the first instruction information, or the first time value. The first instruction information may be used to instruct the second terminal <NUM> whether to perform, before disconnecting from the first terminal <NUM>, the downlink synchronization with the cell corresponding to the cell identity. The first time value is used to instruct the longest time allowed for the second terminal <NUM> to access the cell corresponding to the cell identity.

It can be understood that, for specific implementations of the first terminal <NUM>, the second terminal <NUM>, the first network device <NUM>, and the second network device <NUM> in Solution <NUM>, reference may be made to the embodiments in <FIG>, or the embodiment in <FIG>, and another implementation related to Solution <NUM>.

Solution <NUM>: The first terminal <NUM> directly instructs the second terminal <NUM> to perform path switching. Optionally, the second terminal <NUM> may switch from an indirect connection path to a network device that is different from the first network device <NUM> connected to the first terminal <NUM>, that is, the second network device <NUM>. The following separately describes implementations of the first terminal <NUM>, the second terminal <NUM>, the first network device <NUM>, and the second network device <NUM>.

The communications unit <NUM> may be configured to send a fourth message to the second terminal.

The fourth message herein may be used to instruct the second terminal to switch from an indirect connection path for communicating with the first network device by using the first terminal to a direct connection path for communicating with the first network device or the second network device. Alternatively, the fourth message may be used to instruct to release a link between the first terminal and the second terminal.

The processing unit <NUM> may be configured to release the link between the first terminal and the second terminal.

The seventh message herein may be sent by the first network device or the second terminal after the first network device sends a sixth message to the second terminal, and is used to instruct the first terminal to release the link.

The sixth message may include at least one of the following: a cell identity, random access configuration information, first instruction information, or a first time value, and is used to configure the second terminal to switch from the indirect connection path to the direct connection path.

(<NUM>) The processing unit <NUM> may be configured to release the link when a time length for maintaining the link after the first terminal sends the fourth message exceeds a first time length.

Specifically, the fourth message may include at least one of the following: a cell identity of a serving cell of the first terminal, or common radio resource configuration information of a serving cell of the first terminal.

The communications unit <NUM> may be configured to receive the fourth message sent by the first terminal.

The fourth message may be used to instruct the second terminal to switch from the indirect connection path for communicating with the first network device by using the first terminal to the direct connection path for communicating with the first network device or the second network device. Alternatively, the fourth message may be used to instruct to release the link between the first terminal and the second terminal.

The processing unit <NUM> may be configured to switch from the indirect connection path to the direct connection path according to the fourth message.

Specifically, the fourth message may include at least one of the following: the cell identity of the serving cell of the first terminal, or the common radio resource configuration information of the serving cell of the first terminal.

In an optional embodiment, the communications unit <NUM> may be further configured to send a second message to the first network device, to request to switch from the indirect connection path to the direct connection path. In addition, the communications unit <NUM> may be further configured to receive the sixth message sent by the first network device.

Herein, the sixth message may include at least one of the following: the cell identity, the random access configuration information, the first instruction information, or the first time value, and is used to configure the second terminal to switch from the indirect connection path to the direct connection path. The first instruction information may be used to instruct the second terminal whether to perform, before disconnecting from the first terminal, downlink synchronization with a cell corresponding to the cell identity. The first time value may be a longest time allowed for the second terminal to access the cell corresponding to the cell identity.

In an optional embodiment, the communications unit <NUM> may be further configured to trigger a radio resource control connection reestablishment process after receiving the fourth message.

In an optional embodiment, the communications unit <NUM> may be further configured to connect, by the second terminal, to the serving cell of the first terminal, and send a terminal device identifier to the first network device. The terminal device identifier may be a C-RNTI of the second terminal, or a C-RNTI of the first terminal and a local identifier of the second terminal. Specifically, the terminal device identifier may be carried in the fourth message. Alternatively, the terminal device identifier may be sent to the second terminal by the first terminal before the first terminal sends the fourth message.

According to the technical solutions provided in this application, in relay communication, when a relay device becomes unable to provide a relay service for a remote terminal, the relay device may trigger switching of the remote terminal from an indirect connection path for communicating with a network device by using the relay device to a direct connection path for direct communicating with the network device, and release a short-distance link between the relay terminal and the remote terminal. In this way, the relay device can quickly trigger path switching of the remote terminal based on a status of the relay device in a timely manner, and even can implement the path switching without interrupting data communication over a sidelink, thereby ensuring that data communication between the remote terminal and the network device is not interrupted.

Claim 1:
A path switching method, comprising:
sending (S101), by a relay terminal, a first message to a first network device, wherein the first message is used to request to switch a remote terminal from an indirect connection path for communicating with the first network device by using the relay terminal to a direct connection path for communicating directly with the first network device or a second network device, or the first message includes a request to release a link between the relay terminal and the remote terminal, and the first network device is different from the second network device, wherein the first message includes a reason for releasing the short-distance link by the relay terminal; and
after the relay terminal sends the first message to the first network device, releasing (S106), by the relay terminal, the link between the relay terminal and the remote terminal,
wherein the releasing, by the relay terminal, the link between the relay terminal and the remote terminal after the relay terminal sends the first message to the first network device comprises:
releasing, by the relay terminal, the link after receiving (S105) a third message, wherein the third message is sent by the first network device or the remote terminal after the first network device sends a second message to the remote terminal, and is used to instruct the relay terminal to release the link, wherein
the second message comprises at least one of the following: a cell identity, random access configuration information, first instruction information, or a first time value, and is used to configure the remote terminal to switch from the indirect connection path to the direct connection path, wherein
the first instruction information is used to instruct the remote terminal whether to perform, before disconnecting from the relay terminal, downlink synchronization with a cell corresponding to the cell identity, and the first time value is a longest time allowed for the remote terminal to access the cell corresponding to the cell identity.