Correct TA timer condition

- wrap around 1024 (frame number is 0-1023)
- check for equality of frames with high numbers will trigger every 10ms
This commit is contained in:
Robert Schmidt
2020-11-11 16:45:54 +01:00
parent 3d60e95387
commit 434186fd9f
@@ -641,7 +641,7 @@ void nr_schedule_ue_spec(module_id_t module_id,
* Possible improvement: take the periodicity from input file.
* If such UE is not scheduled now, it will be by the preprocessor later.
* If we add the CE, ta_apply will be reset */
if (frame >= (sched_ctrl->ta_frame + 10) % 1023)
if (frame == (sched_ctrl->ta_frame + 10) % 1024)
sched_ctrl->ta_apply = true; /* the timer is reset once TA CE is scheduled */
if (sched_ctrl->rbSize <= 0)