From: Serge S. <ser...@gm...> - 2009-04-28 08:49:17
|
Ok, i put a patch in the tracker here : http://sourceforge.net/tracker/?func=detail&aid=2782691&group_id=42445&atid=433164 On Wed, Mar 25, 2009 at 2:44 AM, Toby Collett <tco...@pl...> wrote: > The problem here is in p_wifi.cc in stage. This only copies the mac address > information into the wifi structure > > pdata.links_count = sdata->neighbours->len; > pdata.links = new player_wifi_link_t[pdata.links_count]; > assert(pdata.links); > memset(pdata.links,0,sizeof(player_wifi_link_t)*pdata.links_count); > for(guint i=0;i<sdata->neighbours->len;i++) > { > stg_wifi_sample_t samp = g_array_index(sdata->neighbours, > stg_wifi_sample_t, i); > memcpy(pdata.links[i].mac,samp.mac,sizeof(pdata.links[i].mac)); > pdata.links[i].mac_count = sizeof(pdata.links[i].mac); > //printf("%f\n", samp.db); > } > > // Publish it > this->driver->Publish(this->addr, > > You would need to update this method in order to see the rest of the data on > the client side. If you do fix this please submit a patch to the tracker. > > Toby > > 2009/3/17 Serge Stinckwich <ser...@gm...> >> >> Hi all, >> i'm still trying to investigate my problem with Wifi models in stage ... >> I'm using Stage 2.1.1 & Player 2.1.2 under Mac OS X. I'm using the >> "simple" wifi model under stage. >> When i print the various values of links in model_wifi.cc file, >> everything is ok. For example, i got the default freq 2450 value. >> But on the other side, in my player client program, all the value are >> zeroed except the mac adress. >> Something happens during the transmission of wifi informations between >> the simulation engine and the client ... >> >> The following program always print 0 for signal quality and freq : >> >> #include <iostream> >> #include <libplayerc++/playerc++.h> >> >> int >> main(int argc, char *argv[]) >> { >> using namespace PlayerCc; >> >> PlayerClient robot("localhost"); >> Position2dProxy pp(&robot,0); >> WiFiProxy wp(&robot,0); >> >> for (int j=0; j<1000; j++) { >> robot.Read(); >> std::cout << wp << std::endl; >> for (int i=0; i<wp.GetLinkCount(); i++) { >> std::cout << "Signal Quality = " << wp.GetLinkQuality(i) <<std::endl; >> std::cout << "Signal Freq = " << wp.GetLinkFreq(i) << std::endl; >> std::cout << "IP = " << wp.GetLinkIP(i) << std::endl; >> } >> } >> } >> >> Best regards, >> -- >> Serge Stinckwich >> UMI UMMISCO 209 (IRD/UPMC), Hanoi, Vietnam >> Smalltalkers do: [:it | All with: Class, (And love: it)] >> http://doesnotunderstand.org/ >> >> >> ------------------------------------------------------------------------------ >> Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are >> powering Web 2.0 with engaging, cross-platform capabilities. Quickly and >> easily build your RIAs with Flex Builder, the Eclipse(TM)based development >> software that enables intelligent coding and step-through debugging. >> Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com >> _______________________________________________ >> Playerstage-users mailing list >> Pla...@li... >> https://lists.sourceforge.net/lists/listinfo/playerstage-users > > > > -- > This email is intended for the addressee only and may contain privileged > and/or confidential information > > ------------------------------------------------------------------------------ > Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are > powering Web 2.0 with engaging, cross-platform capabilities. Quickly and > easily build your RIAs with Flex Builder, the Eclipse(TM)based development > software that enables intelligent coding and step-through debugging. > Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com > _______________________________________________ > Playerstage-users mailing list > Pla...@li... > https://lists.sourceforge.net/lists/listinfo/playerstage-users > > -- Serge Stinckwich UMI UMMISCO 209 (IRD/UPMC), Hanoi, Vietnam Smalltalkers do: [:it | All with: Class, (And love: it)] http://doesnotunderstand.org/ |