Good day:
I apologize in advance, maybe this question is quite obvious but i haven't clear enough my doubt with the existing documentation or i have being reading the wrong documentation.
I want to know if the protocol/protocol_number is just a number that the user developer can use as a flag identifier or we can actually map the protocol number to a specific protocol
meaning:
protocolNumber = 1 -> Protocol A
protocolNumber = 2 -> Protocol B, and so on
Looking at the ne-device.cc and .h i just found this
In the documentation below is a description of the protocol
- Parameters
device | a pointer to the net device which is calling this callback |
packet | the packet received |
protocol | the 16 bit protocol number associated with this packet. This protocol number is expected to be the same protocol number given to the Send method by the user on the sender side. |
sender | the address of the sender |
Also in the send command for the netdevice (and wifinetdevice) you can find that this protocol number is used
In the wifinetdevice.cc you can see also this protocol number
314 bool
326 m_mac->NotifyTx (packet);
327 m_mac->Enqueue (packet, realTo);
Digging further the protocolNumber is used for the LLcSnapHeader for them_etherType
I´m out of ideas, i just want to clarify this to see if this has a direct relationship with when we setup the protocol with the helper, is just a number we can use a an identifier and has no direct mapping with a protocol vs its number
Thanks in advance and best regards