Hello all,
I was hoping that someone can help me with understanding how to create and
modify interfaces.
I will use the following example with the TossimPacketModelC module in the
/tos/lib/tossim folder.
We have:
module TossimPacketModelC{
provides{ ...}
uses interface MyInterface;
}
implementation {
// Use MyInterface somewhere
}
MyInterface is defined in MyInterface.nc :
interface MyInterface {
command DoSomething();
command DoSomething2();
}
The MyInterface configuration file PacketEnergyEstimatorC.nc:
configuration MyInterfaceC {
provides interface MyInterface;
}
implementation {
components MyInterfaceP;
MyInterface = MyInterfaceP;
}
This is the implementation of MyInterfaceP.nc:
module MyInterfaceP {
provides interface MyInterface as MyInt;
}
implementation {
MyInt.DoSomething() { // Do something}
MyInt.DoSomething2() { // Do something else}
}
What more needs to be done to define an interface? Other files I look at seem
to have this structure, and nothing more.
When I try to do create a TOSSIM application I get the following error:
>>TossimPacketModelC.nc: MyIntreface.DoSomething not connected
>>TossimPacketModelC.nc: MyIntreface.DoSomething2() not connected
If you see anything wrong here, and if you have any suggestions on why this
might be causing a problem, please
let me know.
Thanks,
Ali Shareef
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help