Commit 69ce3ca9 authored by Marek Gumiński's avatar Marek Gumiński

Desktop shortcut made executable.

Added rabbit icon.
Small changes in user questions.
ADC data is stored as image.
parent e8f511d0
......@@ -33,7 +33,7 @@ then
fi
apt-get install python-numpy python-scipy python-matplotlib ipython python2-pyro4 python-psutil python-dnspython
apt-get install git gitk libusb-dev
apt-get install git gitk libusb-dev terminator
# initialise and update repository
git submodule init
......@@ -94,8 +94,18 @@ fi
echo "Installation successful!"
echo "Creating desktop shortcut"
echo -e "[Desktop Entry]
Type=Application
Terminal=false
Name=PTSmasterFIP
Exec=terminator --working-directory=${PWD}/pts/ -e \"sudo -u root ${PWD}/pts/fmcmasterfip.sh ; bash\"
Icon=${PWD}/doc/icon.png
Comment=
Path=
StartupNotify=false
" > ~/Desktop/test_fmcmasterfip.desktop
# create desktop shortcut
echo "cd ${PWD}/pts/" > ~/Desktop/test_fmcmasterfip.sh
echo "./fmcmasterfip.sh" >> ~/Desktop/test_fmcmasterfip.sh
chmod +x ~/Desktop/test_fmcmasterfip.sh
\ No newline at end of file
# echo "cd ${PWD}/pts/" > ~/Desktop/test_fmcmasterfip.sh
# echo "./fmcmasterfip.sh" >> ~/Desktop/test_fmcmasterfip.sh
chmod +x ~/Desktop/test_fmcmasterfip.desktop
\ No newline at end of file
......@@ -57,6 +57,7 @@ class adc_conf:
self.trigger_threshold = 2048;
self.undersampling = 1;
self.output_file = "/tmp/data.bin";
self.output_img = "/tmp/image.png";
......@@ -319,7 +320,9 @@ class fmcmasterfip:
def save_transmission(self, path ):
if os.path.exists(self.adc_def_conf.output_file) :
shutil.move(self.adc_def_conf.output_file, path )
shutil.move(self.adc_def_conf.output_file, path+".bin" )
if os.path.exists(self.adc_def_conf.output_img) :
shutil.move(self.adc_def_conf.output_img, path+".png" )
###############################################################################################
......
......@@ -36,7 +36,7 @@ def speed_verification( dut ):
util.info_msg("Found %s speed version board" % speed_string[speed])
if util.ask_user("Detected %s FmcMasterFip speed version.\nPlease verify that %s resistors are mount and %s resistors are not mount." % ( speed_string[speed], mount[speed], notmount[speed] ) ):
if util.ask_user("Detected %s FmcMasterFip speed version.\nPlease verify that %s resistors are mount" % ( speed_string[speed], mount[speed] ) ):
result[ 'Speed specification'] = 1
else :
result[ 'Speed specification'] = 0
......
......@@ -67,7 +67,7 @@ def test_running_led( dut ):
util.section_msg("Testing LED's")
util.user_msg("Please observe FmcMasterfip front panel")
util.user_msg("Try to make sure that no more than one LED is enabled at a time")
util.user_msg("Please make sure that no more than one LED is enabled at a time")
util.ask_user("Are you ready to start a test?" )
for j in xrange(2):
......
......@@ -16,6 +16,8 @@ import numpy
import string
import matplotlib.pyplot as plt
PLOT=True
......@@ -271,6 +273,12 @@ def test_transmission( dut, transmission, should_succed = True, primary = True )
else:
result[ 'Captured ADC transmission' ] = 1
plt.plot(diff)
plt.ylabel("Signal [LSB]")
plt.xlabel("Time [samples]")
plt.savefig("/tmp/image.png")
plt.close()
###############################################
util.section_msg("Decoding acquired data")
util.info_msg("___________Please node that if an error occur in this section raw data should be examined.")
......
......@@ -117,8 +117,7 @@ def crit_msg( msg ):
raise Exception("Critical: %s" % msg )
def ask_user( question ):
user_msg(question);
user_msg("y/n")
user_msg(question+" (Y/n)");
ret = raw_input("")
info_msg("User was asked:")
......
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