How can I get mobile node IP address in OPNET 14.5? -


i tried following code in opnet modeler 14.5

objid addr_info_attr_objid; char address_string[128]; addr_info_attr_objid = op_id_self(); op_ima_obj_attr_get(addr_info_attr_objid, "address", address_string); 

to node ip address gives error message:

<<<recoverable error>>> attribute name(address) unrecognizzed object(542) 

you have find proper ip interface first. based on code, not right way ip address of one-interface node, such server/client model.

here sample code

op_ima_obj_attr_get(ip_moudle_objid, "ip router parameters [0].interface information [3].address", &address_str); 

Comments

Popular posts from this blog

android - Why am I getting the message 'Youractivity.java is not an activity subclass or alias' -

python - How do I create a list index that loops through integers in another list -

c# - “System.Security.Cryptography.CryptographicException: Keyset does not exist” when reading private key from remote machine -