KS4031(4032) folder/Makecode
Tutorial/Makecode Code/Project
11:Microphone-2
Project 11:
Microphone-2.hex
Or you could edit code step by step in the editing area.
Enter“Advanced”module→ choose“Serial”to find and drag“serial redirect
to USB”into “on start”block ;
Enter “ Variables ” module → choose “ Make a Variable ” → input
“maxSound”→click “OK”,variable ”maxSound”is established;
Enter“Variables”module to find and drag“set maxSound to 0”into “on
start”block ;
Enter“Logic”module to find and drag“if true then...else”into “forever”
block ;
Enter“Input”module to find and dragbutton A is pressed”into “then” ;