Sound Effect — Ezblock

In this example, we use PiCrawler’s (to be precise, Robot HAT’s) sound effects. It consists of three parts, namely Muisc, Sound, Text to Speech.

Program

After opening the example, you can see the following code block.

../_images/soundeff.png

Switch to the Remote Control interface, and you will see the following widgets.

../_images/soundeff_B.png

After the program is running, you can press different buttons to make PiCrawler sound.

How it works?

Functions related to background music include these:

../_images/sp210928_101816.png

Functions related to sound effects include these:

../_images/sp210928_101727.png

Functions related to Text to Speech include these:

../_images/sp210928_101609.png