st-one-io / node-red-contrib-pccc

A Node-RED node to interact with some Allen-Bradley PLCs using PCCC protocol
GNU General Public License v3.0
8 stars 2 forks source link

Allen Bradley PowerFlex750 Drive #3

Closed JorgeAlberto91MS closed 7 months ago

JorgeAlberto91MS commented 4 years ago

Hi,

I'm working with the "pccc-node" using a PowerFlex 755 Drive.

Reading all parameters are just fine, when I write to the timeout parameter (N42:3) it's working well but if I try to write to N45:X the "pccc out" node is sending the "bad values" error message, also if I try to set N150:X or N201:X the node status show "failure".

Does anyone know if the data must be in a specific format or there is a configuration on the VSD that must set for allowing the data to be written?

JorgeAlberto91MS commented 4 years ago

This is the Node-Red Flow when I'm trying to write N45:4-5 parameters on VSD [{"id":"33e9b553.7e386a","type":"group","z":"332d1a8b.fa2e76","style":{"stroke":"#999999","stroke-opacity":"1","fill":"none","fill-opacity":"1","label":true,"label-position":"nw","color":"#a4a4a4"},"nodes":["a7a7c431.39f448","46d2c28b.13288c","d0d0823c.c889f","d7d30f6f.795d1","c1caf04d.fda86","d1af532e.cd9"],"x":344,"y":259,"w":522,"h":192},{"id":"a7a7c431.39f448","type":"pccc out","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","endpoint":"6a7a7415.784b3c","variable":"Time Out","name":"Write VFD","x":750,"y":300,"wires":[]},{"id":"46d2c28b.13288c","type":"pccc out","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","endpoint":"6a7a7415.784b3c","variable":"DL To Net MS","name":"DL to Net MS","x":760,"y":360,"wires":[]},{"id":"d0d0823c.c889f","type":"function","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","name":"","func":"var msg1 = {payload:parseInt(450)};\nvar msg2 = {payload:parseInt(0)};\n\nreturn [msg1, msg2];","outputs":2,"noerr":0,"initialize":"","finalize":"","x":570,"y":390,"wires":[["d1af532e.cd9"],["46d2c28b.13288c"]]},{"id":"d7d30f6f.795d1","type":"inject","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":450,"y":390,"wires":[["d0d0823c.c889f"]]},{"id":"c1caf04d.fda86","type":"inject","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"5","payloadType":"str","x":580,"y":300,"wires":[["a7a7c431.39f448"]]},{"id":"d1af532e.cd9","type":"pccc out","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","endpoint":"6a7a7415.784b3c","variable":"DL To Net LS","name":"DL to Net LS","x":750,"y":410,"wires":[]},{"id":"6a7a7415.784b3c","type":"pccc endpoint","z":"","address":"192.168.2.10","port":"44818","userouting":false,"routing":"0x01,0x00,0x01,0x00","cycletime":"2000","timeout":"10000","name":"","vartable":[{"addr":"N42:3","name":"Time Out"},{"addr":"N45:4","name":"DL To Net LS"},{"addr":"N45:5","name":"DL To Net MS"}]}]

JorgeAlberto91MS commented 4 years ago

This is the Node-Red flow when I set the parameter N150:2 [{"id":"33e9b553.7e386a","type":"group","z":"332d1a8b.fa2e76","style":{"stroke":"#999999","stroke-opacity":"1","fill":"none","fill-opacity":"1","label":true,"label-position":"nw","color":"#a4a4a4"},"nodes":["a7a7c431.39f448","46d2c28b.13288c","d0d0823c.c889f","d7d30f6f.795d1","c1caf04d.fda86","d1af532e.cd9"],"x":344,"y":259,"w":522,"h":192},{"id":"a7a7c431.39f448","type":"pccc out","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","endpoint":"6a7a7415.784b3c","variable":"Time Out","name":"Write VFD","x":750,"y":300,"wires":[]},{"id":"46d2c28b.13288c","type":"pccc out","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","endpoint":"6a7a7415.784b3c","variable":"DL To Net MS","name":"DL to Net MS","x":760,"y":360,"wires":[]},{"id":"d0d0823c.c889f","type":"function","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","name":"","func":"var msg1 = {payload:parseInt(450)};\nvar msg2 = {payload:parseInt(0)};\n\nreturn [msg1, msg2];","outputs":2,"noerr":0,"initialize":"","finalize":"","x":570,"y":390,"wires":[["d1af532e.cd9"],["46d2c28b.13288c"]]},{"id":"d7d30f6f.795d1","type":"inject","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":450,"y":390,"wires":[["d0d0823c.c889f"]]},{"id":"c1caf04d.fda86","type":"inject","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"5","payloadType":"str","x":580,"y":300,"wires":[["a7a7c431.39f448"]]},{"id":"d1af532e.cd9","type":"pccc out","z":"332d1a8b.fa2e76","g":"33e9b553.7e386a","endpoint":"6a7a7415.784b3c","variable":"DL To Net LS","name":"DL to Net LS","x":750,"y":410,"wires":[]},{"id":"6a7a7415.784b3c","type":"pccc endpoint","z":"","address":"192.168.2.10","port":"44818","userouting":false,"routing":"0x01,0x00,0x01,0x00","cycletime":"2000","timeout":"10000","name":"","vartable":[{"addr":"N42:3","name":"Time Out"},{"addr":"N45:4","name":"DL To Net LS"},{"addr":"N45:5","name":"DL To Net MS"},{"addr":"N150:2","name":"Drive Parameter 1"}]}]