contiki

Contiki mote type creation error when trying to use libtomcrypt library (rsa public key generation)

情到浓时终转凉″ 提交于 2019-12-06 07:27:40
I am trying to work on RSA public key generation using libtomcrypt library for my school project. But I am unable to load the library in Cooja using Contiki OS. I tried to compile the file I need into an object file and load it in .csc file. This is the error message I got: se.sics.cooja.GUI$SimulationCreationException: Mote type creation error: Error when creating corecomm instance: Lib1 at se.sics.cooja.GUI.loadSimulationConfig(GUI.java:3440) at se.sics.cooja.GUI.loadSimulationConfig(GUI.java:3352) at se.sics.cooja.GUI.doLoadConfig(GUI.java:2397) at se.sics.cooja.GUI$4.run(GUI.java:636) at

use of malloc in contiki programs

自古美人都是妖i 提交于 2019-12-06 03:21:37
Consider the following contiki program. #include<stdio.h> #include"contiki.h" #include <stdlib.h> static char *mem; static int x; /*---------------------------------------------------------------------------*/ PROCESS(test, "test"); AUTOSTART_PROCESSES(&test); /*---------------------------------------------------------------------------*/ PROCESS_THREAD(test, ev, data) { PROCESS_BEGIN(); printf("before malloc\n"); mem=(char*)malloc(10); for(x=0;x<10;x++) mem[x]=x+1; printf("after malloc\n"); PROCESS_END(); } when this program is compiled for native/z1/wismote/cooja it executes perfectly fine

Adding my own library to Contiki OS

倖福魔咒の 提交于 2019-12-05 08:26:37
I want to add some third party libraries to Contiki, but at the moment I can't. So I wanted to just test with a simple library. I wrote two files hello.c hello.h, in hello.c I have: printf(" Hello everbody, library call\n"); In hello.h I have: extern void print_hello(); I created hello.o using the command: msp430-gcc -mmcu=msp430f1611 hello.c -o hello.o I created an archive file: ar -cvq libhello.a hello.o I move to contiki, i write a simple program that calls hello.h to execute a function.I try to include hello.a using PROJECT LIBRARIES variable in the makefile, when i compile i get this :

contiki over the air programming

做~自己de王妃 提交于 2019-12-04 12:50:46
问题 I'm getting started with contiki on the sky mote through a project. I'm trying to get over the air programming to work right now. I've been looking through examples/sky-shell-exec and apps/shell/. I feel that I need some combination of the functionality that is provided through sky-shell-exec and possibly test-deluge or codeprop. However, reading through the code has lead to me some conceptual roadblocks concerning what code needs to be implemented and what code is already provided in order

contiki netstack数据收发结构

匆匆过客 提交于 2019-12-03 02:41:49
摘要 本文介绍了contiki netstack的MAC层以下数据收发层次结构,并讨论如何移植新的无线器件做为contiki的无线收发器。 正文 contiki netstack的数据收发层级 Radio:主要完成物理层无线数据的收发和控制 Framer: 完成对数据帧的打包和解析 RDC: radio duty cycling, 周期性访问radio,主要为了减少功耗 MAC: 数据链路层 Netstack: 网络协议栈 contiki内各层级的配置与用处 contiki可以在contiki-conf.h中进行配置 #define NETSTACK_CONF_NETWORK rime_driver //使用rime协议栈 #define NETSTACK_CONF_MAC nullmac_driver //不使用mac层协议 #define NETSTACK_CONF_RDC contikimac_driver //使用contikimac rdc #define NETSTACK_CONF_FRAMER framer_nrf24 //使用nrf24的frame结构 #define NETSTACK_CONF_RADIO nrf24_radio_driver //使用nrf24做为无线器件 NETSTACK_CONF_RADIO 定义contiki

ARCH linux建立contiki开发环境

天大地大妈咪最大 提交于 2019-12-02 00:21:40
安装 Instant Contiki运行环境 pacman -S base-devel git jdk8-openjdk jre8-openjdk apache-ant 2.从contiki分支下载源码文件。 https://github.com/JSLeo/contiki.git 或者从官方分支clone源码文件 https://github.com/contiki-os/contiki.git 3.下载并且安装msp430的编译工具 下载地址: http://simonduq.github.io/resources/mspgcc-4.7.2-compiled.tar.bz2 或者: aur/mspgcc-gcc-bin 20120406-1 (0) (0.00) ------------------- (预留:下载不下来的直接联系我) 4.将环境变量添加到系统的profile中。通过source更新系统变量. vi /etc/profile # Set our default path PATH="/usr/local/sbin:/usr/local/bin:/usr/bin:/opt/msp430/bin" export PATH 更新系统变量: source /etc/profile [leonard@Archlinux opt]$ echo $PATH /usr

Contiki移植—cfs-coffee 文件系统在pc上的验证

落花浮王杯 提交于 2019-12-02 00:21:27
最近移植coffee fs, 为了了解coffee细节,方便调试,因此在pc上编译coffee。 考虑到开虚拟机麻烦,费资源。因此安装Cygwin,在Cygwin下面编译。 1. Create cfs-coffee folder Create folder example-coffee/ in path contiki-2.5/examples/ Copy example-shell/ file to example-coffee/ Rename example-shell.c to example-coffee.c in the example-coffee/ 2. Modfiy Makefile Modify example-coffee/Makefile 1 CONTIKI_PROJECT = example - coffee 2 all : $(CONTIKI_PROJECT) 3 4 APPS = serial - shell 5 CONTIKI = . . / . . 6 7 include $(CONTIKI) / Makefile . include 8 Modfiy contiki-2.5/platform/native/Makefile.native 1 CONTIKI_TARGET_SOURCEFILES = contiki - main . c clock

Contiki Makefile结构

最后都变了- 提交于 2019-12-02 00:21:18
摘要 本文简要介绍了contiki的makefile结构和添加新平台的方法。 正文 1.CPU a. 建立需要支持的cpu目录contiki/cpu/cputype/ b.在../cputype/下放置以下文件: CPU相关的底层代码和驱动 contiki移植与CPU相关的代码,例如clock.c rtimer-arch.c 链接文件 makefile c. makefile文件解释: 文件名: Makefile.cputype CONTIKI_CPU=$(CONTIKI)/cpu/cputype CONTIKI_CPU_DIRS = . dev hal #定义与CPU有关的的文件夹 CONTIKI_TARGET_SOURCEFILES += CONTIKI_SOURCEFILES += $(CONTIKI_TARGET_SOURCEFILES) #定于与CPU有关的文件 #定义编译器 CC = arm-none-eabi-gcc LD = arm-none-eabi-gcc AS = arm-none-eabi-gcc NM = arm-none-eabi-nm AR = arm-none-eabi-ar OBJCOPY = arm-none-eabi-objcopy STRIP = arm-none-eabi-strip SIZE = arm-none-eabi-size

How to use external libraries and compile them along with a Contiki application

大城市里の小女人 提交于 2019-12-01 11:27:41
I want to be able to interface some sensors and send the sensor data to Thingspeak cloud using Contiki-OS. C libraries are available for interfacing sensors and the libthingspeak library is available for updating the feed on Thingspeak. I'm able to perform communication between two motes using the examples provided in examples/udp-ipv6 folder, setting one node as client and another as the server. How do I now include the required library code in my application and build it. What changes need to be made in the Makefile? I'm using cc2538 development kit. Use TARGET_LIBFILES variable. For example

How to use external libraries and compile them along with a Contiki application

浪尽此生 提交于 2019-12-01 07:22:53
问题 I want to be able to interface some sensors and send the sensor data to Thingspeak cloud using Contiki-OS. C libraries are available for interfacing sensors and the libthingspeak library is available for updating the feed on Thingspeak. I'm able to perform communication between two motes using the examples provided in examples/udp-ipv6 folder, setting one node as client and another as the server. How do I now include the required library code in my application and build it. What changes need