Skip to content

JavaScript error when re-defining leds #24

@uPaymeiFixit

Description

@uPaymeiFixit

The following code re-defines the leds 2d array, yet does not throw any errors, and does not let the program recover by switching to another pattern.

leds[0] = 0

This is because we have redefined this led[0] array. I suspect it will also not work if we do leds = null or something.

A possible fix for this is either re-instantiating the leds every time we load a new pattern, or check every update if every element of the 2d array is still in tact.

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions