The block plays the specified audio on the Quarky speaker. The block has a callback, so other blocks will be executed after the audio is played.

Learn how to code logic for video input detection .set the bounding box threshold, and detect signals to control Humanoid movements.
Introduction
A sign detector Humanoid robot is a robot that can recognize and interpret certain signs or signals, such as hand gestures or verbal commands, given by a human. The robot uses sensors, cameras, and machine learning algorithms to detect and understand the sign, and then performs a corresponding action based on the signal detected.
These robots are often used in manufacturing, healthcare, and customer service industries to assist with tasks that require human-like interaction and decision-making.
Code
Logic
- Initialise the video on stage and set the transparency as 0%
- Show the bounding box and set its threshold to 0.8.
- Get the input from the camera forever.
- If the signal is detected as ‘Go’ then it displays an ‘up arrow’, sounds go straight and the Humanoid will move 2 steps forward at high speed using do () motion () times at () speed block.
- If the signal is detected as ‘TurnRight’ then it displays a ‘right arrow’, sounds Turn right and Humanoid will take a right turn at high speed using do () motion () times at () speed block.
- If the signal is detected as ‘TurnLeft’ then it displays a ‘Left arrow’, sounds Turn Left and Humanoid will take a left turn at high speed using do () motion () times at () speed block.
- If it detects as stop the display will be cleared in the quirky and the humanoid will be at a home() posture.
Output
Read More