Hi
I am working on a project to avoid things using Pixy Cam.
I wrote the code and implemented it, and I’m not sure it’s working.
Is it right to do it like code?
if((pixy.ccc.blocks[0].m_x>120)&&(pixy.ccc.blocks[0].m_x<190)) {left();}
if(((pixy.ccc.blocks[0].m_x<120) && (pixy.ccc.blocks[0].m_x>10)) or ((pixy.ccc.blocks[0].m_x>190))) {go();}
if((pixy.ccc.blocks[0].m_x>10)&&(pixy.ccc.blocks[0].m_x<190)) {right();}
if((pixy.ccc.blocks[0].m_x>120)&&(pixy.ccc.blocks[0].m_x<315)) {left();}
if(((pixy.ccc.blocks[0].m_x>10)&&(pixy.ccc.blocks[0].m_x<120))&& (pixy.ccc.blocks[0].m_x>190)) {go();}
else{stop();}}}