Files
AireOptoSifAndSpectral/html/config/location.php
xin 84787f1006 程序重命名及版本更新
- 程序名从 TowerOptoSifAndSpectral 更名为 AirOptoSifAndSpectral
- 版本从 2.1.5 更新至 2.1.9
- GPIO 控制逻辑修改:引脚 1 和 12 输出改为 0
- 新增 dpkg preinst 脚本处理冲突文件
2026-04-07 10:28:53 +08:00

67 lines
1.7 KiB
PHP
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
$a=$_GET["p"];
if ($a==0)
{
echo "error";
return;
}
set_time_limit(0);
ob_end_clean();//清空(擦除)缓冲区并关闭输出缓冲
ob_implicit_flush(1);//将打开或关闭绝对(隐式)刷送。绝对(隐式)刷送将导致在每次输出调用后有一次刷送操作,以便不再需要对 flush() 的显式调用
//echo shell_exec("D:\\03MyGit\\linux\\movingliner\\cmake-build-debug-mingw\\movingliner.exe");
//$cmd = 'ping 127.0.0.1';
//sy""
system("sudo killall Mywathdog.sh");
system("sudo killall AirOptoSifAndSpectral");
system("sudo pkill movingliner");
Echo $a;
$cmd = 'sudo /home/pi/bin/movingliner '.$a;
while(@ ob_end_flush());
$proc = popen($cmd, 'r');
while(!feof($proc)){
echo fread($proc, 4096);
@ flush();
}
echo '<form action="/config/calibrate.php" method="get" target="_blank">';
echo '设备<input id="sensor" name="sensor" type="text" list="typelist" placeholder="请选择">
<datalist id="typelist">
  <option>IS1</option>
  <option>IS2</option>
  <option>ISIF</option>
  <option>OSIFAlpha</option>
<option>OSIFBeta</option>
</datalist>';
echo '尼特 <input type="number" name="nite" id="nite"/>';
echo '<input id="p" name="p" type="hidden" value="'.$a.'">';
echo '<input type="submit" value="定标">';
echo '</form>';
echo '<a href=/config/position.html>回到首页</a>';
/*
$i = 100;
while ($i<1000) {
++$i;
//部分浏览器需要内容达到一定长度了才输出
if ($i === 103) {
echo"<p>hello word".$i."</p>";;
} else {
echo"<p>hello word".$i."</p>";;
}
sleep(1);
}
*/