Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Arduino doesn't receive messages for 2 seconds after connection #12

austinbv opened this Issue Nov 17, 2012 · 4 comments


None yet
2 participants

austinbv commented Nov 17, 2012

I am not sure what causes it but the arduino seems to not get any messages for about 2 seconds after connecting.

Possible places to check

  • IO actually going out
  • board no reading IO
  • IO being off

vickash commented Feb 4, 2013

I realized just now that it's because most of the Arduino boards reset themselves when you connect via the built in serial to USB converter. Article from the Arduino site:


In short: a 10uF capacitor between RESET and GROUND will prevent it with the UNO. Most of the other boards require a 120 Ohm resistor between RESET and 5V. Leonardo doesn't auto reset by default.

I've tried the 10uF cap on my UNO and it works. Starts up quickly. It doesn't look like there's anything we can do about this in software though.


austinbv commented Feb 22, 2013

good find I thought it was something to do with IO flush for a while. I still think we need to make sure IO is always flushing to the board at execution time rather than buffering. http://www.ruby-doc.org/core-1.9.3/IO.html#method-i-sync is the solution


vickash commented Feb 26, 2013

Both TCPSocket and SerialPort have sync set to true by default. Maybe we should call fsync after each write as well?



austinbv commented Mar 30, 2013

that makes sense

@vickash vickash closed this Apr 1, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment