智能车制作
标题:
CCD
[打印本页]
作者:
未来不远
时间:
2014-4-27 21:27
标题:
CCD
for(i=0;i<128;i++)
{
if(ADV[i]>ADV[i+1]&&ADV[i+1]>ADV[i+2]&&ADV[i+2]<ADV[i+3]&&ADV[i+3]<ADV[i+4])
z=64-i-2;
}
if(z>0)
PWMDTY2 =35;//右
delay(50);
if(z<0)
PWMDTY2 =65;//zuo
delay(50);
for(i=0;i<64;i++)
{
if(ADV[i]>ADV[i+1]&&ADV[i+1]>ADV[i+2]&&ADV[i+2]<ADV[i+3]&&ADV[i+3]<ADV[i+4])
x=64-i-2;
}
for(i=0;i<64;i++)
{
if(ADV[i]>ADV[i+1]&&ADV[i+1]>ADV[i+2]&&ADV[i+2]<ADV[i+3]&&ADV[i+3]<ADV[i+4])
y=i+2-64;
}
if(x>y)
PWMDTY2 =65;//zuo
delay(50);
if(x<y)
PWMDTY2 =35;
delay(50);
作者:
未来不远
时间:
2014-4-27 21:27
求助
作者:
zhou1994
时间:
2014-4-28 13:00
25mm的线宽。你这个是很难寻到线的吧
欢迎光临 智能车制作 (http://dns.znczz.com/)
Powered by Discuz! X3.2