Thanks! I started at the top and worked though it methodically and now have it working correctly.
By capturing what I needed later in the flow and passing that info though, I was able to change this
{"id":"be5d7a99069b1e51","type":"switch","z":"e6297a214de291b4","name":"Correct?","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"$round($round($number(msg.payload.data.position) * 0.99, 0) / 0.99,0)\t\t","vt":"jsonata"},{"t":"else"}],"checkall":"false","repair":false,"outputs":2,"x":520,"y":180,"wires":[["fc6ddbc0b036f5eb"],["d782386f816f1200"
to this:
[{"id":"be5d7a99069b1e51","type":"switch","z":"e6297a214de291b4","name":"Correct?","property":"current_position","propertyType":"msg","rules":[{"t":"eq","v":"$round($round($number(msg.blind_preset.blind_preset) * 0.99, 0) / 0.99,0)\t\t","vt":"jsonata"},{"t":"else"}],"checkall":"false","repair":false,"outputs":2,"x":720,"y":160,"wires":[["fc6ddbc0b036f5eb"],["d782386f816f1200","0d04f7680c9279e0"]]}]
Here is my revised design..
[{"id":"e6297a214de291b4","type":"subflow","name":"Check Blind Position (2)","info":"","category":"","in":[{"x":40,"y":180,"wires":[{"id":"3afea99cf6ff17d9"}]}],"out":[{"x":1000,"y":166,"wires":[{"id":"d782386f816f1200","port":0}]}],"env":[],"meta":{},"color":"#DDAA99"},{"id":"3afea99cf6ff17d9","type":"delay","z":"e6297a214de291b4","name":"","pauseType":"delay","timeout":"10","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":160,"y":180,"wires":[["3e590d726f9522a2"]]},{"id":"3d323d005e2f1717","type":"api-render-template","z":"e6297a214de291b4","name":"Get Blind Position","server":"c879ac61.99cd1","version":0,"template":"states.{{msg.payload}}.attributes.current_position","resultsLocation":"payload","resultsLocationType":"msg","templateLocation":"template","templateLocationType":"msg","x":190,"y":300,"wires":[[]]},{"id":"be5d7a99069b1e51","type":"switch","z":"e6297a214de291b4","name":"Correct?","property":"current_position","propertyType":"msg","rules":[{"t":"eq","v":"$round($round($number(msg.blind_preset.blind_preset) * 0.99, 0) / 0.99,0)\t\t","vt":"jsonata"},{"t":"else"}],"checkall":"false","repair":false,"outputs":2,"x":720,"y":160,"wires":[["fc6ddbc0b036f5eb"],["d782386f816f1200","0d04f7680c9279e0"]]},{"id":"d782386f816f1200","type":"repeat","z":"e6297a214de291b4","name":"Retry","repetitions":"3","elseOutput":false,"outputs":1,"x":890,"y":166,"wires":[[]]},{"id":"fc6ddbc0b036f5eb","type":"debug","z":"e6297a214de291b4","name":"EQUAL","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"true","targetType":"full","statusVal":"payload","statusType":"auto","x":899,"y":114,"wires":[]},{"id":"0d04f7680c9279e0","type":"debug","z":"e6297a214de291b4","name":"RETRY","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"true","targetType":"full","statusVal":"payload","statusType":"auto","x":900,"y":220,"wires":[]},{"id":"f0a8df9e84a81b81","type":"debug","z":"e6297a214de291b4","name":">>> MSG IN","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":350,"y":140,"wires":[]},{"id":"3e590d726f9522a2","type":"api-current-state","z":"e6297a214de291b4","name":"","server":"c879ac61.99cd1","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"{{payload.data.entity_id}}","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"entity","propertyType":"msg","value":"","valueType":"entity"},{"property":"topic","propertyType":"msg","value":"msg.topic","valueType":"jsonata"},{"property":"blind_preset","propertyType":"msg","value":"msg.blind_preset","valueType":"jsonata"},{"property":"current_position","propertyType":"msg","value":"$entity().state.attributes.current_position","valueType":"jsonata"}],"for":0,"forType":"num","forUnits":"minutes","override_topic":false,"state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","x":440,"y":180,"wires":[["be5d7a99069b1e51"]]},{"id":"ec02ed66656daccb","type":"debug","z":"e6297a214de291b4","name":"MSGOUT >>>","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":720,"y":220,"wires":[]},{"id":"33715394c50bb9b2","type":"comment","z":"3a2942f23b8df6dc","name":"Blinds","info":"","x":70,"y":60,"wires":[]},{"id":"8c71885ebfdfdb22","type":"api-call-service","z":"3a2942f23b8df6dc","name":"Living Room","server":"c879ac61.99cd1","version":3,"debugenabled":false,"service_domain":"cover","service":"set_cover_position","entityId":"cover.living_room_blind","data":"{\"position\":$number(msg.blind_position)}","dataType":"jsonata","mergecontext":"","mustacheAltTags":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"data"}],"queue":"none","x":910,"y":500,"wires":[["c340abca1a6cc12b"]]},{"id":"36e8984c012a32cb","type":"api-call-service","z":"3a2942f23b8df6dc","name":"Bedroom","server":"c879ac61.99cd1","version":3,"debugenabled":false,"service_domain":"cover","service":"set_cover_position","entityId":"cover.bedroom_blind","data":"{\"position\":$number(msg.blind_position)}","dataType":"jsonata","mergecontext":"","mustacheAltTags":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"data"}],"queue":"none","x":900,"y":780,"wires":[["51dc1668d4833007"]]},{"id":"f9930d18c1b4e83f","type":"api-call-service","z":"3a2942f23b8df6dc","name":"Patio Door","server":"c879ac61.99cd1","version":3,"debugenabled":false,"service_domain":"cover","service":"set_cover_position","entityId":"cover.patio_door_blind","data":"{\"position\":$number(msg.blind_position)}","dataType":"jsonata","mergecontext":"","mustacheAltTags":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"data"}],"queue":"none","x":910,"y":640,"wires":[["21b17ab29d57c954"]]},{"id":"3d8bd6f78bba04a8","type":"api-call-service","z":"3a2942f23b8df6dc","name":"Kitchen 2","server":"c879ac61.99cd1","version":3,"debugenabled":false,"service_domain":"cover","service":"set_cover_position","entityId":"cover.kitchen_blind_2","data":"{\"position\":$number(msg.blind_position)}","dataType":"jsonata","mergecontext":"","mustacheAltTags":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"data"}],"queue":"none","x":900,"y":220,"wires":[["c862b3690ce623f8"]]},{"id":"3cc872052c9b410d","type":"api-call-service","z":"3a2942f23b8df6dc","name":"Kitchen 3","server":"c879ac61.99cd1","version":3,"debugenabled":false,"service_domain":"cover","service":"set_cover_position","entityId":"cover.kitchen_blind_3","data":"{\"position\":$number(msg.blind_position)}","dataType":"jsonata","mergecontext":"","mustacheAltTags":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"data"}],"queue":"none","x":900,"y":360,"wires":[["5619e01082d68ca4"]]},{"id":"7c29659767672a57","type":"server-state-changed","z":"3a2942f23b8df6dc","name":"Night mode","server":"c879ac61.99cd1","version":3,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"binary_sensor.night_mode","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"on","halt_if_type":"str","halt_if_compare":"is","outputs":2,"output_only_on_state_change":true,"for":"2","forType":"num","forUnits":"minutes","ignorePrevStateNull":true,"ignorePrevStateUnknown":true,"ignorePrevStateUnavailable":true,"ignoreCurrentStateUnknown":true,"ignoreCurrentStateUnavailable":true,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"eventData"},{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"},{"property":"blind_position","propertyType":"msg","value":"$entity().state = on ? 99 : null","valueType":"jsonata"}],"x":190,"y":380,"wires":[["b7e69af7fc22e723"],["33d6b266dd0daefe"]]},{"id":"ed4248b134f71c7a","type":"api-current-state","z":"3a2942f23b8df6dc","name":"Home?","server":"c879ac61.99cd1","version":3,"outputs":2,"halt_if":"home","halt_if_type":"str","halt_if_compare":"is","entity_id":"person.daniel_brunt","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"entity"}],"for":0,"forType":"num","forUnits":"minutes","x":800,"y":900,"wires":[["d01bad5423dd52b0"],["36e8984c012a32cb"]]},{"id":"d01bad5423dd52b0","type":"api-current-state","z":"3a2942f23b8df6dc","name":"Awake?","server":"c879ac61.99cd1","version":3,"outputs":2,"halt_if":"off","halt_if_type":"str","halt_if_compare":"is","entity_id":"input_boolean.sleep_mode","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"entity"}],"for":0,"forType":"num","forUnits":"minutes","x":720,"y":840,"wires":[["36e8984c012a32cb"],[]]},{"id":"cd1d4f722c24ce12","type":"api-current-state","z":"3a2942f23b8df6dc","name":"Preset","server":"c879ac61.99cd1","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"input_number.kitchen_blind_3","state_type":"num","blockInputOverrides":false,"outputProperties":[{"property":"blind_position","propertyType":"msg","value":"","valueType":"entityState"}],"for":0,"forType":"num","forUnits":"minutes","x":710,"y":420,"wires":[["3cc872052c9b410d"]]},{"id":"2effdbdb63ec3712","type":"server-state-changed","z":"3a2942f23b8df6dc","name":"Bedroom Preset","server":"c879ac61.99cd1","version":3,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"input_number.bedroom_blind","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"for":0,"forType":"num","forUnits":"minutes","ignorePrevStateNull":false,"ignorePrevStateUnknown":false,"ignorePrevStateUnavailable":false,"ignoreCurrentStateUnknown":false,"ignoreCurrentStateUnavailable":false,"outputProperties":[{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"},{"property":"blind_position","propertyType":"msg","value":"$number($entity().state)","valueType":"jsonata"}],"x":640,"y":780,"wires":[["36e8984c012a32cb"]]},{"id":"843791376b0ca738","type":"server-state-changed","z":"3a2942f23b8df6dc","name":"Patio Door Preset","server":"c879ac61.99cd1","version":3,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"input_number.patio_door_blind","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"for":0,"forType":"num","forUnits":"minutes","ignorePrevStateNull":false,"ignorePrevStateUnknown":false,"ignorePrevStateUnavailable":false,"ignoreCurrentStateUnknown":false,"ignoreCurrentStateUnavailable":false,"outputProperties":[{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"},{"property":"blind_position","propertyType":"msg","value":"$number($entity().state)","valueType":"jsonata"}],"x":640,"y":640,"wires":[["f9930d18c1b4e83f"]]},{"id":"8a6e5a85c025723d","type":"server-state-changed","z":"3a2942f23b8df6dc","name":"Living Room Preset","server":"c879ac61.99cd1","version":3,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"input_number.living_room_blind","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"for":0,"forType":"num","forUnits":"minutes","ignorePrevStateNull":false,"ignorePrevStateUnknown":false,"ignorePrevStateUnavailable":false,"ignoreCurrentStateUnknown":false,"ignoreCurrentStateUnavailable":false,"outputProperties":[{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"},{"property":"blind_position","propertyType":"msg","value":"$number($entity().state)","valueType":"jsonata"}],"x":630,"y":500,"wires":[["8c71885ebfdfdb22"]]},{"id":"dede40213235bc18","type":"server-state-changed","z":"3a2942f23b8df6dc","name":"Kitchen 2 Preset","server":"c879ac61.99cd1","version":3,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"input_number.kitchen_blind_2","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"for":0,"forType":"num","forUnits":"minutes","ignorePrevStateNull":false,"ignorePrevStateUnknown":false,"ignorePrevStateUnavailable":false,"ignoreCurrentStateUnknown":false,"ignoreCurrentStateUnavailable":false,"outputProperties":[{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"},{"property":"blind_position","propertyType":"msg","value":"$number($entity().state)","valueType":"jsonata"}],"x":640,"y":220,"wires":[["3d8bd6f78bba04a8"]]},{"id":"c1e5b19b4996726d","type":"server-state-changed","z":"3a2942f23b8df6dc","name":"Kitchen 3 Preset","server":"c879ac61.99cd1","version":3,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"input_number.kitchen_blind_3","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"for":0,"forType":"num","forUnits":"minutes","ignorePrevStateNull":false,"ignorePrevStateUnknown":false,"ignorePrevStateUnavailable":false,"ignoreCurrentStateUnknown":false,"ignoreCurrentStateUnavailable":false,"outputProperties":[{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"},{"property":"blind_position","propertyType":"msg","value":"$number($entity().state)","valueType":"jsonata"}],"x":640,"y":360,"wires":[["3cc872052c9b410d"]]},{"id":"c862b3690ce623f8","type":"subflow:e6297a214de291b4","z":"3a2942f23b8df6dc","name":"Check","env":[],"x":1050,"y":220,"wires":[[]]},{"id":"5619e01082d68ca4","type":"subflow:e6297a214de291b4","z":"3a2942f23b8df6dc","name":"Check","env":[],"x":1050,"y":360,"wires":[[]]},{"id":"c340abca1a6cc12b","type":"subflow:e6297a214de291b4","z":"3a2942f23b8df6dc","name":"Check","env":[],"x":1050,"y":500,"wires":[[]]},{"id":"21b17ab29d57c954","type":"subflow:e6297a214de291b4","z":"3a2942f23b8df6dc","name":"Check","env":[],"x":1050,"y":640,"wires":[[]]},{"id":"51dc1668d4833007","type":"subflow:e6297a214de291b4","z":"3a2942f23b8df6dc","name":"Check","env":[],"x":1050,"y":780,"wires":[[]]},{"id":"cda764e22ec736e9","type":"ha-button","z":"3a2942f23b8df6dc","name":"Close","version":0,"debugenabled":false,"outputs":1,"entityConfig":"6f4289fef8fe0216","outputProperties":[{"property":"blind_position","propertyType":"msg","value":"0","valueType":"num"}],"x":130,"y":320,"wires":[["b7e69af7fc22e723","379da37adb41f711"]]},{"id":"20da19a8178e9bf8","type":"ha-button","z":"3a2942f23b8df6dc","name":"Open","version":0,"debugenabled":false,"outputs":1,"entityConfig":"ad2d0beb111a89a5","outputProperties":[{"property":"payload","propertyType":"msg","value":"true","valueType":"bool"}],"x":130,"y":440,"wires":[["33d6b266dd0daefe"]]},{"id":"207e0a3bedc7f1d9","type":"ui_button","z":"3a2942f23b8df6dc","name":"Close","group":"7637eac1.3e08b4","order":5,"width":0,"height":0,"passthru":true,"label":"Close Blinds","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"on","payloadType":"str","topic":"topic","topicType":"msg","x":90,"y":280,"wires":[["cd8d59178ebbc590"]]},{"id":"fee4c18566228130","type":"link in","z":"3a2942f23b8df6dc","name":"Kitchen 1 Night","links":["b7e69af7fc22e723"],"x":585,"y":60,"wires":[["53522d5ec16217c4"]]},{"id":"76654f5f88395dfd","type":"link in","z":"3a2942f23b8df6dc","name":"Bedroom","links":["b7e69af7fc22e723"],"x":745,"y":802,"wires":[["36e8984c012a32cb"]]},{"id":"2095599a5a0742eb","type":"link in","z":"3a2942f23b8df6dc","name":"Patio Door","links":["b7e69af7fc22e723"],"x":745,"y":662,"wires":[["f9930d18c1b4e83f"]]},{"id":"b11fc5b0f6f3f2aa","type":"link in","z":"3a2942f23b8df6dc","name":"Kitchen 3","links":["b7e69af7fc22e723"],"x":745,"y":382,"wires":[["3cc872052c9b410d"]]},{"id":"2540d484eada57af","type":"link in","z":"3a2942f23b8df6dc","name":"Living Room","links":["b7e69af7fc22e723"],"x":745,"y":522,"wires":[["8c71885ebfdfdb22"]]},{"id":"9fb6833df7f73bf8","type":"link in","z":"3a2942f23b8df6dc","name":"Kitchen 2","links":["b7e69af7fc22e723"],"x":745,"y":243,"wires":[["3d8bd6f78bba04a8"]]},{"id":"b7e69af7fc22e723","type":"link out","z":"3a2942f23b8df6dc","name":"Night Mode On","mode":"link","links":["fee4c18566228130","9fb6833df7f73bf8","b11fc5b0f6f3f2aa","2540d484eada57af","2095599a5a0742eb","76654f5f88395dfd"],"x":345,"y":360,"wires":[]},{"id":"b0694bab21c40ade","type":"link in","z":"3a2942f23b8df6dc","name":"Kitchen 1 Day","links":["33d6b266dd0daefe"],"x":585,"y":120,"wires":[["05340dc0a0bbf59a"]]},{"id":"554c5a6641e4c0a2","type":"link in","z":"3a2942f23b8df6dc","name":"Kitchen 2 Day","links":["33d6b266dd0daefe"],"x":625,"y":280,"wires":[["03f3ad8513fceeb9"]]},{"id":"d24eed52f625cd7e","type":"link in","z":"3a2942f23b8df6dc","name":"Kitchen 3 Day","links":["33d6b266dd0daefe"],"x":625,"y":420,"wires":[["cd1d4f722c24ce12"]]},{"id":"6391aa3bd06304ec","type":"link in","z":"3a2942f23b8df6dc","name":"Living Room Day","links":["33d6b266dd0daefe"],"x":625,"y":560,"wires":[["3f997175efc98ee0"]]},{"id":"7ac93a9b81b75e9a","type":"link in","z":"3a2942f23b8df6dc","name":"Patio Door Day","links":["33d6b266dd0daefe"],"x":625,"y":700,"wires":[["6dbfc34999d8c3a1"]]},{"id":"cd2ec401ccbaf2f9","type":"link in","z":"3a2942f23b8df6dc","name":"Bedroom Day","links":["33d6b266dd0daefe"],"x":585,"y":900,"wires":[["e4ee82525e7119c3"]]},{"id":"33d6b266dd0daefe","type":"link out","z":"3a2942f23b8df6dc","name":"Day","mode":"link","links":["b0694bab21c40ade","554c5a6641e4c0a2","d24eed52f625cd7e","6391aa3bd06304ec","7ac93a9b81b75e9a","cd2ec401ccbaf2f9"],"x":345,"y":400,"wires":[]},{"id":"05340dc0a0bbf59a","type":"api-call-service","z":"3a2942f23b8df6dc","name":"Open Kitchen Blind 1","server":"c879ac61.99cd1","version":3,"debugenabled":false,"service_domain":"switch","service":"turn_on","entityId":"switch.kitchen_blind_1","data":"","dataType":"jsonata","mergecontext":"","mustacheAltTags":false,"outputProperties":[],"queue":"none","x":720,"y":120,"wires":[[]]},{"id":"53522d5ec16217c4","type":"api-call-service","z":"3a2942f23b8df6dc","name":"Close Kitchen Blind 1","server":"c879ac61.99cd1","version":3,"debugenabled":false,"service_domain":"switch","service":"turn_off","entityId":"switch.kitchen_blind_1","data":"","dataType":"jsonata","mergecontext":"","mustacheAltTags":false,"outputProperties":[],"queue":"none","x":720,"y":60,"wires":[[]]},{"id":"03f3ad8513fceeb9","type":"api-current-state","z":"3a2942f23b8df6dc","name":"Preset","server":"c879ac61.99cd1","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"input_number.kitchen_blind_2","state_type":"num","blockInputOverrides":false,"outputProperties":[{"property":"blind_position","propertyType":"msg","value":"","valueType":"entityState"}],"for":0,"forType":"num","forUnits":"minutes","x":710,"y":280,"wires":[["3d8bd6f78bba04a8"]]},{"id":"3f997175efc98ee0","type":"api-current-state","z":"3a2942f23b8df6dc","name":"Preset","server":"c879ac61.99cd1","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"input_number.living_room_blind","state_type":"num","blockInputOverrides":false,"outputProperties":[{"property":"blind_position","propertyType":"msg","value":"","valueType":"entityState"}],"for":0,"forType":"num","forUnits":"minutes","x":710,"y":560,"wires":[["8c71885ebfdfdb22"]]},{"id":"6dbfc34999d8c3a1","type":"api-current-state","z":"3a2942f23b8df6dc","name":"Preset","server":"c879ac61.99cd1","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"input_number.patio_door_blind","state_type":"num","blockInputOverrides":false,"outputProperties":[{"property":"blind_position","propertyType":"msg","value":"","valueType":"entityState"}],"for":0,"forType":"num","forUnits":"minutes","x":710,"y":700,"wires":[["f9930d18c1b4e83f"]]},{"id":"e4ee82525e7119c3","type":"api-current-state","z":"3a2942f23b8df6dc","name":"Preset","server":"c879ac61.99cd1","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"input_number.bedroom_blind","state_type":"num","blockInputOverrides":false,"outputProperties":[{"property":"blind_position","propertyType":"msg","value":"","valueType":"entityState"}],"for":0,"forType":"num","forUnits":"minutes","x":670,"y":900,"wires":[["ed4248b134f71c7a"]]},{"id":"cd8d59178ebbc590","type":"change","z":"3a2942f23b8df6dc","name":"99","rules":[{"t":"set","p":"blind_position","pt":"msg","to":"0","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":210,"y":280,"wires":[["b7e69af7fc22e723","379da37adb41f711"]]},{"id":"a0869df71b06da89","type":"ui_button","z":"3a2942f23b8df6dc","name":"Open","group":"7637eac1.3e08b4","order":5,"width":0,"height":0,"passthru":true,"label":"Open Blinds","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"true","payloadType":"bool","topic":"topic","topicType":"msg","x":90,"y":480,"wires":[["33d6b266dd0daefe"]]},{"id":"379da37adb41f711","type":"debug","z":"3a2942f23b8df6dc","name":"C L O S E","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":400,"y":300,"wires":[]},{"id":"c879ac61.99cd1","type":"server","name":"Home Assistant","version":2,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":false,"cacheJson":true,"heartbeat":false,"heartbeatInterval":"30"},{"id":"6f4289fef8fe0216","type":"ha-entity-config","server":"c879ac61.99cd1","name":"Close Blinds","version":2,"haConfig":[{"property":"name","value":"Close Blinds"},{"property":"icon","value":""},{"property":"device_class","value":""}],"entityType":"button"},{"id":"ad2d0beb111a89a5","type":"ha-entity-config","server":"c879ac61.99cd1","name":"Open Blinds","version":2,"haConfig":[{"property":"name","value":"Open Blinds"},{"property":"icon","value":""},{"property":"device_class","value":""}],"entityType":"button"},{"id":"7637eac1.3e08b4","type":"ui_group","name":"Triggers","tab":"f1b3c4b9490cc675","order":1,"disp":true,"width":"6","collapse":false,"className":""},{"id":"f1b3c4b9490cc675","type":"ui_tab","name":"Home","icon":"dashboard","disabled":false,"hidden":false}]
[{"id":"3afea99cf6ff17d9","type":"delay","z":"e6297a214de291b4","name":"","pauseType":"delay","timeout":"10","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":160,"y":180,"wires":[["3e590d726f9522a2"]]},{"id":"be5d7a99069b1e51","type":"switch","z":"e6297a214de291b4","name":"Correct?","property":"current_position","propertyType":"msg","rules":[{"t":"eq","v":"$round($round($number(msg.blind_preset.blind_preset) * 0.99, 0) / 0.99,0)\t\t","vt":"jsonata"},{"t":"else"}],"checkall":"false","repair":false,"outputs":2,"x":720,"y":160,"wires":[["fc6ddbc0b036f5eb"],["d782386f816f1200","0d04f7680c9279e0"]]},{"id":"d782386f816f1200","type":"repeat","z":"e6297a214de291b4","name":"Retry","repetitions":"3","elseOutput":false,"outputs":1,"x":890,"y":166,"wires":[[]]},{"id":"fc6ddbc0b036f5eb","type":"debug","z":"e6297a214de291b4","name":"EQUAL","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"true","targetType":"full","statusVal":"payload","statusType":"auto","x":899,"y":114,"wires":[]},{"id":"0d04f7680c9279e0","type":"debug","z":"e6297a214de291b4","name":"RETRY","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"true","targetType":"full","statusVal":"payload","statusType":"auto","x":900,"y":220,"wires":[]},{"id":"f0a8df9e84a81b81","type":"debug","z":"e6297a214de291b4","name":">>> MSG IN","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":350,"y":140,"wires":[]},{"id":"3e590d726f9522a2","type":"api-current-state","z":"e6297a214de291b4","name":"","server":"c879ac61.99cd1","version":3,"outputs":1,"halt_if":"","halt_if_type":"str","halt_if_compare":"is","entity_id":"{{payload.data.entity_id}}","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"entity","propertyType":"msg","value":"","valueType":"entity"},{"property":"topic","propertyType":"msg","value":"msg.topic","valueType":"jsonata"},{"property":"blind_preset","propertyType":"msg","value":"msg.blind_preset","valueType":"jsonata"},{"property":"current_position","propertyType":"msg","value":"$entity().state.attributes.current_position","valueType":"jsonata"}],"for":0,"forType":"num","forUnits":"minutes","override_topic":false,"state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","x":440,"y":180,"wires":[["be5d7a99069b1e51"]]},{"id":"ec02ed66656daccb","type":"debug","z":"e6297a214de291b4","name":"MSGOUT >>>","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":720,"y":220,"wires":[]},{"id":"c879ac61.99cd1","type":"server","name":"Home Assistant","version":2,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":false,"cacheJson":true,"heartbeat":false,"heartbeatInterval":"30"}]