From ae64313eced3acff0698647d37042ac32c852795 Mon Sep 17 00:00:00 2001 From: trotFunky Date: Wed, 13 Dec 2017 17:33:02 +0100 Subject: [PATCH] Script qui modifie le nom pour direct avoir les PID --- Perso/serialToCSV.sh | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/Perso/serialToCSV.sh b/Perso/serialToCSV.sh index c5778c2..0e810d4 100755 --- a/Perso/serialToCSV.sh +++ b/Perso/serialToCSV.sh @@ -6,12 +6,18 @@ boucle=true stty -F /dev/ttyACM0 115200 raw -echo -echoe -echok -rm -f ./serialOutput/serialOutput.csv -touch ./serialOutput/serialOutput.csv +if [ $# -eq 3 ]; then + fileName="./serialOutput/serialOutput-"$1","$2","$3".csv" +else + fileName="./serialOutput/serialOutput.csv" +fi + +rm -f $fileName +touch $fileName while $boucle; do read line < /dev/ttyACM0 - echo $line >> ./serialOutput/serialOutput.csv + echo $line >> $fileName done -python3 /home/trotfunky/Programmation/Git/Python/extraction_asserv.py \ No newline at end of file +python3 /home/trotfunky/Programmation/Git/Python/extraction_asserv.py $1 $2 $3 \ No newline at end of file