From 743b49e07ea795fc223b93bc40ad490c92576d46 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Thu, 17 Mar 2022 19:15:27 +0800 Subject: [PATCH] coredevice: remove exception workarounds --- artiq/coredevice/ad53xx.py | 6 ------ artiq/coredevice/ad9910.py | 6 ------ artiq/coredevice/ad9912.py | 6 ------ artiq/coredevice/ad9914.py | 6 ------ artiq/coredevice/adf5356.py | 7 ------- artiq/coredevice/fastino.py | 9 --------- artiq/coredevice/mirny.py | 6 ------ artiq/coredevice/phaser.py | 6 ------ artiq/coredevice/sampler.py | 7 ------- artiq/coredevice/spi2.py | 7 ------- artiq/coredevice/suservo.py | 6 ------ artiq/coredevice/urukul.py | 7 ------- 12 files changed, 79 deletions(-) diff --git a/artiq/coredevice/ad53xx.py b/artiq/coredevice/ad53xx.py index 080713090..26bc0d6c0 100644 --- a/artiq/coredevice/ad53xx.py +++ b/artiq/coredevice/ad53xx.py @@ -17,12 +17,6 @@ from artiq.coredevice.ttl import TTLOut from artiq.coredevice.spi2 import * -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - SPI_AD53XX_CONFIG = (0*SPI_OFFLINE | 1*SPI_END | 0*SPI_INPUT | 0*SPI_CS_POLARITY | 0*SPI_CLK_POLARITY | 1*SPI_CLK_PHASE | diff --git a/artiq/coredevice/ad9910.py b/artiq/coredevice/ad9910.py index 708509d5e..23d2856f2 100644 --- a/artiq/coredevice/ad9910.py +++ b/artiq/coredevice/ad9910.py @@ -10,12 +10,6 @@ from artiq.coredevice.ttl import TTLOut from artiq.coredevice.kasli_i2c import KasliEEPROM # NAC3TODO -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - __all__ = [ "AD9910", "PHASE_MODE_CONTINUOUS", "PHASE_MODE_ABSOLUTE", "PHASE_MODE_TRACKING", diff --git a/artiq/coredevice/ad9912.py b/artiq/coredevice/ad9912.py index d8dce22e1..bd5daa78f 100644 --- a/artiq/coredevice/ad9912.py +++ b/artiq/coredevice/ad9912.py @@ -10,12 +10,6 @@ from artiq.coredevice.urukul import * from artiq.coredevice.ttl import TTLOut -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - @nac3 class AD9912: """ diff --git a/artiq/coredevice/ad9914.py b/artiq/coredevice/ad9914.py index 1a8abe35c..092654675 100644 --- a/artiq/coredevice/ad9914.py +++ b/artiq/coredevice/ad9914.py @@ -10,12 +10,6 @@ from artiq.coredevice.rtio import rtio_output from artiq.coredevice.core import Core -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - __all__ = [ "AD9914", "PHASE_MODE_CONTINUOUS", "PHASE_MODE_ABSOLUTE", "PHASE_MODE_TRACKING" diff --git a/artiq/coredevice/adf5356.py b/artiq/coredevice/adf5356.py index 2167ef9ad..683990bfa 100644 --- a/artiq/coredevice/adf5356.py +++ b/artiq/coredevice/adf5356.py @@ -20,13 +20,6 @@ from artiq.coredevice.spi2 import * from artiq.coredevice.adf5356_reg import * -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - - SPI_CONFIG = ( 0 * SPI_OFFLINE | 0 * SPI_END diff --git a/artiq/coredevice/fastino.py b/artiq/coredevice/fastino.py index f0ab00cc2..6e455a324 100644 --- a/artiq/coredevice/fastino.py +++ b/artiq/coredevice/fastino.py @@ -10,15 +10,6 @@ from artiq.language.units import ns from artiq.coredevice.core import Core -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass -@nac3 -class NotImplementedError(Exception): - pass - - @nac3 class Fastino: """Fastino 32-channel, 16-bit, 2.5 MS/s per channel streaming DAC diff --git a/artiq/coredevice/mirny.py b/artiq/coredevice/mirny.py index 9ac7644ee..95247e6d2 100644 --- a/artiq/coredevice/mirny.py +++ b/artiq/coredevice/mirny.py @@ -10,12 +10,6 @@ from artiq.coredevice.core import Core from artiq.coredevice.spi2 import * -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - SPI_CONFIG = ( 0 * SPI_OFFLINE | 0 * SPI_END diff --git a/artiq/coredevice/phaser.py b/artiq/coredevice/phaser.py index b456266eb..e26a3fafe 100644 --- a/artiq/coredevice/phaser.py +++ b/artiq/coredevice/phaser.py @@ -9,12 +9,6 @@ from artiq.coredevice.dac34h84 import DAC34H84 from artiq.coredevice.trf372017 import TRF372017 -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - PHASER_BOARD_ID = 19 PHASER_ADDR_BOARD_ID = 0x00 PHASER_ADDR_HW_REV = 0x01 diff --git a/artiq/coredevice/sampler.py b/artiq/coredevice/sampler.py index 2722d12cf..686e92d62 100644 --- a/artiq/coredevice/sampler.py +++ b/artiq/coredevice/sampler.py @@ -8,13 +8,6 @@ from artiq.coredevice.spi2 import * from artiq.coredevice.ttl import TTLOut -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - - SPI_CONFIG = (0*SPI_OFFLINE | 0*SPI_END | 0*SPI_INPUT | 0*SPI_CS_POLARITY | 0*SPI_CLK_POLARITY | 0*SPI_CLK_PHASE | diff --git a/artiq/coredevice/spi2.py b/artiq/coredevice/spi2.py index 19e5ce805..4b07dc907 100644 --- a/artiq/coredevice/spi2.py +++ b/artiq/coredevice/spi2.py @@ -14,13 +14,6 @@ from artiq.coredevice.core import Core from artiq.coredevice.rtio import rtio_output, rtio_input_data -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - - __all__ = [ "SPI_DATA_ADDR", "SPI_CONFIG_ADDR", "SPI_OFFLINE", "SPI_END", "SPI_INPUT", diff --git a/artiq/coredevice/suservo.py b/artiq/coredevice/suservo.py index 7ea8eef11..07655ba43 100644 --- a/artiq/coredevice/suservo.py +++ b/artiq/coredevice/suservo.py @@ -10,12 +10,6 @@ from artiq.coredevice.ad9910 import AD9910 from artiq.coredevice.sampler import adc_mu_to_volt as sampler_adc_mu_to_volt, SPI_CONFIG as SAMPLER_SPI_CONFIG, SPI_CS_PGIA as SAMPLER_SPI_CS_PGIA -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - COEFF_WIDTH = 18 Y_FULL_SCALE_MU = (1 << (COEFF_WIDTH - 1)) - 1 COEFF_DEPTH = 10 + 1 diff --git a/artiq/coredevice/urukul.py b/artiq/coredevice/urukul.py index 18cc5c9d1..ab03201ec 100644 --- a/artiq/coredevice/urukul.py +++ b/artiq/coredevice/urukul.py @@ -8,13 +8,6 @@ from artiq.coredevice.spi2 import * from artiq.coredevice.ttl import TTLOut -# NAC3TODO work around https://git.m-labs.hk/M-Labs/nac3/issues/189 -@nac3 -class ValueError(Exception): - pass - - - SPI_CONFIG = (0 * SPI_OFFLINE | 0 * SPI_END | 0 * SPI_INPUT | 1 * SPI_CS_POLARITY | 0 * SPI_CLK_POLARITY | 0 * SPI_CLK_PHASE |