mirror of
https://github.com/HASwitchPlate/openHASP.git
synced 2025-07-24 11:46:34 +00:00
Update tests
This commit is contained in:
parent
4cd5e1e481
commit
e018baed09
@ -1,11 +1,11 @@
|
||||
# config.yaml
|
||||
# Copy and rename this file to config.yaml
|
||||
---
|
||||
name: Common test information
|
||||
description: Connection information for MQTT Client
|
||||
|
||||
variables:
|
||||
host: homeassistant.local
|
||||
username: hasp
|
||||
password: hasp
|
||||
username: <mqtt_username>
|
||||
password: <mqtt_password>
|
||||
port: 1883
|
||||
plate: plate35
|
||||
plate: <platename>
|
@ -1,6 +1,35 @@
|
||||
# test_value_str.tavern.yaml
|
||||
---
|
||||
test_name: Obj Standard Properties
|
||||
test_name: Colors setup
|
||||
|
||||
includes:
|
||||
- !include config.yaml
|
||||
|
||||
paho-mqtt:
|
||||
client:
|
||||
transport: tcp
|
||||
client_id: tavern-tester
|
||||
connect:
|
||||
host: "{host}"
|
||||
port: !int "{port:d}"
|
||||
timeout: 3
|
||||
auth:
|
||||
username: "{username}"
|
||||
password: "{password}"
|
||||
|
||||
stages:
|
||||
- name: Page 1
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "page 1"
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/page
|
||||
payload: "1"
|
||||
timeout: 1
|
||||
delay_after: 0
|
||||
|
||||
---
|
||||
test_name: Colors loop
|
||||
|
||||
includes:
|
||||
- !include config.yaml
|
||||
@ -77,27 +106,10 @@ marks:
|
||||
- btn
|
||||
|
||||
stages:
|
||||
- name: Page 1
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "page 1"
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/page
|
||||
payload: "1"
|
||||
timeout: 1
|
||||
delay_after: 0
|
||||
|
||||
- name: Set bg_color
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p[1].b[0].bg_color={color}"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Clear page
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/clearpage
|
||||
payload: ""
|
||||
delay_after: 0.02
|
||||
topic: hasp/{plate}/command/json
|
||||
payload: '["p1b0.bg_color={color}","clearpage"]'
|
||||
|
||||
- name: Create object
|
||||
mqtt_publish:
|
||||
@ -109,18 +121,16 @@ stages:
|
||||
r: !int "{r:d}"
|
||||
g: !int "{g:d}"
|
||||
b: !int "{b:d}"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Set bg_color
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p[1].b[0].bg_color={rgb565}"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Test named COLOR
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/json
|
||||
payload: '["p[1].b[1].text_color={color}","p[1].b[1].text_color"]'
|
||||
payload: '["p1b1.text_color={color}","p1b1.text_color"]'
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/p1b1
|
||||
json:
|
||||
@ -133,13 +143,12 @@ stages:
|
||||
- name: Reset
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p[1].b[1].text_color=123"
|
||||
delay_after: 0.02
|
||||
payload: "p1b1.text_color=123"
|
||||
|
||||
- name: Test hex COLOR
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/json
|
||||
payload: '["p[1].b[1].text_color={hex}","p[1].b[1].text_color"]'
|
||||
payload: '["p1b1.text_color={hex}","p1b1.text_color"]'
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/p1b1
|
||||
json:
|
||||
@ -152,13 +161,12 @@ stages:
|
||||
- name: Reset
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p[1].b[1].text_color=529"
|
||||
delay_after: 0.02
|
||||
payload: "p1b1.text_color=529"
|
||||
|
||||
- name: Test rgb565 COLOR
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/json
|
||||
payload: '["p[1].b[1].text_color={rgb565}","p[1].b[1].text_color"]'
|
||||
payload: '["p1b1.text_color={rgb565}","p1b1.text_color"]'
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/p1b1
|
||||
json:
|
||||
|
161
test/test_cpicker.tavern.yaml
Normal file
161
test/test_cpicker.tavern.yaml
Normal file
@ -0,0 +1,161 @@
|
||||
# test_page.tavern.yaml
|
||||
---
|
||||
test_name: Cpicker setup
|
||||
|
||||
includes:
|
||||
- !include config.yaml
|
||||
|
||||
paho-mqtt:
|
||||
client:
|
||||
transport: tcp
|
||||
client_id: tavern-tester
|
||||
connect:
|
||||
host: "{host}"
|
||||
port: !int "{port:d}"
|
||||
timeout: 3
|
||||
auth:
|
||||
username: "{username}"
|
||||
password: "{password}"
|
||||
|
||||
stages:
|
||||
- name: Page 1
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "page 1"
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/page
|
||||
payload: "1"
|
||||
timeout: 1
|
||||
|
||||
- name: Clear page
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/clearpage
|
||||
payload: ""
|
||||
|
||||
---
|
||||
test_name: Cpicker loop
|
||||
|
||||
includes:
|
||||
- !include config.yaml
|
||||
|
||||
paho-mqtt:
|
||||
client:
|
||||
transport: tcp
|
||||
client_id: tavern-tester
|
||||
connect:
|
||||
host: "{host}"
|
||||
port: !int "{port:d}"
|
||||
timeout: 3
|
||||
auth:
|
||||
username: "{username}"
|
||||
password: "{password}"
|
||||
|
||||
marks:
|
||||
- parametrize:
|
||||
key:
|
||||
- color
|
||||
- hex
|
||||
- r
|
||||
- g
|
||||
- b
|
||||
- rgb565
|
||||
vals:
|
||||
- ["red", "#ff0000", 255, 0, 0, 63488]
|
||||
- ["tan", "#d2b48c", 213, 182, 139, 54705]
|
||||
- ["aqua", "#00ffff", 0, 255, 255, 2047]
|
||||
- ["blue", "#0000ff", 0, 0, 255, 31]
|
||||
- ["cyan", "#00ffff", 0, 255, 255, 2047]
|
||||
- ["gold", "#ffd600", 255, 214, 0, 65184]
|
||||
- ["gray", "#838183", 131, 129, 131, 33808]
|
||||
- ["grey", "#838183", 131, 129, 131, 33808]
|
||||
- ["lime", "#00ff00", 0, 255, 0, 2016]
|
||||
- ["navy", "#000083", 0, 0, 131, 16]
|
||||
- ["peru", "#cd8139", 205, 129, 57, 52263]
|
||||
- ["pink", "#ffc2cd", 255, 194, 205, 65049]
|
||||
- ["plum", "#dea1de", 222, 161, 222, 56603]
|
||||
- ["snow", "#fffaff", 255, 250, 255, 65503]
|
||||
- ["teal", "#008183", 0, 129, 131, 1040]
|
||||
- ["azure", "#f6ffff", 246, 255, 255, 63487]
|
||||
- ["beige", "#f6f6de", 246, 246, 222, 63419]
|
||||
- ["black", "#000000", 0, 0, 0, 0]
|
||||
- ["blush", "#b50000", 181, 0, 0, 45056]
|
||||
- ["brown", "#a42829", 164, 40, 41, 41285]
|
||||
- ["coral", "#ff7d52", 255, 125, 82, 64490]
|
||||
- ["green", "#008100", 0, 129, 0, 1024]
|
||||
- ["ivory", "#fffff6", 255, 255, 246, 65534]
|
||||
- ["khaki", "#f6e28b", 246, 226, 139, 63281]
|
||||
- ["linen", "#fff2ee", 255, 242, 238, 65436]
|
||||
- ["olive", "#837d00", 131, 125, 0, 33792]
|
||||
- ["wheat", "#f6dab5", 246, 218, 181, 63222]
|
||||
- ["white", "#ffffff", 255, 255, 255, 65535]
|
||||
- ["bisque", "#ffe6c5", 255, 230, 197, 65336]
|
||||
- ["indigo", "#4a0083", 74, 0, 131, 18448]
|
||||
- ["maroon", "#830000", 131, 0, 0, 32768]
|
||||
- ["orange", "#ffa500", 255, 165, 0, 64800]
|
||||
- ["orchid", "#de71d5", 222, 113, 213, 56218]
|
||||
- ["purple", "#7b0083", 123, 0, 131, 32784]
|
||||
- ["salmon", "#ff8173", 255, 129, 115, 64526]
|
||||
- ["sienna", "#a44c29", 164, 76, 41, 41605]
|
||||
- ["tomato", "#ff6141", 255, 97, 65, 64264]
|
||||
- ["violet", "#ee81ee", 230, 129, 238, 60445]
|
||||
- ["yellow", "#ffff00", 255, 255, 0, 65504]
|
||||
- ["fuchsia", "#f600ff", 246, 0, 255, 63519]
|
||||
- ["magenta", "#f600ff", 246, 0, 255, 63519]
|
||||
- ["silver", "#c5c2c5", 197, 194, 197, 50712]
|
||||
|
||||
stages:
|
||||
- name: Set bg_color
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p[1].b[0].bg_color={color}"
|
||||
|
||||
- name: Create cpicker
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/jsonl
|
||||
json:
|
||||
obj: "cpicker"
|
||||
id: 1
|
||||
color: "{color}"
|
||||
|
||||
- name: Test named COLOR
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.color"
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/p1b1
|
||||
json:
|
||||
color: "{hex}"
|
||||
r: !int "{r:d}"
|
||||
g: !int "{g:d}"
|
||||
b: !int "{b:d}"
|
||||
timeout: 1
|
||||
|
||||
- name: Test hex COLOR
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/json
|
||||
payload: '["p1b1.color={hex}","p1b1.color"]'
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/p1b1
|
||||
json:
|
||||
color: "{hex}"
|
||||
r: !int "{r:d}"
|
||||
g: !int "{g:d}"
|
||||
b: !int "{b:d}"
|
||||
timeout: 1
|
||||
- name: Reset
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.color=529"
|
||||
|
||||
- name: Test rgb565 COLOR
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/json
|
||||
payload: '["p1b1.color={rgb565}","p1b1.color"]'
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/p1b1
|
||||
json:
|
||||
color: "{hex}"
|
||||
r: !int "{r:d}"
|
||||
g: !int "{g:d}"
|
||||
b: !int "{b:d}"
|
||||
timeout: 1
|
@ -26,13 +26,11 @@ stages:
|
||||
topic: hasp/{plate}/state/page
|
||||
payload: "1"
|
||||
timeout: 1
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Clear page
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/clearpage
|
||||
payload: ""
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Create object
|
||||
mqtt_publish:
|
||||
@ -40,13 +38,12 @@ stages:
|
||||
json:
|
||||
objid: 12
|
||||
id: 1
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Set x
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.x=50"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get x
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -74,7 +71,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.y=50"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get y
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -88,7 +85,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.y=25"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get y
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -103,7 +100,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.w=50"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get w
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -131,7 +128,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.h=50"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get h
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -145,7 +142,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.h=25"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get h
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -160,7 +157,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.mode=crop"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get mode
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -170,7 +167,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.w=50"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get w
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -198,7 +195,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.h=50"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get h
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -212,7 +209,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.h=45"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get h
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -227,7 +224,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.enabled=0"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get enabled
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -241,7 +238,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.enabled=1"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get enabled
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -256,7 +253,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.hidden=1"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get hidden
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -280,7 +277,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.hidden=0"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get hidden
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -304,7 +301,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.vis=0"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get hidden
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -328,7 +325,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.vis=1"
|
||||
delay_after: 0.02
|
||||
|
||||
- name: Get hidden
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
|
@ -88,7 +88,6 @@ stages:
|
||||
topic: hasp/{plate}/LWT
|
||||
payload: "offline"
|
||||
timeout: 20
|
||||
delay_after: 0
|
||||
|
||||
---
|
||||
test_name: Idle States
|
||||
@ -114,7 +113,6 @@ stages:
|
||||
topic: hasp/{plate}/state/idle
|
||||
payload: "long"
|
||||
timeout: 190
|
||||
delay_after: 0
|
||||
|
||||
- name: Test idle
|
||||
mqtt_publish:
|
||||
@ -124,7 +122,6 @@ stages:
|
||||
topic: hasp/{plate}/state/idle
|
||||
payload: "short"
|
||||
timeout: 70
|
||||
delay_after: 0
|
||||
|
||||
- name: Test idle
|
||||
mqtt_publish:
|
||||
@ -134,4 +131,3 @@ stages:
|
||||
topic: hasp/{plate}/state/idle
|
||||
payload: "off"
|
||||
timeout: 1
|
||||
delay_after: 0
|
||||
|
@ -1,6 +1,34 @@
|
||||
# test_page.tavern.yaml
|
||||
---
|
||||
test_name: Obj Standard Properties
|
||||
test_name: Objects Standard Properties Setup
|
||||
|
||||
includes:
|
||||
- !include config.yaml
|
||||
|
||||
paho-mqtt:
|
||||
client:
|
||||
transport: tcp
|
||||
client_id: tavern-tester
|
||||
connect:
|
||||
host: "{host}"
|
||||
port: !int "{port:d}"
|
||||
timeout: 3
|
||||
auth:
|
||||
username: "{username}"
|
||||
password: "{password}"
|
||||
|
||||
stages:
|
||||
- name: Page 1
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "page 1"
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/page
|
||||
payload: "1"
|
||||
timeout: 1
|
||||
|
||||
---
|
||||
test_name: Objects Standard Properties Loop
|
||||
|
||||
includes:
|
||||
- !include config.yaml
|
||||
@ -90,13 +118,11 @@ stages:
|
||||
topic: hasp/{plate}/state/page
|
||||
payload: "1"
|
||||
timeout: 1
|
||||
delay_after: 0
|
||||
|
||||
- name: Clear page
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/clearpage
|
||||
payload: ""
|
||||
delay_after: 0.2
|
||||
|
||||
- name: Create object
|
||||
mqtt_publish:
|
||||
@ -106,7 +132,6 @@ stages:
|
||||
id: 1
|
||||
x: 128
|
||||
y: 128
|
||||
delay_after: 0
|
||||
|
||||
- name: Test y
|
||||
mqtt_publish:
|
||||
@ -142,7 +167,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/json
|
||||
payload: '["p1b1.h={h}","p1b1.h"]'
|
||||
delay_after: 0
|
||||
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/p1b1
|
||||
json:
|
||||
@ -153,7 +178,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/json
|
||||
payload: '["p1b1.enabled={hidden}","p1b1.enabled"]'
|
||||
delay_after: 0
|
||||
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/p1b1
|
||||
json:
|
||||
@ -164,7 +189,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.vis={hidden}"
|
||||
delay_after: 0
|
||||
|
||||
- name: Get hidden
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -188,7 +213,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "p1b1.hidden={hidden}"
|
||||
delay_after: 0
|
||||
|
||||
- name: Get hidden
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
@ -233,7 +258,7 @@ stages:
|
||||
mqtt_publish:
|
||||
topic: "hasp/{plate}/command/p1b1.value_str"
|
||||
payload: "{str1}{str2}"
|
||||
delay_after: 0.05
|
||||
|
||||
- name: Get value_str
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
|
@ -1,6 +1,34 @@
|
||||
# test_value_str.tavern.yaml
|
||||
---
|
||||
test_name: Obj Standard Properties
|
||||
test_name: Value String Setup
|
||||
|
||||
includes:
|
||||
- !include config.yaml
|
||||
|
||||
paho-mqtt:
|
||||
client:
|
||||
transport: tcp
|
||||
client_id: tavern-tester
|
||||
connect:
|
||||
host: "{host}"
|
||||
port: !int "{port:d}"
|
||||
timeout: 3
|
||||
auth:
|
||||
username: "{username}"
|
||||
password: "{password}"
|
||||
|
||||
stages:
|
||||
- name: Page 1
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/json
|
||||
payload: '["page 1","clearpage"]'
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/page
|
||||
payload: "1"
|
||||
timeout: 1
|
||||
|
||||
---
|
||||
test_name: Value String Loop
|
||||
|
||||
includes:
|
||||
- !include config.yaml
|
||||
@ -74,16 +102,6 @@ marks:
|
||||
- ""
|
||||
|
||||
stages:
|
||||
- name: Page 1
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
payload: "page 1"
|
||||
mqtt_response:
|
||||
topic: hasp/{plate}/state/page
|
||||
payload: "1"
|
||||
timeout: 1
|
||||
delay_after: 0
|
||||
|
||||
- name: Create object
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command/jsonl
|
||||
@ -94,13 +112,11 @@ stages:
|
||||
y: 0
|
||||
w: 240
|
||||
h: 240
|
||||
delay_after: 0
|
||||
|
||||
- name: Set value_str
|
||||
mqtt_publish:
|
||||
topic: "hasp/{plate}/command/p[1].b[1].value_str"
|
||||
payload: "{str1}{str2}"
|
||||
delay_after: 0
|
||||
- name: Get value_str
|
||||
mqtt_publish:
|
||||
topic: hasp/{plate}/command
|
||||
|
Loading…
x
Reference in New Issue
Block a user