问题标签 [contiki-process]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
contiki - 有没有办法设置计时器而不必将其放入 Contiki OS 的进程中?
是否可以在没有任何过程的情况下执行下面的代码?我需要一个超时而不用 Contiki 进程包围它。这可能吗?
java - Moving more than one node simultaneously in contiki-os (Mobility)
Do the lines need to be in time order? e.g.
#node time(s) x y
0 1.1 50.26 139.3
1 1.1 55.26 144.3
0 1.3 60.26 153.1
1 1.3 65.26 158.1 ...
I've only done single-node movement myself, but that's what I'd guess based on the error you're getting.
Hi everyone,
I have been able to incorporate the mobility plugin with Cooja and am able to make a single node traverse a particular path (via specifying the time instants and coordinate positions in the 'positions.dat' file).
I now wish to enable two or more nodes to move simultaneously along different paths.
Is this possible in Cooja? I have tried to write the contents of the positions.dat file in the following manner to achieve it but either only one node would move at a time or the 'java.lang.RuntimeException: Next event is in the past' error is encountered.
#node time(s) x y
0 1.1 50.26 139.3
0 1.3 60.26 153.1
0 1.5 70.26 174.1
0 1.7 50.26 139.3
1 1.1 55.26 144.3
1 1.3 65.26 158.1
1 1.5.26 179.1
1 1.7 85.26 144.3
Any information regarding the above would be highly appreciated.
contiki-process - 如何在节点之间共享数据
我创建了一个具有一个接收器和五个发送器节点的网络。我想与所有节点共享一个数据(一个整数值)。我希望节点能够更新和读取共享整数值。我使用指针并尝试在节点之间共享内存。但是,由于 contiki 使用 protothreads,因此引用内存中包含的数据不会为其他节点保存,而是仅在单个节点中更新。这是我尝试过的。
当 sink 调用 share(val) 时,打印结果为
如果 display() 被另一个节点调用,打印结果是
发送者和接收器的代码都在不同的文件中。
我希望在 *val 中分配的数字显示在两个打印件中。即一旦 sink 节点调用节点 A 的 share(val),接收到的值应该保存在内存中,以供其余 4 个节点访问。但是,我的代码分别更新了所有 5 个节点的内存。
我真的非常感谢您的帮助。谢谢
struct - 如何指向 dio 发送者节点
我试图指向 DIO 发送者节点。我的代码如下:
p = rpl_find_parent(dag, from); if(instance == NULL && p->suspiciousNode!=1) { printf("\nSuspicious node value %d \n",p->suspiciousNode ); }
suspeciousNode 值1
用于发送者节点,但在这里打印0
. 因此使p->suspiciousNode!=1
条件为真,这实际上是假的。我认为我没有使用正确的方式指向发件人节点。我怎样才能做到这一点?