mirror of
http://172.16.0.230/r/SIF/TowerOptoSifAndSpectral.git
synced 2025-10-18 19:39:43 +08:00
修改显示
This commit is contained in:
@ -17,19 +17,14 @@
|
||||
/2021_10_16
|
||||
/Log
|
||||
其他
|
||||
|
||||
```
|
||||
|
||||
|
||||
|
||||
3. **数据内容确定**
|
||||
|
||||
```
|
||||
按照《SIF加地物光谱仪本地数据存储格式说明.pdf》存储
|
||||
```
|
||||
|
||||
|
||||
|
||||
4. **shutter切换顺序**
|
||||
|
||||
```
|
||||
@ -73,8 +68,3 @@
|
||||
```
|
||||
添加温湿度传感器
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -7,6 +7,8 @@ $shuter=$_GET['shutterTime'];
|
||||
set_time_limit(0);
|
||||
ob_end_clean();//清空(擦除)缓冲区并关闭输出缓冲
|
||||
ob_implicit_flush(1);//将打开或关闭绝对(隐式)刷送。绝对(隐式)刷送将导致在每次输出调用后有一次刷送操作,以便不再需要对 flush() 的显式调用
|
||||
system("sudo gpio mode 1 out");
|
||||
system("sudo gpio write 1 1");
|
||||
system("sudo pkill shutter_calibrate");
|
||||
|
||||
|
||||
|
133
othersoft/findtty.sh
Normal file
133
othersoft/findtty.sh
Normal file
@ -0,0 +1,133 @@
|
||||
|
||||
stty -F /dev/ttyUSB0 raw speed 9600
|
||||
sleep 1s
|
||||
stty -F /dev/ttyUSB0 raw speed 9600
|
||||
echo -e "0 dev\n" > /dev/ttyUSB0
|
||||
cat /dev/ttyUSB0 > 1.txt &
|
||||
sleep 1s
|
||||
pkill cat
|
||||
if test -s 1.txt;then
|
||||
echo '/dev/ttyUSB0 may be linermotor'> /home/data/Setting/tryfindtty.txt
|
||||
fi
|
||||
|
||||
stty -F /dev/ttyUSB1 raw speed 9600
|
||||
sleep 1s
|
||||
stty -F /dev/ttyUSB1 raw speed 9600
|
||||
echo -e "0 dev\n" > /dev/ttyUSB1
|
||||
cat /dev/ttyUSB1 > 1.txt &
|
||||
sleep 1s
|
||||
pkill cat
|
||||
if test -s 1.txt;then
|
||||
echo '/dev/ttyUSB1 may be linermotor'> /home/data/Setting/tryfindtty.txt
|
||||
fi
|
||||
|
||||
stty -F /dev/ttyUSB2 raw speed 9600
|
||||
sleep 1s
|
||||
stty -F /dev/ttyUSB2 raw speed 9600
|
||||
echo -e "0 dev\n" > /dev/ttyUSB2
|
||||
cat /dev/ttyUSB2 > 1.txt &
|
||||
sleep 1s
|
||||
pkill cat
|
||||
if test -s 1.txt;then
|
||||
echo '/dev/ttyUSB2 may be linermotor'> /home/data/Setting/tryfindtty.txt
|
||||
fi
|
||||
|
||||
stty -F /dev/ttyUSB3 raw speed 9600
|
||||
sleep 1s
|
||||
stty -F /dev/ttyUSB3 raw speed 9600
|
||||
echo -e "0 dev\n" > /dev/ttyUSB3
|
||||
cat /dev/ttyUSB3 > 1.txt &
|
||||
sleep 1s
|
||||
pkill cat
|
||||
if test -s 1.txt;then
|
||||
echo '/dev/ttyUSB3 may be linermotor'> /home/data/Setting/tryfindtty.txt
|
||||
fi
|
||||
|
||||
|
||||
stty -F /dev/ttyS1 raw speed 115200
|
||||
sleep 1s
|
||||
stty -F /dev/ttyS1 raw speed 115200
|
||||
cat -e /dev/ttyS1 > 1.txt &
|
||||
sleep 1s
|
||||
echo aa5500040307 | xxd -r -ps > /dev/ttyS1
|
||||
sleep 1s
|
||||
pkill cat
|
||||
sleep 1s
|
||||
|
||||
if test -s 1.txt;then
|
||||
echo '/dev/ttyS1 is ISIF or IS2'>> /home/data/Setting/tryfindtty.txt
|
||||
fi
|
||||
|
||||
|
||||
stty -F /dev/ttyS2 raw speed 115200
|
||||
sleep 1s
|
||||
stty -F /dev/ttyS2 raw speed 115200
|
||||
cat -e /dev/ttyS2 > 1.txt &
|
||||
sleep 1s
|
||||
echo aa5500040307 | xxd -r -ps > /dev/ttyS2
|
||||
sleep 1s
|
||||
pkill cat
|
||||
sleep 1s
|
||||
|
||||
if test -s 1.txt;then
|
||||
echo '/dev/ttyS2 is ISIF or IS2'>> /home/data/Setting/tryfindtty.txt
|
||||
fi
|
||||
|
||||
stty -F /dev/ttyUSB0 raw speed 115200
|
||||
sleep 1s
|
||||
stty -F /dev/ttyUSB0 raw speed 115200
|
||||
cat -e /dev/ttyUSB0 > 1.txt &
|
||||
sleep 1s
|
||||
echo aa5500040307 | xxd -r -ps > /dev/ttyUSB0
|
||||
sleep 1s
|
||||
pkill cat
|
||||
sleep 1s
|
||||
|
||||
if test -s 1.txt;then
|
||||
echo '/dev/ttyUSB0 is IS1'>> /home/data/Setting/tryfindtty.txt
|
||||
fi
|
||||
|
||||
stty -F /dev/ttyUSB1 raw speed 115200
|
||||
sleep 1s
|
||||
stty -F /dev/ttyUSB1 raw speed 115200
|
||||
cat -e /dev/ttyUSB1 > 1.txt &
|
||||
sleep 1s
|
||||
echo aa5500040307 | xxd -r -ps > /dev/ttyS1
|
||||
sleep 1s
|
||||
pkill cat
|
||||
sleep 1s
|
||||
if test -s 1.txt;then
|
||||
echo '/dev/ttyUSB1 is IS1'>> /home/data/Setting/tryfindtty.txt
|
||||
fi
|
||||
|
||||
stty -F /dev/ttyUSB2 raw speed 115200
|
||||
sleep 1s
|
||||
stty -F /dev/ttyUSB2 raw speed 115200
|
||||
cat -e /dev/ttyUSB2 > 1.txt &
|
||||
sleep 1s
|
||||
echo aa5500040307 | xxd -r -ps > /dev/ttyUSB2
|
||||
sleep 1s
|
||||
pkill cat
|
||||
sleep 1s
|
||||
if test -s 1.txt;then
|
||||
echo '/dev/ttyUSB2 is IS1'>> /home/data/Setting/tryfindtty.txt
|
||||
fi
|
||||
|
||||
|
||||
stty -F /dev/ttyUSB3 raw speed 115200
|
||||
sleep 1s
|
||||
stty -F /dev/ttyUSB3 raw speed 115200
|
||||
cat -e /dev/ttyUSB3 > 1.txt &
|
||||
sleep 1s
|
||||
echo aa5500040307 | xxd -r -ps > /dev/ttyUSB3
|
||||
sleep 1s
|
||||
pkill cat
|
||||
sleep 1s
|
||||
|
||||
if test -s 1.txt;then
|
||||
echo '/dev/ttyUSB3 is IS1'>> /home/data/Setting/tryfindtty.txt
|
||||
fi
|
||||
|
||||
|
||||
|
||||
|
@ -195,7 +195,7 @@ int main(int argc, char* argv[])
|
||||
vector<int>loction2 = FindFeng(location1point, valuepinghua);
|
||||
|
||||
if (loction2.size() == 1)
|
||||
{ cout1<<"find "<<i<<"point value is"<<loction2[0]<<"<br>"<<flush;
|
||||
{ cout1<<"find "<<i<<"point value is <b color=\'green\'>"<<loction2[0]<<"<\/b><br>"<<flush;
|
||||
outfile1 <<i+1<<"," << loction2[0]<< std::endl;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user