Author Topic: MBTCP Time-out was 0 , what does it do  (Read 524 times)

graham.burgess@stfc.ac.uk

  • Newbie
  • *
  • Posts: 2
    • View Profile
MBTCP Time-out was 0 , what does it do
« on: November 14, 2022, 10:06:53 AM »
I have an HMI connected to a FX1616-Ba  using modbus over ethernet, I am also trying to add an extra serial port by doing a TCPconnect to a moxa 5230, when I connect (tcpconnect) to the moxa, the hmi complains about a lack of connection. increasing this value from 0 to 2 improves it greatly but not eliminates the problem. what happens if I take this value even higher?
many thanks
Graham
 

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3151
    • View Profile
    • Internet Programmable PLCs
Re: MBTCP Time-out was 0 , what does it do
« Reply #1 on: November 15, 2022, 06:50:13 PM »
If the MBTCP time-out is set to zero then the firmware will automatically adjust the MBTCP server time-out to 20 seconds.

Note that this time-out is for the PLC acting as slave (Server) to an external Modbus TCP master (client). 

Did you try to run "PRINT #4 "<TCPCONNECT xxxx>"? Note that TCPCONNECT is for the PLC to act as a client to access an external TCP server. It is not to be used to configure the PLC as a Modbus TCP server.

I checked the Moxa 5230 - it appears to be a MODBUS TCP-to-MODBUS RTU gateway converter? If you want to access the serial port on the Fx1616-BA PLC from an external Mobdus TCP master then MOXA 5230 can be used but you must configure the serial port on the MOXA to be compatible to that on the PLC. I don't understand why do you want to do that since you can already directly access the PLC via its Ethernet port...
Email: support@triplc.com
Tel: 1-877-TRI-PLCS

graham.burgess@stfc.ac.uk

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: MBTCP Time-out was 0 , what does it do
« Reply #2 on: December 01, 2022, 07:28:22 AM »
I am trying to add an extra serial port to the PLC, (1 x RS232 and 2 x RS485 is not enough!!!!) this is what the Moxa 5230 is for.
I also have a Weintek MT8071iE HMI that uses modbus on the ethernet to connect to the PLC.
The PLC HMI link works fine until I try to connect from PLC to Moxa, it appears to connected but upsets the HMI PLC link, hence the original question about the timer.
Moxa is server, PLC is client and will execute a <TCPCONNECT 192.....>
which appears to work but, after about 30 minutes, it varies quite a bit, the PLC Moxa link fails without indication.
I am trying to look at messages but not getting very far, my scope is meant to decode but does not.
Update December 2022
The HMI has 1 x RS232 and 2 X RS485 which I am trying to use instead of the moxa as this link is normally very good, especially where the moxa is not connected.
The HMI serial port idea is progressing but it has it's own issues, should this method fall apart I might have to try the moxa idea again.
any thoughts on what is happening?
Cheers





support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3151
    • View Profile
    • Internet Programmable PLCs
Re: MBTCP Time-out was 0 , what does it do
« Reply #3 on: December 02, 2022, 05:45:01 AM »
I assume you have an Ethernet switch that provides Ethernet port connection to the Fx1616-BA, the Weintek HMI and the MOXA?

The HMI connect to the PLC using Modbus TCP protocol and that part is working fine according to your experience.

The PLC connects to the MOXA using <TCPCONNECT....> command. I assume once connected MOXA works transparently and will transfer data from the PLC to its serial port and vice versa.

1) Does the PLC use this connection regularly?
2) Does the PLC close the TCP connection after transferring data with external serial port or does it keep it open?
3) Does MOXA has a timeout for this connection if it is idle? 
4) Did you define the client connection time-out value on the PLC?

What version is your PLC's firmware? if it is an older firmware (current release is F91.8) you can try to upgrade the firmware to see if it makes a difference. Contact support@triplc.com for upgrade instructions if you don't have it.




Email: support@triplc.com
Tel: 1-877-TRI-PLCS