added led.enable (#294)
* added led.enable * fixed simulator support for led.enable
This commit is contained in:
@ -9,6 +9,7 @@ namespace pxsim {
|
||||
brigthness = 255;
|
||||
displayMode = DisplayMode.bw;
|
||||
font: Image = createFont();
|
||||
disabled: boolean;
|
||||
|
||||
animationQ: AnimationQueue;
|
||||
|
||||
@ -284,4 +285,8 @@ namespace pxsim.led {
|
||||
board().ledMatrixState.image.copyTo(0, 5, img, 0);
|
||||
return img;
|
||||
}
|
||||
export function enable(on: boolean) {
|
||||
board().ledMatrixState.disabled = !on;
|
||||
runtime.queueDisplayUpdate();
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user