fixing pin value visibility
This commit is contained in:
parent
994aee0db5
commit
a751be2e97
@ -9,6 +9,7 @@ namespace ks.rt.micro_bit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export enum PinMode {
|
export enum PinMode {
|
||||||
|
Unused = 0,
|
||||||
Digital = 0x0001,
|
Digital = 0x0001,
|
||||||
Analog = 0x0002,
|
Analog = 0x0002,
|
||||||
Input = 0x0004,
|
Input = 0x0004,
|
||||||
@ -20,7 +21,7 @@ namespace ks.rt.micro_bit {
|
|||||||
constructor(public id: number) {}
|
constructor(public id: number) {}
|
||||||
touched = false;
|
touched = false;
|
||||||
value = 0;
|
value = 0;
|
||||||
mode = PinMode.Digital | PinMode.Output;
|
mode = PinMode.Unused;
|
||||||
|
|
||||||
isTouched() : boolean {
|
isTouched() : boolean {
|
||||||
this.mode = PinMode.Touch;
|
this.mode = PinMode.Touch;
|
||||||
|
Loading…
Reference in New Issue
Block a user