Commit d313bf3d authored by Matthieu Cattin's avatar Matthieu Cattin

struct: Update paths, works in standalone, fails when launch from pts.

parent e6c22156
...@@ -47,7 +47,7 @@ do ...@@ -47,7 +47,7 @@ do
echo "Test series run $nb_test out of $nb_test_limit" echo "Test series run $nb_test out of $nb_test_limit"
echo " " echo " "
sudo ./pts.py -b FmcAdc100M14b4cha -s $serial -e $extra_serial -t./test/fmcadc100m14b4cha/python -l $LOGDIR 00 01 02 03 04 05 06 07 08 09 22 19 23 25 sudo ./pts/pts.py -b FmcAdc100M14b4cha -s $serial -e $extra_serial -t ./tests -l $LOGDIR 00 01 02 03 04 05 06 07 08 09 22 19 23 25
if [ "$nb_test" != "$nb_test_limit" ] if [ "$nb_test" != "$nb_test_limit" ]
then then
...@@ -69,4 +69,4 @@ read reply ...@@ -69,4 +69,4 @@ read reply
if [ "$reply" = "y" ] if [ "$reply" = "y" ]
then then
sudo shutdown -h now sudo shutdown -h now
fi fi
\ No newline at end of file
...@@ -5,4 +5,4 @@ echo "************************************************************************** ...@@ -5,4 +5,4 @@ echo "**************************************************************************
echo "* FmcAdc100M14b4cha Test program *" echo "* FmcAdc100M14b4cha Test program *"
echo "********************************************************************************" echo "********************************************************************************"
echo " " echo " "
cd ~/pts && sudo ./fmcadc100m14b4cha.sh cd ~/fmc-adc-tst && sudo ./fmcadc100m14b4cha.sh
...@@ -13,8 +13,13 @@ import time ...@@ -13,8 +13,13 @@ import time
import random import random
import math import math
# Add common modules and libraries location to path
sys.path.append('../pts/')
sys.path.append('../pts/gnurabbit/python/')
sys.path.append('../pts/common/')
sys.path.append('../pts/common/fmceeprom/')
# Import specific modules # Import specific modules
#import rr
from sdb import * from sdb import *
from csr import * from csr import *
from onewire import * from onewire import *
......
...@@ -12,19 +12,13 @@ import sys ...@@ -12,19 +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 *
""" """
test00: Load gateware, verify gateware type and test mezzanine presence line. test00: Load gateware, verify gateware type and test mezzanine presence line.
""" """
......
...@@ -12,19 +12,13 @@ import sys ...@@ -12,19 +12,13 @@ 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 *
# Import common modules
from ptsexcept import *
import rr
""" """
test01: Test 1-wire thermometer and read the unique ID. test01: Test 1-wire thermometer and read the unique ID.
......
...@@ -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 *
""" """
test02: Test EEPROM access test02: Test EEPROM access
......
...@@ -12,19 +12,13 @@ import sys ...@@ -12,19 +12,13 @@ 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 *
# Import common modules
from ptsexcept import *
import rr
""" """
test03: Test mezzanine front-panel LEDs test03: Test mezzanine front-panel LEDs
......
...@@ -11,19 +11,14 @@ import sys ...@@ -11,19 +11,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 *
""" """
test04: Test Si570 programmable oscillator test04: Test Si570 programmable oscillator
......
...@@ -11,19 +11,14 @@ import sys ...@@ -11,19 +11,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 *
""" """
test05: Test LTC2174 ADC test05: Test LTC2174 ADC
......
...@@ -11,19 +11,13 @@ import sys ...@@ -11,19 +11,13 @@ 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 *
# Import common modules
from ptsexcept import *
import rr
from PAGE.Agilent33250A import * from PAGE.Agilent33250A import *
......
...@@ -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
""" """
test07: Test offset DACs test07: Test offset DACs
......
...@@ -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 *
...@@ -30,6 +21,10 @@ import find_usb_tty ...@@ -30,6 +21,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
""" """
test08: Test analogue front-end switches test08: Test analogue front-end switches
......
...@@ -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
""" """
test09: Test analogue front-end frequency response, test09: Test analogue front-end frequency response,
......
...@@ -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 *
...@@ -33,6 +24,10 @@ import find_usb_tty ...@@ -33,6 +24,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
""" """
test19: Calibration test19: Calibration
......
...@@ -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
""" """
test22: Test FMC temperature stability test22: Test FMC temperature stability
......
...@@ -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 *
""" """
test23: Write IPMI information and calibration data to FMC EEPROM. test23: Write IPMI information and calibration data to FMC EEPROM.
...@@ -47,7 +41,7 @@ def main (default_directory='.'): ...@@ -47,7 +41,7 @@ def main (default_directory='.'):
MANUFACTURER = "CERN" MANUFACTURER = "CERN"
PRODUCT_NAME = "FmcAdc100m14b4cha" PRODUCT_NAME = "FmcAdc100m14b4cha"
PART_NUMBER = "EDA-02063-V5-0" PART_NUMBER = "EDA-02063-V5-0"
SERIAL_FILENAME = "../../../serial.txt" SERIAL_FILENAME = "../serial.txt"
SERIAL_FILENAME = os.path.join(default_directory, SERIAL_FILENAME) SERIAL_FILENAME = os.path.join(default_directory, SERIAL_FILENAME)
CALIBR_FILENAME = "calibration_data.txt" CALIBR_FILENAME = "calibration_data.txt"
CALIBR_FILENAME = os.path.join(default_directory, CALIBR_FILENAME) CALIBR_FILENAME = os.path.join(default_directory, CALIBR_FILENAME)
......
...@@ -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,10 @@ from PAGE.Agilent33250A import * ...@@ -35,6 +24,10 @@ 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
""" """
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment