diff --git a/libavr b/libavr index c291f07..afebe8e 160000 --- a/libavr +++ b/libavr @@ -1 +1 @@ -Subproject commit c291f070d939aabc46d36fbd0d06d8ac82430436 +Subproject commit afebe8eb8f51b7d1674a9210bd0d698fbc3abd31 diff --git a/pureboot/README.md b/pureboot/README.md index 8732c7a..4f71304 100644 --- a/pureboot/README.md +++ b/pureboot/README.md @@ -429,6 +429,21 @@ SRAM, and through the same address space the register file and every I/O register. Reading an I/O register can have side effects (reading UDR clears its flags), which is the caller's business to know. +Reads are safe anywhere; **two small regions cannot be written without ending the +session,** because they are what the loader is standing on: + +- the **top of SRAM**, where its stack lives — a handful of bytes below RAMEND; +- on an **autobaud** build, the **two bytes at RAMSTART**: the measured bit + period, in `.noinit`, which is the whole of that loader's static RAM. Overwrite + it and its next reply is timed against garbage. On an ATtiny13A that is + `0x60..0x61`, and the symptom is a mangled prompt byte rather than any error — + the loader is fine, it simply is no longer speaking the agreed rate. + +Both are self-inflicted rather than defects, and a reset clears them. Note also +that `--poke` can write OSCCAL, which does take effect — but a session can only +survive a step or two of it before the clock walks the link out of the rate +autobaud locked to, and OSCCAL reverts on reset regardless. + Readouts come one fact per line: `--info` prints the device's version and signature and the geometry that follows from them, `--fuses` each fuse byte plus, on a boot-sectioned mega, its decoded meaning. Transfers that take wire time draw a transient progress bar on stderr