Hi,
If I am right you are sending serial ModBus data to the TCP link and you don't handle the received data correctly.
You also are using the wrong port. Default port 502 is used for ModBus TCP.
Here is an example how it could be done. Data in is the loopback command.
Data out is the TCP data without the slave address and CRC of the serial data
Kees