diff --git a/flows/main.json b/flows/main.json index 19c5e14..58a1ebb 100644 --- a/flows/main.json +++ b/flows/main.json @@ -6136,7 +6136,7 @@ "z": "9daf9e2b.019fc", "name": "", "group": "1be83144.4fe4bf", - "order": 10, + "order": 15, "width": 2, "height": 1, "passthru": false, @@ -6148,8 +6148,8 @@ "payload": "reboot", "payloadType": "str", "topic": "reboot", - "x": 400, - "y": 420, + "x": 420, + "y": 680, "wires": [ [ "4af9112d.87767" @@ -6167,8 +6167,8 @@ "timer": "2", "oldrc": false, "name": "cmd", - "x": 870, - "y": 460, + "x": 710, + "y": 720, "wires": [ [], [], @@ -6181,7 +6181,7 @@ "z": "9daf9e2b.019fc", "name": "", "group": "1be83144.4fe4bf", - "order": 8, + "order": 17, "width": 2, "height": 1, "passthru": false, @@ -6193,8 +6193,8 @@ "payload": "shutdown", "payloadType": "str", "topic": "shutdown", - "x": 390, - "y": 500, + "x": 410, + "y": 760, "wires": [ [ "4af9112d.87767" @@ -6227,8 +6227,8 @@ "timer": "", "oldrc": false, "name": "", - "x": 1100, - "y": 340, + "x": 1120, + "y": 600, "wires": [ [], [ @@ -6252,8 +6252,8 @@ "randomLast": "5", "randomUnits": "seconds", "drop": false, - "x": 700, - "y": 340, + "x": 720, + "y": 600, "wires": [ [ "fa914867.0a0658" @@ -6266,7 +6266,7 @@ "z": "9daf9e2b.019fc", "name": "Restart Python", "group": "1be83144.4fe4bf", - "order": 6, + "order": 12, "width": 4, "height": 1, "passthru": true, @@ -6278,8 +6278,9 @@ "payload": "", "payloadType": "str", "topic": "", - "x": 380, - "y": 340, + "topicType": "str", + "x": 400, + "y": 600, "wires": [ [ "1575db82.742854", @@ -6299,8 +6300,8 @@ "timer": "", "oldrc": false, "name": "Python soft kill", - "x": 720, - "y": 400, + "x": 740, + "y": 660, "wires": [ [], [], @@ -6318,8 +6319,8 @@ "timer": "", "oldrc": false, "name": "Raspimjpeg soft kill", - "x": 730, - "y": 280, + "x": 750, + "y": 540, "wires": [ [], [], @@ -6340,8 +6341,8 @@ "fwdInMessages": false, "resendOnRefresh": false, "templateScope": "local", - "x": 1660, - "y": 380, + "x": 1700, + "y": 640, "wires": [ [] ] @@ -6356,8 +6357,8 @@ "noerr": 0, "initialize": "", "finalize": "", - "x": 1480, - "y": 300, + "x": 1500, + "y": 560, "wires": [ [ "d12008a0.47be4" @@ -6382,8 +6383,8 @@ "payload": "", "payloadType": "str", "topic": "", - "x": 1320, - "y": 460, + "x": 1340, + "y": 720, "wires": [ [ "73500be7.9ab7c4" @@ -6397,8 +6398,8 @@ "name": "Catch Errors", "scope": null, "uncaught": false, - "x": 1070, - "y": 400, + "x": 1090, + "y": 660, "wires": [ [ "f9a871d5.a73828" @@ -6415,8 +6416,8 @@ "noerr": 0, "initialize": "", "finalize": "", - "x": 1240, - "y": 400, + "x": 1260, + "y": 660, "wires": [ [ "8b511c2b.9c24c8" @@ -6433,8 +6434,8 @@ "noerr": 0, "initialize": "", "finalize": "", - "x": 1480, - "y": 460, + "x": 1500, + "y": 720, "wires": [ [ "d12008a0.47be4" @@ -6458,8 +6459,8 @@ "topic": "", "payload": "start", "payloadType": "str", - "x": 130, - "y": 340, + "x": 150, + "y": 600, "wires": [ [ "466eb611.4da048" @@ -6658,11 +6659,11 @@ "z": "9daf9e2b.019fc", "name": "Update", "group": "1be83144.4fe4bf", - "order": 3, + "order": 9, "width": 6, "height": 1, "passthru": false, - "label": "Update", + "label": "System Update", "tooltip": "", "color": "", "bgcolor": "", @@ -6670,8 +6671,9 @@ "payload": "", "payloadType": "str", "topic": "update", - "x": 400, - "y": 220, + "topicType": "str", + "x": 440, + "y": 460, "wires": [ [ "2d2ef1fd.40e6e6" @@ -6689,8 +6691,8 @@ "timer": "", "oldrc": false, "name": "Update", - "x": 700, - "y": 220, + "x": 720, + "y": 460, "wires": [ [ "64f61762.68c788", @@ -6717,7 +6719,7 @@ "fwdInMessages": true, "resendOnRefresh": true, "templateScope": "local", - "x": 390, + "x": 410, "y": 180, "wires": [ [] @@ -6737,8 +6739,8 @@ "raw": false, "topic": "", "name": "Update notif", - "x": 970, - "y": 200, + "x": 1030, + "y": 440, "wires": [ [] ] @@ -8872,5 +8874,387 @@ "ce7087fc.dcc9e8" ] ] + }, + { + "id": "b3448fbb.351d28", + "type": "rpi-gpio out", + "z": "1371dec5.76e671", + "name": "Fan", + "pin": "33", + "set": false, + "level": "0", + "freq": "25000", + "out": "pwm", + "x": 1110, + "y": 40, + "wires": [] + }, + { + "id": "f6ff420b.0af648", + "type": "ui_slider", + "z": "bccd1f23.87219", + "name": "focus_speed", + "label": "Focus Speed", + "tooltip": "in µm/sec", + "group": "fbd92986.1028c8", + "order": 5, + "width": 0, + "height": 0, + "passthru": true, + "outs": "end", + "topic": "focus_speed", + "topicType": "str", + "min": "250", + "max": "2500", + "step": "250", + "x": 550, + "y": 460, + "wires": [ + [ + "dc48dc42.98d18" + ] + ] + }, + { + "id": "2d371e59.b0e50a", + "type": "inject", + "z": "bccd1f23.87219", + "name": "Default: 1000µm/s", + "props": [ + { + "p": "payload" + } + ], + "repeat": "", + "crontab": "", + "once": true, + "onceDelay": "0.5", + "topic": "", + "payload": "1000", + "payloadType": "num", + "x": 130, + "y": 460, + "wires": [ + [ + "f6ff420b.0af648" + ] + ] + }, + { + "id": "167cda35.c9b6ae", + "type": "ui_button", + "z": "bccd1f23.87219", + "name": "", + "group": "fbd92986.1028c8", + "order": 1, + "width": 3, + "height": 1, + "passthru": false, + "label": "UP 100um", + "tooltip": "", + "color": "", + "bgcolor": "", + "icon": "fa-angle-up fa-3x", + "payload": "{\"action\":\"move\",\"direction\":\"UP\",\"distance\":0.1}", + "payloadType": "json", + "topic": "actuator/focus", + "topicType": "str", + "x": 350, + "y": 520, + "wires": [ + [ + "62030521.88317c" + ] + ] + }, + { + "id": "72a7c597.9374fc", + "type": "ui_button", + "z": "bccd1f23.87219", + "name": "", + "group": "fbd92986.1028c8", + "order": 6, + "width": 3, + "height": 1, + "passthru": false, + "label": "DOWN 100um", + "tooltip": "", + "color": "", + "bgcolor": "", + "icon": "fa-angle-down fa-3x", + "payload": "{\"action\":\"move\",\"direction\":\"DOWN\",\"distance\":0.1}", + "payloadType": "json", + "topic": "actuator/focus", + "topicType": "str", + "x": 340, + "y": 600, + "wires": [ + [ + "62030521.88317c" + ] + ] + }, + { + "id": "e73fd87d.d24e4", + "type": "function", + "z": "b771c342.49603", + "name": "get acq_minimum_mesh", + "func": "msg.payload = msg.payload.acq_minimum_mesh;\nreturn msg;", + "outputs": 1, + "noerr": 0, + "x": 330, + "y": 360, + "wires": [ + [ + "5517c129.1617e" + ] + ] + }, + { + "id": "489c8e06.cc7d6", + "type": "function", + "z": "b771c342.49603", + "name": "get acq_maximum_mesh", + "func": "msg.payload = msg.payload.acq_maximum_mesh;\nreturn msg;", + "outputs": 1, + "noerr": 0, + "x": 330, + "y": 400, + "wires": [ + [ + "9f3edbe2.43c728" + ] + ] + }, + { + "id": "9f3edbe2.43c728", + "type": "ui_numeric", + "z": "b771c342.49603", + "name": "acq_maximum_mesh", + "label": "Max fraction size (μm)", + "tooltip": "", + "group": "3e1ba03d.f01d8", + "order": 8, + "width": 5, + "height": 1, + "wrap": false, + "passthru": true, + "topic": "acq_maximum_mesh", + "topicType": "str", + "format": "{{value}}", + "min": "200", + "max": "2000", + "step": "100", + "x": 640, + "y": 400, + "wires": [ + [ + "9f501f49.45645" + ] + ] + }, + { + "id": "5517c129.1617e", + "type": "ui_numeric", + "z": "b771c342.49603", + "name": "acq_minimum_mesh", + "label": "Min fraction size (μm)", + "tooltip": "", + "group": "3e1ba03d.f01d8", + "order": 7, + "width": 5, + "height": 1, + "wrap": false, + "passthru": true, + "topic": "acq_minimum_mesh", + "topicType": "str", + "format": "{{value}}", + "min": 0, + "max": "300", + "step": "10", + "x": 640, + "y": 360, + "wires": [ + [ + "9f501f49.45645" + ] + ] + }, + { + "id": "83c5a708.a5715", + "type": "exec", + "z": "9daf9e2b.019fc", + "command": "git --git-dir=/home/pi/PlanktonScope/.git describe --long --tags", + "addpay": false, + "append": "", + "useSpawn": "true", + "timer": "", + "oldrc": false, + "name": "Get git revision", + "x": 640, + "y": 340, + "wires": [ + [ + "af2b8d95.195bb8" + ], + [], + [] + ] + }, + { + "id": "d334d264.8a7728", + "type": "exec", + "z": "9daf9e2b.019fc", + "command": "git --git-dir=/home/pi/PlanktonScope/.git branch --list", + "addpay": false, + "append": "", + "useSpawn": "false", + "timer": "", + "oldrc": false, + "name": "Get git branch", + "x": 640, + "y": 260, + "wires": [ + [ + "e5e8e66c.899588" + ], + [], + [] + ] + }, + { + "id": "e4342b66.72972", + "type": "ui_button", + "z": "9daf9e2b.019fc", + "name": "get git branch", + "group": "1be83144.4fe4bf", + "order": 4, + "width": 4, + "height": 1, + "passthru": false, + "label": "Update branch list", + "tooltip": "", + "color": "", + "bgcolor": "", + "icon": "mi-compare_arrows", + "payload": "", + "payloadType": "str", + "topic": "", + "topicType": "str", + "x": 410, + "y": 260, + "wires": [ + [ + "d334d264.8a7728" + ] + ] + }, + { + "id": "3f13b9f8.bac94e", + "type": "ui_dropdown", + "z": "9daf9e2b.019fc", + "name": "Git branch list", + "label": "Switch branch to", + "tooltip": "", + "place": "branch", + "group": "1be83144.4fe4bf", + "order": 5, + "width": 6, + "height": 1, + "passthru": false, + "multiple": false, + "options": [], + "payload": "", + "topic": "topic", + "topicType": "msg", + "x": 1020, + "y": 260, + "wires": [ + [ + "d037a624.60bea8" + ] + ] + }, + { + "id": "e5e8e66c.899588", + "type": "function", + "z": "9daf9e2b.019fc", + "name": "filter branch", + "func": "msg.options = msg.payload.trimEnd().split('\\n')\nmsg.payload = msg.options.find((str) => str.startsWith('*'));\nreturn msg;", + "outputs": 1, + "noerr": 0, + "initialize": "", + "finalize": "", + "x": 830, + "y": 260, + "wires": [ + [ + "3f13b9f8.bac94e" + ] + ] + }, + { + "id": "c1fb03f7.e675f8", + "type": "inject", + "z": "9daf9e2b.019fc", + "name": "once", + "props": [ + { + "p": "payload" + } + ], + "repeat": "", + "crontab": "", + "once": true, + "onceDelay": "", + "topic": "", + "payload": "start", + "payloadType": "str", + "x": 430, + "y": 300, + "wires": [ + [ + "d334d264.8a7728", + "83c5a708.a5715" + ] + ] + }, + { + "id": "d037a624.60bea8", + "type": "exec", + "z": "9daf9e2b.019fc", + "command": "git --git-dir=/home/pi/PlanktonScope/.git checkout", + "addpay": true, + "append": "", + "useSpawn": "false", + "timer": "", + "oldrc": false, + "name": "git checkout branch", + "x": 1270, + "y": 260, + "wires": [ + [], + [ + "d334d264.8a7728", + "83c5a708.a5715" + ], + [] + ] + }, + { + "id": "af2b8d95.195bb8", + "type": "ui_text", + "z": "9daf9e2b.019fc", + "group": "1be83144.4fe4bf", + "order": 2, + "width": 12, + "height": 1, + "name": "", + "label": "Current code version", + "format": "{{msg.payload}}", + "layout": "row-center", + "x": 1040, + "y": 340, + "wires": [] } ] \ No newline at end of file