Sorry to open this old, old topic. I'm having trouble with this myself, and I've spent a couple days trying to figure it out.
Problem: I have a memory address in an I2C device that gives device status:
I can poll that address, receive an integer back, separate it into the corresponding bits. But I can't figure out how to output the 6 messages declaring the status (true or false, 1 or 0 doesn't matter) to make decisions... can someone help me?
[{"id":"7e15029f.3ab42c","type":"tab","label":"Flow 3","disabled":false,"info":""},{"id":"8ae6db2.b5ec028","type":"i2c in","z":"7e15029f.3ab42c","name":"Lidar Status","busno":"1","address":"98","command":"1","count":"1","x":270,"y":140,"wires":[["56596c42.6e16f4","bfd11c29.08915"]]},{"id":"56596c42.6e16f4","type":"debug","z":"7e15029f.3ab42c","name":"","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":790,"y":140,"wires":[]},{"id":"bfd11c29.08915","type":"bitunloader","z":"7e15029f.3ab42c","name":"System Status","mode":"arrayBits","prop":"payload","padding":"8","x":460,"y":200,"wires":[["ac461ea.cc313e","32454ad1.b50786"]]},{"id":"ac461ea.cc313e","type":"debug","z":"7e15029f.3ab42c","name":"","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":790,"y":200,"wires":[]},{"id":"d7b05339.a4322","type":"debug","z":"7e15029f.3ab42c","name":"","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":990,"y":260,"wires":[]},{"id":"f19a1ef1.d72a9","type":"inject","z":"7e15029f.3ab42c","name":"","props":[{"p":"payload"},{"p":"topic","v":"topic","vt":"flow"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":100,"y":140,"wires":[["8ae6db2.b5ec028"]]},{"id":"32454ad1.b50786","type":"switch","z":"7e15029f.3ab42c","name":"Separate Statuses","property":"key","propertyType":"msg","rules":[{"t":"eq","v":"0","vt":"num"},{"t":"eq","v":"1","vt":"num"},{"t":"eq","v":"2","vt":"num"},{"t":"eq","v":"3","vt":"num"},{"t":"eq","v":"4","vt":"num"},{"t":"eq","v":"5","vt":"num"}],"checkall":"true","repair":true,"outputs":6,"x":550,"y":380,"wires":[["caabc82a.02f858"],["1e180185.c5efde"],["6aa8bd5d.9fa4c4"],["d292ce2.ed51f3"],["177c92c8.80ac1d"],["49917ca8.400dd4"]]},{"id":"1e180185.c5efde","type":"debug","z":"7e15029f.3ab42c","name":"","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":990,"y":320,"wires":[]},{"id":"6aa8bd5d.9fa4c4","type":"debug","z":"7e15029f.3ab42c","name":"","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":990,"y":380,"wires":[]},{"id":"177c92c8.80ac1d","type":"debug","z":"7e15029f.3ab42c","name":"","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":990,"y":500,"wires":[]},{"id":"d292ce2.ed51f3","type":"debug","z":"7e15029f.3ab42c","name":"","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":990,"y":440,"wires":[]},{"id":"49917ca8.400dd4","type":"debug","z":"7e15029f.3ab42c","name":"","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":990,"y":560,"wires":[]},{"id":"caabc82a.02f858","type":"change","z":"7e15029f.3ab42c","name":"Set","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.value","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":790,"y":260,"wires":[["d7b05339.a4322"]]}]
Before saying read this, read that, I've read and re-read it. I learn from seeing an example. I can understand and scale from there.
Please help me!
Thanking you in advance!