Setup contiki toolchain in ubuntu 13.04

This shows how to setup the Contiki toolchain in a freshly installed Ubuntu 13.04.

1. Run this command in terminal so that the URLs point to the right repositories 
(older repos are moved to archive server):

    sudo sed -i -re 's/([a-z]{2}\.)?archive.ubuntu.com|security.ubuntu.com/old-releases.ubuntu.com/g' 
/etc/apt/sources.list

    sudo apt-get update

2. Install the following packages:

    sudo apt-get install build-essential binutils-msp430 gcc-msp430 msp430-libc 
binutils-avr gcc-avr gdb-avr avr-libc avrdude openjdk-7-jdk openjdk-7-jre ant libncurses5-dev doxygen git

This will allow you to cross-compile for MSP430- and AVR-platforms.

3. Clone the Contiki sources from Github:

     git clone --recursive git://github.com/contiki-os/contiki.git contiki

And you should be good to go.

4. You can test your setup by compiling and running the hello-world-example as follows:

    cd contiki/examples/hello-world
    make TARGET=native hello-world
    ./hello-world.native

The last command should result in an output like this:

    Contiki-2.6-584-g807293a started
    Rime started with address 2.1
    MAC nullmac RDC nullrdc NETWORK Rime
    Hello, world
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值