<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://anrg.usc.edu/contiki/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Jason</id>
		<title>Contiki - User contributions [en]</title>
		<link rel="self" type="application/atom+xml" href="http://anrg.usc.edu/contiki/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Jason"/>
		<link rel="alternate" type="text/html" href="http://anrg.usc.edu/contiki/index.php/Special:Contributions/Jason"/>
		<updated>2026-05-17T19:43:09Z</updated>
		<subtitle>User contributions</subtitle>
		<generator>MediaWiki 1.26.2</generator>

	<entry>
		<id>http://anrg.usc.edu/contiki/index.php?title=Installation&amp;diff=1680</id>
		<title>Installation</title>
		<link rel="alternate" type="text/html" href="http://anrg.usc.edu/contiki/index.php?title=Installation&amp;diff=1680"/>
				<updated>2016-01-25T21:00:07Z</updated>
		
		<summary type="html">&lt;p&gt;Jason: /* Using Sourceforge repository */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
This guide covers the installation of ContikiOS 2.7.  You will need either a Linux-based operating system, or an operating system that supports [https://www.virtualbox.org/ VirtualBox] or [https://my.vmware.com/web/vmware/downloads VMWare Player].&lt;br /&gt;
&lt;br /&gt;
== You will learn ==&lt;br /&gt;
&lt;br /&gt;
This tutorial will take you through the steps for downloading and installing ContikiOS the following ways:&lt;br /&gt;
&lt;br /&gt;
* Download Instant Contiki [http://sourceforge.net/projects/contiki/files/Instant%20Contiki/]&lt;br /&gt;
* Download ContikiOS from Sourceforge repository [http://sourceforge.net/projects/contiki/files/latest/download]&lt;br /&gt;
* Clone ContikiOS from Github repository [https://github.com/contiki-os/contiki]&lt;br /&gt;
&lt;br /&gt;
=== Using Instant Contiki ===&lt;br /&gt;
&lt;br /&gt;
This is the easiest way of installing and using ContikiOS. You simply need to download Instant Contiki, which is a virtual machine created with all necessary toolchains and software for ContikiOS development.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Link to download Instant Contiki: [http://sourceforge.net/projects/contiki/files/Instant%20Contiki/]&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After downloading Instant Contiki you need also to download either VMWare Player or VirtualBox, if you are using Windows as your host OS. If you use MacOS X you should download VMWare Fusion, instead of VMWare Player.&lt;br /&gt;
&lt;br /&gt;
IMPORTANT: To login in to Instant Contiki: &amp;#039;&amp;#039;&amp;#039;username&amp;#039;&amp;#039;&amp;#039;: &amp;#039;&amp;#039;user&amp;#039;&amp;#039; &amp;#039;&amp;#039;&amp;#039;password&amp;#039;&amp;#039;&amp;#039;: &amp;#039;&amp;#039;user&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
=== Using Sourceforge repository ===&lt;br /&gt;
&lt;br /&gt;
This method requires an existing installation of a Linux-based operating system. The guide assumes you are using Ubuntu 12.04 but should still be useful for similar versions.&lt;br /&gt;
&lt;br /&gt;
Download contiki-2.7.zip from [http://downloads.sourceforge.net/project/contiki/Contiki/Contiki%202.7/contiki-2.7.zip http://downloads.sourceforge.net/project/contiki/Contiki/Contiki 2.7/contiki-2.7.zip]&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;wget http://downloads.sourceforge.net/project/contiki/Contiki/Contiki%202.7/contiki-2.7.zip&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Unzip the file. For the purposes of this guide, it is assumed that the file is unzipped into /home/user/&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;unzip contiki-2.7.zip&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Rename the folder from contiki-2.7 to contiki.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;mv contiki-2.7 contiki&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Install all the required packages for compiling and running ContikiOS. &lt;br /&gt;
&lt;br /&gt;
If you are using a MSP430-based platform (such as Tmote) you only need the following packages: &amp;#039;&amp;#039;binutils-msp430&amp;#039;&amp;#039;, &amp;#039;&amp;#039;gcc-msp430&amp;#039;&amp;#039;, &amp;#039;&amp;#039;msp430-libc&amp;#039;&amp;#039;, &amp;#039;&amp;#039;msp430mcu&amp;#039;&amp;#039; and &amp;#039;&amp;#039;mspdebug&amp;#039;&amp;#039;. If you intend to code for multiple platforms, you should also install the following tool chains for other micro-controller: &amp;#039;&amp;#039;binutils-avr&amp;#039;&amp;#039;, &amp;#039;&amp;#039;gcc-avr&amp;#039;&amp;#039;, &amp;#039;&amp;#039;gdb-avr&amp;#039;&amp;#039;, &amp;#039;&amp;#039;avr-libc&amp;#039;&amp;#039; and &amp;#039;&amp;#039;avrdude&amp;#039;&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
You can run the following command to install all packages for multiple platforms:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;sudo apt-get install build-essential binutils-msp430 gcc-msp430 msp430-libc msp430mcu mspdebug binutils-avr gcc-avr gdb-avr avr-libc avrdude openjdk-7-jdk openjdk-7-jre ant libncurses5-dev&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When working with a 64-bit virtual machine, you may run into problems with the `serialdump-linux` executable because it may have been compiled for 32-bit machines. Install the following package to fix this issue.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;sudo apt-get install lib32ncurses5&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You are done! You can now try to compile and run any example, such as [[Hello_World | Hello World]].&lt;br /&gt;
&lt;br /&gt;
=== Using Github repository ===&lt;br /&gt;
&lt;br /&gt;
This method also requires an existing installation of a Linux-based operating system. It is very similar to the previous installation method, but instead of downloading the source code you are going to &amp;#039;&amp;#039;clone&amp;#039;&amp;#039; it from the official Github repository. &lt;br /&gt;
&lt;br /&gt;
This method eases the update of your ContikiOS to the new releases.&lt;br /&gt;
&lt;br /&gt;
You need to &amp;#039;&amp;#039;clone&amp;#039;&amp;#039; the repository using the following command:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;git clone git://github.com/contiki-os/contiki.git contiki&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
After that you need to download all development tools as described in the previous installation method.&lt;br /&gt;
&lt;br /&gt;
[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
Edited by: Kwame, Pedro&lt;/div&gt;</summary>
		<author><name>Jason</name></author>	</entry>

	<entry>
		<id>http://anrg.usc.edu/contiki/index.php?title=Installation&amp;diff=1679</id>
		<title>Installation</title>
		<link rel="alternate" type="text/html" href="http://anrg.usc.edu/contiki/index.php?title=Installation&amp;diff=1679"/>
				<updated>2016-01-25T20:59:24Z</updated>
		
		<summary type="html">&lt;p&gt;Jason: /* Using Sourceforge repository */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
This guide covers the installation of ContikiOS 2.7.  You will need either a Linux-based operating system, or an operating system that supports [https://www.virtualbox.org/ VirtualBox] or [https://my.vmware.com/web/vmware/downloads VMWare Player].&lt;br /&gt;
&lt;br /&gt;
== You will learn ==&lt;br /&gt;
&lt;br /&gt;
This tutorial will take you through the steps for downloading and installing ContikiOS the following ways:&lt;br /&gt;
&lt;br /&gt;
* Download Instant Contiki [http://sourceforge.net/projects/contiki/files/Instant%20Contiki/]&lt;br /&gt;
* Download ContikiOS from Sourceforge repository [http://sourceforge.net/projects/contiki/files/latest/download]&lt;br /&gt;
* Clone ContikiOS from Github repository [https://github.com/contiki-os/contiki]&lt;br /&gt;
&lt;br /&gt;
=== Using Instant Contiki ===&lt;br /&gt;
&lt;br /&gt;
This is the easiest way of installing and using ContikiOS. You simply need to download Instant Contiki, which is a virtual machine created with all necessary toolchains and software for ContikiOS development.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Link to download Instant Contiki: [http://sourceforge.net/projects/contiki/files/Instant%20Contiki/]&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After downloading Instant Contiki you need also to download either VMWare Player or VirtualBox, if you are using Windows as your host OS. If you use MacOS X you should download VMWare Fusion, instead of VMWare Player.&lt;br /&gt;
&lt;br /&gt;
IMPORTANT: To login in to Instant Contiki: &amp;#039;&amp;#039;&amp;#039;username&amp;#039;&amp;#039;&amp;#039;: &amp;#039;&amp;#039;user&amp;#039;&amp;#039; &amp;#039;&amp;#039;&amp;#039;password&amp;#039;&amp;#039;&amp;#039;: &amp;#039;&amp;#039;user&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
=== Using Sourceforge repository ===&lt;br /&gt;
&lt;br /&gt;
This method requires an existing installation of a Linux-based operating system. The guide assumes you are using Ubuntu 12.04 but should still be useful for similar versions.&lt;br /&gt;
&lt;br /&gt;
Download contiki-2.7.zip from [http://downloads.sourceforge.net/project/contiki/Contiki/Contiki%202.7/contiki-2.7.zip http://downloads.sourceforge.net/project/contiki/Contiki/Contiki 2.7/contiki-2.7.zip]&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;wget http://downloads.sourceforge.net/project/contiki/Contiki/Contiki%202.7/contiki-2.7.zip&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Unzip the file. For the purposes of this guide, it is assumed that the file is unzipped into /home/user/&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;unzip contiki-2.7.zip&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Rename the folder from contiki-2.7 to contiki.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;mv contiki-2.7 contiki&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Install all the required packages for compiling and running ContikiOS. &lt;br /&gt;
&lt;br /&gt;
If you are using a MSP430-based platform (such as Tmote) you only need the following packages: &amp;#039;&amp;#039;binutils-msp430&amp;#039;&amp;#039;, &amp;#039;&amp;#039;gcc-msp430&amp;#039;&amp;#039;, &amp;#039;&amp;#039;msp430-libc&amp;#039;&amp;#039;, &amp;#039;&amp;#039;msp430mcu&amp;#039;&amp;#039; and &amp;#039;&amp;#039;mspdebug&amp;#039;&amp;#039;. If you intend to code for multiple platforms, you should also install the following tool chains for other micro-controller: &amp;#039;&amp;#039;binutils-avr&amp;#039;&amp;#039;, &amp;#039;&amp;#039;gcc-avr&amp;#039;&amp;#039;, &amp;#039;&amp;#039;gdb-avr&amp;#039;&amp;#039;, &amp;#039;&amp;#039;avr-libc&amp;#039;&amp;#039; and &amp;#039;&amp;#039;avrdude&amp;#039;&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
You can run the following command to install all packages for multiple platforms:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;sudo apt-get install build-essential binutils-msp430 gcc-msp430 msp430-libc msp430mcu mspdebug binutils-avr gcc-avr gdb-avr avr-libc avrdude openjdk-7-jdk openjdk-7-jre ant libncurses5-dev&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When working with a 64-bit virtual machine, you may run into problems with the `serialdump-linux` executable. Install the following package to fix the issue.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;sudo apt-get install lib32ncurses5&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You are done! You can now try to compile and run any example, such as [[Hello_World | Hello World]].&lt;br /&gt;
&lt;br /&gt;
=== Using Github repository ===&lt;br /&gt;
&lt;br /&gt;
This method also requires an existing installation of a Linux-based operating system. It is very similar to the previous installation method, but instead of downloading the source code you are going to &amp;#039;&amp;#039;clone&amp;#039;&amp;#039; it from the official Github repository. &lt;br /&gt;
&lt;br /&gt;
This method eases the update of your ContikiOS to the new releases.&lt;br /&gt;
&lt;br /&gt;
You need to &amp;#039;&amp;#039;clone&amp;#039;&amp;#039; the repository using the following command:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;git clone git://github.com/contiki-os/contiki.git contiki&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
After that you need to download all development tools as described in the previous installation method.&lt;br /&gt;
&lt;br /&gt;
[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
Edited by: Kwame, Pedro&lt;/div&gt;</summary>
		<author><name>Jason</name></author>	</entry>

	<entry>
		<id>http://anrg.usc.edu/contiki/index.php?title=Hello_World&amp;diff=1678</id>
		<title>Hello World</title>
		<link rel="alternate" type="text/html" href="http://anrg.usc.edu/contiki/index.php?title=Hello_World&amp;diff=1678"/>
				<updated>2016-01-25T20:57:11Z</updated>
		
		<summary type="html">&lt;p&gt;Jason: /* Hello World on the Tmote Sky! */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
This article is about the Hello World program, which is used to show the compilation and upload steps of a simple program on a Tmote Sky.&lt;br /&gt;
&lt;br /&gt;
== You will learn ==&lt;br /&gt;
&lt;br /&gt;
This tutorial teaches you how to compile a program on Contiki OS and also the most basic syntax of programming in ContikiOS.&lt;br /&gt;
&lt;br /&gt;
=== Step 1 ===&lt;br /&gt;
&lt;br /&gt;
Open the terminal window.&lt;br /&gt;
&lt;br /&gt;
=== Step 2 ===  &lt;br /&gt;
&lt;br /&gt;
In the terminal window, go to the hello world example folder.	&lt;br /&gt;
&lt;br /&gt;
:: &amp;lt;code&amp;gt;.cd /examples/hello-world&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Step 3=== &lt;br /&gt;
&lt;br /&gt;
Compile the code for the native platform (to be used when no mote is connected to the laptop.)&lt;br /&gt;
&lt;br /&gt;
:: &amp;lt;code&amp;gt;make TARGET=native&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Step 4 ===&lt;br /&gt;
&lt;br /&gt;
Once the compilation is over, run the Hello World program. &lt;br /&gt;
&lt;br /&gt;
:: &amp;lt;code&amp;gt;./hello-world.native&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Step 5 ===&lt;br /&gt;
&lt;br /&gt;
This will print the words &amp;quot;Hello, world&amp;quot; on the terminal window. The code will appear to hang, however, it is still running on Contiki, but not producing any output as the Hello World program is finished. Press Ctrl-C to quit.&lt;br /&gt;
&lt;br /&gt;
== Hello World on the Tmote Sky! ==&lt;br /&gt;
&lt;br /&gt;
=== Step 1 ===&lt;br /&gt;
&lt;br /&gt;
Using the opened terminal window compile and upload the Hello World program on the Tmote Sky.&lt;br /&gt;
&lt;br /&gt;
:: &amp;lt;code&amp;gt;make TARGET=sky savetarget&amp;lt;/code&amp;gt;    (This save the target for any future compilations)&lt;br /&gt;
:: &amp;lt;code&amp;gt;make hello-world.upload&amp;lt;/code&amp;gt;    (This will upload the code on the Tmote Sky)&lt;br /&gt;
:: &amp;lt;code&amp;gt;make login&amp;lt;/code&amp;gt;    (This will enable us to view the output. If permission error occurs, use sudo command at the beginning)&lt;br /&gt;
&lt;br /&gt;
=== Step 2 ===&lt;br /&gt;
&lt;br /&gt;
Press the reset button on the Tmote Sky. The following message will appear on the terminal window &lt;br /&gt;
&lt;br /&gt;
:: &amp;lt;code&amp;gt;Contiki 2.7 started. Node id is set to 3.&amp;lt;/code&amp;gt;&lt;br /&gt;
:: &amp;lt;code&amp;gt;Rime started with address 3.0&amp;lt;/code&amp;gt;&lt;br /&gt;
:: &amp;lt;code&amp;gt;MAC 00:12:ff:11:65:23:52:ed&amp;lt;/code&amp;gt;&lt;br /&gt;
:: &amp;lt;code&amp;gt;Starting &amp;#039;Hello world process&amp;#039;&amp;lt;/code&amp;gt;&lt;br /&gt;
:: &amp;lt;code&amp;gt;Hello, world&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
: The boot up code of Contiki-OS prints the first four lines whereas the last line is printed by the Hello World program.&lt;br /&gt;
&lt;br /&gt;
=== Step 3 ===&lt;br /&gt;
&lt;br /&gt;
Press Ctrl-C to quit.&lt;br /&gt;
&lt;br /&gt;
=== Try This ===&lt;br /&gt;
&lt;br /&gt;
You can upload and login with one line. You can also point the upload and/or login to a specific device path (use `dmesg` to find the device path of a mote after inserting it to your computer). Try the following command:&lt;br /&gt;
&lt;br /&gt;
:: &amp;lt;code&amp;gt;make TARGET=sky MOTES=/dev/ttyUSB0 hello-world.upload login&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;/div&gt;</summary>
		<author><name>Jason</name></author>	</entry>

	<entry>
		<id>http://anrg.usc.edu/contiki/index.php?title=Installation&amp;diff=1677</id>
		<title>Installation</title>
		<link rel="alternate" type="text/html" href="http://anrg.usc.edu/contiki/index.php?title=Installation&amp;diff=1677"/>
				<updated>2016-01-25T20:14:11Z</updated>
		
		<summary type="html">&lt;p&gt;Jason: /* Using Sourceforge repository */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
This guide covers the installation of ContikiOS 2.7.  You will need either a Linux-based operating system, or an operating system that supports [https://www.virtualbox.org/ VirtualBox] or [https://my.vmware.com/web/vmware/downloads VMWare Player].&lt;br /&gt;
&lt;br /&gt;
== You will learn ==&lt;br /&gt;
&lt;br /&gt;
This tutorial will take you through the steps for downloading and installing ContikiOS the following ways:&lt;br /&gt;
&lt;br /&gt;
* Download Instant Contiki [http://sourceforge.net/projects/contiki/files/Instant%20Contiki/]&lt;br /&gt;
* Download ContikiOS from Sourceforge repository [http://sourceforge.net/projects/contiki/files/latest/download]&lt;br /&gt;
* Clone ContikiOS from Github repository [https://github.com/contiki-os/contiki]&lt;br /&gt;
&lt;br /&gt;
=== Using Instant Contiki ===&lt;br /&gt;
&lt;br /&gt;
This is the easiest way of installing and using ContikiOS. You simply need to download Instant Contiki, which is a virtual machine created with all necessary toolchains and software for ContikiOS development.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Link to download Instant Contiki: [http://sourceforge.net/projects/contiki/files/Instant%20Contiki/]&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
After downloading Instant Contiki you need also to download either VMWare Player or VirtualBox, if you are using Windows as your host OS. If you use MacOS X you should download VMWare Fusion, instead of VMWare Player.&lt;br /&gt;
&lt;br /&gt;
IMPORTANT: To login in to Instant Contiki: &amp;#039;&amp;#039;&amp;#039;username&amp;#039;&amp;#039;&amp;#039;: &amp;#039;&amp;#039;user&amp;#039;&amp;#039; &amp;#039;&amp;#039;&amp;#039;password&amp;#039;&amp;#039;&amp;#039;: &amp;#039;&amp;#039;user&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
=== Using Sourceforge repository ===&lt;br /&gt;
&lt;br /&gt;
This method requires an existing installation of a Linux-based operating system. The guide assumes you are using Ubuntu 12.04 but should still be useful for similar versions.&lt;br /&gt;
&lt;br /&gt;
Download contiki-2.7.zip from [http://downloads.sourceforge.net/project/contiki/Contiki/Contiki%202.7/contiki-2.7.zip http://downloads.sourceforge.net/project/contiki/Contiki/Contiki 2.7/contiki-2.7.zip]&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;wget http://downloads.sourceforge.net/project/contiki/Contiki/Contiki%202.7/contiki-2.7.zip&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Unzip the file. For the purposes of this guide, it is assumed that the file is unzipped into /home/user/&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;unzip contiki-2.7.zip&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Rename the folder from contiki-2.7 to contiki.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;mv contiki-2.7 contiki&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Install all the required packages for compiling and running ContikiOS. &lt;br /&gt;
&lt;br /&gt;
If you are using a MSP430-based platform (such as Tmote) you only need the following packages: &amp;#039;&amp;#039;binutils-msp430&amp;#039;&amp;#039;, &amp;#039;&amp;#039;gcc-msp430&amp;#039;&amp;#039;, &amp;#039;&amp;#039;msp430-libc&amp;#039;&amp;#039;, &amp;#039;&amp;#039;msp430mcu&amp;#039;&amp;#039; and &amp;#039;&amp;#039;mspdebug&amp;#039;&amp;#039;. If you intend to code for multiple platforms, you should also install the following tool chains for other micro-controller: &amp;#039;&amp;#039;binutils-avr&amp;#039;&amp;#039;, &amp;#039;&amp;#039;gcc-avr&amp;#039;&amp;#039;, &amp;#039;&amp;#039;gdb-avr&amp;#039;&amp;#039;, &amp;#039;&amp;#039;avr-libc&amp;#039;&amp;#039; and &amp;#039;&amp;#039;avrdude&amp;#039;&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
You can run the following command to install all packages for multiple platforms:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;sudo apt-get install build-essential binutils-msp430 gcc-msp430 msp430-libc msp430mcu mspdebug binutils-avr gcc-avr gdb-avr avr-libc avrdude openjdk-7-jdk openjdk-7-jre ant libncurses5-dev&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You are done! You can now try to compile and run any example, such as [[Hello_World | Hello World]].&lt;br /&gt;
&lt;br /&gt;
=== Using Github repository ===&lt;br /&gt;
&lt;br /&gt;
This method also requires an existing installation of a Linux-based operating system. It is very similar to the previous installation method, but instead of downloading the source code you are going to &amp;#039;&amp;#039;clone&amp;#039;&amp;#039; it from the official Github repository. &lt;br /&gt;
&lt;br /&gt;
This method eases the update of your ContikiOS to the new releases.&lt;br /&gt;
&lt;br /&gt;
You need to &amp;#039;&amp;#039;clone&amp;#039;&amp;#039; the repository using the following command:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;git clone git://github.com/contiki-os/contiki.git contiki&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
After that you need to download all development tools as described in the previous installation method.&lt;br /&gt;
&lt;br /&gt;
[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
Edited by: Kwame, Pedro&lt;/div&gt;</summary>
		<author><name>Jason</name></author>	</entry>

	<entry>
		<id>http://anrg.usc.edu/contiki/index.php?title=Cooja_Simulator&amp;diff=1676</id>
		<title>Cooja Simulator</title>
		<link rel="alternate" type="text/html" href="http://anrg.usc.edu/contiki/index.php?title=Cooja_Simulator&amp;diff=1676"/>
				<updated>2016-01-22T04:59:41Z</updated>
		
		<summary type="html">&lt;p&gt;Jason: /* Running Cooja Simulator */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
This tutorial aims at introducing the Cooja Simulator and guiding the reader in a simple debugging exercise. We are going to work with Hello World example for the debugging process. You can also study the [[Hello_World]] tutorial to get familiar with its source code.&lt;br /&gt;
&lt;br /&gt;
== You Will Learn ==&lt;br /&gt;
&lt;br /&gt;
* How to run Cooja Simulator.&lt;br /&gt;
* How to debug an application using Cooja Simulator.&lt;br /&gt;
&lt;br /&gt;
== Relevant Directories ==&lt;br /&gt;
&lt;br /&gt;
* /contiki/tools/cooja/ - This folder has Cooja Simulator source code. You can run Cooja inside this directory.&lt;br /&gt;
* /contiki/examples/hello-world/ - This has the source code of Hello World example.&lt;br /&gt;
&lt;br /&gt;
== Running Cooja Simulator ==&lt;br /&gt;
&lt;br /&gt;
Cooja Simulator is a network simulator specifically designed for Wireless Sensor Networks. A summary of how Cooja executes binaries of different platforms (different types of nodes) and a few details about its structure can be found here:[https://github.com/contiki-os/contiki/wiki/An-Introduction-to-Cooja#Create_a_Hello_World_simulation].&lt;br /&gt;
&lt;br /&gt;
The simples way of running Cooja is executing it inside its own directory (we will see later how to execute Cooja from any working directory):&lt;br /&gt;
&lt;br /&gt;
 cd contiki/tools/cooja&lt;br /&gt;
 ant run&lt;br /&gt;
&lt;br /&gt;
We you execute Cooja the following window pops up.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-1.png|center|450px]]&lt;br /&gt;
&lt;br /&gt;
=== Creating a new simulation ===&lt;br /&gt;
&lt;br /&gt;
In the File menu you can start a new simulation or open an existing one. At this moment we will start a new one. You should select: File &amp;gt; New simulation... The following window should show up.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-2.png|center|350px]]&lt;br /&gt;
&lt;br /&gt;
In the &amp;#039;&amp;#039;Simulation name&amp;#039;&amp;#039; box you should enter an identifier for the new simulation, and in &amp;#039;&amp;#039;Advanced settings&amp;#039;&amp;#039; you can choose parameters of the simulation such as Radio medium, node startup delay and random seed generation. We are going to create a simulation called &amp;quot;First Cooja Sim&amp;quot;, as shown above.&lt;br /&gt;
&lt;br /&gt;
After creating a new simulation, Cooja&amp;#039;s window is filled with the main simulating tools, as shown in the next image.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-3.png|center|650px]]&lt;br /&gt;
&lt;br /&gt;
Here we briefly describe the functionalities of each tool:&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Network&amp;#039;&amp;#039;&amp;#039; - Shows the location of each node in the network. Can be used to visualize the status of each node, including LEDs, mote IDs, addresses, lof outputs, etc. Initially this window is empty and we need to populate it with our sensors.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Simulation Control&amp;#039;&amp;#039;&amp;#039; - This panel is used to Start, Pause, Reload or execute Steps of the simulation. It shows the time of execution and the speed of simulation. It means that we can run the events several times faster than it would take in real-time execution.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Notes&amp;#039;&amp;#039;&amp;#039; - This is a simple notepad for taking notes about the simulation.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Mote output&amp;#039;&amp;#039;&amp;#039; - Shows all output of serial interface of the nodes. It is possible to enable one window of Mote output for each node in the simulation.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Timeline&amp;#039;&amp;#039;&amp;#039; - Simulation timeline where messages and events such as channel change, LEDs change, log outputs, etc are shown.&lt;br /&gt;
&lt;br /&gt;
In addition to the default tools, it is possible to exhibit other tools such as &amp;#039;&amp;#039;&amp;#039;Breakpoints&amp;#039;&amp;#039;&amp;#039;, &amp;#039;&amp;#039;&amp;#039;Radio messages&amp;#039;&amp;#039;&amp;#039;, &amp;#039;&amp;#039;&amp;#039;Script editor&amp;#039;&amp;#039;&amp;#039;, &amp;#039;&amp;#039;&amp;#039;Buffer view&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;Mote duty cycle&amp;#039;&amp;#039;&amp;#039;, which can be enable in the &amp;#039;&amp;#039;Tools&amp;#039;&amp;#039; menu.&lt;br /&gt;
&lt;br /&gt;
=== Creating a new mote type ===&lt;br /&gt;
&lt;br /&gt;
You need to create a new mote type before starting any simulation. You can do this in the menu &amp;#039;&amp;#039;&amp;#039;Motes&amp;#039;&amp;#039;&amp;#039; &amp;gt; &amp;#039;&amp;#039;&amp;#039;Add motes&amp;#039;&amp;#039;&amp;#039; &amp;gt; &amp;#039;&amp;#039;&amp;#039;Create new motes type&amp;#039;&amp;#039;&amp;#039;. Let&amp;#039;s select &amp;#039;&amp;#039;&amp;#039;Sky mote&amp;#039;&amp;#039;&amp;#039; in order to create a mote of the same type as the used Tmote Sky.&lt;br /&gt;
&lt;br /&gt;
The window that shows up (see below) asks for the &amp;#039;&amp;#039;&amp;#039;Description&amp;#039;&amp;#039;&amp;#039; of the new mote type and the &amp;#039;&amp;#039;&amp;#039;Contiki process / Firmware&amp;#039;&amp;#039;&amp;#039;. You can name your mote type as &amp;#039;&amp;#039;First mote type&amp;#039;&amp;#039; and you can select the firmware that will be used during the simulation using the &amp;#039;&amp;#039;Browse&amp;#039;&amp;#039; button. After selecting the desired firmware you can test the compilation click the &amp;#039;&amp;#039;Compile&amp;#039;&amp;#039; button. In this example we will use the Hello World fimware, typically located at &amp;#039;&amp;#039;/contiki/examples/hello-world/hello-world.c&amp;#039;&amp;#039;. If the compiling process is successed, you will see a final message: &amp;#039;&amp;#039;LD hello-world.sky&amp;#039;&amp;#039; in the Compilation output tab.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-4.png|center|500px]]&lt;br /&gt;
&lt;br /&gt;
=== Adding motes and running the simulation ===&lt;br /&gt;
&lt;br /&gt;
After successfully compiling the firmware in the last step you should click on &amp;#039;&amp;#039;Create&amp;#039;&amp;#039; button (see figure above). A new mote type will be created and you will be able to add a few nodes of that same type in your simulation. You will see the window shown below, where you will be able to set the number of nodes that will be created and specify their positioning. In this example we are going to create 3 new nodes and they will have random positioning.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-5.png|center|350px]]&lt;br /&gt;
&lt;br /&gt;
=== Saving simulation file ===&lt;br /&gt;
&lt;br /&gt;
The simulation configuration and parameters such as number of nodes, type of nodes, firmware used, location of nodes, etc. can be stored in a file for future simulations. You can save your simulation configuration in &amp;#039;&amp;#039;File&amp;#039;&amp;#039; &amp;gt; &amp;#039;&amp;#039;Save simulation as...&amp;#039;&amp;#039;. The generated file has extension &amp;quot;.csc&amp;quot;. In the case of Hello World firmware there already exist a .csc file inside &amp;#039;&amp;#039;contiki/examples/hello-world&amp;#039;&amp;#039;, called hello-world-example.csc, which contains 2 nodes. We are going to use this pre-existing Cooja file to show how to debug an application.&lt;br /&gt;
&lt;br /&gt;
== Debugging with Cooja Simulator ==&lt;br /&gt;
&lt;br /&gt;
The easiest way to debug an application is to initially create a proper .csc simulation file, as described above. Then, inside the folder with the simulation file and all firmware source code (.c and .h files), you need to execute the following command.&lt;br /&gt;
&lt;br /&gt;
 make TARGET=cooja &amp;lt;simulation_file&amp;gt;.csc&lt;br /&gt;
&lt;br /&gt;
The command above will initialize Cooja Simulator loaded with the desired simulation file and will make Cooja recognized the source code of the application we intend to debug. In our case we are going to simulate and debug the Hello Worls application, so we need to go into /contiki/examples/hello-world folder and execute the command &amp;#039;&amp;#039;make TARGET=cooja hello-world-example.csc&amp;#039;&amp;#039;. The window shown below should be displayed.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-6.png|center|400px]]&lt;br /&gt;
&lt;br /&gt;
If we click on &amp;#039;&amp;#039;Start&amp;#039;&amp;#039; button the simulation begins and we can see both nodes printing out log messages on the &amp;#039;&amp;#039;&amp;#039;Mote output&amp;#039;&amp;#039;&amp;#039; window.&lt;br /&gt;
&lt;br /&gt;
All debugging tools can be accessed by right-clicking on a node and selecting &amp;#039;&amp;#039;Mote tools for Sky&amp;#039;&amp;#039; in the pop-up menu. The two main debugging tools that we are going to use are: &amp;#039;&amp;#039;Msp Code Watcher&amp;#039;&amp;#039; and &amp;#039;&amp;#039;Msp Stack Watcher&amp;#039;&amp;#039;. The first one can be used for analysing the source code of the application in a step-by-step fashion, with the possibility of setting breakpoints. The second tool is used to read and write the variables used throughout the execution.&lt;br /&gt;
&lt;br /&gt;
The &amp;#039;&amp;#039;Msp Code Watcher&amp;#039;&amp;#039; tool can be seen below. &lt;br /&gt;
&lt;br /&gt;
[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
Edited by: Pedro&lt;/div&gt;</summary>
		<author><name>Jason</name></author>	</entry>

	<entry>
		<id>http://anrg.usc.edu/contiki/index.php?title=Cooja_Simulator&amp;diff=1675</id>
		<title>Cooja Simulator</title>
		<link rel="alternate" type="text/html" href="http://anrg.usc.edu/contiki/index.php?title=Cooja_Simulator&amp;diff=1675"/>
				<updated>2016-01-22T04:57:29Z</updated>
		
		<summary type="html">&lt;p&gt;Jason: /* Running Cooja Simulator */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
This tutorial aims at introducing the Cooja Simulator and guiding the reader in a simple debugging exercise. We are going to work with Hello World example for the debugging process. You can also study the [[Hello_World]] tutorial to get familiar with its source code.&lt;br /&gt;
&lt;br /&gt;
== You Will Learn ==&lt;br /&gt;
&lt;br /&gt;
* How to run Cooja Simulator.&lt;br /&gt;
* How to debug an application using Cooja Simulator.&lt;br /&gt;
&lt;br /&gt;
== Relevant Directories ==&lt;br /&gt;
&lt;br /&gt;
* /contiki/tools/cooja/ - This folder has Cooja Simulator source code. You can run Cooja inside this directory.&lt;br /&gt;
* /contiki/examples/hello-world/ - This has the source code of Hello World example.&lt;br /&gt;
&lt;br /&gt;
== Running Cooja Simulator ==&lt;br /&gt;
&lt;br /&gt;
Cooja Simulator is a network simulator specifically designed for Wireless Sensor Networks. A summary of how Cooja executes binaries of different platforms (different types of nodes) and a few details about its structure can be found here:[https://github.com/contiki-os/contiki/wiki/An-Introduction-to-Cooja#Create_a_Hello_World_simulation].&lt;br /&gt;
&lt;br /&gt;
The simples way of running Cooja is executing it inside its own directory (we will see later how to execute Cooja from any working directory):&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install ant&lt;br /&gt;
 cd contiki/tools/cooja&lt;br /&gt;
 ant run&lt;br /&gt;
&lt;br /&gt;
We you execute Cooja the following window pops up.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-1.png|center|450px]]&lt;br /&gt;
&lt;br /&gt;
=== Creating a new simulation ===&lt;br /&gt;
&lt;br /&gt;
In the File menu you can start a new simulation or open an existing one. At this moment we will start a new one. You should select: File &amp;gt; New simulation... The following window should show up.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-2.png|center|350px]]&lt;br /&gt;
&lt;br /&gt;
In the &amp;#039;&amp;#039;Simulation name&amp;#039;&amp;#039; box you should enter an identifier for the new simulation, and in &amp;#039;&amp;#039;Advanced settings&amp;#039;&amp;#039; you can choose parameters of the simulation such as Radio medium, node startup delay and random seed generation. We are going to create a simulation called &amp;quot;First Cooja Sim&amp;quot;, as shown above.&lt;br /&gt;
&lt;br /&gt;
After creating a new simulation, Cooja&amp;#039;s window is filled with the main simulating tools, as shown in the next image.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-3.png|center|650px]]&lt;br /&gt;
&lt;br /&gt;
Here we briefly describe the functionalities of each tool:&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Network&amp;#039;&amp;#039;&amp;#039; - Shows the location of each node in the network. Can be used to visualize the status of each node, including LEDs, mote IDs, addresses, lof outputs, etc. Initially this window is empty and we need to populate it with our sensors.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Simulation Control&amp;#039;&amp;#039;&amp;#039; - This panel is used to Start, Pause, Reload or execute Steps of the simulation. It shows the time of execution and the speed of simulation. It means that we can run the events several times faster than it would take in real-time execution.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Notes&amp;#039;&amp;#039;&amp;#039; - This is a simple notepad for taking notes about the simulation.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Mote output&amp;#039;&amp;#039;&amp;#039; - Shows all output of serial interface of the nodes. It is possible to enable one window of Mote output for each node in the simulation.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Timeline&amp;#039;&amp;#039;&amp;#039; - Simulation timeline where messages and events such as channel change, LEDs change, log outputs, etc are shown.&lt;br /&gt;
&lt;br /&gt;
In addition to the default tools, it is possible to exhibit other tools such as &amp;#039;&amp;#039;&amp;#039;Breakpoints&amp;#039;&amp;#039;&amp;#039;, &amp;#039;&amp;#039;&amp;#039;Radio messages&amp;#039;&amp;#039;&amp;#039;, &amp;#039;&amp;#039;&amp;#039;Script editor&amp;#039;&amp;#039;&amp;#039;, &amp;#039;&amp;#039;&amp;#039;Buffer view&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;Mote duty cycle&amp;#039;&amp;#039;&amp;#039;, which can be enable in the &amp;#039;&amp;#039;Tools&amp;#039;&amp;#039; menu.&lt;br /&gt;
&lt;br /&gt;
=== Creating a new mote type ===&lt;br /&gt;
&lt;br /&gt;
You need to create a new mote type before starting any simulation. You can do this in the menu &amp;#039;&amp;#039;&amp;#039;Motes&amp;#039;&amp;#039;&amp;#039; &amp;gt; &amp;#039;&amp;#039;&amp;#039;Add motes&amp;#039;&amp;#039;&amp;#039; &amp;gt; &amp;#039;&amp;#039;&amp;#039;Create new motes type&amp;#039;&amp;#039;&amp;#039;. Let&amp;#039;s select &amp;#039;&amp;#039;&amp;#039;Sky mote&amp;#039;&amp;#039;&amp;#039; in order to create a mote of the same type as the used Tmote Sky.&lt;br /&gt;
&lt;br /&gt;
The window that shows up (see below) asks for the &amp;#039;&amp;#039;&amp;#039;Description&amp;#039;&amp;#039;&amp;#039; of the new mote type and the &amp;#039;&amp;#039;&amp;#039;Contiki process / Firmware&amp;#039;&amp;#039;&amp;#039;. You can name your mote type as &amp;#039;&amp;#039;First mote type&amp;#039;&amp;#039; and you can select the firmware that will be used during the simulation using the &amp;#039;&amp;#039;Browse&amp;#039;&amp;#039; button. After selecting the desired firmware you can test the compilation click the &amp;#039;&amp;#039;Compile&amp;#039;&amp;#039; button. In this example we will use the Hello World fimware, typically located at &amp;#039;&amp;#039;/contiki/examples/hello-world/hello-world.c&amp;#039;&amp;#039;. If the compiling process is successed, you will see a final message: &amp;#039;&amp;#039;LD hello-world.sky&amp;#039;&amp;#039; in the Compilation output tab.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-4.png|center|500px]]&lt;br /&gt;
&lt;br /&gt;
=== Adding motes and running the simulation ===&lt;br /&gt;
&lt;br /&gt;
After successfully compiling the firmware in the last step you should click on &amp;#039;&amp;#039;Create&amp;#039;&amp;#039; button (see figure above). A new mote type will be created and you will be able to add a few nodes of that same type in your simulation. You will see the window shown below, where you will be able to set the number of nodes that will be created and specify their positioning. In this example we are going to create 3 new nodes and they will have random positioning.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-5.png|center|350px]]&lt;br /&gt;
&lt;br /&gt;
=== Saving simulation file ===&lt;br /&gt;
&lt;br /&gt;
The simulation configuration and parameters such as number of nodes, type of nodes, firmware used, location of nodes, etc. can be stored in a file for future simulations. You can save your simulation configuration in &amp;#039;&amp;#039;File&amp;#039;&amp;#039; &amp;gt; &amp;#039;&amp;#039;Save simulation as...&amp;#039;&amp;#039;. The generated file has extension &amp;quot;.csc&amp;quot;. In the case of Hello World firmware there already exist a .csc file inside &amp;#039;&amp;#039;contiki/examples/hello-world&amp;#039;&amp;#039;, called hello-world-example.csc, which contains 2 nodes. We are going to use this pre-existing Cooja file to show how to debug an application.&lt;br /&gt;
&lt;br /&gt;
== Debugging with Cooja Simulator ==&lt;br /&gt;
&lt;br /&gt;
The easiest way to debug an application is to initially create a proper .csc simulation file, as described above. Then, inside the folder with the simulation file and all firmware source code (.c and .h files), you need to execute the following command.&lt;br /&gt;
&lt;br /&gt;
 make TARGET=cooja &amp;lt;simulation_file&amp;gt;.csc&lt;br /&gt;
&lt;br /&gt;
The command above will initialize Cooja Simulator loaded with the desired simulation file and will make Cooja recognized the source code of the application we intend to debug. In our case we are going to simulate and debug the Hello Worls application, so we need to go into /contiki/examples/hello-world folder and execute the command &amp;#039;&amp;#039;make TARGET=cooja hello-world-example.csc&amp;#039;&amp;#039;. The window shown below should be displayed.&lt;br /&gt;
&lt;br /&gt;
[[File:cooja-6.png|center|400px]]&lt;br /&gt;
&lt;br /&gt;
If we click on &amp;#039;&amp;#039;Start&amp;#039;&amp;#039; button the simulation begins and we can see both nodes printing out log messages on the &amp;#039;&amp;#039;&amp;#039;Mote output&amp;#039;&amp;#039;&amp;#039; window.&lt;br /&gt;
&lt;br /&gt;
All debugging tools can be accessed by right-clicking on a node and selecting &amp;#039;&amp;#039;Mote tools for Sky&amp;#039;&amp;#039; in the pop-up menu. The two main debugging tools that we are going to use are: &amp;#039;&amp;#039;Msp Code Watcher&amp;#039;&amp;#039; and &amp;#039;&amp;#039;Msp Stack Watcher&amp;#039;&amp;#039;. The first one can be used for analysing the source code of the application in a step-by-step fashion, with the possibility of setting breakpoints. The second tool is used to read and write the variables used throughout the execution.&lt;br /&gt;
&lt;br /&gt;
The &amp;#039;&amp;#039;Msp Code Watcher&amp;#039;&amp;#039; tool can be seen below. &lt;br /&gt;
&lt;br /&gt;
[[Contiki_tutorials | Back to Contiki Tutorials]]&lt;br /&gt;
&lt;br /&gt;
Edited by: Pedro&lt;/div&gt;</summary>
		<author><name>Jason</name></author>	</entry>

	<entry>
		<id>http://anrg.usc.edu/contiki/index.php?title=Team&amp;diff=413</id>
		<title>Team</title>
		<link rel="alternate" type="text/html" href="http://anrg.usc.edu/contiki/index.php?title=Team&amp;diff=413"/>
				<updated>2014-05-05T05:13:02Z</updated>
		
		<summary type="html">&lt;p&gt;Jason: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;#039;&amp;#039;&amp;#039;Suvil Deora&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Timothy Ferrell&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Lakshmi Phani Gadde&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
[http://www-scf.usc.edu/~pdasilva/ &amp;#039;&amp;#039;&amp;#039;Pedro Henrique Gomes&amp;#039;&amp;#039;&amp;#039;] is a Ph.D. student at the University of Southern California.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Leo Linsky&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Rahul Madduluri&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Nikhil Narang&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Deepanker Parikh&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Bhavana Srinivas&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Jason Tran&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
[http://www-scf.usc.edu/~kwamelaw/ &amp;#039;&amp;#039;&amp;#039;Kwame Wright&amp;#039;&amp;#039;&amp;#039;] is a Ph.D. student in the Autonomous Networks Research Group at the University of Southern California.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Shanpei Zhou&amp;#039;&amp;#039;&amp;#039;&lt;/div&gt;</summary>
		<author><name>Jason</name></author>	</entry>

	</feed>