[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-chat] avrdude arduino failed to connect to mega 644
From: |
Peter Saunderson |
Subject: |
Re: [avr-chat] avrdude arduino failed to connect to mega 644 |
Date: |
Tue, 02 Jul 2013 19:40:53 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130623 Thunderbird/17.0.7 |
Hi Joerg,
Thanks for the link, I will look into it. I suspect that it will not
fix my problem since my problem is caused first by the additional delay
cause by any of the Arduino boards rebooting as a result of the USB
serial connection opening. A better solution would be to try to sync,
wait, try to sync, wait till the Arduino board has finished its reboot.
If I read the patch that you mention correctly the STK500v1 code will
only try the sync once and so the Arduino board will miss the sync
attempt because it is rebooting. The confusion with various attempts to
fix this issue is caused by the number of people who make either
hardware or other mods to the Arduino so that it does not reboot when
the USB serial connection is opened. I want to use a standard with no
mods Arduino board so I put a delay in the Arduino.c code that will then
pause the sync attempt till after the Arduino board has rebooted so I
dont propose any change to the STK500v1 code.
/* Set DTR and RTS back to high --- this is the bit that I think
makes the stock Arduino board reset */
serial_set_dtr_rts(&pgm->fd, 1);
/* Sleep to allow the Arduino board to reset --- delay by 1 or 2
second or more to allow the Arduino to complete its reset - crude but
effective quick fix! */
usleep(1000*1000);
As I mentioned above a better solution would be to try to sync, wait,
try to sync, wait till the Arduino board has finished its reboot but
this would require more code churn ...
On filling in the bug report I did try but it did not seem to allow me
to create a bug report without signing in.
Peter
Date: Tue, 2 Jul 2013 08:43:00 +0200 (MET DST)
From:address@hidden (Joerg Wunsch)
To:address@hidden
Subject: Re: [avr-chat] avrdude arduino failed to connect to mega 644
chip via a Mega 2560 running mega-isp sketch - BUG FIX
Message-ID:<address@hidden>
Content-Type: text/plain; charset=us-ascii
Peter Saunderson<address@hidden> wrote:
Using Port : /dev/ttyACM0
Using Programmer : arduino
Overriding Baud Rate : 9600
avrdude: Send: 0 [30] [20]
avrdude: Send: 0 [30] [20]
avrdude: Send: 0 [30] [20]
avrdude: ser_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
I'm curious, this patch recently came in to a FreeBSD problem report:
http://www.freebsd.org/cgi/query-pr.cgi?pr=179505;cat=usb&getpatch=1
I'm somewhat hesitant to touch that old STK500v1 code anymore (in
order to not break it), but does that patch perhaps solve your
problem?
I could not get registered onhttps://savannah.nongnu.org/ because
of a bug in the New User creation script so could someone please
apply this diff to the main avrdude branch for me?
I think you can file a bug report without logging in. The only
requirement then is that you should provide an email address so we can
contact you again.
-- cheers, Joerg .-.-. --... ...-- -.. . DL8DTL
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [avr-chat] avrdude arduino failed to connect to mega 644,
Peter Saunderson <=