brianmc95 / OpenCV2X

OMNeT++ V2X simulation framework for ETSI ITS-G5
GNU General Public License v2.0
37 stars 15 forks source link

How are MAC packets transferred to the next layer? #27

Open yuxingguang opened 2 years ago

yuxingguang commented 2 years ago

Hi @brianmc95 , I noticed when MAC layer gets a newDataPkt from RLC layer, it will save the packet into the harq buffers, however i can't figure out how dose the mac layer pass these pkts to phy layer.Maybe the class's inheritance hierarchy is too complicated to me. So can you tell me who take out the pkts in the harq buffers , the harq buffer, or the mac module? By the way, if my focus is just about SB-SPS, the harq module doesn't realy mean that much to me, So can i just remove it or ignore it?

Kind Regards, Xingguang Yu

brianmc95 commented 2 years ago

Hi @yuxingguang

The flushHarqBuffers is likely what you want to look at to figure this out, the specific call is it2->second->sendSelectedDown() this actually asks the harq buffers to send the packet down to the PHY layer for transmissions.

What I would say is that you are best to ignore it, removing it would be much more work than it's worth given that it doesn't impact on the SB-SPS algorithm anyway so it doesn't effect you (bar maybe making debugging a little more awkward).

Kind Regards, Brian