Professional Documents
Culture Documents
Contikseminar1 140818182506 Phpapp01
Contikseminar1 140818182506 Phpapp01
Contikseminar1 140818182506 Phpapp01
Source OS for
the Internet of
Things
Why
Choose
Contiki?
The
Contiki
Operatin
g System
Get Started
with Contiki
Firstly
https://
my.vmware.com/web/vmware/free#deskto
p_end_user_computing/vmware_player/6
_0
Register and reboot
Boot
Ubuntu
Log in
Step 2: Start
Cooja
Open a
terminal
window
Start Cooja by
Start
Cooja
Running
Cooja
Cooja UI
Creating
Simulation
Create New Simulation:
Network
window(mot
es)
Simulation
Window
Timeline
Window->all
communication
s
Networkwindow
-Top left
-shows all motes in the
simulated area
Timeline window
Simulation
windows
Noteswindow
Simulation control
Add mote
to the
interface
Add mote
to the
interface
Simulation
window
Step 4
Run Contiki on
hardware
Platform
porting
cd contiki/examples/FOLDER/
Then upload the compiled firmware to the
hardware
Then make login
To access the burnt firmware on the device
Hi.c file
MakeFile
./hi.nativ
e
Upload Contiki to
the hardware
-in this case we
have no
connected
hardware
Connection
prob.
Platform in
contiki
Contiki
platforms
Example of
contiki
system(Tmo
te Sky
platform)
Example
of contiki
system(T
mote Sky
platform)
Blink
Application
example
-Code
explanation
-Cooja
runnin
-video
-Code
Blink
example
code
PROCESS (
strname
name,
)
Code
explanation
Declare a process.
PROCESS(blink_process, "Blink");
AUTOSTART_PROCESSES(&blink_proc
ess);
ROCESS_THREAD(name,
ev,data )
Code
detail
PROCESS_EXITHANDLER(handler )
PROCESS_BEGIN(
,PROCESS_END()
etimer et;
Code
explanation
PROCESS_WAIT_EVENT_UNTIL(c)
Code
detail
leds_on(LEDS_ALL);
On the LEDS
leds_off(LEDS_ALL);
LED API
#define
#define
#define
#define
LEDS_GREEN
LEDS_YELLOW
LEDS_RED
LEDS_ALL
1
2
4
7
Cooja capture
Youtube
Demo
http://www.youtube.com/watch?
v=9WohGp8udOQ
APIs
ESB
platform
sensors
Sensor
functions
PROCESS_BEGIN()
PROCESS_END()
process
PROCESS_YIELD()
PROCESS_YIELD_UNTIL(c)
PROCESS_WAIT_UNTIL(c)
PROCESS_EXIT()
PROCESS_PAUSE()
LED
functions
Beeper
functions
Timer
functions
-generates an
event when the
timer expires a
-call a function
when the timer
expires
-have to be
actively queried
to check when
they have
expired
etimer_expired
()
etimer_reset
etimer_set()
etimer_restart(
)
ctimer_expire
d()
ctimer_reset
ctimer_set()
ctimer_restar
t()
timer_expired
()
timer_reset
timer_set()
timer_restart
()
Sky websense
Light and temperatur sensor web demo
Border
router setup
Steps
Router: http://
[aaaa::0212:7401:0001:0101]/
Node 2: http://
[aaaa::0212:7402:0002:0202]/
tunslip6
output
Websense
code
details
Define processes
Opens the tcp server socket which defined in
httpd.c
Websense
code
details
Review
Question
Question
Questions
What is COOJA?
Question
http://www.contiki-os.org/start.html
Reference
s
http://virtualsense.googlecode.com/git/VirtualSense/examples
/rest-example/README
http://www.wolfe.id.au/2014/03/02/configuring-asimple-ipv6-network/
http://contiki-os.blogspot.kr/
http://people.inf.ethz.ch/mkovatsc/wiki/general:co
ntiki:webserver