Debugging Your Code
If your code isn’t running as expected, check the following common issues:
1. Code Connected to the Start Block
-
Make sure all code blocks (except function definitions) are connected to the [START] block.
-
Code blocks that aren’t connected will not run when you press Upload.

2. Empty Code Blocks
-
Empty blocks will prevent your code from loading or running.
-
Remove or fill in any empty blocks.

3. Match Inputs and Outputs to Your Circuit
-
Ensure the inputs in your code match the inputs in your circuit.
-
Example: If your input is on IN 3, a
[WAIT FOR IN1 TO BE ON]block will not work. Change it to[WAIT FOR IN3 TO BE ON].

4. Add [WAIT] Blocks Between Animation Frames
-
Code runs very quickly, so animations may appear too fast.
-
Add
[WAIT]blocks between frames to make animations visible.

5. Add [WAIT] Blocks After [SCROLLING TEXT]
-
Scrolling text continues without stopping.
-
Add a
[WAIT]block after a[SCROLLING TEXT]block. The wait time should correspond to the length of the message.

6. Follow Transform Blocks with [SEND IMAGE]
-
Blocks like
[ROTATE IMAGE BY 90],[MOVE IMAGE UP BY 1], and[ADD PIXEL AT X: Y: TO IMAGE]require a[SEND IMAGE]block afterward to display changes on the LED matrix.

7. Place Logic Blocks Inside a Loop
-
To continuously check a condition, put dark blue logic blocks inside a
[DO FOREVER]loop. -
Example: To detect when a button on IN 1 is pressed, the logic block must be inside a loop to check repeatedly.

8. Set and Use Variables
-
Ensure that any variables you create are both set to a value and used in your code.

Debugging Checklist

Still Having Trouble?