RealCrab
Newbie

Materials
• Ameba D [RTL8722 CSM/DM] x 1
• Adafruit PDM MEMS microphone
• LED x 4
Example
Procedure
Connect the microphone and LEDs to the RTL8722 board following the diagram.
Download the Ameba customized version of TensorFlow Lite for Microcontrollers library at https://github.com/ambiot/ambd_arduino/tree/master/Arduino_zip_libraries.
Follow the instructions at https://www.arduino.cc/en/guide/libraries to install it.
Ensure that the patch files found at https://github.com/ambiot/ambd_arduino/tree/master/Ameba_misc/ are also installed.
Open the example, “Files” -> “Examples” -> “TensorFlowLite_Ameba” -> “micro_speech”.
Upload the code and press the reset button on Ameba once the upload is finished.
Once it is running, you should see one of the LEDs flashing, indicating that it is processing audio. Saying the word “yes” will cause the green LED to light up. Saying the word “no” will cause the red LED to light up. If the word is not recognized, the blue LED will to light up.
The inference results are also output to the Arduino serial monitor, which appear as follows:
If you are having trouble in getting the words recognized, here are some tips:
– Ensure that your surroundings are quiet with minimal noise.
– Experiment with varying the distance of the microphone, starting with it at an arm’s length.
– Experiment with different tones and volume when saying the words.
– Depending on how you pronounce the words, the characteristics of the microphone used, getting one keyword recognized may be easier than the other.
Code Reference
More information on TensorFlow Lite for Microcontrollers can be found at: https://www.tensorflow.org/lite/microcontrollers
Join in the community discussions at:
https://www.facebook.com/groups/amebaioten
https://forum.amebaiot.com/
Purchase links for the various Realtek development boards can be found at:
https://www.amebaiot.com/en/where-to-buy-link/
• Ameba D [RTL8722 CSM/DM] x 1
• Adafruit PDM MEMS microphone
• LED x 4
Example
Procedure
Connect the microphone and LEDs to the RTL8722 board following the diagram.
![r/arduino - [RTL8722CSM/RTL8722DM] TensorFlow Lite - Micro Speech r/arduino - [RTL8722CSM/RTL8722DM] TensorFlow Lite - Micro Speech](https://preview.redd.it/ghda5n3533c71.png?width=844&format=png&auto=webp&s=9d93f2004a9454dc8ab3640988d089e5d4d79ec4)
Download the Ameba customized version of TensorFlow Lite for Microcontrollers library at https://github.com/ambiot/ambd_arduino/tree/master/Arduino_zip_libraries.
Follow the instructions at https://www.arduino.cc/en/guide/libraries to install it.
Ensure that the patch files found at https://github.com/ambiot/ambd_arduino/tree/master/Ameba_misc/ are also installed.
Open the example, “Files” -> “Examples” -> “TensorFlowLite_Ameba” -> “micro_speech”.
![r/arduino - [RTL8722CSM/RTL8722DM] TensorFlow Lite - Micro Speech r/arduino - [RTL8722CSM/RTL8722DM] TensorFlow Lite - Micro Speech](https://preview.redd.it/syhwdfy533c71.png?width=556&format=png&auto=webp&s=b46371e8578684a6d17ca8ad6af3af6a1241dde0)
Upload the code and press the reset button on Ameba once the upload is finished.
Once it is running, you should see one of the LEDs flashing, indicating that it is processing audio. Saying the word “yes” will cause the green LED to light up. Saying the word “no” will cause the red LED to light up. If the word is not recognized, the blue LED will to light up.
The inference results are also output to the Arduino serial monitor, which appear as follows:
![r/arduino - [RTL8722CSM/RTL8722DM] TensorFlow Lite - Micro Speech r/arduino - [RTL8722CSM/RTL8722DM] TensorFlow Lite - Micro Speech](https://preview.redd.it/fezpgcr633c71.png?width=607&format=png&auto=webp&s=0d2bdd4bb6fb5a7b0a2df03f1d36d90f01d989d8)
If you are having trouble in getting the words recognized, here are some tips:
– Ensure that your surroundings are quiet with minimal noise.
– Experiment with varying the distance of the microphone, starting with it at an arm’s length.
– Experiment with different tones and volume when saying the words.
– Depending on how you pronounce the words, the characteristics of the microphone used, getting one keyword recognized may be easier than the other.
Code Reference
More information on TensorFlow Lite for Microcontrollers can be found at: https://www.tensorflow.org/lite/microcontrollers
Join in the community discussions at:
https://www.facebook.com/groups/amebaioten
https://forum.amebaiot.com/
Purchase links for the various Realtek development boards can be found at:
https://www.amebaiot.com/en/where-to-buy-link/