Skip to content

Commit 5d96f54

Browse files
committed
remove ability to set NPCL for diode measurements from keithley (for compatibility between DMMs)
1 parent 52a49ec commit 5d96f54

File tree

3 files changed

+20
-4
lines changed

3 files changed

+20
-4
lines changed

src/fixate/drivers/dmm/keithley_6500.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,15 @@ def __init__(self, instrument, *args, **kwargs):
4040
"continuity": "CONT",
4141
"diode": "DIOD",
4242
}
43+
# note: the keithley 6500 also supports changing NPLC for diode measurements, but this has been removed as the fluke does not support it.
4344
self._nplc_modes = [
4445
"voltage_dc",
4546
"current_dc",
4647
"resistance",
4748
"fresistance",
48-
"diode",
4949
"temperature",
5050
]
51+
# note: the keithley supports setting NPLC to any value between 0.0005 and 12 (with 50hz mains power) but for compatibility with the fluke, we only support the following values
5152
self._nplc_settings = [0.02, 0.2, 1, 10]
5253
self._nplc_default = 1
5354
self._init_string = "" # Unchanging

test/drivers/test_fluke_8846A.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -323,6 +323,9 @@ def test_measurement_diode(funcgen, dmm, rm):
323323
("current_dc"),
324324
("resistance"),
325325
("fresistance"),
326+
pytest.param(
327+
"diode", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
328+
),
326329
pytest.param(
327330
"voltage_ac", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
328331
),
@@ -358,6 +361,9 @@ def test_get_nplc(mode, dmm):
358361
("current_dc"),
359362
("resistance"),
360363
("fresistance"),
364+
pytest.param(
365+
"diode", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
366+
),
361367
pytest.param(
362368
"voltage_ac", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
363369
),
@@ -401,6 +407,9 @@ def test_set_nplc(mode, dmm):
401407
("current_dc"),
402408
("resistance"),
403409
("fresistance"),
410+
pytest.param(
411+
"diode", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
412+
),
404413
pytest.param(
405414
"voltage_ac", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
406415
),

test/drivers/test_keithley_6500.py

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -329,9 +329,11 @@ def test_measurement_diode(funcgen, dmm, rm):
329329
[
330330
("voltage_dc"),
331331
("current_dc"),
332-
("diode"),
333332
("resistance"),
334333
("fresistance"),
334+
pytest.param(
335+
"diode", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
336+
),
335337
pytest.param(
336338
"voltage_ac", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
337339
),
@@ -365,9 +367,11 @@ def test_get_nplc(mode, dmm):
365367
[
366368
("voltage_dc"),
367369
("current_dc"),
368-
("diode"),
369370
("resistance"),
370371
("fresistance"),
372+
pytest.param(
373+
"diode", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
374+
),
371375
pytest.param(
372376
"voltage_ac", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
373377
),
@@ -409,9 +413,11 @@ def test_set_nplc(mode, dmm):
409413
[
410414
("voltage_dc"),
411415
("current_dc"),
412-
("diode"),
413416
("resistance"),
414417
("fresistance"),
418+
pytest.param(
419+
"diode", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
420+
),
415421
pytest.param(
416422
"voltage_ac", marks=pytest.mark.xfail(raises=ParameterError, strict=True)
417423
),

0 commit comments

Comments
 (0)