Instrument Timeout or DUT Timeout? Keep the Failure Owner in the Result

Assign a timeout to the stage whose evidence is missing before assigning it to the product. A host waiting too long for an instrument response does not prove that the DUT responded too slowly. Preserve admission, stimulus, acquisition, transport and physical-response observations so the failure owner remains diagnosable.

The concrete library boundary is PyVISA 1.14.1. Six synthetic evidence classifications passed under Python 3.12.14; PyVISA, instruments and DUTs were not executed. All real deadline values and acquisition guarantees must come from the approved test method and measured implementation.

Draw the complete observation chain

Start at the test runner: it obtains the resource, configures the instrument, arms acquisition, applies the stimulus, observes the DUT response and retrieves the result. Some instruments combine stages, while others require separate acknowledgement and completion checks.

Name the event that starts the product deadline. It might be a voltage transition at the DUT pin, a completed command frame or another specified physical condition. The time the host queued a request is usually a different event.

Keep a stage ledger with requested action, accepted action, independently observed completion where available, deadline, actual observation time and error category. Missing evidence should remain missing; it must not be replaced by an optimistic assumption that the preceding command worked.

The test chain separates admission/stimulus, physical response and result delivery; a VISA I/O timeout is classified at the first missing evidence boundary rather than automatically assigned to the DUT.
Original timeout-ownership map; six synthetic evidence cases passed without instrument timing.

Interpret the instrument timeout narrowly

PyVISA 1.14.1’s resource guide describes per-resource I/O timeouts in milliseconds. Its timeout setting concerns VISA I/O operations, not a universal end-to-end test deadline. Infinite or immediate timeout settings also have specific meanings and should not be used accidentally through a unit-conversion mistake.

The tagged MessageBasedResource.query implementation writes the message, optionally waits query_delay in seconds, then reads. A timeout attached to the resource does not make that entire sequence one atomic product-response measurement. Configuration, host scheduling, the delay and multiple underlying operations can contribute separately.

Record the selected VISA backend and instrument firmware when qualifying behavior. The Python wrapper’s API does not establish the device’s command execution time, trigger semantics or response buffering. Consult the exact instrument manual before interpreting a missing response.

Distinguish readiness from physical stimulus

An instrument acknowledging a command may establish that it parsed or queued the command, depending on its contract. It does not universally establish that a waveform reached the DUT. Similarly, a successful write to a relay controller does not prove the intended route is closed.

Use the test’s qualified stimulus observation or supported completion mechanism. If that evidence is absent, classify the product timing result as unsupported rather than charging the entire wait to the DUT.

For a hypothetical response-time test, a delayed source trigger can make the host’s elapsed interval exceed the requirement while the DUT’s actual stimulus-to-response interval remains acceptable. Conversely, an early host timestamp can hide a late response if the wrong event is used as the endpoint.

Use a failure-owner decision tree

Evidence at failure Initial classification Next question
Job never admitted to the instrument resource. Host/resource admission timeout. Who owned the resource and what consumed the queue budget?
Job admitted, stimulus not established. Stimulus unconfirmed. Was command execution, routing or trigger completion observed?
Stimulus established, acquisition invalid or incomplete. Instrument/observation incomplete. Was the capture armed and did transfer/framing complete?
Valid physical capture shows late DUT response. Product response outside the supplied limit. Does the event definition and uncertainty support that classification?
Valid timely response exists, host receives it late. Delivery or host delay. Where did buffering or scheduling delay arise?

These categories identify the first unsupported or violated boundary. They are not final root-cause diagnoses. A shared power fault, for example, can affect both the instrument and DUT, requiring a broader investigation.

Preserve partial evidence without inventing a complete result

Retain available command identifiers, instrument status, byte counts, acquisition markers and partial responses through supported interfaces. A partial numerical string or truncated binary block must not become a valid measurement because its prefix looks plausible.

PyVISA’s guide describes termination settings and chunked reads. Check the actual message framing and expected length when investigating timeouts; a missing terminator can make a completed physical measurement appear as a transport wait.

Do not assume every API exposes partial data after an exception. Record what was actually available and qualify any lower-level diagnostic capture separately. Avoid replaying consequential commands merely to retrieve a lost response unless the operation’s recovery contract permits it.

Read the executed evidence-model controls

The pure model supplied a baseline with admitted work, confirmed stimulus, valid acquisition, timely physical response and host receipt. That case completed. Five altered cases each removed or violated one stage and produced the corresponding category in the table.

All six expected classifications passed. The model does not measure time or discover which Boolean is true on hardware. Its purpose is to ensure that a reporting path can preserve the failure owner instead of converting every missing result into DUT_TIMEOUT.

A real classifier also needs multi-fault cases, stale evidence, clock uncertainty and explicit precedence when several stages are unresolved. Treat those as additional qualification work rather than inferring completeness from this small model.

Keep test infrastructure and product budgets separate

Give each infrastructure stage a bounded operational budget and keep an overall test-run deadline. The product requirement remains tied to its defined physical events. Increasing an instrument timeout can help collect diagnostics without changing the product’s acceptance limit.

Conversely, a slower host does not justify loosening the product specification. Improve the observation path or use a qualified hardware timing mechanism when host receipt cannot resolve the required interval.

Release the stage ledger, exact library/backend/instrument versions, failure categories and controlled fault cases with the station software. The useful outcome is a timeout that points to the missing evidence and the next test, rather than a label that blames the board before the stimulus or measurement was established.

Similar Posts