Papabravo
Well-Known Member
Can any AVR expert explain why the TXD1(PD3) line of an ATmega128 is allowed to toggle multiple times (high-low-high) for several tens of milliseconds just prior to the rising edge of RESET from a power off condition? This does not happen with a manual (push button) external reset. It shows up on the terminal emulator as a BREAK condition which is a START Bit followed by a long string of zeros with no STOP bit which also generates a framing error.
Says me -- a processor should hold the configuration of its port pins in the default reset condition during RESET, until after RESET rising, when the firmware gets around to configuring the ports. Since the port configuration happens long after RESET rising my choice of pin configuration is not relevant and it is overridden as soon as I configure the serial port. But the damage has already been done.
I observed this multiple times with a logic analyzer, not a scope. We all know logic analyzers can lie an trick you into thinking that something is there when it is not. The best explanation I can come up with is that the pins are floating inputs prior to RESET and I'm consistently observing a predictable pattern of excursions on this line that looks to the terminal emulator like a BREAK condition.
Says me -- a processor should hold the configuration of its port pins in the default reset condition during RESET, until after RESET rising, when the firmware gets around to configuring the ports. Since the port configuration happens long after RESET rising my choice of pin configuration is not relevant and it is overridden as soon as I configure the serial port. But the damage has already been done.
I observed this multiple times with a logic analyzer, not a scope. We all know logic analyzers can lie an trick you into thinking that something is there when it is not. The best explanation I can come up with is that the pins are floating inputs prior to RESET and I'm consistently observing a predictable pattern of excursions on this line that looks to the terminal emulator like a BREAK condition.