# Sending Commands via TCP into OMRON Code Reader F430

**URL:** <https://discourse.nodered.org/t/sending-commands-via-tcp-into-omron-code-reader-f430/67048>\
**Category:** General\
**Created:** [29 August 2022 01:53 UTC](https://discourse.nodered.org/t/sending-commands-via-tcp-into-omron-code-reader-f430/67048 "2022-08-29T01:53:53Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![giller\_m](https://avatars.discourse-cdn.com/v4/letter/g/f0a364/32.png) [@giller\_m](https://discourse.nodered.org/u/giller_m)\
**Post date:** [29 August 2022 01:53 UTC](https://discourse.nodered.org/t/sending-commands-via-tcp-into-omron-code-reader-f430/67048/1 "2022-08-29T01:53:53Z")

</div>

Hi!

Good day everyone.

Sorry I am so new in using Node-RED this is because one of my client is using Node-REd ever since but unfortunately we have challenges on sending commands into Code Reader Device (specifically OMRON F430 Series) via TCP connection.

for reference this will be the commands I am trying to send:

JOBLOAD  
Loads a job from slot n or from memory.

Command Format  
JOBLOAD -slot=SettingValue -r  
or  
JOBLOAD -mem -r  
• Specify -slot or -mem.  
• Insert a space between the command and the parameters.  
• Insert a space between each parameter.  
• Add a delimiter to the end of the command or parameter.  
• No space is required between the parameter and the delimiter.

[https://www.fa.omron.com.cn/data\_pdf/mnu/z444-e-02\_f430-f\_f420-f.pdf?id=3789](https://www.fa.omron.com.cn/data_pdf/mnu/z444-e-02_f430-f_f420-f.pdf?id=3789)

Almost all of the commands did not work for me except the TRIGGER Command.  
This trigger command send a trigger to the F430 for sensor capture.

 ![MicrosoftTeams-image (37)](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/d/d/ddbd8d8a9ffb570755d52f3092ec3c5b8dd2a13e.png)

All of the commands already tested via hyper terminal and it all works fine.

I am now thinking what was missing on my sample nodes.

Hope somebody can help me. Thanks in advance!

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [29 August 2022 07:56 UTC](https://discourse.nodered.org/t/sending-commands-via-tcp-into-omron-code-reader-f430/67048/2 "2022-08-29T07:56:29Z")

</div>

Do you maybe need to add a `\n` or `\r` character to the end of the command as an [enter] to get it to send correctly ?

---

<div class="post-metadata">

**Author:** ![MountainKing91](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/mountainking91/32/59516_2.png) [@MountainKing91](https://discourse.nodered.org/u/MountainKing91)\
**Post date:** [29 August 2022 10:32 UTC](https://discourse.nodered.org/t/sending-commands-via-tcp-into-omron-code-reader-f430/67048/3 "2022-08-29T10:32:12Z")

</div>

Hi,  
I actually have the sensor so I made a few tries. This is working for me.

Let me know.

```auto
[{"id":"c23e4166ed60556b","type":"tab","label":"Omron F430","disabled":false,"info":"","env":[]},{"id":"eaed6e0511b67869","type":"inject","z":"c23e4166ed60556b","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"TRIGGER","payloadType":"str","x":180,"y":100,"wires":[["1c97fb190c520922"]]},{"id":"e78e12eef0218cbb","type":"tcp request","z":"c23e4166ed60556b","name":"","server":"192.168.188.2","port":"49211","out":"char","ret":"buffer","splitc":"\\n","newline":"","tls":"","x":450,"y":420,"wires":[["cbcd6232ba6c1d8e"]]},{"id":"cbcd6232ba6c1d8e","type":"debug","z":"c23e4166ed60556b","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":650,"y":420,"wires":[]},{"id":"664052bda1eb13b8","type":"inject","z":"c23e4166ed60556b","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"INFO","payloadType":"str","x":170,"y":140,"wires":[["1c97fb190c520922"]]},{"id":"5fb1c2343cf11a90","type":"function","z":"c23e4166ed60556b","name":"append CR","func":"msg.payload = msg.payload + \"\\r\";\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":250,"y":420,"wires":[["e78e12eef0218cbb"]]},{"id":"4d05e86baa9c803d","type":"link in","z":"c23e4166ed60556b","name":"","links":["1c97fb190c520922"],"x":125,"y":420,"wires":[["5fb1c2343cf11a90"]]},{"id":"1c97fb190c520922","type":"link out","z":"c23e4166ed60556b","name":"","mode":"link","links":["4d05e86baa9c803d"],"x":445,"y":200,"wires":[]},{"id":"d8b0151144f8aaef","type":"inject","z":"c23e4166ed60556b","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"HELP","payloadType":"str","x":170,"y":180,"wires":[["1c97fb190c520922"]]},{"id":"3fb6b1bcacfb53b0","type":"inject","z":"c23e4166ed60556b","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"ONLINE","payloadType":"str","x":180,"y":220,"wires":[["1c97fb190c520922"]]},{"id":"198be708d88c6781","type":"inject","z":"c23e4166ed60556b","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"OFFLINE","payloadType":"str","x":180,"y":260,"wires":[["1c97fb190c520922"]]},{"id":"eeb99f159ffa292d","type":"inject","z":"c23e4166ed60556b","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"MEMINFO","payloadType":"str","x":180,"y":300,"wires":[["1c97fb190c520922"]]}]

```

---

<div class="post-metadata">

**Author:** ![giller\_m](https://avatars.discourse-cdn.com/v4/letter/g/f0a364/32.png) [@giller\_m](https://discourse.nodered.org/u/giller_m)\
**Post date:** [30 August 2022 01:08 UTC](https://discourse.nodered.org/t/sending-commands-via-tcp-into-omron-code-reader-f430/67048/4 "2022-08-30T01:08:17Z")

</div>

Thank you! It works for me too.  
This will help me a lot.

I will try now the other commands. Thanks again.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [13 September 2022 01:09 UTC](https://discourse.nodered.org/t/sending-commands-via-tcp-into-omron-code-reader-f430/67048/5 "2022-09-13T01:09:01Z")

</div>

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