If you are simply wanting to extract data from a buffer, then the buffer-parser node is designed to do this the "no-code" way...
[{"id":"9b8474f8aa18762a","type":"buffer-parser","z":"4c5ad8c7caa80822","name":"","data":"payload","dataType":"msg","specification":"spec","specificationType":"ui","items":[{"type":"bool","name":"zone19open","offset":4,"length":1,"offsetbit":2,"scale":"1","mask":""},{"type":"bool","name":"zone20open","offset":4,"length":1,"offsetbit":3,"scale":"1","mask":""}],"swap1":"","swap2":"","swap3":"","swap1Type":"swap","swap2Type":"swap","swap3Type":"swap","msgProperty":"payload","msgPropertyType":"str","resultType":"keyvalue","resultTypeType":"return","multipleResult":false,"fanOutMultipleResult":false,"setTopic":true,"outputs":1,"x":2150,"y":860,"wires":[["f39a39559f771680"]]},{"id":"e403c7115f8776c7","type":"inject","z":"4c5ad8c7caa80822","name":"simulating your data","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"[\"0x37\",\"0x39\",\"0x0\",\"0x0\",\"0x4\"]","payloadType":"bin","x":1950,"y":860,"wires":[["9b8474f8aa18762a"]]},{"id":"f39a39559f771680","type":"debug","z":"4c5ad8c7caa80822","name":"debug 94","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":2310,"y":860,"wires":[]},{"id":"83d494286ca2baa4","type":"inject","z":"4c5ad8c7caa80822","name":"simulating your data","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"[\"0x37\",\"0x39\",\"0x0\",\"0x0\",\"0x8\"]","payloadType":"bin","x":1950,"y":920,"wires":[["9b8474f8aa18762a"]]}]