OMNET++的使用(1)

俗话说:工欲善其事必先利其器。

应老板指点,决定做wsn网络的路由算法和存储算法方面的改进。

看了一篇vcp的论文,08年ieee的,仿真工具是用的OMNET++,其实本来要用ns-2的,可是比较了一下,OMNET++好像更容易上手。

工具只要会用即可,而且opensource的plugin越来越强大了。最终选择了OMnet++


应该是OMNET++是基于离散事件仿真的。

熟悉eclipse的人用起OMNET++是很容易上手的。

而且OMNET++4.0比起之前的版本有了很大的改变,不管是doc还是demo都做得很详细,里面还包括了很多eclipse快捷键的使用。。。可见叙述是淋漓尽致的。

如果只是用来仿真的话只看

即可。


研究了一个dyna的demo

整个工程研究下来基本上分为三个部分:

1.ned——network emulator design

2.msg——消息

3.c++代码——利用提供的api接口写的消息处理程序和路由算法、路由协议


从这些file就能感受到离散事件的意思,还有wsn是基于事件的。正好利于仿真。

相当于把c++代码放在指定的node里,每当msg到来的时候,input,process,output——>other node...



其他的还包括ini配置文件,有图形和代码界面。

ned doc是可以自动生成的并且可以自定义css格式,doxygen是个强大的家伙。这点用来做demo很好。

还有anf——analysis file,有很强的处理log的能力,用来截图做实验结果是很方便的。

而且ned是设计拓扑结构的,基本上都可以在图形界面上拖拽来设计网络。另外结合ini可以灵活的设置小型、大型的node数量。实现多种网络状态+一种网络设计的仿真实验,用起来应该很方面的。


另外是由eclipse改造来的,有很强大的plugin功能和配置功能。


大概了解了一下OMNET++的创建一个工程和工程结构,还有如何building,run。

还没有深入的了解如何编写一个有效的project,可是我想模仿demo来做应该不会很难把。


后天就要找boss签字了,现在还是赶紧写开题报告吧~




If you have some questions or ideas ,please feel free to contact me : )

thx.^^


QQ: 1623213673

MAIL: codingkid@qq.com


  • 1
    点赞
  • 5
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
This is a simulation of LEACH (Low-Energy Adaptive Clustering Hierarchy), a well-known cluster-based protocol for sensor networks with an extension to make it solar-aware. This simulation was created for the following paper: Thiemo Voigt, Hartmut Ritter, Jochen Schiller, Adam Dunkels, and Juan Alonso. Solar-aware Clustering in Wireless Sensor Networks. In Proceedings of the Ninth IEEE Symposium on Computers and Communications, June 2004. http://www.sics.se/~thiemo/iscc2004Final.pdf Abstract: "Energy conservation plays a crucial in wireless sensor networks since such networks are designed to be placed in hostile and non-accessible areas. While battery-driven sensors will run out of battery sooner or later, the use of renewable energy sources such as solar power or gravitation may extend the lifetime of a sensor network. We propose to utilize solar power in wireless sensor networks and extend LEACH, a well-known cluster-based protocol for sensor networks to become solar-aware. The presented simulation results show that making LEACH solar-aware significantly extends the lifetime of sensor networks." The code contains two directories: one is a distributed LEACH version, the other one a centralized where the base station (assumed to know everything) chooses the optimal cluster head. The "optimal" is in the code approximated via rules that include some kind of geopgraphical criteria among others. In solar.h you choose if you want to have solar turned on or not and also set some other parameters. To compile on Linux: opp_makemake -f -N make On Windows with Visual C++: opp_nmakemake -f -N nmake -f Makefile.vc Hope you find the model useful. Thiemo Voigt (thiemo@sics.se) (model packaged by Andras Varga)
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值