ARC Pro

Upgrade to ARC Pro

ARC Pro is your gateway to a community of like-minded robot enthusiasts and professionals, all united by a passion for advanced robot programming.

PRO
USA
#10   — Edited

Ptp, I re-arranged the code, now it works when it sees me and stay there for another round of seeing me again and again -  color or face

User-inserted image

User-inserted image

still my Blockly code some controls appears and the next time it is gone like set isFaceTracking, , go figure :-)

tracking color

User-inserted image

In Java:

setVar("$CameraTrackingType", 0);

if (getVar("$CameraTrackingType") == 1) {

// Wait until the camera detects the specified color controlCommand("Camera", "CameraMovementTrackDisable"); controlCommand("Camera", "CameraUseTrackingScripts", false); controlCommand("Camera", "CameraColorTracking", "Red"); while (getVar("$CameraIsTracking") == 0); controlCommand("Camera", "CameraDisableTracking"); controlCommand("Camera", "CameraUseTrackingScripts", true);

}

if (getVar("$CameraTrackingType") == 1) {

controlCommand("Camera", "CameraColorTrackingEnable");

}

Audio.sayWait("I see red");

or

User-inserted image

I guess simple is not so simple today :-)

be well,

thanks EzAng