1.杂项
组件是新的,makefile保留了原来风格。新的make进行了封装,没有platform等,集成度较高。
源码目录介绍。
tep3.txt介绍。
PppRouter通过电脑连接边界路由,通过ppp和他连接,就可以连接烧写coap server的节点。
CoapPPP没有启动rf。
2.nesc基本概念
1)编程基本结构:
(1)configuration
configuration XXC
{
}
implementation{
}
configuration不一定有,因为有一个P的文件。
(2)module
module XXP @safe()
{
}
implementation{
}
(3)interface
连接平台
2)关键字
configuration对项目管理,类似于makefile,provides、uses、->、<-、=、.、as
@safe 对指针非法和数组越界进行检测,类似指针先判断、数组检查。
generic 类似static class
command/async command (call)
event//async event (signal)
task (post)
重点类型 rx_struct
atomic { }
3.Eclipse编程示例
import一下blink作为模板
example新建一个,不用写makefile
1)写BlinkC代码,注意编程习惯
2)传感器编程示例
(tinyos programing.pdf)
最后总结
By:霜月孤鸟
2016.2.16