unsigned long time = millis();
I would have posted the code but it is too long for the forum, thus the link to code.google.com above.
// speed for the comm port for talking with vixen, this is the comm// port on the FT232R breakout board.#define VIXEN_COM_SPEED 57600// speed for talking with the serial monitor in the IDE, this is the// comm port built into the ardunio with the USB port#define PC_COM_SPEED 115200
randomSeed( 614 );
if(waitForVixenHeader()) // we got the data header now read the channel data
If the ISR / digital I/O code is a bottleneck (I highly doubt it is) using "port manipulation" should allow you to speed it up. You would be able to manipulate eight bits / eight I/O pins with a few machine instructions.
I guess my next move is to truly hook this up and see what happens,
TICK_HALF_CYCLE * ( 12 / 255)
#define TICK_HALF_CYCLE 133333