Added Breadbox64 to the Atari Makefile (now that I ported BB64 to that target). This...
[contiki-2.x.git] / README-EXAMPLES
blob783b8a505487f71de655fe5f024492f25008ceda
1 The examples/ directory contains a few examples that will help you get
2 started with Contiki.
4 To run the example programs, you need either to be running Linux or
5 FreeBSD (or any other *nix-type system), or install Cygwin if you are
6 running Microsoft Windows (http://www.cygwin.com/). As a minimum you
7 will need to have the gcc C compiler installed. To run the examples in
8 the 'netsim' target, you need to have GTK 1.x development libraries
9 installed. These are usually called 'gtk-devel', 'libgtk1-devel' or
10 similar in your Linux software installation programs.
12 compile-platforms/
14   A test script that compiles Contiki for a number of platforms and
15   reports any errors found during the build.
17 email/
19   An email program supporting SMTP. It can be compiled and run in the
20   'win32' target by typing the following commands:
22     cd examples/email
23     make
24     ./email-client.win32
26   Most likely you'll have to adjust the TCP/IP values set in main() in
27   platform/win32/contiki-main.c to match your needs.
29   Please consult cpu/native/net/README-WPCAP as well.
31 esb/
33   A set of demo applications for the ESB board.
35 hello-world/
37   A really simple Contiki program that shows how to write Contiki
38   programs. To compile and test the program, go into the hello-world
39   directory:
41     cd examples/hello-world
43   Run the 'make' command.
45     make
47   This will compile the hello-world program in the 'native' target.
48   This causes the entire Contiki operating system and the hello-world
49   application to be compiled into a single program that can be run by
50   typing the following command:
52     ./hello-world.native
54   This will print out the following text:
56     Contiki initiated, now starting process scheduling
57     Hello, world
59   The program will then appear to hang, and must be stopped by
60   pressing the C key while holding down the Control key.
62 irc/
64   An IRC client. It can be compiled and run in the 'win32' target by
65   typing the following commands:
67     cd examples/irc
68     make
69     ./irc-client.win32
71   Most likely you'll have to adjust the TCP/IP values set in main() in
72   platform/win32/contiki-main.c to match your needs.
74   Please consult cpu/native/net/README-WPCAP as well.
76 multi-threading/
78   A quite simple demonstration of the Contiki multi-threading library
79   employing two worker threads each running a recursive function. It
80   can be compiled and run in the 'native' target by typing the
81   following commands:
83     cd examples/multi-threading
84     make
85     ./multi-threading.native
87 rime/
89   Contains a set of examples on how to use the Rime communications
90   stack. To run those examples in the 'netsim' target (a very simple
91   Contiki network simulator), compile the programs with:
93     make TARGET=netsim
95   You will need to have GTK 1.x development libraries installed.
97   Run the different programs:
98   
99     ./test-abc.netsim
100     ./test-meshroute.netsim
101     ./test-rudolph0.netsim
102     ./test-rudolph1.netsim
103     ./test-treeroute.netsim
104     ./test-trickle.netsim
106   Most of the examples requires you to click with the middle mouse
107   button on one of the simulated nodes for something to happen.
109 sky/
111   Examples inteded for running on the Tmote Sky board. To compile
112   those, you need to have msp430-gcc (the gcc C compiler for the
113   MSP430 microcontroller) installed.
115   The follwing programs are included:
117     blink.c          A simple program that blinks the on-board LEDs
118     sky-collect.c    Collects sensor data and energy profile values
119                      to a sink. Press the "user" button on the Tmote
120                      Sky that is connected to the PC to make the node a
121                      sink.
122     test-button.c    Toggles the LEDs when the button is pressed.
123     test-cfs.c       Tests the 1 mb flash memory of the Tmote Sky
125 telnet-server/
127   A simple TCP telnet server with a simple command shell. It can be
128   compiled and run in the 'minimal-net' target by typing the following
129   commands:
131     cd examples/telnet-server
132     make
133     ./telnet-server.minimal-net
134     
135   Most likely you'll have to adjust the TCP/IP values set in main() in
136   platform/minimal-net/contiki-main.c to match your needs.
137   
138   Please consult cpu/native/net/README-WPCAP as well if you are running
139   Microsoft Windows.
141 webbrowser/
143   A text mode web browser supporting links and forms. It can be compiled
144   and run in the 'win32' target by typing the following commands:
146     cd examples/webbrowser
147     make
148     ./webbrowser.win32
150   Most likely you'll have to adjust the TCP/IP values set in main() in
151   platform/win32/contiki-main.c to match your needs.
153   Please consult cpu/native/net/README-WPCAP as well.
155 webserver/
157   A web server supporting dynamic content creation using "scripts" which
158   are actually compiled-in C-functions. It can be compiled and run in the
159   'minimal-net' target by typing the following commands:
161     cd examples/webserver
162     make
163     ./webserver-example.minimal-net
165   As an alternative to the static and dynamic compiled-in content the web
166   server can instead support "external" static-only content loaded from
167   any storage supported by the 'Contiki File System' (CFS) interface. To
168   compile it in the 'minimal-net' target and have it load files from disk
169   use the following command:
171     make HTTPD-CFS=1
173   Most likely you'll have to adjust the TCP/IP values set in main() in
174   platform/minimal-net/contiki-main.c to match your needs.
176   Please consult cpu/native/net/README-WPCAP as well if you are running
177   Microsoft Windows.
179 wget/
181   A command line program that retrieves files from web servers and saves
182   them using the 'Contiki File System' (CFS). It can be compiled and run
183   in the 'minimal-net' target by typing the following commands:
185     cd examples/wget
186     make
187     ./wget.minimal-net
189   Most likely you'll have to adjust the TCP/IP values set in main() in
190   platform/minimal-net/contiki-main.c to match your needs.
192   Please consult cpu/native/net/README-WPCAP as well if you are running
193   Microsoft Windows.