Hi,
can someone please help me with rs232 communication?
Have a scale that has an RS232 interface.
Unfortunately I have no idea how I can accomplish the commands I send and receive values.
[{"id":"f0190195.7939f8","type":"serial in","z":"5b6e97cb.a67bf8","name":"","serial":"d606e68c.2e18b","x":140,"y":400,"wires":[["9a100448.11dc5"]]},{"id":"9a100448.11dc5","type":"debug","z":"5b6e97cb.a67bf8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":400,"y":400,"wires":[]},{"id":"b7af98bb.68b3d","type":"serial out","z":"5b6e97cb.a67bf8","name":"test","serial":"d606e68c.2e18b","x":610,"y":400,"wires":[]},{"id":"df93de13.b2485","type":"inject","z":"5b6e97cb.a67bf8","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":120,"y":540,"wires":[["74b1d48d.bc7c04"]]},{"id":"74b1d48d.bc7c04","type":"function","z":"5b6e97cb.a67bf8","name":"","func":"msg.payload = new Buffer\n([0x02+A+0x03]);\nreturn msg;\n\n","outputs":1,"noerr":0,"x":370,"y":560,"wires":[["8d036d47.a8cc2"]]},{"id":"8d036d47.a8cc2","type":"debug","z":"5b6e97cb.a67bf8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":620,"y":620,"wires":[]},{"id":"d606e68c.2e18b","type":"serial-port","z":"","serialport":"/dev/ttyAMA0","serialbaud":"2400","databits":"8","parity":"none","stopbits":"1","waitfor":"","newline":"","bin":"bin","out":"char","addchar":"false","responsetimeout":""}]
these are the commands:
5: Command mode, output on request
Request gross weight Command: HEX (02) + “A“ + “HEX (03), Answer: GW: 0023.45 (kg)
Request net weight Command HEX (02) + “B“ + “HEX (03): Answer: NW: 0013.45 (kg)
Request tare weight Command HEX (02) + “C“ + “HEX (03): Answer: TW: 0010.00 (kg)
Trigger zero position Command HEX (02) + “D“ + “HEX (03): Answer: D
Trigger tare function Command HEX (02) + “E“ + “HEX (03): Answer: E
Pleas Pleas.
THX
Mike