- Platform information:
- Hardware: Raspberry Pi 3b+
- OS: openhabian
- Java Runtime Environment: embedded
- openHAB version: 2.4
Hi, I’m using rmmini3 with BlackBeanControl, and I have recorded 2 signals: volumeUp and volumeDown, how can I create an item and sitemap to have the button + and - that exec 2 different commands?
thanx in advance
Edit:
that’s what I did:
Things:
Thing exec:command:TVVolUp [Command="/usr/bin/python /usr/share/openhab2/BlackBeanControl/BlackBeanControl.py -c AumentaVolume", interval=0, timeout=5, autorun=false]
Thing exec:command:TVVolDw [Command="/usr/bin/python /usr/share/openhab2/BlackBeanControl/BlackBeanControl.py -c DiminuisciVolume", interval=0, timeout=5, autorun=false]
Items:
Switch TVVolUp_RUN "TV Aumenta Volume" {channel="exec:command:TVVolUp:run"}
Switch TVVolDw_RUN "TV Diminuisci Volume" {channel="exec:command:TVVolDw:run"}
now I would like to combine TVVolUp and TVVolDw in sitemaps but this not work:
Switch item=Volume mappings=["+"={channel="exec:command:TVVolUp:run"},"-"={channel="exec:command:TVVolDw:run"}]
I get in the log:
2019-02-22 20:43:13.229 [WARN ] [el.core.internal.ModelRepositoryImpl] - Configuration model 'default.sitemap' has errors, therefore ignoring it: [144,36]: no viable alternative at input '{'
[144,71]: missing ']' at '}'
[144,72]: mismatched input ',' expecting '}'