Skip to content

Commit cba7ec9

Browse files
authored
update 4067 example
1 parent 40ac572 commit cba7ec9

File tree

1 file changed

+13
-18
lines changed

1 file changed

+13
-18
lines changed

docs/Scripting-Language.md

Lines changed: 13 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -2530,26 +2530,21 @@ start dim level = initial dimmer level after power-up or restart; max 100
25302530
next
25312531
endif
25322532

2533+
#rsub
2534+
rap ,"CD4067":{
2535+
for cnt 1 16 1
2536+
rap "%is1[cnt]%":%mux[cnt]%
2537+
if cnt<16
2538+
then
2539+
rap ,
2540+
endif
2541+
next
2542+
rap }
2543+
25332544
>J
25342545
; send to mqtt
2535-
,"CD4067":{
2536-
"%is1[1]%":%mux[1]%,
2537-
"%is1[2]%":%mux[2]%,
2538-
"%is1[3]%":%mux[3]%,
2539-
"%is1[4]%":%mux[4]%,
2540-
"%is1[5]%":%mux[5]%,
2541-
"%is1[6]%":%mux[6]%,
2542-
"%is1[7]%":%mux[7]%,
2543-
"%is1[8]%":%mux[8]%,
2544-
"%is1[9]%":%mux[9]%,
2545-
"%is1[10]%":%mux[10]%,
2546-
"%is1[11]%":%mux[11]%,
2547-
"%is1[12]%":%mux[12]%,
2548-
"%is1[13]%":%mux[13]%,
2549-
"%is1[14]%":%mux[14]%,
2550-
"%is1[15]%":%mux[15]%,
2551-
"%is1[16]%":%mux[16]%
2552-
}
2546+
; call json subroutine
2547+
%=#rsub
25532548

25542549
>W
25552550
; call web subroutine

0 commit comments

Comments
 (0)