An alarm indication appeared, but the timestamp reads as zeros. On the Epson RX-8035SA/LC, verify the register bank and the order of operations before treating the event as missed.
The RX-8035SA/LC is a real-time clock module with an integrated 32.768 kHz quartz crystal. Its event timestamp is not a running history; it holds the first qualifying event after detection is armed. A host that responds to an interrupt by clearing EDEN before reading the timestamp bank may delete the data it intended to read. First check event and validity status; read and save the required fields; then clear and rearm as the application requires.
1. Event status, validity and rearming are separate
EDEN is bit 4 at Eh. Setting it enables event detection and timestamp capture. Clearing it stops detection and clears the record. Maintenance code can treat it like a routine interrupt control and assume that turning it off and back on only resets a pin. In fact, the write can determine whether the data remains readable. To diagnose an existing issue, start the capture before the interrupt and include the write to Eh and the later read of the timestamp.
EDFG indicates that an event was detected. TSFG indicates whether the timestamp is valid. The manufacturer relates validity to the state at the event: TSFG is set only when both XSTP and VDET were zero. An event flag does not establish that the time can be trusted, and a plausible date does not mean the validity check passed. Log the two flags separately and preserve device time and host collection time in separate fields. Do not silently substitute one for the other.
Clearing the event flag to release its interrupt is different from clearing and setting EDEN to rearm the detector. The manual states that the next event will not overwrite the first record before rearming. A system that must record successive changes needs to account separately for the interval in which firmware retrieves the record and rearms detection. This hardware behavior alone cannot guarantee that no event will be missed. For process traceability, mark any interval that is not covered rather than interpreting an empty log as proof that nothing happened.
2. The right register bank matters more than the byte count
Ordinary calendar access uses BANK0. In BANK1, addresses 0h through 6h contain the timestamp fields. The address alone does not identify the meaning. Seven plausible bytes from the wrong bank can be more misleading than all zeros, because software may confuse the live RTC with a frozen event time. Save the bank-selection operation and the actual read start address in the same trace as a suspect record.
BANK and TSFG have different access semantics at the same bit of Fh: a write selects the bank; a read reports timestamp validity. Reading a one therefore does not establish that access is still in BANK1. Do not use an unmodified Fh readback as a generic write template. Keep bank-selection intent separate from status decoding in the driver, and construct any required write according to the rules for each Fh field to avoid inadvertently changing other flags. After the read, restore the bank expected by the ordinary calendar access path.
| Observable | Evidence to retain | What it does not establish |
|---|---|---|
| EDFG and TSFG | Both states after the interrupt and before clearing | An event always has a valid time |
| EDEN at Eh | Written value and its place in the sequence | Clearing merely disables an interrupt |
| BANK1, 0h through 6h | Bank-selection frame and seven raw bytes | Any value at those addresses is a timestamp |
| Host logging | Successful buffer or log write and rearm time | A first-event latch is a queue |
3. Worked example: zeros alone are not a diagnosis
Suppose a door-event recorder observes the module interrupt at 100 ms on the host timebase. All times in this example are hypothetical host readings, not device debounce or delay specifications. The faulty path clears EDEN at 102 ms and starts reading BANK1 at 107 ms: a 5 ms clear-to-read interval. Making it shorter cannot recover a record that has already been deleted. Waiting longer before reading does not fix the order; move the destructive write after the save.
In the comparison path the host also sees the interrupt at 100 ms. At 102 ms it records the two status flags, completes the seven-byte read at 107 ms, and durably saves the device time, event channel and status at 111 ms. Only then does it clear and set EDEN. If the application defines the service window from 100 ms until rearming, read the actual end point from the trace before comparing it to the minimum event spacing. The chip was not necessarily ready at 107 ms. Before rearming, make sure the input is in the condition planned for the next detection. Do not assume an input that remained active will count as a new event.
Save a raw bus capture for each path. Change only the read-versus-clear order first, keeping the board, supply, source and input configuration the same. A valid first-event record for a known isolated stimulus supports the diagnosis that the previous order lost data; it does not establish that successive events are all captured. Then vary event spacing or force a storage failure to see if software discards the device’s only copy before the record is saved.
4. Evidence for board verification and a replacement request
Before reproducing the issue, align the event source, INTRA, power and host I²C data in one trace. Distinguish receipt of the interrupt from its handling by firmware. If the data reads zero, keep the bank selection, Eh write, Fh status and raw bytes. Do not reset before capturing; reset can also change the record. If reinitialization is necessary, document why and which evidence was saved independently. When the original event was not captured, leave that limitation explicit rather than calling a simulated failure a reproduction of the field issue.
In a multitasking system, let one driver operation own the bank selection, read and save sequence so that a clock-setting thread cannot change banks midway. If persistent storage is too slow, place the raw data and status in a verified reliable buffer in order, then let the application's power-loss requirements determine when the hardware record can be released. Test both traceability after a software error and normal readiness for the next event. If the requirements conflict, set a project priority rather than deleting the original data to conceal the performance gap.
For a request to replace a part because the calendar works but the event time is zero, obtain the exact SA or LC order number, board revision, driver version, failing frame and reproduction conditions. A substitute with the same integrated 32.768 kHz crystal still needs separate checks for record depth, bank switching, validity flags, effects of clearing and rearm conditions. If the firmware order explains the problem on the test board, have engineering confirm that before expanding the investigation to parts or lots.
5. Quick questions
Does clearing EDFG alone get me another timestamp?
Do not assume so. Releasing an event interrupt is not rearming the timestamp capture. After saving the current record, use EDEN to end one capture and enable the next, then confirm that the input can produce a new detectable event.
Can I use a plausible-looking time if TSFG is zero?
Do not treat it as a valid event time. Keep raw bytes, status and host observation time for troubleshooting, but label them separately. If the application fills the gap from another trusted clock, label it as estimated or host-recorded rather than a valid device timestamp.
