I've never had to setup serial card for such purpose but I guess
it wouldn't be much different from unsolicited messages using Ethernet...
Assuming hardware setup is ok and cabling is ok, you would
have to:
- initialize card (straight copy from the manual - might need to
relocate some addresses if they are already used)
- setup mesage and trigger it when you have something to send
- check if something is received and take it out of buffer
(unless it's written directly to PLC memory).
What you do with data and how is it formated is up to you.
Now before you get all excited about communication, are you
familiar with terminal emulator of your choice (HyperTerminal
is free version that comes with Windows...)? You will need
it to know what is your PLC really sending and to send data
to PLC so you can check the receiving part.
Be prepared to get/make some cables (crossover and straight) and adapters (pair of converters 422/232 for example...).
Unfortunatelly you will be on your own most of the time. I will
try to see if I can find any sample code to help you out (don't expect too much, I'm very bussy these days and this is tough
topic - at least when dealing with Mitsubishi).
You can always call their Tech Support Center in Chicago but
I wouldn't be surprised if this is way over their heads.
Or in short:
If you intend to send and recive data using ANY type of serial
communication (232, 422, 485...), you MUST have something to
test it with. Don't even think of trying to do it straight
with PLC program. Make sure you can do it with PC first.
For every hour you spend with PC communication, you will spend
one day to do same with PLC. If you make no progress with PC in
two days, you should really ask for some serious help:
A)
You have to:
- capture typical message from device (scanner, drive or whatever
you want to talk to)
- reproduce (simulate) this message using PC (learn how to use
terminal emulator).
B)
In order to do the mentioned you might need some:
- cables
- signal converters
C)
Goal is to:
- verify comm settings (baud rate, stop bits...)
- verify that you can fool other device that it's talking to PLC.
Now, you really need to put your hands on those manuals. They are
probably ca. 400pages of pure Jinglish each, so it will take some
time to digest it all. Don't think that reading it once will do the
trick. Japanese are sort or robots. They read everything regardless
if it's fine print or not. You should do the same...
Hope this helps