Pro
12 min

CCST 43 — As-Found / As-Left Tolerance Decision

ccstcalibrationtoleranceas-foundas-leftdecision

Ready to build this?

Sign up free — no credit card required. This scenario requires the Pro plan.

Sign up to play this scenario →

Already have an account? Log in

CCST 43 — As-Found / As-Left Tolerance Decision

Briefing

After a calibration check the technician enters the errors as signed hundredths of a percent of span: AS_FOUND_ERR_X100 (the error before touching anything) and AS_LEFT_ERR_X100 (the error after any adjustment). ADJUSTED is on once the technician has adjusted the instrument. The rules for this plant: - As-found tolerance is +/-0.50 percent (50). Outside it, ADJUST_REQUIRED is on. - If the as-found error is in tolerance, the calibration passes: CAL_PASS is on. - If it was out, CAL_PASS comes on only after the instrument has been adjusted AND the as-left error is within the tighter +/-0.25 percent (25). - Each limit includes its edge, and errors can be negative. A comparison cannot be written against a negative number, such as | (A > -5) |. To test a negative reading, flip its sign first with SUB(0, X) and compare the flipped value with a positive limit. Comparisons are built with Compare boxes, or in the Code tab as contacts, for example | (A > B) | := LAMP ;

Objectives

  • As-found within +/-0.50 percent: no adjustment needed, calibration passes
  • As-found outside +/-0.50 percent, high or low: ADJUST_REQUIRED on
  • After an adjustment, CAL_PASS only if the as-left error is within +/-0.25 percent
  • An out-of-tolerance instrument never passes without an adjustment

Hints

  • There are two separate questions: was the instrument in tolerance when you found it, and is it good enough now? Which input answers each?
  • A tolerance is a band either side of zero. Describe the band in words first: what is true when an error is out of it, in either direction?
  • The pass condition has two ways to be true: the instrument never needed adjusting, or it was adjusted and then checked against the tighter limit.
  • Walk through these: found 20 (passes), found 80 not adjusted (fails), found 80 adjusted left 10 (passes), found 80 adjusted left 40 (fails), found -80 (adjust required).

I/O Table

Inputs

AS_FOUND_ERR_X100

As-found error, signed hundredths of a percent of span

INT · %IW0

AS_LEFT_ERR_X100

As-left error, signed hundredths of a percent of span

INT · %IW1

ADJUSTED

Technician has adjusted the instrument

BOOL · %I0.0

Outputs

ADJUST_REQUIRED

As-found error outside tolerance: adjustment required

BOOL · %Q0.0

CAL_PASS

Calibration passes

BOOL · %Q0.1

Your program will be tested against:

All test cases run automatically when you submit. Assertions are hidden until you pass.

  1. #1As-found +0.20 → passes, no adjustment

    In tolerance when found

  2. #2As-found +0.80 → adjust required

    Out of tolerance, not yet adjusted

  3. #3Adjusted, as-left +0.10 → passes

    Adjustment brought it inside the as-left limit

  4. #4Adjusted, as-left +0.40 → does not pass

    Inside the as-found band but outside the tighter as-left band

  5. #5As-found -0.80 → adjust required

    Drift below zero counts too

  6. #6Out, not adjusted, as-left looks good → no pass

    A good as-left reading without an adjustment is not a pass

  7. #7Limits include their edge

    As-found 50 and as-left 25 are inside; 51 and 26 are outside

Ready to build this?

Sign up free — no credit card required. This scenario requires the Pro plan.

Sign up to play this scenario →

Already have an account? Log in