Hello All ! Thank you for your help !
I try to install contiki on arduino Uno.
I did that :
Hi! You need to obtain a copy of the Contiki Arduino port and execute the commands below.
Cheers,
Nestor
# Clone contiki-arduino source code tree
git clone https://github.com/contiki/contiki-arduino
# COMPILING AND UPLOADING TO ARDUINO
# To compile the code, e.g., under examples/hello-world
make TARGET=arduino ARDUINO_MODEL=Duemilanove
# To generate hex image file
avr-objcopy hello-world.arduinoaCgYkiHX -j .text -j .data -O ihex hello-world.hex
# To program the Arduino
avrdude -D -p atmega328p -c arduino -P /dev/ttyUSB0 -b 57600 -Uflash:w:hello-world.hex
# To monitor the serial output
ttylog -V -d /dev/ttyUSB0 -b 115200
But before compiling, I added some lines to my contiki-arduino/platform/arduino/Makefile.arduino :
else ifeq ($(ARDUINO_MODEL), Uno) # ATmega168 @ 16MHz (5V)
# http://www.arduino.cc/en/Main/ArduinoBoardUno
AVR_MCU_CLOCK = 16
AVR_MCU_SPEED = 16000000UL
MCU = atmega328
USART_PORT = 0
But when using "make TARGET=arduino ARDUINO_MODEL=Uno", here's what I get :
make TARGET=arduino ARDUINO_MODEL=Uno
avr-gcc -DCONTIKI=1 -DCONTIKI_TARGET_ARDUINO=1 -Wall -mmcu=atmega328 -gdwarf-2 -I. -I../../core -I../../cpu/avr -I../../platform/arduino -DF_CPU=16000000UL -DMCU_MHZ=16 -DAUTO_CRC_PADDING=2 -DUSART_BAUD=USART_BAUD_9600 -DUSART_PORT=RS232_PORT_0 -Os -I. -I../../platform/arduino/. -I../../platform/arduino/apps -I../../platform/arduino/net -I../../platform/arduino/loader -I../../cpu/avr/. -I../../cpu/avr/dev -I../../core/dev -I../../core/lib -I../../core/net -I../../core/net/mac -I../../core/net/rime -I../../core/net/rpl -I../../core/sys -I../../core/cfs -I../../core/ctk -I../../core/lib/ctk -I../../core/loader -I../../core/. -MMD -c ../../core/net/rime/rimeaddr.c -o obj_arduino/rimeaddr.o
In file included from ../../platform/arduino/platform-conf.h:71,
from ../../platform/arduino/contiki-conf.h:49,
from ../../core/net/rime/rimeaddr.h:58,
from ../../core/net/rime/rimeaddr.c:46:
../../cpu/avr/dev/rs232.h:56:2: error: #error "Please implement a rs232 header for your MCU (or set the MCU type in contiki-conf.h)."
In file included from ../../platform/arduino/contiki-conf.h:49,
from ../../core/net/rime/rimeaddr.h:58,
from ../../core/net/rime/rimeaddr.c:46:
../../platform/arduino/platform-conf.h:77:3: error: #error "RS232 header was not included ?"
../../platform/arduino/platform-conf.h:86:3: error: #error "RS232 header was not included ?"
make: *** [obj_arduino/rimeaddr.o] Error 1
Any idea about how to solve this?
Thank you !
Kile