Commit 655d0e02db8688faa9c6d11981cae0c622bc7ce3
1 parent
b186066f
feat(*): ajout des fichiers de recherche des commandes+ajout de deux interfaces test (sans onglets)
Showing
94 changed files
with
1537 additions
and
89 deletions
Show diff stats
README.md
html/Captures/Siglent_SDS1102CML_SDS1MEBX2R2090_6_01_01_19.bmp
No preview for this file type
html/Captures/Siglent_Technologies_SDG1032X_SDG1XCAX3R0874_1_01_01_33R1.bmp
No preview for this file type
... | ... | @@ -0,0 +1,22 @@ |
1 | +<?php | |
2 | + $chemin = getcwd().'/'.$Appareil[$i]['type']; | |
3 | + $files = array_diff(scandir($chemin),array('..','.')); | |
4 | + foreach($files as $Fich){ | |
5 | + $path = $chemin.'/'.$Fich; | |
6 | + if(is_dir($path)){ | |
7 | + $files = array_diff(scandir($path),array('..','.')); | |
8 | + foreach($files as $dir){ | |
9 | + $path2 = $path.'/'.$dir; | |
10 | + if(is_dir($path2)){ | |
11 | + $files2 = array_diff(scandir($path2),array('..','.')); | |
12 | + foreach($files2 as $cmd){ | |
13 | + $path3 = $path2.'/'.$cmd; | |
14 | + if(is_file($path3) && strpos($path3,"cmd")!=false){ | |
15 | + include($path3); | |
16 | + } | |
17 | + } | |
18 | + } | |
19 | + } | |
20 | + } | |
21 | + } | |
22 | +?> | ... | ... |
html/Generateur/main_generateur.php
1 | 1 | <!DOCTYPE html> |
2 | 2 | <html> |
3 | 3 | <?php |
4 | + if(isset($_GET['tab'])){ | |
5 | + $tab=$_GET['tab']; | |
6 | + }else{ | |
7 | + $tab="Global"; | |
8 | + } | |
4 | 9 | echo '<div class="d-md-flex flex-md-equal w-100 my-md-3 pl-md-3">'; |
5 | 10 | echo '<div class="mr-md-3 pt-3 px-3 pt-md-5 px-md-5 text-center">'; |
6 | - /* Affichage de la capture d'ecran */ | |
7 | - usleep(90000); /* Utilisation pour un premier screenshot plus propre */ | |
8 | - /* Nom de la capture d'ecran au nom de l'appareil */ | |
9 | - $pic_name[$i] = str_replace(".","_",$Appareil[$i]['nom']); | |
10 | - $pic_name[$i] = str_replace(" ","_",$pic_name[$i]); | |
11 | - $pic_name[$i] = str_replace("+","",$pic_name[$i]); | |
12 | - $pic_name[$i] = str_replace(",","_",$pic_name[$i]).".bmp"; | |
13 | - $pic_name[$i] = 'Captures/'.$pic_name[$i]; | |
14 | - $_SESSION['pic_name'] = $pic_name[$i]; | |
15 | - include(getcwd().'/Scripts/screenshot.php'); /* Execution commande screenshot */ | |
16 | - /* Recuperation du nom du fichier a partir du chemin complet */ | |
17 | - echo "<img id='cam$i' class='fit-picture' src='".$pic_name[$i]."' alt='Image de ".$Appareil[$i]['nom']."'>"; | |
11 | + /* Affichage image */ | |
12 | + include('./Scripts/creation_img.php'); | |
18 | 13 | echo '</div>'; |
19 | 14 | echo '<div class="bg-light mr-md-3 pt-3 px-3 pt-md-5 px-md-5 overflow-hidden">'; |
20 | 15 | /* Commandes de l'appareil */ | ... | ... |
html/Generateur_test/Fonctions/Burst/form_burst.php
0 → 100644
... | ... | @@ -0,0 +1,24 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <style> | |
4 | + .pannel-button{ | |
5 | + font-size: 1.6em; | |
6 | + height: 40px; | |
7 | + width: 200px; | |
8 | + text-align: center; | |
9 | + color: #000; | |
10 | + background: #fff; | |
11 | + border-radius: 10px; | |
12 | + } | |
13 | + .pannel-button:hover{ | |
14 | + background: #b8ff70; | |
15 | + } | |
16 | + .pannel-button:active{ | |
17 | + background: #07e50a; | |
18 | + } | |
19 | + </style> | |
20 | + <form method="post" action="main.php"> | |
21 | + <input type="button" id="burst" name="burst" class="pannel-button" value="Burst" onclick="this.form.submit()"/> | |
22 | + <input type="hidden" id="burst" name="burst" value="BURST"/> | |
23 | + </form> | |
24 | +</html> | ... | ... |
html/Generateur_test/Fonctions/Channel/cmd_channel.php
0 → 100644
html/Generateur_test/Fonctions/Channel/form_channel.php
0 → 100644
... | ... | @@ -0,0 +1,7 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <input type="button" id="channel" name="channel" class="pannel-button" value="Channel" onclick="this.form.submit()"/> | |
5 | + <input type="hidden" id="channel" name="channel" value="CHANNEL"/> | |
6 | + </form> | |
7 | +</html> | ... | ... |
html/Generateur_test/Fonctions/Parameter/cmd_parameter.php
0 → 100644
html/Generateur_test/Fonctions/Parameter/form_parameter.php
0 → 100644
... | ... | @@ -0,0 +1,7 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <input type="button" id="parameter" name="parameter" class="pannel-button" value="Parametre" onclick="this.form.submit()"/> | |
5 | + <input type="hidden" id="parameter" name="parameter" value="PARAMETER"/> | |
6 | + </form> | |
7 | +</html> | ... | ... |
html/Generateur_test/Fonctions/Sweep/form_sweep.php
0 → 100644
... | ... | @@ -0,0 +1,7 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <input type="button" id="sweep" name="sweep" class="pannel-button" value="Sweep" onclick="this.form.submit()"/> | |
5 | + <input type="hidden" id="sweep" name="sweep" value="SWEEP"/> | |
6 | + </form> | |
7 | +</html> | ... | ... |
html/Generateur_test/Fonctions/Utility/cmd_utility.php
0 → 100644
html/Generateur_test/Fonctions/Utility/form_utility.php
0 → 100644
... | ... | @@ -0,0 +1,7 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <input type="button" id="utility" name="utility" class="pannel-button" value="Utility" onclick="this.form.submit()"/> | |
5 | + <input type="hidden" id="utility" name="utility" value="UTILITY"/> | |
6 | + </form> | |
7 | +</html> | ... | ... |
html/Generateur_test/Fonctions/Waves/form_waves.php
0 → 100644
... | ... | @@ -0,0 +1,7 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <input type="button" id="waves" name="waves" class="pannel-button" value="Waveforms" onclick="this.form.submit()"/> | |
5 | + <input type="hidden" id="waves" name="waves" value="WAVES"/> | |
6 | + </form> | |
7 | +</html> | ... | ... |
html/Generateur_test/Global/Chiffres/cmd_chiffres.php
0 → 100644
html/Generateur_test/Global/Chiffres/form_chiffres.php
0 → 100644
... | ... | @@ -0,0 +1,83 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <style> | |
4 | + .pave-numerique{ | |
5 | + font-size: 1.6em; | |
6 | + height: 40px; | |
7 | + width: 50px; | |
8 | + text-align: center; | |
9 | + color: #000; | |
10 | + background: #fff; | |
11 | + border-radius: 10px; | |
12 | + } | |
13 | + .pave-numerique:hover{ | |
14 | + background: #b8ff70; | |
15 | + } | |
16 | + .pave-numerique:active{ | |
17 | + background: #07e50a; | |
18 | + } | |
19 | + </style> | |
20 | + <div class="w-100 my-md-3 pl-md-3 text-center"> | |
21 | + <div class="text-center"> | |
22 | + <div class="btn-group" role="group" aria-label="panel-haut"> | |
23 | + <form method="post" action="main.php"> | |
24 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="7" onclick="this.form.submit();"/> | |
25 | + <input type="hidden" id="chiffre" name="chiffre" value="NUMBER_7"/> | |
26 | + </form> | |
27 | + <form method="post" action="main.php"> | |
28 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="8" onclick="this.form.submit();"/> | |
29 | + <input type="hidden" id="chiffre" name="chiffre" value="NUMBER_8"/> | |
30 | + </form> | |
31 | + <form method="post" action="main.php"> | |
32 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="9" onclick="this.form.submit();"/> | |
33 | + <input type="hidden" id="chiffre" name="chiffre" value="NUMBER_9"/> | |
34 | + </form> | |
35 | + </div> | |
36 | + <br/> | |
37 | + <div class="btn-group" role="group" aria-label="panel-centre-haut"> | |
38 | + <form method="post" action="main.php"> | |
39 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="4" onclick="this.form.submit();"/> | |
40 | + <input type="hidden" id="chiffre" name="chiffre" value="NUMBER_4"/> | |
41 | + </form> | |
42 | + <form method="post" action="main.php"> | |
43 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="5" onclick="this.form.submit();"/> | |
44 | + <input type="hidden" id="chiffre" name="chiffre" value="NUMBER_5"/> | |
45 | + </form> | |
46 | + <form method="post" action="main.php"> | |
47 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="6" onclick="this.form.submit();"/> | |
48 | + <input type="hidden" id="chiffre" name="chiffre" value="NUMBER_6"/> | |
49 | + </form> | |
50 | + </div> | |
51 | + <br/> | |
52 | + <div class="btn-group" role="group" aria-label="panel-centre-bas"> | |
53 | + <form method="post" action="main.php"> | |
54 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="1" onclick="this.form.submit();"/> | |
55 | + <input type="hidden" id="chiffre" name="chiffre" value="NUMBER_1"/> | |
56 | + </form> | |
57 | + <form method="post" action="main.php"> | |
58 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="2" onclick="this.form.submit();"/> | |
59 | + <input type="hidden" id="chiffre" name="chiffre" value="NUMBER_2"/> | |
60 | + </form> | |
61 | + <form method="post" action="main.php"> | |
62 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="3" onclick="this.form.submit();"/> | |
63 | + <input type="hidden" id="chiffre" name="chiffre" value="NUMBER_3"/> | |
64 | + </form> | |
65 | + </div> | |
66 | + <br/> | |
67 | + <div class="btn-group" role="group" aria-label="panel-bas"> | |
68 | + <form method="post" action="main.php"> | |
69 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="." onclick="this.form.submit();"/> | |
70 | + <input type="hidden" id="chiffre" name="chiffre" value="POINT"/> | |
71 | + </form> | |
72 | + <form method="post" action="main.php"> | |
73 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="0" onclick="this.form.submit();"/> | |
74 | + <input type="hidden" id="chiffre" name="chiffre" value="NUMBER_0"/> | |
75 | + </form> | |
76 | + <form method="post" action="main.php"> | |
77 | + <input type="button" id="chiffre" name="chiffre" class="pave-numerique" value="+/-" onclick="this.form.submit();"/> | |
78 | + <input type="hidden" id="chiffre" name="chiffre" value="NEGATIVE"/> | |
79 | + </form> | |
80 | + </div> | |
81 | + </div> | |
82 | + </div> | |
83 | +</html> | ... | ... |
html/Generateur_test/Global/Fleches/cmd_fleches.php
0 → 100644
html/Generateur_test/Global/Fleches/form_fleches.php
0 → 100644
... | ... | @@ -0,0 +1,15 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <div class="text-center"> | |
4 | + <div class="btn-group" role="group" aria-label="gauche_droite"> | |
5 | + <form method="post" action="main.php?tab=Global"> | |
6 | + <input type="button" id="fleches" name="fleches" class="pave-numerique" value="<" onclick="this.form.submit();"/> | |
7 | + <input type="hidden" id="fleches" name="fleches" value="LEFT"/> | |
8 | + </form> | |
9 | + <form method="post" action="main.php?tab=Global"> | |
10 | + <input type="button" id="fleches" name="fleches" class="pave-numerique" value=">" onclick="this.form.submit();"/> | |
11 | + <input type="hidden" id="fleches" name="fleches" value="RIGHT"/> | |
12 | + </form> | |
13 | + </div> | |
14 | + </div> | |
15 | +</html> | ... | ... |
16 KB
... | ... | @@ -0,0 +1,36 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <style> | |
4 | + .knob-button{ | |
5 | + font-size: 2.5em; | |
6 | + height: 125px; | |
7 | + width: 50px; | |
8 | + text-align: center; | |
9 | + color: #000; | |
10 | + background: #fff; | |
11 | + border-radius: 10px; | |
12 | + } | |
13 | + .knob-button:hover{ | |
14 | + background: #b8ff70; | |
15 | + } | |
16 | + .knob-button:active{ | |
17 | + background: #07e50a; | |
18 | + } | |
19 | + </style> | |
20 | + <div aria-label="bouton_tournant"> | |
21 | + <div class="btn-group" role="group" aria-label="panel-haut"> | |
22 | + <form method="post" action="main.php?tab=Global"> | |
23 | + <input type="button" id="knob" name="knob" class="knob-button" value="↱" onclick="this.form.submit();"/> | |
24 | + <input type="hidden" id="knob" name="knob" value="KNOB_RIGHT" class="btn btn-outline-danger"/> | |
25 | + </form> | |
26 | + <form method="post" action="main.php?tab=Global"> | |
27 | + <input type="image" src="Generateur/Global/Knob/btn_knob_generateur.png" name="submit" onclick="this.form.submit()"/> | |
28 | + <input type="hidden" id="chiffre" name="chiffre" value="KNOB_DOWN"/> | |
29 | + </form> | |
30 | + <form method="post" action="main.php?tab=Global"> | |
31 | + <input type="button" id="knob" name="knob" class="knob-button" value="↰" onclick="this.form.submit();"/> | |
32 | + <input type="hidden" id="knob" name="knob" value="KNOB_LEFT" class="btn btn-outline-danger"/> | |
33 | + </form> | |
34 | + </div> | |
35 | + </div> | |
36 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,13 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <input type="button" id="func1" name="func1" class="func-button" value="" onclick="this.form.submit()"/> | |
5 | + <input type="hidden" id="func1" name="func1" value="FUNC1" class="btn-outline-danger"/> | |
6 | + </form> | |
7 | + <script type='text/javascript'> | |
8 | + var elem = document.getElementById('cam<?php echo $i ?>'); | |
9 | + var pos = elem.getBoundingClientRect(); | |
10 | + var btn = document.getElementById('func1'); | |
11 | + btn.style = "top : "+pos.bottom+"px; left : "+pos.x+"px"; | |
12 | + </script> | |
13 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,13 @@ |
1 | +<html> | |
2 | + <form method="post" action="main.php"> | |
3 | + <input type="button" id="func2" name="func2" class="func-button" value="" onclick="this.form.submit()"/> | |
4 | + <input type="hidden" id="func2" name="func2" value="FUNC2" class="btn-outline-danger"/> | |
5 | + </form> | |
6 | + <script type='text/javascript'> | |
7 | + var elem = document.getElementById('cam<?php echo $i ?>'); | |
8 | + var pos = elem.getBoundingClientRect(); | |
9 | + var btn = document.getElementById('func2'); | |
10 | + var pos_x = pos.x+80; | |
11 | + btn.style = "top : "+(pos.bottom)+"px; left : "+(pos_x)+"px"; | |
12 | + </script> | |
13 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,13 @@ |
1 | +<html> | |
2 | + <form method="post" action="main.php"> | |
3 | + <input type="button" id="func3" name="func3" class="func-button" value="" onclick="this.form.submit()"/> | |
4 | + <input type="hidden" id="func3" name="func3" value="FUNC3" class="btn-outline-danger"/> | |
5 | + </form> | |
6 | + <script type='text/javascript'> | |
7 | + var elem = document.getElementById('cam<?php echo $i ?>'); | |
8 | + var pos = elem.getBoundingClientRect(); | |
9 | + var btn = document.getElementById('func3'); | |
10 | + var pos_x = pos.x+160; | |
11 | + btn.style = "top : "+(pos.bottom)+"px; left : "+(pos_x)+"px"; | |
12 | + </script> | |
13 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,13 @@ |
1 | +<html> | |
2 | + <form method="post" action="main.php"> | |
3 | + <input type="button" id="func4" name="func4" class="func-button" value="" onclick="this.form.submit()"/> | |
4 | + <input type="hidden" id="func4" name="func4" value="FUNC4" class="btn-outline-danger"/> | |
5 | + </form> | |
6 | + <script type='text/javascript'> | |
7 | + var elem = document.getElementById('cam<?php echo $i ?>'); | |
8 | + var pos = elem.getBoundingClientRect(); | |
9 | + var btn = document.getElementById('func4'); | |
10 | + var pos_x = pos.x+240; | |
11 | + btn.style = "top : "+(pos.bottom)+"px; left : "+(pos_x)+"px"; | |
12 | + </script> | |
13 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,13 @@ |
1 | +<html> | |
2 | + <form method="post" action="main.php"> | |
3 | + <input type="button" id="func5" name="func5" class="func-button" value="" onclick="this.form.submit()"/> | |
4 | + <input type="hidden" id="func5" name="func5" value="FUNC5" class="btn-outline-danger"/> | |
5 | + </form> | |
6 | + <script type='text/javascript'> | |
7 | + var elem = document.getElementById('cam<?php echo $i ?>'); | |
8 | + var pos = elem.getBoundingClientRect(); | |
9 | + var btn = document.getElementById('func5'); | |
10 | + var pos_x = pos.x+320; | |
11 | + btn.style = "top : "+(pos.bottom)+"px; left : "+(pos_x)+"px"; | |
12 | + </script> | |
13 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,13 @@ |
1 | +<html> | |
2 | + <form method="post" action="main.php"> | |
3 | + <input type="button" id="func6" name="func6" class="func-button" value="" onclick="this.form.submit()"/> | |
4 | + <input type="hidden" id="func6" name="func6" value="FUNC6"/> | |
5 | + </form> | |
6 | + <script type='text/javascript'> | |
7 | + var elem = document.getElementById('cam<?php echo $i ?>'); | |
8 | + var pos = elem.getBoundingClientRect(); | |
9 | + var btn = document.getElementById('func6'); | |
10 | + var pos_x = pos.x+400; | |
11 | + btn.style = "top : "+(pos.bottom)+"px; left : "+(pos_x)+"px"; | |
12 | + </script> | |
13 | +</html> | ... | ... |
html/Generateur_test/Outputs/Output1/cmd_output_1.php
0 → 100644
html/Generateur_test/Outputs/Output1/form_output_1.php
0 → 100644
... | ... | @@ -0,0 +1,7 @@ |
1 | +<!DOCTYPE> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <input type="button" id="output1" name="output1" class="pannel-button" value="Output1" onclick="this.form.submit()"/> | |
5 | + <input type="hidden" id="output1" name="output1" value="OUTPUT1"/> | |
6 | + </form> | |
7 | +</html> | ... | ... |
html/Generateur_test/Outputs/Output2/cmd_output_2.php
0 → 100644
html/Generateur_test/Outputs/Output2/form_output_2.php
0 → 100644
... | ... | @@ -0,0 +1,7 @@ |
1 | +<!DOCTYPE> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <input type="button" id="output2" name="output2" class="pannel-button" value="Output2" onclick="this.form.submit()"/> | |
5 | + <input type="hidden" id="output2" name="output2" value="OUTPUT2"/> | |
6 | + </form> | |
7 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,22 @@ |
1 | +<?php | |
2 | + $chemin = getcwd().'/'.$Appareil[$i]['type']; | |
3 | + $files = array_diff(scandir($chemin),array('..','.')); | |
4 | + foreach($files as $Fich){ | |
5 | + $path = $chemin.'/'.$Fich; | |
6 | + if(is_dir($path)){ | |
7 | + $files = array_diff(scandir($path),array('..','.')); | |
8 | + foreach($files as $dir){ | |
9 | + $path2 = $path.'/'.$dir; | |
10 | + if(is_dir($path2)){ | |
11 | + $files2 = array_diff(scandir($path2),array('..','.')); | |
12 | + foreach($files2 as $cmd){ | |
13 | + $path3 = $path2.'/'.$cmd; | |
14 | + if(is_file($path3) && strpos($path3,"cmd")!=false){ | |
15 | + include($path3); | |
16 | + } | |
17 | + } | |
18 | + } | |
19 | + } | |
20 | + } | |
21 | + } | |
22 | +?> | ... | ... |
... | ... | @@ -0,0 +1,60 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <style> | |
4 | + .func-button{ | |
5 | + height: 30px; | |
6 | + width: 80px; | |
7 | + background: #fff; | |
8 | + border-radius: 10px; | |
9 | + position: absolute; | |
10 | + } | |
11 | + .func-button:hover{ | |
12 | + background: #b8ff70; | |
13 | + } | |
14 | + .func-button:active{ | |
15 | + background: #07e50a; | |
16 | + } | |
17 | + </style> | |
18 | + <?php | |
19 | + echo '<div class="d-md-flex flex-md-equal w-100 my-md-3 pl-md-3">'; | |
20 | + echo '<div class="mr-md-3 pt-3 px-3 pt-md-5 px-md-5 text-center">'; | |
21 | + /* Affichage image */ | |
22 | + include('./Scripts/creation_img.php'); | |
23 | + echo '</div>'; | |
24 | + echo '<div class="bg-light mr-md-3 pt-3 px-3 pt-md-5 px-md-5 overflow-hidden">'; | |
25 | + /* Commandes de l'appareil */ | |
26 | + echo '<div class="my-3 py-3">'; | |
27 | + echo '<h2 class="display-6 text-center">Panel de commande</h2>'; | |
28 | + echo '</div>'; | |
29 | + $chemin = getcwd().'/'.$Appareil[$i]['type']; | |
30 | + $files = array_diff(scandir($chemin),array('..','.')); | |
31 | + echo '<div class="d-md-flex flex-md-equal w-100 my-md-3 pl-md-3">'; | |
32 | + foreach($files as $Fich){ | |
33 | + $path = $chemin.'/'.$Fich; | |
34 | + if(is_dir($path)){ | |
35 | + $files = array_diff(scandir($path),array('..','.')); | |
36 | + if($Fich!="Menus"){ | |
37 | + echo '<div class="mr-md-1 pt-1 px-1 pt-md-1 px-md-1">'; | |
38 | + } | |
39 | + foreach($files as $dir){ | |
40 | + $path2 = $path.'/'.$dir; | |
41 | + if(is_dir($path2)){ | |
42 | + $new_dir = array_diff(scandir($path2),array('..','.')); | |
43 | + foreach($new_dir as $form){ | |
44 | + $path3 = $path2.'/'.$form; | |
45 | + if(is_file($path3) && strpos($path3,"form")!=false){ | |
46 | + include($path3); | |
47 | + } | |
48 | + } | |
49 | + } | |
50 | + } | |
51 | + if($Fich!="Menus"){ | |
52 | + echo '</div>'; | |
53 | + } | |
54 | + } | |
55 | + } | |
56 | + echo '</div>'; | |
57 | + echo '</div>'; | |
58 | + echo '</div>'; | |
59 | + ?> | |
60 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,22 @@ |
1 | +<?php | |
2 | + $chemin = getcwd().'/'.$Appareil[$i]['type']; | |
3 | + $files = array_diff(scandir($chemin),array('..','.')); | |
4 | + foreach($files as $Fich){ | |
5 | + $path = $chemin.'/'.$Fich; | |
6 | + if(is_dir($path)){ | |
7 | + $files = array_diff(scandir($path),array('..','.')); | |
8 | + foreach($files as $dir){ | |
9 | + $path2 = $path.'/'.$dir; | |
10 | + if(is_dir($path2)){ | |
11 | + $files2 = array_diff(scandir($path2),array('..','.')); | |
12 | + foreach($files2 as $cmd){ | |
13 | + $path3 = $path2.'/'.$cmd; | |
14 | + if(is_file($path3) && strpos($path3,"cmd")!=false){ | |
15 | + include($path3); | |
16 | + } | |
17 | + } | |
18 | + } | |
19 | + } | |
20 | + } | |
21 | + } | |
22 | +?> | ... | ... |
html/Oscilloscope/main_oscilloscope.php
1 | 1 | <!DOCTYPE html> |
2 | 2 | <html> |
3 | 3 | <?php |
4 | + if(isset($_GET['tab'])){ | |
5 | + $tab=$_GET['tab']; | |
6 | + }else{ | |
7 | + $tab="Global"; | |
8 | + } | |
4 | 9 | echo '<div class="d-md-flex flex-md-equal w-100 my-md-3 pl-md-3">'; |
5 | 10 | echo '<div class="mr-md-3 pt-3 px-3 pt-md-5 px-md-5 text-center">'; |
6 | - /* Affichage de la capture d'ecran */ | |
7 | - usleep(90000); /* Utilisation pour un premier screenshot plus propre */ | |
8 | - /* Nom de la capture d'ecran au nom de l'appareil */ | |
9 | - $pic_name[$i] = str_replace(".","_",$Appareil[$i]['nom']); | |
10 | - $pic_name[$i] = str_replace(" ","_",$pic_name[$i]); | |
11 | - $pic_name[$i] = str_replace("+","",$pic_name[$i]); | |
12 | - $pic_name[$i] = str_replace(",","_",$pic_name[$i]).".bmp"; | |
13 | - $pic_name[$i] = 'Captures/'.$pic_name[$i]; | |
14 | - $_SESSION['pic_name'] = $pic_name[$i]; | |
15 | - include(getcwd().'/Scripts/screenshot.php'); /* Execution commande screenshot */ | |
16 | - /* Recuperation du nom du fichier a partir du chemin complet */ | |
17 | - echo "<img id='cam$i' class='fit-picture' src='".$pic_name[$i]."' alt='Image de ".$Appareil[$i]['nom']."'>"; | |
11 | + /* Affichage image */ | |
12 | + include('./Scripts/creation_img.php'); | |
18 | 13 | echo '</div>'; |
19 | 14 | echo '<div class="bg-light mr-md-3 pt-3 px-3 pt-md-5 px-md-5 overflow-hidden">'; |
20 | 15 | /* Commandes de l'appareil */ |
21 | - echo '<div class="my-3 py-3">'; | |
22 | - echo '<h2 class="display-6 text-center">Panel de commande</h2>'; | |
23 | - echo '</div>'; | |
24 | - echo '<div class="bd-example">'; | |
25 | - echo '<nav>'; | |
26 | - echo '<div class="bg-warning nav nav-tabs mb-3" id="nav-tab" role="tablist">'; | |
27 | - $chemin = getcwd().'/'.$Appareil[$i]['type']; | |
28 | - $files = array_diff(scandir($chemin),array('..','.')); | |
29 | - foreach($files as $Fich){ | |
30 | - $trypath = $chemin.'/'.$Fich; | |
31 | - if(is_dir($trypath)){ | |
32 | - echo '<button class="nav-link '; | |
33 | - if($tab==$Fich){ | |
34 | - echo "active"; | |
35 | - } | |
36 | - echo '" id="nav-'.$Fich.'-tab" data-bs-toggle="tab" data-bs-target="#nav-'.$Fich.'" type="button" role="tab" aria-controls="nav-'.$Fich.'" aria-selected="true">'.$Fich.'</button>'; | |
37 | - } | |
38 | - } | |
39 | - echo '</div>'; | |
40 | - echo '</nav>'; | |
41 | - echo '<div class="tab-content" id="nav-tabContent">'; | |
42 | - foreach($files as $Fich){ | |
43 | - $path = $chemin.'/'.$Fich; | |
44 | - if(is_dir($path)){ | |
45 | - echo '<div class="tab-pane fade '; | |
46 | - if($tab==$Fich){ | |
47 | - echo "show active"; | |
48 | - } | |
49 | - echo '" id="nav-'.$Fich.'" role=tabpanel" aria-labelledby="nav-'.$Fich.'-tab">'; | |
50 | - echo '<p>'; | |
51 | - $files = array_diff(scandir($path),array('..','.')); | |
52 | - foreach($files as $dir){ | |
53 | - $path2 = $path.'/'.$dir; | |
54 | - if(is_dir($path2)){ | |
55 | - $files2 = array_diff(scandir($path2),array('..','.')); | |
56 | - foreach($files2 as $form){ | |
57 | - $path3 = $path2.'/'.$form; | |
58 | - if(is_file($path3) && strpos($path3,"form")!=false){ | |
59 | - include($path3); | |
60 | - echo '<br/>'; | |
61 | - } | |
62 | - } | |
63 | - } | |
64 | - } | |
65 | - echo '</p>'; | |
66 | - echo '</div>'; | |
16 | + echo '<div class="my-3 py-3">'; | |
17 | + echo '<h2 class="display-6 text-center">Panel de commande</h2>'; | |
18 | + echo '</div>'; | |
19 | + echo '<div class="bd-example">'; | |
20 | + echo '<nav>'; | |
21 | + echo '<div class="bg-warning nav nav-tabs mb-3" id="nav-tab" role="tablist">'; | |
22 | + $chemin = getcwd().'/'.$Appareil[$i]['type']; | |
23 | + $files = array_diff(scandir($chemin),array('..','.')); | |
24 | + foreach($files as $Fich){ | |
25 | + $trypath = $chemin.'/'.$Fich; | |
26 | + if(is_dir($trypath)){ | |
27 | + echo '<button class="nav-link '; | |
28 | + if($tab==$Fich){ | |
29 | + echo "active"; | |
30 | + } | |
31 | + echo '" id="nav-'.$Fich.'-tab" data-bs-toggle="tab" data-bs-target="#nav-'.$Fich.'" type="button" role="tab" aria-controls="nav-'.$Fich.'" aria-selected="true">'.$Fich.'</button>'; | |
32 | + } | |
33 | + } | |
34 | + echo '</div>'; | |
35 | + echo '</nav>'; | |
36 | + echo '<div class="tab-content" id="nav-tabContent">'; | |
37 | + foreach($files as $Fich){ | |
38 | + $path = $chemin.'/'.$Fich; | |
39 | + if(is_dir($path)){ | |
40 | + echo '<div class="tab-pane fade '; | |
41 | + if($tab==$Fich){ | |
42 | + echo "show active"; | |
43 | + } | |
44 | + echo '" id="nav-'.$Fich.'" role=tabpanel" aria-labelledby="nav-'.$Fich.'-tab">'; | |
45 | + echo '<p>'; | |
46 | + $files = array_diff(scandir($path),array('..','.')); | |
47 | + foreach($files as $dir){ | |
48 | + $path2 = $path.'/'.$dir; | |
49 | + if(is_dir($path2)){ | |
50 | + $files2 = array_diff(scandir($path2),array('..','.')); | |
51 | + foreach($files2 as $form){ | |
52 | + $path3 = $path2.'/'.$form; | |
53 | + if(is_file($path3) && strpos($path3,"form")!=false){ | |
54 | + include($path3); | |
55 | + echo '<br/>'; | |
67 | 56 | } |
68 | - } | |
69 | - echo '</div>'; | |
70 | - echo '</div>'; | |
57 | + } | |
58 | + } | |
59 | + } | |
60 | + echo '</p>'; | |
71 | 61 | echo '</div>'; |
62 | + } | |
63 | + } | |
64 | + echo '</div>'; | |
65 | + echo '</div>'; | |
66 | + echo '</div>'; | |
72 | 67 | echo '</div>'; |
73 | 68 | ?> |
74 | 69 | </html> | ... | ... |
... | ... | @@ -0,0 +1,12 @@ |
1 | +<?php | |
2 | + /* Commande Tracer CH1 */ | |
3 | + $trace_c1 = shell_exec('lxi scpi -a '.$adresse.' "c1:tra?"'); | |
4 | + if(array_key_exists('tra_c1',$_POST)){ | |
5 | + if(strpos($trace_c1,"ON")!=false){ | |
6 | + shell_exec('lxi scpi -a '.$adresse.' "c1:tra off"'); | |
7 | + }else{ | |
8 | + shell_exec('lxi scpi -a '.$adresse.' "c1:tra on"'); | |
9 | + } | |
10 | + $trace_c1 = shell_exec('lxi scpi -a '.$adresse.' "c1:tra?"'); | |
11 | + } | |
12 | +?> | ... | ... |
... | ... | @@ -0,0 +1,8 @@ |
1 | +<?php | |
2 | + /* Commande Attenuation Sonde CH1 */ | |
3 | + if(array_key_exists('c1_sonde',$_POST)){ | |
4 | + $c1sonde=$_POST["c1_sonde"]; | |
5 | + shell_exec('lxi scpi -a '.$adresse.' "c1:attn '.$c1sonde.'"'); | |
6 | + } | |
7 | + $c1sonde=shell_exec('lxi scpi -a '.$adresse.' "c1:attn?"'); | |
8 | +?> | ... | ... |
... | ... | @@ -0,0 +1,24 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <label for="c1_sonde">Attenuation Sonde CH1 :</label> | |
5 | + <select id="c1_sonde" name="c1_sonde" onchange="this.form.submit();"> | |
6 | + <option value="0.1" <?php if(strpos($c1sonde,"ATTN 0.1")!=false) echo "selected" ?> >0.1X</option> | |
7 | + <option value="0.2" <?php if(strpos($c1sonde,"ATTN 0.2")!=false) echo "selected" ?> >0.2X</option> | |
8 | + <option value="0.5" <?php if(strpos($c1sonde,"ATTN 0.5")!=false) echo "selected" ?> >0.5X</option> | |
9 | + <option value="1" <?php if(strpos($c1sonde,"ATTN 1")!=false) echo "selected" ?> >1X</option> | |
10 | + <option value="2" <?php if(strpos($c1sonde,"ATTN 2")!=false) echo "selected" ?> >2X</option> | |
11 | + <option value="5" <?php if(strpos($c1sonde,"ATTN 5")!=false) echo "selected" ?> >5X</option> | |
12 | + <option value="10" <?php if(strpos($c1sonde,"ATTN 10")!=false) echo "selected" ?> >10X</option> | |
13 | + <option value="20" <?php if(strpos($c1sonde,"ATTN 20")!=false) echo "selected" ?> >20X</option> | |
14 | + <option value="50" <?php if(strpos($c1sonde,"ATTN 50")!=false) echo "selected" ?> >50X</option> | |
15 | + <option value="100" <?php if(strpos($c1sonde,"ATTN 100")!=false) echo "selected" ?> >100X</option> | |
16 | + <option value="200" <?php if(strpos($c1sonde,"ATTN 200")!=false) echo "selected" ?> >200X</option> | |
17 | + <option value="500" <?php if(strpos($c1sonde,"ATTN 500")!=false) echo "selected" ?> >500X</option> | |
18 | + <option value="1000" <?php if(strpos($c1sonde,"ATTN 1000")!=false) echo "selected" ?> >1000X</option> | |
19 | + <option value="2000" <?php if(strpos($c1sonde,"ATTN 2000")!=false) echo "selected" ?> >2000X</option> | |
20 | + <option value="5000" <?php if(strpos($c1sonde,"ATTN 5000")!=false) echo "selected" ?> >5000X</option> | |
21 | + <option value="10000" <?php if(strpos($c1sonde,"ATTN 10000")!=false) echo "selected" ?> >10000X</option> | |
22 | + </select> | |
23 | + </form> | |
24 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,10 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <label for="c1_unit">Unité CH1 :</label> | |
5 | + <select id="c1_unit" name="c1_unit" onchange="this.form.submit();"> | |
6 | + <option value="V" <?php if(strpos($c1u,"V")!=false) echo "selected" ?> >Volt</option> | |
7 | + <option value="A" <?php if(strpos($c1u,"A")!=false) echo "selected" ?> >Ampere</option> | |
8 | + </select> | |
9 | + </form> | |
10 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,14 @@ |
1 | +<?php | |
2 | + /* Commande Volts/DIV CH1 */ | |
3 | + if(array_key_exists('c1_vdiv',$_POST)){ | |
4 | + $div=$_POST["c1_vdiv"]; | |
5 | + shell_exec('lxi scpi -a '.$adresse.' "c1:vdiv '.$div.'"'); | |
6 | + } | |
7 | + if(strpos($c1u,"A")!=false){ | |
8 | + shell_exec('lxi scpi -a '.$adresse.' "c1:unit V"'); | |
9 | + $vdiv1=shell_exec('lxi scpi -a '.$adresse.' "c1:vdiv?"'); | |
10 | + shell_exec('lxi scpi -a '.$adresse.' "c1:unit A"'); | |
11 | + }else{ | |
12 | + $vdiv1=shell_exec('lxi scpi -a '.$adresse.' "c1:vdiv?"'); | |
13 | + } | |
14 | +?> | ... | ... |
html/Oscilloscope_test/CH1/4_Vdiv/form_volt_div.php
0 → 100644
... | ... | @@ -0,0 +1,26 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <?php | |
4 | + /* TODO : Meilleur endroit ? */ | |
5 | + $vdiv1 = floatval(substr($vdiv1,8,-2)); | |
6 | + $sonde = floatval(substr($c1sonde,7)); | |
7 | + $unite1 = substr($c1u,8,-1); | |
8 | + ?> | |
9 | + <form method="post" action="main.php"> | |
10 | + <label for="c1_vdiv"><?php if($unite1=="A"){echo "Amps";}else{echo "Volts";}?>/div CH1 :</label> | |
11 | + <select id="c1_vdiv" name="c1_vdiv" onchange="this.form.submit();"> | |
12 | + <option value="<?php echo floatval(2.00E-03)*$sonde ?>V" <?php if($vdiv1==(floatval(2.00E-03*$sonde))) echo "selected" ?> ><?php echo floatval(2.00E-03)*$sonde.$unite1 ?></option> | |
13 | + <option value="<?php echo floatval(5.00E-03)*$sonde ?>V" <?php if($vdiv1==(floatval(5.00E-03*$sonde))) echo "selected" ?> ><?php echo floatval(5.00E-03)*$sonde.$unite1 ?></option> | |
14 | + <option value="<?php echo floatval(1.00E-02)*$sonde ?>V" <?php if($vdiv1==(floatval(1.00E-02*$sonde))) echo "selected" ?> ><?php echo floatval(1.00E-02)*$sonde.$unite1 ?></option> | |
15 | + <option value="<?php echo floatval(2.00E-02)*$sonde ?>V" <?php if($vdiv1==(floatval(2.00E-02*$sonde))) echo "selected" ?> ><?php echo floatval(2.00E-02)*$sonde.$unite1 ?></option> | |
16 | + <option value="<?php echo floatval(5.00E-02)*$sonde ?>V" <?php if($vdiv1==(floatval(5.00E-02*$sonde))) echo "selected" ?> ><?php echo floatval(5.00E-02)*$sonde.$unite1 ?></option> | |
17 | + <option value="<?php echo floatval(1.00E-01)*$sonde ?>V" <?php if($vdiv1==(floatval(1.00E-01*$sonde))) echo "selected" ?> ><?php echo floatval(1.00E-01)*$sonde.$unite1 ?></option> | |
18 | + <option value="<?php echo floatval(2.00E-01)*$sonde ?>V" <?php if($vdiv1==(floatval(2.00E-01*$sonde))) echo "selected" ?> ><?php echo floatval(2.00E-01)*$sonde.$unite1 ?></option> | |
19 | + <option value="<?php echo floatval(5.00E-01)*$sonde ?>V" <?php if($vdiv1==(floatval(5.00E-01*$sonde))) echo "selected" ?> ><?php echo floatval(5.00E-01)*$sonde.$unite1 ?></option> | |
20 | + <option value="<?php echo floatval(1.00E+00)*$sonde ?>V" <?php if($vdiv1==(floatval(1.00E+00*$sonde))) echo "selected" ?> ><?php echo floatval(1.00E+00)*$sonde.$unite1 ?></option> | |
21 | + <option value="<?php echo floatval(2.00E+00)*$sonde ?>V" <?php if($vdiv1==(floatval(2.00E+00*$sonde))) echo "selected" ?> ><?php echo floatval(2.00E+00)*$sonde.$unite1 ?></option> | |
22 | + <option value="<?php echo floatval(5.00E+00)*$sonde ?>V" <?php if($vdiv1==(floatval(5.00E+00*$sonde))) echo "selected" ?> ><?php echo floatval(5.00E+00)*$sonde.$unite1 ?></option> | |
23 | + <option value="<?php echo floatval(1.00E+01)*$sonde ?>V" <?php if($vdiv1==(floatval(1.00E+01*$sonde))) echo "selected" ?> ><?php echo floatval(1.00E+01)*$sonde.$unite1 ?></option> | |
24 | + </select> | |
25 | + </form> | |
26 | +</html> | ... | ... |
html/Oscilloscope_test/CH1/5_Couplage/cmd_couplage.php
0 → 100644
html/Oscilloscope_test/CH1/5_Couplage/form_couplage.php
0 → 100644
... | ... | @@ -0,0 +1,11 @@ |
1 | +<!DOCTYPE html> | |
2 | +<html> | |
3 | + <form method="post" action="main.php"> | |
4 | + <label for="c1_cpl">Couplage CH1 :</label> | |
5 | + <select id="c1_cpl" name="c1_cpl" onchange="this.form.submit();"> | |
6 | + <option value="D1M" <?php if(strpos($c1cpl,"D1M")!=false) echo "selected" ?> >DC</option> | |
7 | + <option value="A1M" <?php if(strpos($c1cpl,"A1M")!=false) echo "selected" ?> >AC</option> | |
8 | + <option value="GND" <?php if(strpos($c1cpl,"GND")!=false) echo "selected" ?> >GND</option> | |
9 | + </select> | |
10 | + </form> | |
11 | +</html> | ... | ... |
... | ... | @@ -0,0 +1,37 @@ |
1 | +<?php | |
2 | + /* Filtre CH1 */ | |
3 | + if(array_key_exists('filt_c1',$_POST)){ | |
4 | + $filt_c1 = shell_exec('lxi scpi -a '.$adresse.' "c1:filt?"'); | |
5 | + if(strpos($filt_c1,"ON")!=false){ | |
6 | + shell_exec('lxi scpi -a '.$adresse.' "c1:filt off"'); | |
7 | + }else{ | |
8 | + shell_exec('lxi scpi -a '.$adresse.' "c1:filt on"'); | |
9 | + } | |
10 | + } | |
11 | + $trace_c1=shell_exec('lxi scpi -a '.$adresse.' "c1:tra?"'); | |
12 | + if(strpos($trace_c1,"OFF")!=false){ | |
13 | + $filt_c1="OFF"; | |
14 | + }else{ | |
15 | + $filt_c1 = shell_exec('lxi scpi -a '.$adresse.' "c1:filt?"'); | |
16 | + } | |
17 | + /* TODO : Probleme (Voir erreur /var/log/apache2/error.log) */ | |
18 | + /* Commande type de filtre CH1 */ | |
19 | + if(array_key_exists('c1_filts',$_POST)){ | |
20 | + $c1filts=$_POST['c1_filts']; | |
21 | + if($c1filts=="LP"){ | |
22 | + $limite_sup = floatval($_POST['lim_sup']); | |
23 | + shell_exec('lxi scpi -a '.$adresse.' "c1:filts type,'.$c1filts.',upplimit,'.$limite_sup.'MHz"'); | |
24 | + }else if($c1filts=="HP"){ | |
25 | + $limite_inf = $_POST['lim_inf']; | |
26 | + shell_exec('lxi scpi -a '.$adresse.' "c1:filts type,'.$c1filts.',lowlimit,'.$limite_inf.'MHz"'); | |
27 | + }else{ | |
28 | + $limite_sup = $_POST['lim_sup']; | |
29 | + $limite_inf = $_POST['lim_inf']; | |
30 | + if($limite_inf>=$limite_sup){ | |
31 | + $limite_inf=$limite_sup-5; | |
32 | + } | |
33 | + shell_exec('lxi scpi -a '.$adresse.' "c1:filts type,'.$c1filts.',upplimit,'.$limite_sup.'MHz,lowlimit,'.$limite_inf.'MHz"'); | |
34 | + } | |
35 | + } | |
36 | + $c1filts=shell_exec('lxi scpi -a '.$adresse.' "c1:filts?"'); | |