From Test-Scratch-Wiki
Please expand this article or section. You can help by adding more information if you are an editor. More information might be found in a section of the talk page. |
When () | |
Category | PicoBoards |
Type | Hat |
Introduced in | 2.0 |
The When () block is a PicoBoard block and a Hat block. The block activates if the button on a PicoBoard is being pressed or the specified port gets connected. It can be used in some interesting ways, for example: if you have a script that tells you to press a button on your PicoBoard, you can press it, and the script will activate.
This block is similar to the When () Key Pressed block. When the condition is true, it will run the script.
This block can only be used with a PicoBoard.
Values
The block has the following options in the drop-down menu:
- button pressed
- A connected
- B connected
- C connected
- D connected