|
if(Anthordistance_count[0]>0&&Anthordistance_count[0]<7)
{
sprintf(dist_str, "serious_injury:%3.2fm", (float)Anthordistance[0]/1000);
OLED_ShowString(0, 2,dist_str);
serious_injury;
}
else if(Anthordistance_count[0]>7&&Anthordistance_count[0]<15)
{ sprintf(dist_str, "slight_injury:%3.2fm", (float)Anthordistance[0]/1000);
OLED_ShowString(0, 2,dist_str);
slight_injury;}
if(Anthordistance_count[1]>0&&Anthordistance_count[1]<7)
{
sprintf(dist_str, "serious_injury:%3.2fm", (float)Anthordistance[1]/1000);
OLED_ShowString(0, 4,dist_str);
serious_injury;}为什么显示屏依旧显示:an0: xxx m,而不是我代码中 sprintf(dist_str, "slight_injury:%3.2fm", (float)Anthordistance[0]/1000);
OLED_ShowString(0, 2,dist_str);程序没有烧录进去吗
|
|