-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathNodeC.nc
More file actions
62 lines (44 loc) · 1.23 KB
/
NodeC.nc
File metadata and controls
62 lines (44 loc) · 1.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
/**
* ANDES Lab - University of California, Merced
* This class provides the basic functions of a network node.
*
* @author UCM ANDES Lab
* @date 2013/09/03
*
*/
#include <Timer.h>
#include "includes/CommandMsg.h"
#include "includes/packet.h"
configuration NodeC{
}
implementation {
components MainC;
components Node;
components new AMReceiverC(AM_PACK) as GeneralReceive;
Node -> MainC.Boot;
Node.Receive -> GeneralReceive;
components ActiveMessageC;
Node.AMControl -> ActiveMessageC;
components new SimpleSendC(AM_PACK);
Node.Sender -> SimpleSendC;
components CommandHandlerC;
Node.CommandHandler -> CommandHandlerC;
//project 1
components new TimerMilliC() as t0; //new timer wired to TOS built in timer
//Node.projTimer -> t0;
components RandomC as r;
Node.rand -> r;
//flooding module connected
// components FloodingC;
// Node.Flooding -> FloodingC;
//Project 2
//DVR Componenet
//will use :
//DV componenent [?]
//Routing Table Componenet [?]
//not sure if should split into different modules or all in one
components dvrC;
Node.dvr -> dvrC;
components NeighborC;
Node.Neighbor -> NeighborC;
}