Problem in beacon broadcast

69 views
Skip to first unread message

Giuliana Carullo

unread,
Jan 30, 2015, 9:58:38 AM1/30/15
to ns-3-...@googlegroups.com
Hello everyone,

I am trying to simulate nodes acting both as wifi-client and AP. In particular, every node announces its presence sending beacons (AP-mode) and recognizes other nodes' presence listening to other nodes' beacons (wifi-client-mode). 

My problem is that, if nodes are in the same position, the ad-hoc node (wifi-client) properly receives the AP's beacon. Otherwise they do not.  

Here is the code I wrote so far: http://codeviewer.org/view/code:4b8c (Sorry if the code is not really clean) 

Any suggestion is welcome. 

Best Regards,
Giuliana Carullo

Giuliana Carullo

unread,
Jan 30, 2015, 10:28:42 AM1/30/15
to ns-3-...@googlegroups.com
Just to let you better understand the problem I have:

while considering the following code

for (uint n=0 ; n < numNodes ; n++) {
//distance = distance +10;
Ptr<ConstantPositionMobilityModel> mob = ap.Get(n)->GetObject<ConstantPositionMobilityModel>();
mob->SetPosition(Vector(distance, distance, 0));
mob = wifiClient.Get(n)->GetObject<ConstantPositionMobilityModel>();
mob->SetPosition(Vector(distance, distance, 0));
}

if I uncomment the line 'distance = distance +10;' nodes stop receiving beacons. Otherwise it works.

Thank you for your help in advance.

Regards,
Giuliana

Tommaso Pecorella

unread,
Jan 30, 2015, 12:05:00 PM1/30/15
to ns-3-...@googlegroups.com
Hi,

didn't check the code yet, but a line in the sources draw my attention.

Are you going to simulate nodes with psychic disorders ? THAT's a new research field !
Sorry for the (bad) joke. I'll check your code later tonight as self-inflicted punishment.

Cheers,

T.

PS: no offence or whatsoever with whoever is affected by / knows someone affected by Bipo.

Tommaso Pecorella

unread,
Jan 30, 2015, 4:33:21 PM1/30/15
to ns-3-...@googlegroups.com
Hi,

from the code, you're setting the Rx gain to -10 db. Try to check if this isn't a bit too low. Perhaps your receivers are just deaf.

Cheers,

T.

Giuliana Carullo

unread,
Jan 31, 2015, 5:08:48 AM1/31/15
to ns-3-...@googlegroups.com
Hi Tommaso,
thanks for your help! Actually, my nodes suffer from different diseases: they are bipolar, a bit of autism from time to time, and they are deaf xD
Unfortunately, I tried to set different values for the Rx gain, but they're still deaf xD Any other suggestion for a possible therapy?

Cheers,
Giuliana.

Tommaso Pecorella

unread,
Jan 31, 2015, 5:17:59 AM1/31/15
to ns-3-...@googlegroups.com
Yo Giuliana,

I can't run your script 'cuz it's missing a file (or some files). Feel free to send me them and I'll take a look.

Cheers,

T.

Giuliana Carullo

unread,
Jan 31, 2015, 5:48:13 AM1/31/15
to ns-3-...@googlegroups.com
Hi Tommaso,
I'm sorry, you are right.

Here is the included script:

Thanks again!

Cheers,
Giuliana

Tommaso Pecorella

unread,
Jan 31, 2015, 7:50:11 AM1/31/15
to ns-3-...@googlegroups.com
Ok, I guess you need to clean up your code. From the bugs I mean.

The wifi STA are on AdHoc:
  wifiMac.SetType ("ns3::AdhocWifiMac");
The APs are all in AP mode, but are on different SSIDs.

No wonder they're not communicating...

However, the point is... no beacon is received, in any case. The distance is not the problem.

Have a nice weekend,

T.
Reply all
Reply to author
Forward
0 new messages