4-Step RA and 2-Step RA in 5G-NR

4-Step RA and 2-Step RA in 5G-NR

#Random Access Procedure: - In Telecommunication a base-station (eNB/gNB) allows multiple UEs to randomly access the network at the same time known as Random Access.

For Random Access the gNB generates a set of 64 Random Access Preambles using Zadoff-Chu Sequence generation method.

As multiple UEs can select the preamble from a group of available preambles there is a chance that the multiple UEs picks the same preamble at the same time for RACH. This could lead to the collision where the gNB will allow the access to only one UE leaving other UEs to re-attempt the RACH again.

In the cases of connected mode mobility (Handover) it is necessary that the UE completes the RACH to target cell without any issue, hence some of the preambles are reserved and transmitted to the UEs during Handover process only. This leads out two types of RACH Process as mentioned below.

1.?????Contention based Random Access (CBRA)

2.?????Contention Free Random Access (CFRA)

Contention based Random Access:

In the case of Contention-based procedure, UE selects a Random-access preamble from a group of available preambles which are shared to all the UE's. There is a possibility at a given time two UE's might select the same Random-access preamble and transmit to gNB at the same time which might result in collision or contention at the gNB.

Contention Free Random Access:

In the case of contention-free random-access procedure, gNB allocates a dedicated random-access preamble to UE which removes the possibility of collision. Like out of 64 available preambles the gNB reserve few preambles for CFRA to be used during Handover.

->> Based on number of steps required to perform RACH Process, it has been classified into two types of RACH Process: -

1.?????4-STEP RACH Process??????????????2.???????2-STEP RACH Process

Till 3gpp Rel.15 we have 4-Step Process only available but 3gpp Rel.16 introduces 2-Step RACH Process that aims to improve the overall latency of the RACH procedure as compared to 4-Step RACH Process by reducing the Control Signalling overhead at the gNB.

No alt text provided for this image

1.??4-step RACH process: -

No alt text provided for this image

Now, to perform Random Access the UE need to select a preamble.

There are two Groups of RA-Preambles defined.

1.?????RA-preamble Group A

2.?????RA-preamble Group B

  • Random Access group A is used by default if Group B is not configured.
  • To use Random Access group B the gNB configure below parameters in SIB1.

No alt text provided for this image
No alt text provided for this image

-ra-Msg3SizeGroupA: the threshold to determine the groups of Random Access Preambles

-msg3-DeltaPreamble: ?PREAMBLE_Msg3

-messagePowerOffsetGroupB: the power offset for preamble selection.

-numberOfRA-PreamblesGroupA: As per 3gpp Spec. 38.321 ,the value given by this parameter indicates the first numbers of Random Access Preambles belong to Random Access Preambles group A. The remaining Random Access Preambles associated with the SSB belong to Random Access Preambles Group B (if configured). If Random Access Preambles Group B is supported by the cell and SSBs are mapped to Random Access Preambles, Random Access Preambles Group B is included in each SSB.

<< Conditions to transmit Group B >>

-->>if Msg3 has not yet been transmitted:

if Random Access Preambles Group B is configured:

{

if the potential Msg3 size (UL data available for transmission + MAC header and, where required, MAC CEs) is greater than ra-Msg3SizeGroupA and the pathloss is less than PCMAX (of the Serving Cell performing the Random Access Procedure) – preambleReceivedTargetPower – msg3- DeltaPreamble – messagePowerOffsetGroupB;

or

if the Random Access procedure was initiated for the CCCH logical channel and the CCCH SDU size + MAC subheader is greater than ra-Msg3SizeGroupA:

select the Random Access Preambles Group B.

else:

select the Random Access Preambles group A.

}

else:

select the Random Access Preambles group A.

->> If Msg3 is being retransmitted:

select the same group of Random Access Preambles as was used for the Random Access Preamble transmission attempt corresponding to the first transmission of Msg3.

From above conditions it can be concluded that:

  • RA-preamble Group A is selected by the UE when the uplink data quantity to be sent is relatively small, or when the UE is in poor coverage.
  • RA-preamble Group B is selected by the UE when the uplink data quantity to be sent is relatively large, and the UE is in good coverage.

The configuration and parameters required to initiate RACH is explained in

https://www.dhirubhai.net/pulse/rach-5g-nr-ajay-kumar-singh

#MSG1 (Random Access Preamble): UE selects a preamble from the set of preambles generated as per PRACH parameters sent by gNB in SIB1 and send MSG1 (Random Access Preamble) on PRACH Channel. The UE also calculates the RA-RNTI based on below formula (As per 3gpp Spec. 38.321 [5.1.3]) and save it.

RA-RNTI = 1 + s_id + 14 × t_id + 14 × 80 × f_id + 14 × 80 × 8 × ul_carrier_id

No alt text provided for this image

Frequency domain location (resource) for PRACH Preamble is determined by the RRC parameter?msg1-FDM?and?msg1-FrequencyStart

Time domain location (resource) for PRACH Preamble is determined by the RRC parameter?prach-ConfigurationIndex.

#MSG2 (Random Access Response): The gNB after receiving the Msg-1 calculates the RA-RNTI using the same formula mentioned above and scramble it with CRC of DCI Format 1_0 and send it on Type 1-PDCCH.

The UE then start monitoring Type 1-PDCCH for the window size mentioned in ra-ResponseWindow in SIB1. If UE successfully decode the PDCCH then it decodes the PDSCH carrying RAR data.

The MAC entity may stop the timer ra-ResponseWindow after successful reception of a RAR containing Random Access Preamble identifiers that matches the transmitted PREAMBLE_INDEX. (HARQ operation is not applicable to the Random Access Response transmission).

RAR is sent in MAC-PDU also known as MAC-RAR PDU. The header of MAC-RAR PDU carries the subheaders consisting of the BI (Backoff Indicator) and multiple RAPID .The payload part of MAC-RAR PDU carries the TA command, UL Grant and Temporary C-RNTI for respective RAPID. After decoding RAR, UE check if RAPID in RAR PDU matches the RAPID assigned to the UE.

No alt text provided for this image
No alt text provided for this image

If UE does not receive the Msg2 within ra-ResponseWindow size, then the UE again send the Msg1 with power ramped up with the step mentioned by powerRampingStep until it receives the Msg2 or the max. attempts of transmitting msg1 reaches the preambleTransMax value. Please note that power ramping is not possible if UE is already using it Max. power (Pmax.) for sending the Msg1.

Also, if the UE receive the Msg2 and the RAPID in the Msg2 does not matches with the preamble sent in Msg1 by the UE then the UE will consider it as Msg1 failure and wait for the time mentioned by BI (Backoff indicator) in Msg2 and re-attempt the PRACH.

No alt text provided for this image

#MSG3 (Scheduled Transmission): The UE after receiving the Msg2 uses the UL grant provided in Msg2 to send Msg3 on PUSCH.

The Msg3 will be sent on PUSCH along with RRC Message – RRC setup Request carrying IEs: UE Identity & Establishment cause.

The UE will send Msg3 on PUSCH and start ra-ContentionResolutionTimer

Now the question is when the UE will send the Msg3 after receiving the Msg2?

“If in slot ‘n’ a UE receives a PDSCH with a RAR message for a corresponding PRACH transmission from the UE, the UE transmits an Msg3 PUSCH in slot n + k2 + Δ “[3gpp Spec. 38.213 8.3]

Where Δ is the additional subcarrier spacing specific slot delay value for the first transmission of MSG3 scheduled by the RAR. When the UE transmits a MSG3 scheduled by RAR, the Δ value specific to MSG3 subcarrier spacing μPUSCH is applied in addition to the K2 value. Refer Table 6.1.2.1.1-5 of 3gpp Spec. 38.214

No alt text provided for this image

From the Msg2 UL grant we can see the size of Msg3 PUSCH time resource allocation is 4 bits (Range 0….15). From the above logs of Msg2 we can see that the value of Msg3 PUSCH time resource allocation is “4”, now we need to go to SIB1 and check the logs for pusch-ConfigCommon and select the item 4 where value of k2 is 5

No alt text provided for this image

So, the Msg3 will be sent after 11 slots {k2+ Δ = 5+ 6 (Considering SCS=120Khz)} once Msg2 is received.

Please note: if?pusch-ConfigCommon?includes?pusch-TimeDomainAllocationList:

then use table defined by?pusch-TimeDomainAllocationList, where the possible values of?k2?is between 0 and 32.

else: use the default A table as shown below.

No alt text provided for this image

The UE may assume a minimum time between the last symbol of a PDSCH reception conveying a RAR message with a RAR UL grant and the first symbol of a corresponding PUSCH transmission scheduled by the RAR UL grant is equal to?

?????????????????????????????????????????NT,1?+ NT,2?+ 0.5 msec, where:

  • NT,1?is a time duration of?N1?symbols corresponding to a PDSCH processing time for UE processing capability 1 when additional PDSCH DM-RS is configured
  • for?μ?= 0,?N1,0?= 14
  • NT,2?is a time duration of?N2?symbols corresponding to a PUSCH preparation time for UE processing capability 1
  • N1?and?N2?correspond to the smaller of the SCS configurations for the PDSCH and the PUSCH

MSG3 timing: minimum time between RAR and PUSCH

No alt text provided for this image
No alt text provided for this image
Time relation: from MSG2 to MSG3

#MSG4 (Contention Resolution): After reception of Msg3 the gNB sends PDCCH carrying DCI format 1_0 with CRC scrambled by a corresponding TC-RNTI scheduling a PDSCH that includes a UE contention resolution identity.

The UE decodes the MSG4 and if the UE contention resolution identity sent in MSG4 matches with the UE identity used in MSG3 then it is considered that contention resolution is successful and ra-ContentionResolutionTimer will be stopped.

If UE does not receive the MSG4 and ra-ContentionResolutionTimer expires, then the UE will send Msg1 again after waiting for time specified by backoff indicator in Msg2.

2. 2-step RACH process: -

The two steps of 2-Step RACH process are: -

  • MsgA (Msg1 + Msg3) from UE to gNB
  • MsgB (Msg2 + Msg4) from gNB to UE

The UE perform Step-2 RACH process only if the parameters related to Step-2 RACH process are configured in SIB1 and below conditions are satisfied.

  • if the BWP selected for Random Access procedure is configured with both 2-step and 4-step RA type Random Access Resources and the RSRP of the downlink pathloss reference is above msgA-RSRP-Threshold 2-stepRA will be used else it will use 4-stepRA.
  • if the BWP selected for Random Access procedure is only configured with 2-step RA type Random Access resources then 2-stepRA will be used.
  • if the BWP selected for Random Access procedure is only configured with 4-step RA type Random Access resources then 4-stepRA will be used.
  • if the Random Access procedure was initiated for reconfiguration with sync and if the contention-free Random Access Resources for 2-step RA type have been explicitly provided in rach-ConfigDedicated for the BWP selected for Random Access procedure 2-stepRA will be used.

As in 2-step RA, MsgA consists of the contents of Msg1+Msg3, the UE needs PUSCH occasion as well in addition to the PRACH occasion.

The UE selects the PUSCH occasion corresponding to the selected preamble and PRACH occasion and determine the UL grant and associated HARQ information for the MsgA payload according to the selected PUSCH and perform the MsgA transmission procedure. So, the task of UE is to first select the PRACH preamble from PRACH occasion and then select the PUSCH occasion.

PRACH Preamble selection: -

The UE identifies the PRACH occasion and select PRACH preamble as per the configuration configured in SIB1-RACH-ConigCommonTwoStepRA

No alt text provided for this image

Like 4-Step RA, in the case of 2-Step RA also the UE identifies the preamble Group to be selected for preamble based on below criteria.

->> if Random Access Preambles Group A for 2-step RA type is configured then select the Random Access Preambles group A.

->> if Random Access Preambles Group B for 2-step RA type is configured:

{

if the potential MsgA payload size (UL data available for transmission + MAC header and, where required, MAC CEs) is greater than the ra-Msg-ASizeGroupA

and the pathloss is less than PCMAX (of the Serving Cell performing the Random Access Procedure) – msgA-PreambleReceivedTargetPower – msgA-DeltaPreamble – msgA-messagePowerOffsetGroupB;

or

if the Random Access procedure was initiated for the CCCH logical channel and the CCCH SDU size + MAC subheader is greater than ra-MsgA-SizeGroupA:

select the Random Access Preambles group B.

else:

select the Random Access Preambles group A.

}

PUSCH Occasion selection:

The parameters for PUSCH occasion configured in SIB1 are mentioned below:?

No alt text provided for this image

msgA-PUSCH-Config: - A UE uses it to determines time resources and frequency resources for PUSCH occasions in an active transmitted in Active / Initial BWP.

  • interlaceIndexFirstPO-MsgA-PUSCH or frequencyStartMsgA-PUSCH: - A UE determines a first interlace or first RB for a first PUSCH occasion in an active UL BWP respectively. It provides an offset in number of RBs in the active UL BWP from a first RB of the active UL BWP.
  • nrofInterlacesPerMsgA-PO or by nrofPRBs-perMsgA-PO: - It provides that how many number of interlaces or how many number of RBs are there in PUSCH Occasion.
  • guardBandMsgA-PUSCH: - It indicates that how many RBs used to separate the Consecutive PUSCH occasions in the frequency domain of an UL BWP.
  • nrofMsgA-PO-FDM: - It indicates the number of PUSCH occasions in frequency domain.
  • startSymbolAndLengthMsgA-PO: -It provides the SLIV to UE for PUSCH transmission
  • mappingTypeMsgA-PUSCH: -It provides the PUSCH mapping type for PUSCH transmission
  • msgA-PUSCH-TimeDomainOffset: -For mapping one or multiple preambles of a PRACH slot to a PUSCH occasion associated with a DMRS resource, a UE determines a first slot for a first PUSCH occasion in an active UL BWP from msgA-PUSCH-TimeDomainOffset that provides an offset, in number of slots in the active UL BWP, relative to the start of a PUSCH slot including the start of each PRACH slot. (The UE does not expect to have a PRACH preamble transmission and a PUSCH transmission with a msgA in a PRACH slot or in a PUSCH slot, or to have overlapping msgA PUSCH occasions for a MsgA PUSCH configuration. The UE expects that a first PUSCH occasion in each slot has a same SLIV for a PUSCH transmission that is provided by startSymbolAndLengthMsgA-PO or msgA-PUSCH-timeDomainAllocation).
  • guardPeriodMsgA-PUSCH: -It indicates that how many symbols are used to separate the consecutive PUSCH occasion within same slot.
  • nrofMsgA-PO-perSlot: - It indicates that in time domain how many PUSCH occasion are there in a slot.
  • nrofSlotsMsgA-PUSCH: -It indicates how many consecutive slots have PUSCH occasions.
  • msgA-DMRS-Config: - It provides the DMRS resources. A PUSCH occasion for PUSCH transmission is defined by a frequency resource and a time resource ,and is associated with a DMRS resource.

Please note: A PUSCH occasion is valid if it does not overlap in time and frequency with any valid PRACH occasion.

For 2-Step RA, a UE first transmits the PRACH and then after “N” symbols it transmits the PUSCH. Where N is dependent on SCS of active UL BWP and given as.

No alt text provided for this image
No alt text provided for this image
PRACH Occasion and PUSCH Occasion in Frequency and Time domain

A UE does not transmit a PUSCH in a PUSCH occasion if the PUSCH occasion associated with a DMRS resource is not mapped to a preamble of valid PRACH occasions or if the associated PRACH preamble is not transmitted. A mapping between one or multiple PRACH preambles and a PUSCH occasion associated with a DMRS resource is as per PUSCH configuration.

#MsgA: UE after selecting the preamble sends the MsgA to the gNB with the selected preamble and PUSCH payload. The content of MsgA-PUSCH is same as Msg3 contents of 4-Step RA i.e., UE identity and Establishment cause.

The RA-RNTI associated with the PRACH occasion in which the Random Access Preamble is transmitted, is computed as:

RA-RNTI = 1 + s_id + 14 × t_id + 14 × 80 × f_id + 14 × 80 × 8 × ul_carrier_id

UE send the MSGA as per parameters defined in SIB1 under RACH-ConigCommonTwoStepRA

#MsgB: The UE after sending MSGA starts the msgB-ResponseWindow and start monitoring for Type-1 PDCCH carrying DCI format 1_0 with CRC scrambled MsgB-RNTI or C-RNTI while the msgBResponseWindow is running.

Now there are two conditions based on what type of RNTI is carried by DCI format 1_0

i.)?DCI format 1_0 with CRC scrambled by MsgB-RNTI

If the UE detects the DCI format 1_0, with CRC scrambled by the corresponding MsgB-RNTI and LSBs of a SFN field in the DCI format 1_0 is same as corresponding LSBs of the SFN where the UE transmitted PRACH, and the UE receives a transport block in a corresponding PDSCH within the window, the UE passes the transport block to higher layers.

The higher layer then,

->> if the MsgB contains a MAC subPDU with Backoff Indicator then set the PREAMBLE_BACKOFF to value of the BI field of the MAC subPDU using Table 7.2-1, multiplied with SCALING_FACTOR_BI else set the PREAMBLE_BACKOFF to 0ms.

No alt text provided for this image
No alt text provided for this image

->> if the MsgB contains a fallbackRAR MAC subPDU and if the RAPID in the MAC subPDU matches the transmitted PREAMBLE_INDEX in MsgA then consider this Random Access Response reception successful and apply the following actions ?

  • process the received Timing Advance Command
  • indicate the msgA-PreambleReceivedTargetPower and the amount of power ramping applied to the latest Random Access Preamble transmission to lower layers (i.e. (PREAMBLE_POWER_RAMPING_COUNTER – 1) × PREAMBLE_POWER_RAMPING_STEP)
  • if the Random Access Preamble was not selected by the MAC entity among the contention-based Random Access Preamble(s) then consider the Random Access procedure successfully completed and process the received UL grant value and indicate it to the lower layers.
  • if the Random Access Preamble was selected by the MAC entity among the contention-based Random Access Preamble(s) then set the T-C-RNTI to the value received in the Random Access Response then obtain the MAC PDU to transmit from the MSGA buffer and store it in the Msg3 buffer (Msg3 Buffer should be empty), process the received UL grant value and indicate it to the lower layers and proceed with Msg3 transmission. It means UE will perform 4-Step RA.

No alt text provided for this image
No alt text provided for this image

->> if the MsgB contains a successRAR MAC subPDU and if the CCCH SDU was included in the MsgA and the UE Contention Resolution Identity in the MAC subPDU matches the CCCH SDU then consider this Random Access Response reception successful. Stop msgB-ResponseWindow and set the C-RNTI to the value received in the successRAR apply the following actions

  • process the received Timing Advance Command
  • indicate the msgA-PreambleReceivedTargetPower and the amount of power ramping applied to the latest Random Access Preamble transmission to lower layers (i.e. (PREAMBLE_POWER_RAMPING_COUNTER – 1) × PREAMBLE_POWER_RAMPING_STEP).
  • deliver the TPC, PUCCH resource Indicator, ChannelAccess-CPext (if indicated), and HARQ feedback Timing Indicator received in successRAR to lower layers and consider this Random Access Response reception successful and ?this Random Access procedure successfully completed.

No alt text provided for this image
No alt text provided for this image

The lower layer then makes the transmission of a PUCCH with HARQ-ACK information having ACK value if the RAR message(s) is for successRAR, where

- a PUCCH resource for the transmission of the PUCCH is indicated by PUCCH resource indicator field of 4 bits in the successRAR from a PUCCH resource set that is provided by pucch-ResourceCommon. [38.214 Table 9.2.1-1]

No alt text provided for this image

- a slot for the PUCCH transmission is indicated by a HARQ Feedback Timing Indicator field of 3 bits in the successRAR having a value k from {1, 2, 3, 4, 5, 6, 7, 8} and, with reference to slots for PUCCH transmission having duration Tslot , the slot is determined as n + k + ?, where n is a slot of the PDSCH reception and ? is as defined for PUSCH transmission in Table 6.1.2.1.1-5 of [6, TS 38.214].

The PUCCH transmission should happen before NT,1 + 0.5 msec after the last symbol of the PDSCH reception, where NT,1 is the PDSCH processing time for UE processing capability 1 [6, TS 38.214]?

ii.)??DCI format 1_0 with CRC scrambled by C-RNTI

If the UE detects the DCI format 1_0 with CRC scrambled by a C-RNTI and a transport block in a corresponding PDSCH within the window, the UE passes the transport block to higher layers.

The higher layer then,

->> If it contains UL grant for a new transmission, consider this RAR reception successful, stop the msgB-ResponseWindow and consider this Random Access procedure successfully completed.

->> if the MAC PDU contains the Absolute Timing Advance Command MAC CE subPDU then process the received Timing Advance Command, consider this RAR reception successful, stop the msgB-ResponseWindow and consider this Random Access procedure successfully completed.

?MAC PDU (MsgB)

A MAC PDU consists of one or more MAC subPDUs and optionally padding. Each MAC subPDU consists one of the following:

- a MAC subheader with Backoff Indicator only

- a MAC subheader and fallbackRAR

- a MAC subheader and successRAR

- a MAC subheader and MAC SDU for CCCH or DCCH

- a MAC subheader and padding.

No alt text provided for this image

Now, if msgB-ResponseWindow expires, and the Random Access Response Reception has not been considered as successful based on descriptions above then increment PREAMBLE_TRANSMISSION_COUNTER by 1 then reattempt the process and if PREAMBLE_TRANSMISSION_COUNTER = preambleTransMax + 1 then indicate a Random Access problem to upper layers and consider this Random Access procedure unsuccessfully completed.

If the Random Access procedure is not completed and if msgA-TransMax is applied and PREAMBLE_TRANSMISSION_COUNTER = msgATransMax + 1 then set the RA_TYPE to 4-stepRA and start 4-step RA.

Sonia Munagapaty

Senior Wireless Design Engineer

3 个月

Hey Can I know the which release version are are is this reference to ?

回复
Rishabh Srivastava

Senior Software Engineer specializing in 5G NR SW Development at Qualcomm

10 个月

nice

回复

要查看或添加评论,请登录

Ajay Kumar Singh的更多文章

  • #SSB : Synchronization Signal Block

    #SSB : Synchronization Signal Block

    A Synchronization Signal Block (SSB) is a block of 20RBs (240 REs) in frequency domain and 4 OFDM symbols in time…

  • RACH in 5G-NR

    RACH in 5G-NR

    #RACH process or RA process is performed by a UE to get uplink synchronization with the gNB and also to request the…

    5 条评论

社区洞察

其他会员也浏览了