Created
February 4, 2012 15:49
-
-
Save mherb/1738588 to your computer and use it in GitHub Desktop.
Homebrew Formula for a patched version of AVRdude to support auto-resetting Arduino boards for ArduinoISP programming (patch based on a suggestion from http://www.arduino.cc/playground/Code/MegaISP)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'formula' | |
class Inodude < Formula | |
url 'http://download.savannah.gnu.org/releases/avrdude/avrdude-5.11.1.tar.gz' | |
homepage 'http://savannah.nongnu.org/projects/avrdude/' | |
md5 '3a43e288cb32916703b6945e3f260df9' | |
depends_on 'libusb-compat' if ARGV.include? '--with-usb' | |
def patches | |
DATA | |
end | |
def options | |
[['--with-usb', 'Compile AVRDUDE with USB support.']] | |
end | |
def install | |
system "./configure", "--disable-dependency-tracking", "--prefix=#{prefix}", "--program-transform-name=s/avrdude/inodude/" | |
system "make" | |
system "make install" | |
end | |
end | |
__END__ | |
diff --git a/ser_posix.c b/ser_posix.c | |
index 2c9e84b..ab184f1 100644 | |
--- a/ser_posix.c | |
+++ b/ser_posix.c | |
@@ -284,6 +284,7 @@ static int ser_open(char * port, long baud, union filedescriptor *fdp) | |
close(fd); | |
return -1; | |
} | |
+ sleep(4); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment