So, it means Connected UE can 3 type of activities with PRACH:
Uplink Data Transmission: If it wants to transport data on uplink way. It should to do ContentionBased R.A process.
Handover: If UE wants to do Handover Process, it should to do NonContentionBased R.A process. But… it is already Connected mode and RACH is a first message to eNB. So, why and how UE can to do it? Because, when UE has bad RSRP value it will be disconnected in the its eNB. So UE want to connect other eNB and it sends NonContention Preamble message to different eNB.
UE doing NonContentionBased process, because we dont want to make wait it when it changing eNB connecting. Because it will be fail trying to connect on ContentionBased Process way.
Downlink Data Transmission: If UE wants to data communication on downlink way, it have to do process of NonContention.
RACH is always not needed for DL data transmission.
One use case i can think of is like this: when UE is in connected mode with data inactivity and timing alignment timer expires at network.
Now, network accumulates some DL buffer for that UE. In this case, even though UE is in connected mode, as timing realignment timer expired at network side, UE is not considered synchronised so, network will trigger PDCCH order to force the UE to start RACH to get the connection resynchronized. Once the RACH is done, connection is considered synchronised so, network can start DL data scheduling.
RACH through PDCCH order is always contention free.
Sending a DCI Format 1_0 on the SSB beam index UE is camped along with a PRACH preamble and RACH occasion.
Does the gNB indicate preamble within the DCI?