osd-contiki/examples/osd/arduino-sketch
Ralf Schlatterbeck c6165a3bcf Refactor GENERIC_RESOURCE macro
Now callback functions get the URI of the request, this allows to use a
single resource for multiple different URIs.
The is_json flag is now gone for the to-string function, instead the
macro has an is_str flag. If set this automagically produces quotes
around the string for json output.
Now from-string functions can return an error-code, 0 for success, -1
for error.
2016-02-26 17:13:48 +01:00
..
arduino-example.c Add Arduino compatibility layer 2014-11-19 13:48:05 +01:00
flash.sh Add Arduino compatibility layer 2014-11-19 13:48:05 +01:00
led_pwm.h Factor/Fix generic resources 2015-01-21 15:41:21 +01:00
Makefile Factor/Fix generic resources 2015-01-21 15:41:21 +01:00
project-conf.h Add Arduino compatibility layer 2014-11-19 13:48:05 +01:00
README.md Add Arduino compatibility layer 2014-11-19 13:48:05 +01:00
resource_led_pwm.c Refactor GENERIC_RESOURCE macro 2016-02-26 17:13:48 +01:00
run.sh Fix run.sh scripts to use jumptable of bootloader 2016-02-19 17:32:09 +01:00
sketch.pde Factor/Fix generic resources 2015-01-21 15:41:21 +01:00

Arduino compatibility example

This example shows that it is now possible to re-use arduino sketches in Contiki. This example documents the necessary magic. Arduino specifies two routines, setup and loop. Before setup is called, the framework initializes hardware. In original Arduino, all this is done in a main function (in C). For contiki we define a process that does the same.

See the documentation file in apps/contiki-compat/README.md