[{"id":"620f988d.f18b48","type":"mqtt in","z":"34b05225.5f8aee","name":"","topic":"robot/ultrasonic","qos":"2","broker":"c6e3938e.73397","x":120,"y":600,"wires":[["4b732d29.b9c104","eec6bd01.4e8cb"]]},{"id":"4b732d29.b9c104","type":"switch","z":"34b05225.5f8aee","name":"dist < 10","property":"payload","propertyType":"msg","rules":[{"t":"lt","v":"10","vt":"num"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":320,"y":600,"wires":[["8346ddf8.af68c"],["8ef5f5ac.978238"]]},{"id":"4c855c07.fa7964","type":"mqtt out","z":"34b05225.5f8aee","name":"","topic":"","qos":"","retain":"","broker":"c6e3938e.73397","x":950,"y":580,"wires":[]},{"id":"8346ddf8.af68c","type":"change","z":"34b05225.5f8aee","name":"Yes:Stop Motor","rules":[{"t":"set","p":"payload","pt":"msg","to":"stop","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"robot/stop","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":520,"y":520,"wires":[["4c855c07.fa7964","50a7e425.cd944c"]]},{"id":"8ef5f5ac.978238","type":"change","z":"34b05225.5f8aee","name":"No:Forward 20","rules":[{"t":"set","p":"payload","pt":"msg","to":"20","tot":"num"},{"t":"set","p":"topic","pt":"msg","to":"robot/forward","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":520,"y":660,"wires":[["4c855c07.fa7964","50a7e425.cd944c"]]},{"id":"50a7e425.cd944c","type":"debug","z":"34b05225.5f8aee","name":"Status","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","x":690,"y":580,"wires":[]},{"id":"eec6bd01.4e8cb","type":"debug","z":"34b05225.5f8aee","name":"Distance","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","x":320,"y":540,"wires":[]},{"id":"c6e3938e.73397","type":"mqtt-broker","z":"","name":"Win8","broker":"192.168.0.23","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","willTopic":"","willQos":"0","willPayload":""}]
The flow is just a simple demo showing how it can interact with the python prog running on the Pi
This sort of setup is not really needed on a Pi as it has enough power and memory and access and many libraries but I'm using it to find out what I need
I'm hoping I can fit at least an ultrasonic sensor and 2 line followers on an ESP8266 based bot
Going to start off using continuous servos as I have a pair lying around and can plug them direct into controller without needing H-Bridge