I seem to be losing my ability to read.
This is the bit of code:
[
{
"id": "d6ed3ea3758e7956",
"type": "inject",
"z": "26262ba1.62dcbc",
"name": "Reset",
"props": [
{
"p": "reset",
"v": "reset",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"x": 2600,
"y": 6090,
"wires": [
[
"e031db0c1b449082"
]
]
},
{
"id": "ba2e5d8d78dc9049",
"type": "inject",
"z": "26262ba1.62dcbc",
"name": "Reset",
"props": [
{
"p": "payload"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"payload": "reset",
"payloadType": "str",
"x": 2600,
"y": 6130,
"wires": [
[
"e031db0c1b449082"
]
]
},
{
"id": "e031db0c1b449082",
"type": "junction",
"z": "26262ba1.62dcbc",
"x": 2690,
"y": 6110,
"wires": [
[
"e6b08c85efe7f4a0"
]
]
},
{
"id": "e6b08c85efe7f4a0",
"type": "trigger",
"z": "26262ba1.62dcbc",
"name": "Timer",
"op1": "on",
"op2": "off",
"op1type": "str",
"op2type": "str",
"duration": "250",
"extend": false,
"overrideDelay": true,
"units": "ms",
"reset": "reset",
"bytopic": "topic",
"topic": "topic",
"outputs": 1,
"x": 2620,
"y": 6350,
"wires": [
[
"28dea75b3e5b1aec",
"39698f31cc2c1ac7"
]
]
}
]
NEITHER of the reset inject nodes reset it if it is running.
Why not?
I'm sending a msg.reset
I ticked the if msg.payload == and set it to reset and send that.
OBSERVATION
This example handles different topics.
If I untick that: it works and the reset works.
New example code showing both ways.
[{"id":"f590dc16c5aa0177","type":"trigger","z":"26262ba1.62dcbc","name":"","op1":"1","op2":"0","op1type":"str","op2type":"str","duration":"250","extend":false,"overrideDelay":true,"units":"ms","reset":"","bytopic":"topic","topic":"topic","outputs":1,"x":3900,"y":6320,"wires":[[]]},{"id":"3abdb00e854c6371","type":"inject","z":"26262ba1.62dcbc","name":"Can't reset","props":[{"p":"payload"},{"p":"delay","v":"20000","vt":"num"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"topic","payload":"foo","payloadType":"str","x":3700,"y":6320,"wires":[["f590dc16c5aa0177"]]},{"id":"56480dde8153495e","type":"inject","z":"26262ba1.62dcbc","name":"reset","props":[{"p":"reset","v":"reset","vt":"str"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":3710,"y":6270,"wires":[["f590dc16c5aa0177"]]},{"id":"9ae784ad56707ebd","type":"inject","z":"26262ba1.62dcbc","name":"reset","props":[{"p":"reset","v":"reset","vt":"str"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":3710,"y":6370,"wires":[["7ae631ad1aa4f971"]]},{"id":"7ae631ad1aa4f971","type":"trigger","z":"26262ba1.62dcbc","name":"","op1":"1","op2":"0","op1type":"str","op2type":"str","duration":"250","extend":false,"overrideDelay":true,"units":"ms","reset":"","bytopic":"all","topic":"topic","outputs":1,"x":3900,"y":6420,"wires":[[]]},{"id":"dd6953b24c6d4da0","type":"inject","z":"26262ba1.62dcbc","name":"CAN reset","props":[{"p":"payload"},{"p":"delay","v":"20000","vt":"num"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"topic","payload":"foo","payloadType":"str","x":3700,"y":6420,"wires":[["7ae631ad1aa4f971"]]}]