# Serial Request echo's input message

**URL:** <https://discourse.nodered.org/t/serial-request-echos-input-message/60715>\
**Category:** General\
**Created:** [3 April 2022 11:35 UTC](https://discourse.nodered.org/t/serial-request-echos-input-message/60715 "2022-04-03T11:35:10Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![ebrady](https://avatars.discourse-cdn.com/v4/letter/e/5f8ce5/32.png) [@ebrady](https://discourse.nodered.org/u/ebrady)\
**Post date:** [3 April 2022 11:35 UTC](https://discourse.nodered.org/t/serial-request-echos-input-message/60715/1 "2022-04-03T11:35:11Z")

</div>

I am trying to Solve a problem with the Serial Request Node. I am using a Raspberry PI, with a USB Serial converter to send data to an ICOM radio. I am not sure what other information would be helpful with understanding the setup but am happy to provide.

When using bash command line, I can manually form up packets to send to the radio and see the proper response. Also, when the same USB to serial converter is connected to Windows, I can also manually form the packet in Realterm, and see the response.

However, when I use the Serial Request object in NR on the Pi, the node will always return the sent packet as the output message. To investigate, I removed the Serial Request Node and replaced it with individual Serial In and Serial out nodes.

After doing this, I noticed the Serial In node would always send two messages. The first message would be a duplicate of the data sent via Serial Out , and the second would be the actual data that was sent received from the radio.

I have attached a copy of my serial setup.

 ![SerialSetup](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/2/6/2606ea27f5fc6640dcd7339a26b9918c4a1bc090.jpeg)

Any help appreciated..

Ed

---

<div class="post-metadata">

**Author:** ![hardillb](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hardillb/32/12373_2.png) [@hardillb](https://discourse.nodered.org/u/hardillb)\
**Post date:** [3 April 2022 14:48 UTC](https://discourse.nodered.org/t/serial-request-echos-input-message/60715/2 "2022-04-03T14:48:56Z")

</div>

I'm 90% sure this will be the device echoing the input back, not node-red

---

<div class="post-metadata">

**Author:** ![ghayne](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/ghayne/32/39_2.png) [@ghayne](https://discourse.nodered.org/u/ghayne)\
**Post date:** [3 April 2022 15:20 UTC](https://discourse.nodered.org/t/serial-request-echos-input-message/60715/3 "2022-04-03T15:20:57Z")

</div>

Agree with @hardillb, look in the manual for the radio for "echo" and if you can turn it off.

---

<div class="post-metadata">

**Author:** ![ebrady](https://avatars.discourse-cdn.com/v4/letter/e/5f8ce5/32.png) [@ebrady](https://discourse.nodered.org/u/ebrady)\
**Post date:** [3 April 2022 19:03 UTC](https://discourse.nodered.org/t/serial-request-echos-input-message/60715/4 "2022-04-03T19:03:16Z")

</div>

Thanks for the replies..

At first, I thought it was radio echoing it back also.  
I moved the dongle over to Windows and launched a terminal program, Realterm, which allowed me to manually form up the packet and send it. I monitored the radio's reply there was no Echo.

I then thought that it might be something weird with the Raspberry Pi drivers, so I created a binary file with the packet contents and sent it to the port via cat, I monitored the return data also, no echo.

It almost feels like the Dongle may be buffering the packet, and due to the system timing of when the Request node switches from transmit to receive, it is actually ends up reading the packet that is buffered in the dongle and thinking it is the reply.

For the time being, I have implemented a less than desirable hack where I use Serial In and Serial out nodes, and then filter out the echo the transmitted packet, and then operate on the second message received. This keeps things going for now, but I would much rather use the Serial Request node instead.

---

<div class="post-metadata">

**Author:** ![ghayne](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/ghayne/32/39_2.png) [@ghayne](https://discourse.nodered.org/u/ghayne)\
**Post date:** [3 April 2022 19:28 UTC](https://discourse.nodered.org/t/serial-request-echos-input-message/60715/5 "2022-04-03T19:28:55Z")

</div>

> [@ebrady](#):
>
> For the time being, I have implemented a less than desirable hack where I use Serial In and Serial out nodes

This is not a hack, it is a perfectly normal way of communicating over serial ports.  
Node-red allows you to manipulate and filter messages, so that it should not be a real problem to filter out the echo message at all.

---

<div class="post-metadata">

**Author:** ![ebrady](https://avatars.discourse-cdn.com/v4/letter/e/5f8ce5/32.png) [@ebrady](https://discourse.nodered.org/u/ebrady)\
**Post date:** [3 April 2022 23:11 UTC](https://discourse.nodered.org/t/serial-request-echos-input-message/60715/6 "2022-04-03T23:11:53Z")

</div>

> [@ghayne](#):
>
> This is not a hack, it is a perfectly normal way of communicating over serial ports.  
> Node-red allows you to manipulate and filter messages, so that it should not be a real problem to filter out the echo message at all.

Well, yes it works, the problem is I loose the nice 1 to 1 "Request/Response" behavior offered by the Serial Request node. It is possible to do it with Serial In/Out, but requires additional timeout and blocking logic which will need to be implemented to achieve the same function.

All do-able, but it is a lot of programming just to work around and mask the root cause of the problem.

Ed

---

<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:** [3 April 2022 23:19 UTC](https://discourse.nodered.org/t/serial-request-echos-input-message/60715/7 "2022-04-03T23:19:52Z")

</div>

Indeed the request node shouldnt echo the input back. Please raise an issue on github node-red-nodes project with as much info as you have so we can investigate.

---

<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:** [2 June 2022 23:20 UTC](https://discourse.nodered.org/t/serial-request-echos-input-message/60715/8 "2022-06-02T23:20:29Z")

</div>

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