Default to remote
This commit is contained in:
parent
0d9e719078
commit
617aae5943
@ -1,6 +0,0 @@
|
|||||||
[ 1] runtime starting...
|
|
||||||
[ 53] runtime started [V0.60]
|
|
||||||
[ 55] mmap /dev/lms_analog len=5172 off=0
|
|
||||||
[ 56] mmap /dev/lms_uart len=42744 off=0
|
|
||||||
[ 64] Error: 7 [0]
|
|
||||||
[ 64] PANIC 42
|
|
@ -49,6 +49,8 @@ namespace input {
|
|||||||
super()
|
super()
|
||||||
this.channel = IrRemoteChannel.Ch0
|
this.channel = IrRemoteChannel.Ch0
|
||||||
this.buttons = []
|
this.buttons = []
|
||||||
|
// otherwise button events won't work
|
||||||
|
this.mode = IrSensorMode.RemoteControl
|
||||||
for (let i = 0; i < 5; ++i) {
|
for (let i = 0; i < 5; ++i) {
|
||||||
this.buttons.push(new ButtonTS())
|
this.buttons.push(new ButtonTS())
|
||||||
}
|
}
|
||||||
|
@ -34,9 +34,7 @@ input.touch.button.onEvent(ButtonEvent.Click, () => {
|
|||||||
num++
|
num++
|
||||||
})
|
})
|
||||||
|
|
||||||
input.ir.getRemoteCommand()
|
input.ir.button(IrRemoteButton.TopLeft).onEvent(ButtonEvent.Click, () => {
|
||||||
|
|
||||||
input.ir.button(IrRemoteButton.TopLeft).onEvent(ButtonEvent.Down, () => {
|
|
||||||
screen.drawText(10, 60, "TOPLEFT " + num)
|
screen.drawText(10, 60, "TOPLEFT " + num)
|
||||||
num++
|
num++
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user