hi i need help. i am creating multple nodes in wifi adhoc model to send and receive multiple packets. i am using loop to create sink sockets and putting them in array same as for sender. i am broadcasting packets. problem.
problelm is for single siink and sender code is sending and receivng pakckets. when i ncrease no of sender and keep single sink. it makes connection successfully but dont recive any single mesage.
for(int i =0; i < 2;i++)
{
TypeId tid = TypeId::LookupByName ("ns3::UdpSocketFactory");
Ptr<Socket> recvSink = Socket::CreateSocket (c.Get (i), tid);
InetSocketAddress local = InetSocketAddress (Ipv4Address::GetAny (), 80);
recvSink->Bind (local);
arrary[i.scoket]= recSink
arrary[i.scoket]->SetRecvCallback (MakeCallback (&ReceivePacket));
}
for(int i =0; i < 2;i++)
{
sender[i].source = Socket::CreateSocket (c.Get (i), tid);
InetSocketAddress remote = InetSocketAddress (i.GetAddress (1, 0), 80);
sender[i].source ->Connect (remote);
}