avrdude-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug #61624] [Feature request] Serial/UART UPDI programmers


From: Joerg Wunsch
Subject: Re: [bug #61624] [Feature request] Serial/UART UPDI programmers
Date: Wed, 15 Dec 2021 15:52:19 +0100

As Dawid Buchwald wrote:

> After some more investigation I concluded that there are actually
> different scenarios where Safemode is disabled, so I would really
> leave that for now.

Just as a side-note, and since there is also one large patch
regarding safemode which I decided to not apply before 6.4:

Safemode has been invented by a time when the parallel-port attached
programming dongle was the standard low-cost programming tool. The
parallel port's driving capabilities (if no buffers have been used)
were not very strong, so with a few 10 cm of wires, it could
occasionally happen that bits might have flipped during an ISP
transaction. If that flakiness accidentally flipped one of the fuse
bits, it could result in the AVR losing its clock source, rendering it
unusable for further ISP sessions.

Safemode was thus implemented to ensure fuses, at the end of an ISP
session, were just those they are supposed to be (i.e., fuses from the
beginning of the session including all requested alterations from -U
options), giving an option to reprogram them while the ISP session is
still active. (Fuses only take effect at a reset, so within the ISP
session, the clock remains what it's been at the start of the
session.)

Given that this kind of flakey programming dongles is now basically
history, I wonder whether it really makes sense to still have Safemode
active all the time. Other programming tools (like Atmel/Microchip
Studio) don't do something like that, and I haven't heard of
accidentally flipped fuse bits lately.

Instead of completely dropping the Safemode code, I'd propose that
after releasing 6.4, we might enable it only if so requested for any
particular programmer by avrdude.conf (and then enable it there for
all parport and serbb programmers).

Opinions?

-- 
cheers, Joerg               .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/
Never trust an operating system you don't have sources for. ;-)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]