I found very nice open source avr emulator (this one.) Since there is uart emulation implemented it can simulate Arduino.
I have some problems with the "board_simduino" example.
I hooked up virtual leds to port B (pins 8-13) - http://gitorious.org/~viroos/simavr/viroos-simduino-simavr/commit/bfaeac1e61f1d6678b3daab7fede9a783d01c098, and they work.
But serial connection looks broken. I can upload sketch (I added ,link=/dev/ttyUSB0
to socat command for that), but after that communication stops working. For example I can upload "physical pixel" sketch but I can't turn on leds. I tried to connect using serial monitor in buily in IDE and from pySerial. It looks like commends are being ignored.
Also in "blink" sketch in the main loop:
void loop()
{
digitalWrite(ledPin, HIGH); // set the LED on
delay(1000); // wait for a second
digitalWrite(ledPin, LOW); // set the LED off
delay(1000); // wait for a second
}"
I have to remove delay(1000);
command because they hang the emulator.
I will appreciate any help. Most important form me for now is uart fixing (run "physical pixel" sketch.)