The Epson RX8901CE timestamp FIFO's INTCNT threshold does not automatically group every four records into one interrupt. A threshold of four produces an event interrupt source when four records are waiting. As long as the unread count has not fallen below the threshold, further timestamp captures can generate the same source again. To wake and read in batches, design how much data the host removes and how it services the interrupt rather than setting one register and assuming periodic batches.
The comparison uses unread FIFO occupancy
Epson's manual ties INTCNT in BUF1_CFG1 to PTR in BUF1_STAT. In FIFO mode, PTR represents the records still available to read. Reaching the configured count generates an event interrupt source. Each subsequent timestamp capture can generate the source again until occupancy drops below that count. It is neither a fixed grouping of external sensor pulses nor a counter that starts at zero automatically after a notification.
Keep this statement scoped to FIFO mode. The manual separately defines the pointer under direct mode, where the relevant buffer and pointer interpretation differ. Check configuration before mapping a readback to stored timestamps. The interrupt line alone does not identify the record responsible. More than one source can affect the output, and system configuration defines how those sources are observed.
Work through two service strategies with a threshold of four
| Step | Readable records in the FIFO | Meaning for the threshold |
|---|---|---|
| Fill from empty to three | Three | Still below threshold |
| Capture one more valid record | Four | Reaches threshold; a source is generated |
| Capture another without reading | Five | Still at or above threshold; another capture can generate the source |
| Read two | Three | Below threshold; the next capture can bring it back to four |
These examples assume the new events are captured and no other queue changes occur. If the host removes one entry after the fifth was recorded, occupancy drops from five to four. It is still not below the threshold. Another capture does not mean a second batch of four has arrived. The queue simply never left the threshold condition. If the service drains to a verified count below four, the next threshold transition is easier to explain. That does not mean always reading two entries: ongoing events make actual occupancy and service time decisive.
Margin is also a product decision. Stopping at three leaves room for one before the next threshold. Draining further gives space for a burst but may lengthen the work. Do not claim a threshold of four cuts battery use by a factor of four. Wake frequency depends on the event rate, delays, whether capture continues during service and how the host exits. Measure consumption under real traffic and fault conditions rather than deriving it from a register value alone.
An internal interrupt source is not a count of pin pulses
The repeat described here is an internal interrupt source. A separately observable edge depends on interrupt enable, flag handling, wiring and other sources. If the previous low has not been released, a new source need not appear as a separate pulse. Likewise the line can remain low due to a different still-active source. An informative log retains FIFO occupancy, serviced flags, actual pin waveform and the records read.
On an approved bench, configure the threshold and feed distinguishable valid events. Hold host reads initially to observe three, four and five. Then run independent cases that read one or drain below the threshold. Do not change multiple sources on the same run or mix uncontrolled cable movement with intended events. Follow the manual's status-update requirements during reads rather than inferring the sequence from one instantaneous pointer value.
If a generator stands in for a sensor, first establish valid voltage, polarity and width. Use independently traceable evidence of accepted captures so the fifth stimulus can be distinguished from the fifth stored record. Production can preserve timing of arrivals, reads and flag handling to distinguish a repeated wake caused during accumulation from one after service exits.
Fit the batching policy to real traffic
Document threshold, wake behavior and resource limits together. If events can arrive during draining, bound the work for one service and decide what happens when that budget is exhausted while the queue remains above threshold. Do not assume timeout restores the initial threshold state. Avoid independently consuming the same queue from background and interrupt tasks without clear ownership. Actual pointer readbacks and record identifiers are more useful than a log with interrupt ordinal alone.
Test two service boundaries. First insert a new event immediately after a partial drain and verify batching and alert behavior. Then simulate the host not reading for an extended period and verify how it recognizes backlogged records on recovery. A higher threshold does not remove backlog risk. Check which data remains, service latency and whether the next wake meets requirements. When useful, log hardware queue events separately from business alerts so an application state cannot conceal device behavior.
A release record should identify the exact part, FIFO mode, threshold, capture conditions and whether the test crossed, held or went below the threshold. Repeat it after changing defaults or only the read strategy. The same threshold can yield different system behavior because what matters is the queue's actual traffic and service timing, not just the constant.
In an incident review, do not infer total external events from interrupt counts. Valid inputs can arrive close together during software delays, and some physical inputs may never enter the queue because of source settings or electrical conditions. At minimum, correlate a timestamp capture with a read and the threshold state on a shared timeline. Leave unpaired events unresolved. This lets subsequent trigger sources use the same acceptance method without using ambiguous interrupt totals to explain retained data.
Frequently asked questions
Does a threshold of four guarantee one external interrupt for every four records?
No. The hardware compares unread occupancy. Captures can keep generating the same source while occupancy stays at or above the threshold. The external signal also depends on enables and other sources.
Does reading one of five records reset counting for the next batch?
No. Four unread entries still meet the example threshold. Check the reads and further captures rather than treating a service operation as an automatic reset.
