bumpy-b / ctp-castalia

Automatically exported from code.google.com/p/ctp-castalia
0 stars 0 forks source link

make error on CtpCastalia-beta-1.01 #1

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.
2.
3.

What is the expected output? What do you see instead?
Unable to make

What version of the product are you using? On what operating system?
CtpCastalia-beta-1.01.zip + Castalia 3.1 + Omnet 4.1 on FEDORA 11

Please provide any additional information below.
[kiranpal@kiranpal Castalia-3.1]$ make
g++ -c -O2 -DNDEBUG=1 -fno-stack-protector -fPIC  -DXMLPARSER=libxml 
-DWITH_PARSIM -DWITH_NETBUILDER  -I. -Isrc -Isrc/helpStructures -Isrc/node 
-Isrc/node/application -Isrc/node/application/bridgeTest 
-Isrc/node/application/connectivityMap 
-Isrc/node/application/ctpTestingApplication 
-Isrc/node/application/simpleAggregation -Isrc/node/application/throughputTest 
-Isrc/node/application/valuePropagation -Isrc/node/application/valueReporting 
-Isrc/node/communication -Isrc/node/communication/mac 
-Isrc/node/communication/mac/baselineBanMac 
-Isrc/node/communication/mac/bypassMac -Isrc/node/communication/mac/cc2420Mac 
-Isrc/node/communication/mac/mac802154 -Isrc/node/communication/mac/tMac 
-Isrc/node/communication/mac/tunableMac -Isrc/node/communication/radio 
-Isrc/node/communication/routing -Isrc/node/communication/routing/bypassRouting 
-Isrc/node/communication/routing/ctpNoe 
-Isrc/node/communication/routing/ctpNoe/components 
-Isrc/node/communication/routing/multipathRingsRouting 
-Isrc/node/mobilityManager -Isrc/node/mobilityManager/lineMobilityManager 
-Isrc/node/mobilityManager/noMobilityManager -Isrc/node/resourceManager 
-Isrc/node/sensorManager -Isrc/physicalProcess 
-Isrc/physicalProcess/carsPhysicalProcess 
-Isrc/physicalProcess/customizablePhysicalProcess -Isrc/wirelessChannel 
-I/home/kiranpal/omnetpp-4.2b2/include -o 
out/gcc-release//src/node/application/ctpTestingApplication/CtpTestingApplicatio
n.o src/node/application/ctpTestingApplication/CtpTestingApplication.cc
src/node/application/ctpTestingApplication/CtpTestingApplication.cc: In member 
function ‘void CtpTestingApplication::update_packets_received(int, int)’:
src/node/application/ctpTestingApplication/CtpTestingApplication.cc:78: error: 
no matching function for call to ‘CtpTestingApplication::declareOutput(const 
char [17], int&)’
src/helpStructures/CastaliaModule.h:87: note: candidates are: void 
CastaliaModule::declareOutput(const char*)
src/node/application/ctpTestingApplication/CtpTestingApplication.cc: In member 
function ‘void CtpTestingApplication::update_ddr_per_sn(int, int)’:
src/node/application/ctpTestingApplication/CtpTestingApplication.cc:88: error: 
no matching function for call to ‘CtpTestingApplication::declareOutput(const 
char [9], int&)’
src/helpStructures/CastaliaModule.h:87: note: candidates are: void 
CastaliaModule::declareOutput(const char*)
make: *** 
[out/gcc-release//src/node/application/ctpTestingApplication/CtpTestingApplicati
on.o] Error 1

Original issue reported on code.google.com by kiranpal...@gmail.com on 10 Sep 2011 at 5:40

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
i am having the same issue on same configuration

Original comment by rajinder...@gmail.com on 15 Sep 2011 at 3:16

GoogleCodeExporter commented 9 years ago
I am facing the same problems,....
can we get any explanation about it, and how to solve the problem

Original comment by jordan.j...@yahoo.com on 21 Sep 2011 at 4:51

GoogleCodeExporter commented 9 years ago
In the code file CTPTestingApplication.cc, I have commented the line by adding 
following line 'COMMENT THIS LINE' as shown below. 

// This method updates the number of packets received by node 0 from other nodes
void CtpTestingApplication::update_packets_received(int srcID, int SN)
{
    map < int, packet_info >::iterator i = packet_info_table.find(srcID);
    if (i == packet_info_table.end());
//COMMENT THIS LINE //  declareOutput("Packets received", srcID);
    packet_info_table[srcID].packets_received[SN]++;
    if (packet_info_table[srcID].packets_received[SN] == 1)
        collectOutput("Packets received", srcID);
}

void CtpTestingApplication::update_ddr_per_sn(int srcID , int SN){
    map<int,int>::iterator i = packet_ddr_table.find(SN) ;
    if(i==packet_ddr_table.end()){
        trace()<<"New entry: "<<SN ;
//COMMENT THIS LINE //  declareOutput("My Stats",SN) ;
    }
    if(packet_info_table[srcID].packets_received[SN]==1){ //duplicate reception
        collectOutput("My Stats",SN,"Duplicates") ;
    }
    else {
        packet_info_table[srcID].packets_received[SN]++;
        packet_ddr_table[SN] += 1 ;
        collectOutput("My Stats",SN,"DDR") ;
    }
    trace()<<"Received for SN "<<SN<<": "<<packet_ddr_table[SN] ;
}

=================================
make is successful.Now proceeding further with CastaliaResults....

Original comment by kiranpal...@gmail.com on 27 Sep 2011 at 2:19

GoogleCodeExporter commented 9 years ago
Sorry for the late reply. I confirm, the compilation error is related to 
changes made to collection statistics between Castalia 3.0 and 3.1.
The solution of comment #4 is fine.
Note that ctp-castalia will not work on Castalia 3.2 due to some changes. An 
updated version already exist but has not been tested. It will be available by 
the end of October (sorry but I have my phd defense before :) ).

Original comment by ucolesa...@gmail.com on 29 Sep 2011 at 3:23

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago

Original comment by ucolesa...@gmail.com on 30 Sep 2011 at 10:26

GoogleCodeExporter commented 9 years ago
Ok here's what you need to do to get the released CTP code to work with 
Castalia 3.2 (or the upcoming 3.3)

in CtpTestingApplication.cc and CtpTestingApplication.h 
- replace ApplicationGenericDataPacket with ApplicationPacket
in CtpTestingApplication.cc
- comment out the whole update_packets_received() method
- delete   declareOutput("My Stats", SN) ; from the update_ddr_perSN() method
  and put declareOutput("My Stats") ;  at the startup() method

in mac/cc2420Mac/CC2420Mac.cc
- replace instances of getRoutingInteractionControl() with 
getNetMacInfoExchange()
- replace getMacInteractionControl() with getMacRadioInfoExchange()
- swap RSSI with LQI in the right hand side of the assignments (little bug in 
the original code)

Optional, depends on platform (I had to do it for my Mac OSX)
in mac/cc2420Mac/TosEnvironment.h  AND in 
routing/ctpNoe/components/TosEnvironment.h:79
- line 79 replace 0x100000000 with 0xffffffff

in routing/ctpNoe/components/CtpForwardingEngine.cc
- replace line 1080 netPkt->getNetMacInfoExchange().source = 
selfAddress.c_str() ; // ok
  with            netPkt->setSource(selfAddress.c_str()) ; // ok
- replace instances of getRoutingInteractionControl() with 
getNetMacInfoExchange()   (lines 213, 1053, 1081)

in routing/ctpNoe/components/CtpRoutingEngine.cc  AND 
routing/ctpNoe/components/DualBuffer.cc AND 
routing/ctpNoe/components/LinkEstimator.cc
- replace instances of getRoutingInteractionControl() with 
getNetMacInfoExchange() 

Original comment by bou...@gmail.com on 18 Oct 2011 at 10:28

GoogleCodeExporter commented 9 years ago
Please check the new CtpCastalia-beta-1.1 release in the download section. Now 
it supports Castalia 3.2.

Original comment by ucolesa...@gmail.com on 4 Jan 2012 at 1:44