Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
F
FMC ADC 100M 14b 4cha - Testing
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
FMC ADC 100M 14b 4cha - Testing
Commits
c52d7107
Commit
c52d7107
authored
Jul 22, 2014
by
Matthieu Cattin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test many: Remove sys.path.append(), fix import order.
parent
0ba13e1e
Hide whitespace changes
Inline
Side-by-side
Showing
25 changed files
with
108 additions
and
237 deletions
+108
-237
test12.py
tests/test12.py
+4
-9
test17.py
tests/test17.py
+4
-9
test18.py
tests/test18.py
+4
-9
test20.py
tests/test20.py
+5
-11
test21.py
tests/test21.py
+2
-7
test24.py
tests/test24.py
+4
-9
test26.py
tests/test26.py
+3
-9
test27.py
tests/test27.py
+4
-9
test28.py
tests/test28.py
+4
-10
test29.py
tests/test29.py
+3
-9
test30.py
tests/test30.py
+4
-9
test31.py
tests/test31.py
+3
-9
test32.py
tests/test32.py
+4
-9
test33.py
tests/test33.py
+3
-9
test34.py
tests/test34.py
+3
-9
test35.py
tests/test35.py
+2
-7
test36.py
tests/test36.py
+3
-8
test37.py
tests/test37.py
+4
-9
test38.py
tests/test38.py
+2
-7
test39.py
tests/test39.py
+4
-9
test40.py
tests/test40.py
+4
-9
test41.py
tests/test41.py
+4
-9
test42.py
tests/test42.py
+5
-9
test43.py
tests/test43.py
+4
-9
test44.py
tests/test44.py
+22
-25
No files found.
tests/test12.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
...
@@ -31,6 +22,10 @@ import find_usb_tty
...
@@ -31,6 +22,10 @@ import find_usb_tty
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test12: Takes an acquisition of each channels separately and print it to a file and on the screen
test12: Takes an acquisition of each channels separately and print it to a file and on the screen
...
...
tests/test17.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
import
rr
from
ptsexcept
import
*
# Import specific modules
# Import specific modules
from
numpy
import
*
from
numpy
import
*
from
pylab
import
*
from
pylab
import
*
...
@@ -32,6 +23,10 @@ import find_usb_tty
...
@@ -32,6 +23,10 @@ import find_usb_tty
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
import
rr
from
ptsexcept
import
*
"""
"""
test17: Plot all channels
test17: Plot all channels
...
...
tests/test18.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
numpy
import
*
from
numpy
import
*
from
pylab
import
*
from
pylab
import
*
...
@@ -29,6 +20,10 @@ import find_usb_tty
...
@@ -29,6 +20,10 @@ import find_usb_tty
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test18: Test calibration box
test18: Test calibration box
...
...
tests/test20.py
View file @
c52d7107
...
@@ -12,17 +12,6 @@ import sys
...
@@ -12,17 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
sys
.
path
.
append
(
'../../fmceeprom/python/'
)
# Import common modules
from
ptsexcept
import
*
from
fmc_eeprom
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
...
@@ -35,6 +24,11 @@ from PAGE.Agilent33250A import *
...
@@ -35,6 +24,11 @@ from PAGE.Agilent33250A import *
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
from
ctypes
import
*
from
ctypes
import
*
# Import common modules
from
ptsexcept
import
*
from
fmc_eeprom
import
*
import
rr
"""
"""
...
...
tests/test21.py
View file @
c52d7107
...
@@ -13,18 +13,13 @@ import time
...
@@ -13,18 +13,13 @@ import time
import
os
import
os
import
re
import
re
# Add common modules and libraries location to path
# Import specific modules
sys
.
path
.
append
(
'../../../'
)
from
cp210x_eeprom
import
*
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
# Import common modules
from
ptsexcept
import
*
from
ptsexcept
import
*
import
rr
import
rr
# Import specific modules
from
cp210x_eeprom
import
*
"""
"""
test21: Store calibration data to CP2103 EEPROM
test21: Store calibration data to CP2103 EEPROM
...
...
tests/test24.py
View file @
c52d7107
...
@@ -13,20 +13,15 @@ import time
...
@@ -13,20 +13,15 @@ import time
import
os
import
os
import
re
import
re
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
cp210x_eeprom
import
*
from
cp210x_eeprom
import
*
from
ctypes
import
*
from
ctypes
import
*
import
find_usb_tty
import
find_usb_tty
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test24: Read calibration data from CP2103 EEPROM
test24: Read calibration data from CP2103 EEPROM
...
...
tests/test26.py
View file @
c52d7107
...
@@ -12,21 +12,15 @@ import sys
...
@@ -12,21 +12,15 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
# Import specific modules
sys
.
path
.
append
(
'../../../'
)
from
fmc_adc_spec
import
*
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
from
fmc_adc
import
*
sys
.
path
.
append
(
'../../../common/'
)
sys
.
path
.
append
(
'../../fmceeprom/python/'
)
# Import common modules
# Import common modules
from
ptsexcept
import
*
from
ptsexcept
import
*
from
fmc_eeprom
import
*
from
fmc_eeprom
import
*
import
rr
import
rr
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
"""
"""
test26: Read FMC EEPROM
test26: Read FMC EEPROM
...
...
tests/test27.py
View file @
c52d7107
...
@@ -11,20 +11,15 @@ import sys
...
@@ -11,20 +11,15 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
from
numpy
import
*
from
numpy
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test27: Test DMA
test27: Test DMA
...
...
tests/test28.py
View file @
c52d7107
...
@@ -12,17 +12,7 @@ import os
...
@@ -12,17 +12,7 @@ import os
import
math
import
math
import
random
as
rdm
import
random
as
rdm
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
from
numpy
import
*
from
numpy
import
*
...
@@ -34,6 +24,10 @@ from find_usb_tty import *
...
@@ -34,6 +24,10 @@ from find_usb_tty import *
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test28: Long term test
test28: Long term test
...
...
tests/test29.py
View file @
c52d7107
...
@@ -12,21 +12,15 @@ import time
...
@@ -12,21 +12,15 @@ import time
import
datetime
import
datetime
import
os
import
os
# Add common modules and libraries location to path
# Import specific modules
sys
.
path
.
append
(
'../../../'
)
from
fmc_adc_spec
import
*
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
from
fmc_adc
import
*
sys
.
path
.
append
(
'../../../common/'
)
sys
.
path
.
append
(
'../../fmceeprom/python/'
)
# Import common modules
# Import common modules
from
ptsexcept
import
*
from
ptsexcept
import
*
from
fmc_eeprom
import
*
from
fmc_eeprom
import
*
import
rr
import
rr
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
"""
"""
test29: Checks FMC EEPROM for existing data
test29: Checks FMC EEPROM for existing data
...
...
tests/test30.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
...
@@ -31,6 +22,10 @@ import find_usb_tty
...
@@ -31,6 +22,10 @@ import find_usb_tty
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test30: Test software reset.
test30: Test software reset.
...
...
tests/test31.py
View file @
c52d7107
...
@@ -13,21 +13,15 @@ import time
...
@@ -13,21 +13,15 @@ import time
import
datetime
import
datetime
import
os
import
os
# Add common modules and libraries location to path
# Import specific modules
sys
.
path
.
append
(
'../../../'
)
from
fmc_adc_spec
import
*
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
from
fmc_adc
import
*
sys
.
path
.
append
(
'../../../common/'
)
sys
.
path
.
append
(
'../../fmceeprom/python/'
)
# Import common modules
# Import common modules
from
ptsexcept
import
*
from
ptsexcept
import
*
from
fmc_eeprom
import
*
from
fmc_eeprom
import
*
import
rr
import
rr
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
"""
"""
test31: Fix EEPROM content:
test31: Fix EEPROM content:
...
...
tests/test32.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
...
@@ -33,6 +24,10 @@ from PAGE.SineWaveform import *
...
@@ -33,6 +24,10 @@ from PAGE.SineWaveform import *
import
scipy.optimize
as
optimize
import
scipy.optimize
as
optimize
import
scipy.fftpack
as
fftpack
import
scipy.fftpack
as
fftpack
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test32: Test decimation
test32: Test decimation
...
...
tests/test33.py
View file @
c52d7107
...
@@ -12,21 +12,15 @@ import sys
...
@@ -12,21 +12,15 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
# Import specific modules
sys
.
path
.
append
(
'../../../'
)
from
fmc_adc_spec
import
*
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
from
fmc_adc
import
*
sys
.
path
.
append
(
'../../../common/'
)
sys
.
path
.
append
(
'../../fmceeprom/python/'
)
# Import common modules
# Import common modules
from
ptsexcept
import
*
from
ptsexcept
import
*
from
fmc_eeprom
import
*
from
fmc_eeprom
import
*
import
rr
import
rr
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
"""
"""
test33: Write FMC EEPROM
test33: Write FMC EEPROM
...
...
tests/test34.py
View file @
c52d7107
...
@@ -12,20 +12,14 @@ import sys
...
@@ -12,20 +12,14 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
# Import specific modules
sys
.
path
.
append
(
'../../../'
)
from
fmc_adc_spec
import
*
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
from
fmc_adc
import
*
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
# Import common modules
from
ptsexcept
import
*
from
ptsexcept
import
*
import
rr
import
rr
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
"""
"""
test34: Test interrupts (EIC + VIC)
test34: Test interrupts (EIC + VIC)
...
...
tests/test35.py
View file @
c52d7107
...
@@ -12,18 +12,13 @@ import sys
...
@@ -12,18 +12,13 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
# Import specific modules
sys
.
path
.
append
(
'../../../'
)
from
fmc_adc_spec
import
*
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
# Import common modules
from
ptsexcept
import
*
from
ptsexcept
import
*
import
rr
import
rr
# Import specific modules
from
fmc_adc_spec
import
*
"""
"""
test35: Prints carrier CSR (without loading the gateware)
test35: Prints carrier CSR (without loading the gateware)
...
...
tests/test36.py
View file @
c52d7107
...
@@ -12,19 +12,14 @@ import sys
...
@@ -12,19 +12,14 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
# Import specific modules
sys
.
path
.
append
(
'../../../'
)
from
fmc_adc_spec
import
*
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
from
fmc_adc
import
*
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
# Import common modules
from
ptsexcept
import
*
from
ptsexcept
import
*
import
rr
import
rr
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
"""
"""
test36: Test SDB records
test36: Test SDB records
...
...
tests/test37.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
...
@@ -31,6 +22,10 @@ import find_usb_tty
...
@@ -31,6 +22,10 @@ import find_usb_tty
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test37: Test trigger timetags (single and multi shot modes)
test37: Test trigger timetags (single and multi shot modes)
...
...
tests/test38.py
View file @
c52d7107
...
@@ -12,18 +12,13 @@ import sys
...
@@ -12,18 +12,13 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
# Import specific modules
sys
.
path
.
append
(
'../../../'
)
from
fmc_adc_spec
import
*
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
# Import common modules
from
ptsexcept
import
*
from
ptsexcept
import
*
import
rr
import
rr
# Import specific modules
from
fmc_adc_spec
import
*
"""
"""
test38: Load gateware, try to access to an un-mapped wishbone address -> the host shouldn't hang!
test38: Load gateware, try to access to an un-mapped wishbone address -> the host shouldn't hang!
...
...
tests/test39.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
...
@@ -31,6 +22,10 @@ import find_usb_tty
...
@@ -31,6 +22,10 @@ import find_usb_tty
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test39: Tests saturation with/without gain/offset correction
test39: Tests saturation with/without gain/offset correction
...
...
tests/test40.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
...
@@ -32,6 +23,10 @@ import find_usb_tty
...
@@ -32,6 +23,10 @@ import find_usb_tty
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test40: Tests hardware internal trigger (threshold, deglitch)
test40: Tests hardware internal trigger (threshold, deglitch)
...
...
tests/test41.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
...
@@ -31,6 +22,10 @@ import find_usb_tty
...
@@ -31,6 +22,10 @@ import find_usb_tty
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test41: Tests shots counter
test41: Tests shots counter
...
...
tests/test42.py
View file @
c52d7107
...
@@ -12,21 +12,17 @@ import sys
...
@@ -12,21 +12,17 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
from
numpy
import
*
from
numpy
import
*
from
pylab
import
*
from
pylab
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test42: Tests sampling frequency counter
test42: Tests sampling frequency counter
"""
"""
...
...
tests/test43.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
...
@@ -31,6 +22,10 @@ import find_usb_tty
...
@@ -31,6 +22,10 @@ import find_usb_tty
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test43: Tests saturation (-> no wraparound)
test43: Tests saturation (-> no wraparound)
...
...
tests/test44.py
View file @
c52d7107
...
@@ -12,15 +12,6 @@ import sys
...
@@ -12,15 +12,6 @@ import sys
import
time
import
time
import
os
import
os
# Add common modules and libraries location to path
sys
.
path
.
append
(
'../../../'
)
sys
.
path
.
append
(
'../../../gnurabbit/python/'
)
sys
.
path
.
append
(
'../../../common/'
)
# Import common modules
from
ptsexcept
import
*
import
rr
# Import specific modules
# Import specific modules
from
fmc_adc_spec
import
*
from
fmc_adc_spec
import
*
from
fmc_adc
import
*
from
fmc_adc
import
*
...
@@ -32,6 +23,10 @@ import find_usb_tty
...
@@ -32,6 +23,10 @@ import find_usb_tty
from
PAGE.Agilent33250A
import
*
from
PAGE.Agilent33250A
import
*
from
PAGE.SineWaveform
import
*
from
PAGE.SineWaveform
import
*
# Import common modules
from
ptsexcept
import
*
import
rr
"""
"""
test44: Tests external trigger and datapath delay difference.
test44: Tests external trigger and datapath delay difference.
...
@@ -184,7 +179,7 @@ def main (default_directory='.'):
...
@@ -184,7 +179,7 @@ def main (default_directory='.'):
# Constants declaration
# Constants declaration
TEST_NB
=
44
TEST_NB
=
44
FMC_ADC_BITSTREAM
=
'../
firm
wares/spec_fmcadc100m14b4cha.bin'
FMC_ADC_BITSTREAM
=
'../
gate
wares/spec_fmcadc100m14b4cha.bin'
FMC_ADC_BITSTREAM
=
os
.
path
.
join
(
default_directory
,
FMC_ADC_BITSTREAM
)
FMC_ADC_BITSTREAM
=
os
.
path
.
join
(
default_directory
,
FMC_ADC_BITSTREAM
)
EXPECTED_BITSTREAM_TYPE
=
0x1
EXPECTED_BITSTREAM_TYPE
=
0x1
...
@@ -210,16 +205,16 @@ def main (default_directory='.'):
...
@@ -210,16 +205,16 @@ def main (default_directory='.'):
print
"Loading hardware access library and opening device.
\n
"
print
"Loading hardware access library and opening device.
\n
"
spec
=
rr
.
Gennum
()
spec
=
rr
.
Gennum
()
# Load FMC ADC
firm
ware
# Load FMC ADC
gate
ware
print
"Loading FMC ADC
firm
ware:
%
s
\n
"
%
FMC_ADC_BITSTREAM
print
"Loading FMC ADC
gate
ware:
%
s
\n
"
%
FMC_ADC_BITSTREAM
if
(
os
.
path
.
isfile
(
FMC_ADC_BITSTREAM
)):
if
(
os
.
path
.
isfile
(
FMC_ADC_BITSTREAM
)):
spec
.
load_
firm
ware
(
FMC_ADC_BITSTREAM
)
spec
.
load_
gate
ware
(
FMC_ADC_BITSTREAM
)
time
.
sleep
(
2
)
time
.
sleep
(
2
)
else
:
else
:
raise
PtsCritical
(
"
Firm
ware file
\"
%
s
\"
is missing, test stopped."
%
FMC_ADC_BITSTREAM
)
raise
PtsCritical
(
"
Gate
ware file
\"
%
s
\"
is missing, test stopped."
%
FMC_ADC_BITSTREAM
)
# Carrier object declaration (SPEC board specific part)
# Carrier object declaration (SPEC board specific part)
# Used to check that the
firm
ware is loaded.
# Used to check that the
gate
ware is loaded.
try
:
try
:
carrier
=
CFmcAdc100mSpec
(
spec
,
EXPECTED_BITSTREAM_TYPE
)
carrier
=
CFmcAdc100mSpec
(
spec
,
EXPECTED_BITSTREAM_TYPE
)
except
FmcAdc100mSpecOperationError
as
e
:
except
FmcAdc100mSpecOperationError
as
e
:
...
@@ -233,7 +228,7 @@ def main (default_directory='.'):
...
@@ -233,7 +228,7 @@ def main (default_directory='.'):
try
:
try
:
"""
# Others objects declaration
# Others objects declaration
usb_tty
=
find_usb_tty
.
CttyUSB
()
usb_tty
=
find_usb_tty
.
CttyUSB
()
awg_tty
=
usb_tty
.
find_usb_tty
(
AWG_USB_VENDOR_ID
,
AWG_USB_PRODUCT_ID
)
awg_tty
=
usb_tty
.
find_usb_tty
(
AWG_USB_VENDOR_ID
,
AWG_USB_PRODUCT_ID
)
...
@@ -241,7 +236,7 @@ def main (default_directory='.'):
...
@@ -241,7 +236,7 @@ def main (default_directory='.'):
gen
=
Agilent33250A
(
device
=
awg_tty
[
0
],
bauds
=
AWG_BAUD
)
gen
=
Agilent33250A
(
device
=
awg_tty
[
0
],
bauds
=
AWG_BAUD
)
sine
=
SineWaveform
()
sine
=
SineWaveform
()
box
=
CCalibr_box
(
box_tty
[
0
])
box
=
CCalibr_box
(
box_tty
[
0
])
"""
# Initialise fmc adc
# Initialise fmc adc
fmc_adc_init
(
spec
,
fmc
)
fmc_adc_init
(
spec
,
fmc
)
...
@@ -323,15 +318,16 @@ def main (default_directory='.'):
...
@@ -323,15 +318,16 @@ def main (default_directory='.'):
##################################################
##################################################
# Set awg sine params
# Set awg sine params
##################################################
##################################################
#sine.frequency = 20
E3
sine
.
frequency
=
1
E3
#
sine.amplitude = 0.4 * ADC_FS[IN_RANGE]
sine
.
amplitude
=
0.4
*
ADC_FS
[
IN_RANGE
]
#
sine.dc = 0
sine
.
dc
=
0
#print "\nSine frequency:%3.3fMHz amplitude:%2.3fVp offset:%2.3fV" % (sine.frequency/1E6, sine.amplitude, sine.dc)
#print "\nSine frequency:%3.3fMHz amplitude:%2.3fVp offset:%2.3fV" % (sine.frequency/1E6, sine.amplitude, sine.dc)
# Set AWG
# Set AWG
#
gen.connect()
gen
.
connect
()
#
gen.play(sine)
gen
.
play
(
sine
)
#gen.output = True
#gen.output = True
#time.sleep(AWG_SET_SLEEP)
gen
.
sync
=
True
time
.
sleep
(
AWG_SET_SLEEP
)
##################################################
##################################################
# Configure analogue input
# Configure analogue input
...
@@ -477,8 +473,9 @@ def main (default_directory='.'):
...
@@ -477,8 +473,9 @@ def main (default_directory='.'):
open_all_channels
(
fmc
)
open_all_channels
(
fmc
)
# Switch AWG OFF
# Switch AWG OFF
#gen.output = False
gen
.
output
=
False
#gen.close()
gen
.
sync
=
False
gen
.
close
()
# Check if an error occured during frequency response test
# Check if an error occured during frequency response test
# if(error != 0):
# if(error != 0):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment