To store a small state record or maintenance counter in the Epson RX-8571NB, start with its split register map. The manual lists 07h as a separate RAM byte and 10h–1Fh as the contiguous user area. Alarm, timer, and control registers lie between them. A continuous write from 07h does not put the following bytes in user RAM. Check the address range, startup delay, and data validity before assigning application storage.
Where are the 128 contiguous bits?
Epson's ETM29E-02 register map lists sixteen eight-bit locations from 10h through 1Fh. The product brief also identifies 128 bits of user SRAM. Text in a block diagram does not consistently pair the byte and bit counts. For write boundaries, use the register map and controlled interpretation for the exact module instead of inferring length from the block diagram. Treat 07h as a separate readable and writable resource, not an extra byte appended to the contiguous area.
Addresses 08h through 0Fh hold alarm, timer, and extension, flag, or control functions. Check the applicable bit definitions for write restrictions and side effects. There is no need to write arbitrary values into those addresses to test a boundary. Use the address map and a noninvasive bus trace, or validate erroneous requests first on a simulated device. Do not change an installed unit's working alarm schedule merely to check its user area.
Internal SRAM is not equivalent to nonvolatile storage. The manual specifies a RAM access delay after initial power-up from 0 V and requires initialization when VLF indicates invalid state. Check power and status before validating application data. Test valid backup power, a drop below retention conditions, and a fresh power-up from zero separately. A single observed retention does not prove that data survives every outage. Critical data that must outlast complete power loss needs suitable nonvolatile storage.
What would five bytes starting at 07h touch?
Consider an address calculation, not a write to perform on a device. With sequential address increment, five bytes starting at 07h would go to 07h, 08h, 09h, 0Ah, and 0Bh. Only the first is the standalone RAM byte. The next three are alarm registers, and the last is in the timer area. Some written bits may be reserved while others can affect functions. A bus acknowledgement does not mean the application record was stored correctly. The fix is not to disable alarms and keep writing those addresses. Move the payload into the contiguous user area.
Twelve bytes starting at 10h end at 1Bh and leave four bytes in 10h–1Fh. If an application structure grows to seventeen bytes, the contiguous block still holds sixteen. Using 07h as a seventeenth byte requires a separate transaction and its own consistency handling across power loss or preemption. Do not treat the two ranges as one atomic record merely to save layout space. Budget separately for any commit marker, version, and integrity check.
Validate the start before calculating the ending address and prevent offset and length conversions from wrapping. Limit the driver to approved windows. Treat a zero-length operation as a no-op or reject it explicitly so the last-address calculation cannot underflow. Expose 07h through a separate one-byte interface instead of giving the application an arbitrary starting address. Test both reads and writes and verify that rejection happens before any bus transaction.
How do you verify startup timing and the stored record?
For initial power-up from 0 V, the manual allows access to 07h and user RAM 30 ms after VDD enters the operating range. The starting point is not the controller's driver entry or the request to enable power. Suppose the driver starts 8 ms after that request, but the module supply enters range at 12 ms. Under this hypothetical timeline, the earliest point meeting the RAM delay is 42 ms after the request. Waiting 30 ms from driver entry reaches only 38 ms, which is 4 ms early. This example concerns the initial RAM access rule, not separate calendar or oscillator stabilization requirements.
On an approved bench, capture the RTC supply, driver request marker, and bus traffic together. Distinguish the power valid time expected by firmware from the one measured. If access fails, check voltage, observed delay, and actual address. If calendar settings change unexpectedly, examine write ranges rather than inferring them from the current date. For stored data, check and record version, length, and integrity result. An integrity check can detect some anomalies but cannot prove persistence or the absence of concurrent writes.
Include simulator cases that end exactly at 1Fh, attempt one extra byte, and access only 07h through the dedicated interface. For that last test, verify that no extra data byte is sent. Where preemption or supply transitions are relevant, also test interruption and recovery so the application does not accept an incomplete record as committed. Before release, confirm on the bus that no alarm or control writes occur as a side effect. For a unit that already showed the problem, preserve evidence before restoring time and application settings through the controlled process.
For retained state, do not let two tasks use the separate areas without coordination. If several tasks need storage, define who owns the user block, who can reset the calendar or perform recovery initialization, and whether either can run during a commit. Clearing an invalidity flag completes a prescribed action. It does not restore contents already lost. An application can fall back to safe defaults on an incomplete record and log that the values were rebuilt on this boot rather than retained from the last one. For multiple application versions, give each byte a stable format and byte order, and do not interpret old fields as a new state. Hand maintenance staff both a permitted address map and a power-boundary diagram so they can see whether integration code flattened the split map. Preserve actual bus requests and responses, not just a debug message claiming success. If the problem coincides with both a power disturbance and a revision change, run the same test on both revisions and isolate one factor at a time. Do not modify a working alarm or timer interface by accident.
Firmware and engineering checklist
| Item | Evidence | Release boundary |
|---|---|---|
| Address regions | Separate 07h and continuous 10h–1Fh | Do not write RAM across alarm and control addresses |
| Initial power-up | VDD entering range and first bus transaction | Time the delay from actual voltage |
| Write verification | Length, version, integrity, and bus trace | An acknowledgement is not functional approval |
| Retention | Valid backup, loss of retention, and cold-start tests | Do not use SRAM as a permanent record |
Frequently asked questions
Why is 07h not included in the 128-bit user block?
The 128 bits are the sixteen consecutive locations from 10h through 1Fh. The 07h byte is independently accessible, but other registers lie between those ranges.
Does reading back what was written establish power-loss retention?
No. An immediate readback establishes consistency for that transaction. Check actual supply conditions, status flags, and the application record to establish retention. Use separate persistent storage when data must survive complete power loss.
