Author Topic: T100MD888 as protocol converter  (Read 13124 times)

zif011

  • Guest
T100MD888 as protocol converter
« on: May 04, 2004, 06:07:48 AM »
Hi All,

I would like to connect RS232 port of T100MD888 to Channel 0 on AB PLC 5/03 (custom serial ASCII protocol) and configure T100MD888's RS485 port as Modbus master for three GE Fanuc's Quick Panel jr. configured as Modbus slaves. I would use built-in Basic on T100MD888 to pass data between two T100MD888's ports.

Is it possible?

Thanks.

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3174
    • View Profile
    • Internet Programmable PLCs
Re:T100MD888 as protocol converter
« Reply #1 on: May 04, 2004, 02:33:19 PM »
Technically this is feasible.  However, it depends mainly on how complex is the AB PLC 5/03 protocol? If it involves only CR  or CR-LF terminated ASCII strings then the TBASIC INPUT$ and PRINT command can be used to talk to the AB PLC 5/03 easily. i.e you write a TBASIC program to handle the custom protocol of AB 5/03.

If it involves binary data transfer with 16-bit CRC computation for error checking the TBASIC can still handle it with it new CRC16 function. But if it involves very complex error correction checksum computation then the routine may be too complex to be handled easily by TBASIC.

The PLC can easily serve as the MODBUS master to talk to the Quick Panel Jr using MODBUS based on the change of data it receive from the AB PLC 5/03.
Email: support@triplc.com
Tel: 1-877-TRI-PLCS

zif011

  • Guest
Re:T100MD888 as protocol converter
« Reply #2 on: May 07, 2004, 07:00:36 AM »
Since I will be using both serial ports, how can I connect my PC and program/monitor PLC at the same time as the protocol conversion is taking place (custom serial ASCII from RS232 to MODBUS slaves on RS485)?

Thanks.

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3174
    • View Profile
    • Internet Programmable PLCs
Re:T100MD888 as protocol converter
« Reply #3 on: May 07, 2004, 09:28:28 AM »
That is a bit tricky. I would recommend that you test one part of the software separately at a time. ie. Use RS485 for monitoring/programming while testing the serial comm routine for RS232 port, and vice versa.

You should build into your software a way for you to start/stop the serial communication routine (say, by using an input to enable/disable) so that at anytime you can stop the PLC from using the serial port and you can connect the PC to perform monitoring/program changes.
Email: support@triplc.com
Tel: 1-877-TRI-PLCS

zif011

  • Guest
Re:T100MD888 as protocol converter
« Reply #4 on: May 07, 2004, 12:39:40 PM »
That's what I thought... Do I need CRC16 if I use on RS232 port CR-LF terminated ASCII strings withTBASIC INPUT$ and PRINT?

Thanks for the great help!

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3174
    • View Profile
    • Internet Programmable PLCs
Re:T100MD888 as protocol converter
« Reply #5 on: May 11, 2004, 09:30:49 AM »
CR-LF terminated ASCII strings usually don't emply CRC16 type error check. So you can simply use the INPUT$ and PRINT to input and output strings. Note that INPUT$ only stop at the CR. So the LF may appear on the first character of the next string but you can use MID$ to extract the proper string.

PRINT only send out CR without the LF. But you can always OUTCOMM an LF character (ASCII 10) after the PRINT statement.
Email: support@triplc.com
Tel: 1-877-TRI-PLCS