Author Topic: full duplex serial com  (Read 12781 times)

kenobe

  • Jr. Member
  • Posts: 66
  • I'm a llama!
    • View Profile
full duplex serial com
« on: June 25, 2009, 01:05:34 AM »
Hi
I am using a T100MD 888 plc
Can this PLC run serial communication in full duplex mode?
I try connect the PLC with a windows xp running vb.net 2008 and found that this can not be done. ( the system hang!)
I can do it in half duplex mode , no problem.
any tips?
Thanks

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3174
    • View Profile
    • Internet Programmable PLCs
Re:full duplex serial com
« Reply #1 on: June 26, 2009, 04:20:36 AM »
The T100MD888+ has two serial ports. The COMM1 RS232 port is full duplex whereas the COMM3 RS485 port is half-duplex.

However, all the PLC communication protocols supported are essentially half duplex since they all depend on the master sending the completed command to it and it will then process the command and send back the response string. However, if the master were to send the second command string to the PLC's RS232 port before the PLC completed sending the response string to the first command, then the incoming characters will be queued in the PLC's serial receive buffer up to 256 characters.
Email: support@triplc.com
Tel: 1-877-TRI-PLCS

kenobe

  • Jr. Member
  • Posts: 66
  • I'm a llama!
    • View Profile
Re:full duplex serial com
« Reply #2 on: June 26, 2009, 06:25:58 PM »
Hi
thanks for your reply.
I use the print #1 PLC command to send the data in the DM back to the host computer at every scan time ( PLC scan time ) and at the same time, I use the hostlink command to control the output port eg:
"send Ctrl_e, wait for reply and send WO0055*"
sometimes I miss the input data partially or completely and sometimes I got no control of the PLC output and sometimes the system hangs. best of all , I got the input data and control the output successfully.
The result seems to be intermittent and not smooth. Should I slow down the PLC sending frequency? how much?
Any example I can refer to?

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3174
    • View Profile
    • Internet Programmable PLCs
Re:full duplex serial com
« Reply #3 on: June 26, 2009, 09:43:41 PM »
It is likely an issue of timing when you send the Ctrl-E, receive reply and then sending the command string. We recommend that you implement the multi-point protocol which only involve sending a single command string including ID and FCS and receiving a complete response string in a single cycle.

There are example communication programs written in Visual Basic 6 and Visual Basic Express demo that you can download from the following webpage:

http://www.tri-plc.com/applications/VBsample.htm

The supplied functions automaticallly handles both point-to-point and multi-point protocol and computes the FCS for you. So you can easily implement the communication program without worrying about handling the handshaking timings between the PC and the PLC.
Email: support@triplc.com
Tel: 1-877-TRI-PLCS

kenobe

  • Jr. Member
  • Posts: 66
  • I'm a llama!
    • View Profile
Re:full duplex serial com
« Reply #4 on: June 28, 2009, 04:27:12 AM »
Hi
thank you very much for your enlightenment.
I am trying it  now.