aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/avrdude/avrdude-5.10/03-fix_auto_reset.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/avrdude/avrdude-5.10/03-fix_auto_reset.patch')
-rw-r--r--recipes/avrdude/avrdude-5.10/03-fix_auto_reset.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/recipes/avrdude/avrdude-5.10/03-fix_auto_reset.patch b/recipes/avrdude/avrdude-5.10/03-fix_auto_reset.patch
new file mode 100644
index 0000000000..71b29451d5
--- /dev/null
+++ b/recipes/avrdude/avrdude-5.10/03-fix_auto_reset.patch
@@ -0,0 +1,29 @@
+Author: Michal Ludvig <mludvig@logix.net.nz>
+Description: Fixed DTR on/off to make Arduino auto-reset work.
+Origin: http://svn.savannah.gnu.org/viewvc?view=rev&root=avrdude&revision=940
+Bug: http://savannah.nongnu.org/bugs/?29108
+Bug-Ubuntu: https://bugs.launchpad.net/arduino/+bug/529444
+
+=== modified file 'ser_posix.c'
+Index: avrdude/ser_posix.c
+===================================================================
+--- avrdude.orig/ser_posix.c 2010-03-22 17:28:07.000000000 -0400
++++ avrdude/ser_posix.c 2010-03-22 17:28:42.000000000 -0400
+@@ -230,13 +230,13 @@
+ }
+
+ if (is_on) {
+- /* Clear DTR and RTS */
+- ctl &= ~(TIOCM_DTR | TIOCM_RTS);
+- }
+- else {
+ /* Set DTR and RTS */
+ ctl |= (TIOCM_DTR | TIOCM_RTS);
+ }
++ else {
++ /* Clear DTR and RTS */
++ ctl &= ~(TIOCM_DTR | TIOCM_RTS);
++ }
+
+ r = ioctl(fdp->ifd, TIOCMSET, &ctl);
+ if (r < 0) {