i using omnet without any framework. Is there a way to get the
position and to change them in simulation time?
best regards christian
Salutes
Marco
On 21 Gen, 16:49, Christian
but it dont get it work in the way i want. at first time i need the
location information from every model. then i want to calculate the
space between the moduls.
i test it with setDisplayString() but i dont get it work. could you
give me an exampel please?
best regards
christian
import inet.world.ChannelControl;
Network myNetwork {
// ...
submodules:
// ...
channelcontrol: ChannelControl
{
playgroundSizeX = 100;
playgroundSizeY = 100;
@display("p=10,10");
}
// ...
}
ChannelControl is made to check the wireless hosts comunication
ranges, and is an observer that mantains various informations about
hosts, position included.
I don't know if this module is exactly what you need, but you may
always extend it, or just take it as an example.
Now _every_ Host of which you want to check position (mind it, also
non moving hosts, you'll use NullMobility for those) must have a
Mobility and a NotificationBoard, like this:
import inet.base.NotificationBoard;
import inet.mobility.LinearMobility; // or whatever kind of
mobility you need
module MyHost
{
parameters:
// ...
submodules:
// ...
notificationBoard: NotificationBoard {
parameters:
@display("p=31,41");
}
mobility: LinearMobility {
parameters:
@display("p=32,103");
}
// ...
}
This way the MobilityModule in each host will provade movements and
animations, while the NotificationBoard triggers the right methods for
position changing in the ChannelControl. ChannelControl is a
singleton, so you can get a pointer to it by calling
ChannelControl::get() from any class.
Setted up this things all you have to do is make the ChannelControl to
fit your needs.
Hope it helped.
Marco
On 21 Gen, 23:40, Christian
Error in module (cCompundModule) myNetwork (id=1): Class
"ChannelControl" not found -- perhaps its code was not linked in or
the class wasn't registered with Register_Class() or in the case of
modules and channels, with Define_Module()/Define_Channel().
But i dont know why he dont finde the class from the inet framework.
i am using windows is there maybe a path entry to set?
best regards christain
On 22 Jan., 16:03, Marco Pattaro <mpatt...@gmail.com> wrote:
> Ok, I think I'm working with some similar situationusingINET.
> Suppose you have to check the distance between a WiFi Host and an AP,
> your Network should contain a ChannelControl module, like this
>
> importinet.world.ChannelControl;
>
> Network myNetwork {
> // ...
> submodules:
> // ...
> channelcontrol: ChannelControl
> {
> playgroundSizeX = 100;
> playgroundSizeY = 100;
> @display("p=10,10");
> }
> // ...
>
> }
>
> ChannelControl is made to check the wireless hosts comunication
> ranges, and is an observer that mantains various informations about
> hosts, position included.
> I don't know if this module is exactly what you need, but you may
> always extend it, or just take it as an example.
>
> Now _every_ Host of which you want to check position (mind it, also
> non moving hosts, you'll use NullMobility for those) must have a
> Mobility and a NotificationBoard, like this:
>
> importinet.base.NotificationBoard;
> importinet.mobility.LinearMobility; // or whatever kind of
> > > different mobility modules implemented inINETframework, I'll suggest
> > > you to try some of them before reinventing the wheel
>
> > > Salutes
>
> > > Marco
>
> > > On 21 Gen, 16:49, Christian
>
> > > <hildebrand.christian.om...@googlemail.com> wrote:
> > > > Hi,
>
> > > > iusingomnet without any framework. Is there a way to get the
I never used Oment on Windows but I'm pretty sure that it's the same,
you choose the project references from a list, so the IDE should hadle
Windows stile path in the Makefile.
cheers
Marco
i am testing what Peter said und selected befor the inet project in
the IDE, like Marco said.
In the IDE the Modules of INET are reachable. And the compilation
works. But if i am running the executable file it will not find the
source of inet and i dont know why. To testing if my framework not
work i load a new one and it dont work also :-(
In the .ini-file i add the following line: "ned-path = D:\Backup\OMNeT
\inetmanet\inetmanetinetmanetee48aae20100126\src;."
The i am starting and get the following messages:
OMNeT++ Discrete Event Simulation (C) 19922008 Andras Varga, OpenSim
Ltd.
Version: 4.0, build: 09031010709, edition: Academic Public License -
NOT FOR COMMERCIAL USE
See the license for distribution terms and warranty disclaimer
Setting up Tkenv...
Loading NED files from D:\Backup\OMNeT\inetmanet
\inetmanetinetmanetee48aae20100126\src: 313
Loading NED files from D:\Backup\OMNeT\RealFlexSVN\0031: 19
Loading images from ./bitmaps: : 0
Loading images from ./images: : 0 .svn/*: 0 .svn/propbase/*: 0 .svn/
props/*: 0 .svn/textbase/*: 0 .svn/tmp/*: 0 .svn/tmp/propbase/*:
0 .svn /tmp/props/*: 0 .svn/tmp/textbase/*: 0 background/*: 7
background/.svn/*: 0 background/.svn/propbase/*: 0 background/.svn/
props/*: 0 background/.svn/textbase/*: 0 background/.svn/tmp/*: 0
background/.svn/tmp/propbase/*: 0 background/.svn/tmp/props/*: 0
background/.svn/tmp/textbase/*: 0
Loading images from d:/Backup/OMNeT/omnetpp4.0srcwindows/omnetpp4.0/
images: *: 0 abstract/*: 90 background/*: 4 block/*: 320 device/*: 195
ma
ps/*: 9 misc/*: 70 msg/*: 55 old/*: 111 status/*: 28
Plugin path: D:\Backup\OMNeT\inet-manet\inetmanet-inetmanet-
ee48aae-2010-01-26\etc\plugins;./plugins
Loading tcl files from D:\Backup\OMNeT\inet-manet\inetmanet-inetmanet-
ee48aae-2010-01-26\etc\plugins: contextmenu.tcl
Recording event log to file `results\General-0.elog'...
But then he could not find the sources :-( but why?
Best regards
Christian
On 26 Jan., 11:54, Marco Pattaro <mpatt...@gmail.com> wrote:
> What do you mean when you say you "included it"? If you mean make you
> project reference toINETyou have to importINETas a project in the
> IDE, then select it from the menu Project->Properties->Project
> References of you project. Then, of course, you have to #inlcude the
> headers of every class you mean to use inside your C++ files, only if
> and when you really need to call methods fromINETclasses.
> I suggest you to use the IDE or else you'll have to edit the Makefile by
> yourself.
>
> I never used Oment on Windows but I'm pretty sure that it's the same,
> you choose the project references from a list, so the IDE should hadle
> Windows stile path in the Makefile.
>
> cheers
>
> Marco
>
> Christian wrote:
> > I tryed but how could i getinetworking in my projekt? i included it
> > and build an executable file but when i start this he sayed something
> > like this:
>
> > Error in module (cCompundModule) myNetwork (id=1): Class
> > "ChannelControl" not found -- perhaps its code was not linked in or
> > the class wasn't registered with Register_Class() or in the case of
> > modules and channels, with Define_Module()/Define_Channel().
>
> > But i dont know why he dont finde the class from theinetframework.
> > i amusingwindows is there maybe a path entry to set?
best regards
Christian
On 26 Jan., 11:54, Marco Pattaro <mpatt...@gmail.com> wrote:
> What do you mean when you say you "included it"? If you mean make you
> project reference toINETyou have to importINETas a project in the
> IDE, then select it from the menu Project->Properties->Project
> References of you project. Then, of course, you have to #inlcude the
> headers of every class you mean to use inside your C++ files, only if
> and when you really need to call methods fromINETclasses.
> I suggest you to use the IDE or else you'll have to edit the Makefile by
> yourself.
>
> I never used Oment on Windows but I'm pretty sure that it's the same,
> you choose the project references from a list, so the IDE should hadle
> Windows stile path in the Makefile.
>
> cheers
>
> Marco
>
> Christian wrote:
> > I tryed but how could i getinetworking in my projekt? i included it
> > and build an executable file but when i start this he sayed something
> > like this:
>
> > Error in module (cCompundModule) myNetwork (id=1): Class
> > "ChannelControl" not found -- perhaps its code was not linked in or
> > the class wasn't registered with Register_Class() or in the case of
> > modules and channels, with Define_Module()/Define_Channel().
>
> > But i dont know why he dont finde the class from theinetframework.
> > i amusingwindows is there maybe a path entry to set?
i think i am one step forward. I created for testing a virtualbox
(ubuntu and omnet) there i get starting my project with inet in the
following way:
./myProject -n $(path-to-inet-src-folder)
but wenn i want to do this in windows it will not work.
Could anybody tell me why it maybe not working in windows?
best regards
Christian
On 26 Jan., 11:54, Marco Pattaro <mpatt...@gmail.com> wrote:
i will use the framework. In Linux my project starts with:
./myProject -n $(path-to-inet-src-folder)
Now i want to start this project in windows. Here i have the MinGw-
Console. I set in /etc/profile the path to the framework and start the
Project in the same way:
./myProject.exe -n $(path-to-inet-src-folder)
But it did not work. I got the following error message:
Error in module (cCompundModule) myNetwork (id=1): Class
"ChannelControl" not found -- perhaps its code was not linked in or
the class wasn't registered with Register_Class() or in the case of
modules and channels, with Define_Module()/Define_Channel().
And i don't know why? Could Anybody help me?
best regards
christian
On 26 Jan., 11:54, Marco Pattaro <mpatt...@gmail.com> wrote:
--
You received this message because you are subscribed to the Google Groups "omnetpp" group.
To post to this group, send email to omn...@googlegroups.com.
To unsubscribe from this group, send email to omnetpp+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/omnetpp?hl=en.
in the virtualbox i activate the option inet in Properties -> C/C++
General -> Path and Symbols -> References.
Then i can start my project with ./myProject without adding any
parameters.
In windows does it work like you said in the best way "myProject.exe -
l inet".
best regards
christian
On 28 Jan., 14:41, Rudolf Hornig <rudolf.hor...@gmail.com> wrote:
> You have to load the libinet.dll otherwise it will not be loaded
> automatically. i.e. the code if the inet library is in that dll. If the
> shared lib is not loaded the framewrork will not find the classes belonging
> to the NED modules.
>
> Use the -l /full/path/to/inet on the command line.
> e.g. myProject -l c:\inet\src\libinet.dll
>
> -l c:\inet\src\inet
>
> will also work as the lib prefix and .dll suffix is automatically added.
>
> if you add c:\inet\src to the path then
> -l inet
>
> will also work.
>
> Honestly I don't know how the linux command worked without that option.
>
> Rudolf
>
> On Thu, Jan 28, 2010 at 1:55 PM, Christian <
>
> > omnetpp+u...@googlegroups.com<omnetpp%2Bunsu...@googlegroups.com>
To unsubscribe from this group, send email to omnetpp+u...@googlegroups.com.