Follow-up Comment #26, patch #7559 (project avrdude):
_Personally_ I'd like to see something that is completely invariant to whether
a _real_ RS232 port/device is connected or a TTL serial adapter, so that it
doesn't matter if signal levels are inverted or not. As I had to find out,
there doesn't seem to be an easy way for the computer to know which is which.
It should always work. There should be comments that explain what is done and
why.
My previously proposed addition of the 'toggle' function would provide just
that, BUT a) I'm not capable of providing the necessary patches to
'ser_win32.c' b) it would also require changes to 'ser_posix.c' as well.
So what to do?
If the bootloader timeout is long enough (really don't know about all optiboot
versions for sure), 'arduino.c' could be modified as such:
------
// explanatory comments should go here...
serial_set_dtr_rts(&pgm->fd, 0);
usleep(50*1000);
serial_set_dtr_rts(&pgm->fd, 1);
usleep(50*1000);
serial_set_dtr_rts(&pgm->fd, 0);
usleep(50*1000);
serial_set_dtr_rts(&pgm->fd, 1);
usleep(50*1000);
------
This would provide at least one usable (5V/0V) transition for the reset
capacitor to be pulled in the right direction, regardless what 'HIGH' actually
means.
I could do some reliability testing on homebrew and a Diecimila board using
various bootloaders, but only on linux.
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/patch/?7559>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/
_______________________________________________
avrdude-dev mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/avrdude-dev