I’d probably give the traffic node a try. Simply listen for the scene data and if it changes to 7800 turn the traffic node to “allow” and then make a loop increasing the brightness. When you release the switch, the scene_data changes to 7740 and that in turn needs to turn the traffice node to “disallow” or “stop”.
Im using something similar with the Ikea Tradfri remote:
[
{
"id": "2db5a6a5.ddffda",
"type": "switch",
"z": "d4113bbe.91f4a8",
"name": "",
"property": "payload",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "brightness_up_hold",
"vt": "str"
},
{
"t": "eq",
"v": "brightness_up_release",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 2,
"x": 330,
"y": 1000,
"wires": [
[
"235ac263.baf1de",
"79a7a052.73"
],
[
"79a7a052.73"
]
]
},
{
"id": "235ac263.baf1de",
"type": "api-current-state",
"z": "d4113bbe.91f4a8",
"name": "",
"server": "2fba4297.e4145e",
"version": 1,
"outputs": 2,
"halt_if": "off",
"halt_if_type": "str",
"halt_if_compare": "is",
"override_topic": false,
"entity_id": "light.wohnzimmer",
"state_type": "str",
"state_location": "payload",
"override_payload": "msg",
"entity_location": "data",
"override_data": "msg",
"blockInputOverrides": false,
"x": 870,
"y": 1000,
"wires": [
[],
[
"3d5903d0.c8a5cc"
]
]
},
{
"id": "3d5903d0.c8a5cc",
"type": "function",
"z": "d4113bbe.91f4a8",
"name": "Lower or Higher",
"func": "newmsg = {}\n\nvar currentbrightness = msg.data.attributes.brightness\nvar up = currentbrightness + 45\n\nnewmsg.payload = { data: { \"brightness\":(up)},\"transition\":\"1\" };\n\n\n\nreturn newmsg;",
"outputs": 1,
"noerr": 0,
"x": 1100,
"y": 1000,
"wires": [
[
"6c08d8e4.aa23d8"
]
]
},
{
"id": "6c08d8e4.aa23d8",
"type": "api-call-service",
"z": "d4113bbe.91f4a8",
"name": "Wohnzimmer 100%",
"server": "2fba4297.e4145e",
"version": "1",
"service_domain": "light",
"service": "turn_on",
"entityId": "light.wohnzimmer",
"data": "",
"dataType": "json",
"mergecontext": "",
"output_location": "",
"output_location_type": "none",
"mustacheAltTags": false,
"x": 1290,
"y": 1000,
"wires": [
[
"6cd31cf3.8c09f4"
]
]
},
{
"id": "79a7a052.73",
"type": "traffic",
"z": "d4113bbe.91f4a8",
"name": "",
"property_allow": "payload",
"filter_allow": "brightness_up_hold",
"ignore_case_allow": false,
"negate_allow": false,
"send_allow": false,
"property_stop": "payload",
"filter_stop": "brightness_up_release",
"ignore_case_stop": false,
"negate_stop": false,
"send_stop": false,
"default_start": false,
"differ": false,
"x": 650,
"y": 1000,
"wires": [
[
"235ac263.baf1de"
]
]
},
{
"id": "6cd31cf3.8c09f4",
"type": "delay",
"z": "d4113bbe.91f4a8",
"name": "",
"pauseType": "delay",
"timeout": "1",
"timeoutUnits": "seconds",
"rate": "1",
"nbRateUnits": "1",
"rateUnits": "second",
"randomFirst": "1",
"randomLast": "5",
"randomUnits": "seconds",
"drop": false,
"x": 480,
"y": 1000,
"wires": [
[
"79a7a052.73"
]
]
},
{
"id": "89e8dfba.f919b",
"type": "server-state-changed",
"z": "d4113bbe.91f4a8",
"name": "Button?",
"server": "2fba4297.e4145e",
"version": 1,
"entityidfilter": "sensor.ikea_remote_action",
"entityidfiltertype": "exact",
"outputinitially": false,
"state_type": "str",
"haltifstate": "",
"halt_if_type": "str",
"halt_if_compare": "is",
"outputs": 1,
"output_only_on_state_change": true,
"x": 70,
"y": 1000,
"wires": [
[
"513118c2.ffcf08",
"387a685a.e54248",
"2db5a6a5.ddffda",
"9001417d.475cf",
"f79774f7.10fe88"
]
]
},
{
"id": "9bd2c2f0.f1535",
"type": "comment",
"z": "d4113bbe.91f4a8",
"name": "Up",
"info": "",
"x": 330,
"y": 960,
"wires": []
},
{
"id": "2fba4297.e4145e",
"type": "server",
"z": "",
"name": "Home Assistant",
"legacy": false,
"hassio": true,
"rejectUnauthorizedCerts": true,
"ha_boolean": "y|yes|true|on|home|open",
"connectionDelay": true
}
]