How get a complete bool values from DB with Double Words?

Dear colleagues,

I a have a DB with alarms that looks something more or less like this :

Imagine that would like to get the values until the direction 99.7 . Of course, introduce one to one the dbx directions in the contrib.s7 node is a tedious task... so:
There is a methor to extract with node red the complete values of the complete db and then split it?
I was thinking in use DBD instead of each DBX but I dont know how can I get the values of the bit once I have the DBD value...

Any ideas about this?
Many thanks!!

You can use buffer-parser node to get all your bools in one go. An additional bonus side-effect is reading 1 numeric is much faster and efficient than reading multiple bools.

[{"id":"30f0e139.daa44e","type":"buffer-parser","z":"766a1068.58afb","name":"","data":"payload","dataType":"msg","specification":"spec","specificationType":"ui","items":[{"type":"16bitbe","name":"bits","offset":0,"length":2,"offsetbit":0,"scale":"1","mask":""},{"type":"bool","name":"bools","offset":0,"length":32,"offsetbit":0,"scale":"1","mask":""},{"type":"bool","name":"bit0","offset":0,"length":0,"offsetbit":0,"scale":"1","mask":""},{"type":"bool","name":"bit1","offset":0,"length":1,"offsetbit":1,"scale":"1","mask":""},{"type":"bool","name":"bit2","offset":0,"length":1,"offsetbit":2,"scale":"1","mask":""}],"swap1":"","swap2":"","swap3":"","swap1Type":"swap","swap2Type":"swap","swap3Type":"swap","msgProperty":"payload","msgPropertyType":"str","resultType":"keyvalue","resultTypeType":"output","multipleResult":false,"fanOutMultipleResult":false,"setTopic":true,"outputs":1,"x":1690,"y":100,"wires":[["84033c6c.93fad"]]},{"id":"90adea38.cc6ff8","type":"inject","z":"766a1068.58afb","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":1680,"y":60,"wires":[["c6e5e1f1.c7876"]]},{"id":"c6e5e1f1.c7876","type":"function","z":"766a1068.58afb","name":"fake PLC data","func":"msg.payload = Buffer.from([\n    0xf0, 0x0f, 0x99, 0x66\n])\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":1840,"y":60,"wires":[["30f0e139.daa44e"]]},{"id":"84033c6c.93fad","type":"debug","z":"766a1068.58afb","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1870,"y":100,"wires":[]}]

The Buffer parser accepts either a 16bit integer array or byte buffer as input.

I going to test today, I will give you my feedback.
Many Thanks!!

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.