If you know the ip address of the sender you can use L3AddressResolver
L3AddressResolver().findHostWithAddress(src)->getFullName()
De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de Moussa ABOUBAKAR <abaka...@gmail.com>
Enviado: lunes, 20 de julio de 2020 15:10
Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: [Omnetpp-l] How to get the name of a submodule
--Hello fellow OMNeT++ users,
I am simulating an UDPBasicAPP on OMNETP 5.4.1. I would like to log the name of the submodule (node) that send a packet to the sink node.
Could you please explain me how to proceed.
Thank you
Best regards
You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omn...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/c7c80993-7d30-4bbc-9265-c293e48d8498o%40googlegroups.com.
Check the code, UDPSocket::getReceivedPacketInfo(PK(msg)) print the src address, in this method you can see how to extract the address
Enviado desde Correo para Windows 10
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/ce631ffc-1d67-44e2-a780-7e76be4362dco%40googlegroups.com.