Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
pelikhan committed Aug 29, 2023
1 parent f94dc0e commit da7c11a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion led-strip/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,10 @@ namespace modules {
//% weight=80 blockGap=8
//% group="LED Strip"
setAll(rgb: number) {
this.runEncoded("fade # wait 1", [rgb])
if (!rgb)
this.runEncoded("setall #000000")
else
this.runEncoded("fade # wait 1", [rgb])
}

private currAnimation = 0
Expand Down

0 comments on commit da7c11a

Please sign in to comment.