Specialist Supplier of Crystals & Frequency Control Componentssales@mecxtal.com.cn0755-26500570
MERLIN home / Rednote / System Validation and Replacement

Both Epson RX-4035 Channels Are Set. Can You Tell Which Event Arrived First?

Not from the channel flags. The RX-4035 SA/LC stores one one-shot timestamp. Two set channel bits mean that the module grouped the inputs into one event record.

Two inputs do not provide two timestamps

Epson’s RX-4035 SA/LC has event inputs EVIN1 and EVIN2. Its timestamp registers contain one set of fields from seconds to year, with EDCH1 and EDCH2 identifying event channels. Individual flags identify their respective inputs. With both set, the device has treated the inputs as simultaneous events. The result is one date and time plus channel information, not a separate timestamp for each input. Without an independent recording, it does not establish which physical edge arrived first.

The flags share register bytes with time fields. EDCH1 is the highest bit of the timestamp seconds byte, and EDCH2 is the highest bit of the minutes byte. Decode the channel flags separately from the time data instead of treating a raw byte as seconds or minutes. Retain the raw capture and store the source and clock value separately. Otherwise a display error can be hard to distinguish from a physical event or a decoding error.

EDFG records detection status, not an additional event. The manual says one capture is recorded per arming cycle. Another timestamp needs EDEN to go from 0 back to 1, and clearing EDEN zeros the timestamp registers. Put reading the old record before rearming. If an interrupt handler disables capture before another task saves the fields, the task may only see zeros. That is not the same as the module never detecting an event, and a later interrupt does not reveal the order of the earlier inputs.

How do debounce, simultaneous detection and interrupt latency differ?

The electrical table gives typical debounce options of 35 ms and 1996 ms, the latter commonly described as 2 s. Its typical event-detection relation is tDB + 7.8 ms. The channel discussion also refers to a 7.8 ms maximum for inputs judged simultaneous, while later explanatory text and diagrams describe both inputs being held effective during debounce. Check the electrical table, channel description and timing diagrams together. One 7.8 ms number does not define the outcome for every raw waveform or preserve the physical arrival order.

Consider a hypothetical example, not a measurement of the module. An independent timer records EVIN1 rising at 100 ms and EVIN2 at 104 ms in one trial. The channels reverse in another trial at the same respective times. Assume the module qualifies both trials with two channel flags and the same timestamp second. Physical order is opposite, but the exported fields are identical. The flags do not reveal a 4 ms separation or establish that channel 1 is always first.

At the 35 ms setting, the typical detection relationship gives approximately 42.8 ms under the relevant electrical conditions. That is an input-to-detection estimate, not the spacing between two events or the time at which the host finishes an SPI read. If the system must save a complete record within a deadline, include interrupt service, bus queuing and durable storage. Confirm supply and temperature conditions rather than using a typical figure as a maximum.

Mark both threshold crossings on one timebase. A host command does not necessarily mark when a signal delivered through different wiring or external circuitry reaches an accepted level at the module. If the inputs are slow or threshold settings differ, record that limitation. The debounce typical figure is not a post-processing rule for sorting two hidden edges.

How can you preserve order if the application needs it?

Define whether the product needs “both channels occurred in this cycle,” or also needs first edge, separation and all subsequent events. One valid record plus both flags may be adequate for the first requirement. For the second, use a hardware timebase that captures each input separately or another recorder; the RTC can provide the calendar reference. The order of GPIO software callbacks is not an independent measurement of physical edges on the same timebase. Scheduling delays delivery, not the original input.

Test each channel alone first, then reverse input order and vary separation and pulse width. Retain the input levels, module interrupt and register readback. Change one variable at a time. If a signal generator drives the inputs, measure the actual waveforms at the module rather than trusting programmed command times. For standby or power recovery tests, record actual module supply state. Event detection and serial access can have different supply conditions; detecting an event does not show that the host can read it immediately.

Check readout and rearming last. Save a valid timestamp and channel information before clearing or starting a new capture cycle, following the manual. For missing records, distinguish absent input, invalid capture, a read after clearing and a one-shot capture that preserved only the first event. This avoids diagnosing any short record or zero value as a stopped crystal. Where voltage or validity flags apply, interpret them under the relevant conditions rather than declaring a numeric time valid unconditionally.

When events around power loss must be retained, do not let automatic recovery rewrite capture settings before readout. Record the first read, configuration restore and completion of the copy into host memory as separate events. Qualify distinct recovery paths. A user summary may say “simultaneous,” but service staff should be able to review channel flags, raw values and the defined timing resolution.

A common checklist for firmware, validation and purchasing

CheckRetainDecision rule
Channel and timestampRaw registers, EDCH1/EDCH2 and decoded fieldsTwo channel flags are not two timestamps
Input and latencyInput edges, width, threshold, debounce and interruptDetection delay is not relative event spacing
Readout and rearmActual read, buffer completion, clear and enable timesSave the record before starting another cycle
Product requirementCalendar alignment, ordering or complete historyDual flags address only part of the requirement

Compare replacement modules by capture channels, storage depth and rearming behavior, not just the sales phrase “dual event inputs.” If current firmware saves one event, a replacement with extra memory still needs readout, clear and loss-case validation. Do not credit an unmodified system with new retention. If replacement reduces capture depth, make clear which software requirements are no longer guaranteed.

For an ambiguous trial, preserve both raw traces and repeat rather than manually swapping channels in the original record. A report can say that reversing the inputs produced the same captured result without claiming that all input spacings behave that way.

Two common questions

Do both set flags prove the inputs occurred in the same nanosecond?

No. They identify the device’s classification under its detection rules, not the precise times of both edges. Independent capture is needed to establish order.

Does clearing EDFG make the next event enter the timestamp registers?

Do not conflate the two actions. Interrupt flag handling and rearming the timestamp are separate. Follow the exact EDEN requirements and read the timestamp before any clearing action that can erase it.

WeChat

MERLIN · TIMING COMPONENTS

Scan with WeChat to contact Sales

Add our WeCom contacts from your usual WeChat app.

On desktop, scan with your phone. On mobile, save the QR image and select it from your album in WeChat Scan.