b6be226e69
We can now directly compile arduino sketches (.pde) files. Arduino compatible analogWrite works now. But there is still a long way to go, serial I/O and timer stuff (delay, millis etc) currently don't work (not tested but I don't expect this to work). It can be used in an arduino sketch or in a normal contiki program. We get a PWM frequency of 490.2 Hz (a period of 2.040 ms), that's Arduino compatible. If you need different frequencies see native timer usage in examples/osd/pwm-example In a contiki program you have to call arduino_pwm_timer_init to initialize the timer before pwm works. The arduino sketch wrapper already does this. For running a sketch, see examples/osd/arduino-sketch |
||
---|---|---|
.. | ||
dev | ||
radio | ||
avr.c | ||
avrdef.h | ||
bootloader.c | ||
bootloader.h | ||
cc2420_spi.c | ||
hw_pwm_timer.c | ||
hw_timer.c | ||
hw_timer.h | ||
leds-arch.c | ||
Makefile.avr | ||
minileds.c | ||
mtarch.c | ||
mtarch.h | ||
rtimer-arch.c | ||
rtimer-arch.h | ||
slip_uart1.c | ||
spi.c | ||
watchdog.c |