connect cp342-5 to et200m and my headache

unclehamid

Member
Join Date
Feb 2007
Location
shiraz
Posts
79
God help me!!! I wish I 'd bought a cpu313c-2dp
but you know some times you made mistake :cry:I have cpu 312c +cp342-5 I want to read and write in et200m
can someone give me an example program for doing this
cpu 312-5be03-0ab0 cp 342-5da02-0xe0


et200m:
im153-1aa03-0xb0 DI 321-1bh02-0aa0 do 322-1bh01-0aa0
 
Last edited:
To communicate with remote I/O you need DP Master .
According Siemens catalog:
"6GK7 342-5DA0x-0XE0
CP 342-5 as PROFIBUS DP Slave"

I think you need different card.
 
Hello Unclehamid;
The configuration of the CP 342-5 as a DP master to an ET 200M (for example) is almost the same as the one you would have dopne with an integrated DP master port.
The main difference comes when you want the CPu to access the Profibus-DP data. It is not automatic, you must use special functions FC1 and FC2 (DP-Send and DP-Recv).
Look at the following FAQ on the differences between the CP and the integrated DP ports:
http://support.automation.siemens.com/WW/view/en/21628388
Follow the proposed link and look up FC1 and FC2 descriptions.
They are also explained here:
http://support.automation.siemens.com/WW/view/en/28923457

Hope this helps,
Daniel Chartier
 
Last edited:
dear daniel it was really useful and it works
as I find from that page we use fc1(send)or fc2(recive)to send data to cp342-5 or recieve from it but I didn't find out how we assign memory of cp 342-5 to a specified dp(for example I have et200m(16di/16do) with "55" dp address )
if I had several dp what would happend. in bellow pic how we assigned dbb10-dbb19 to slave 2
attachment.php
 
Last edited:
Hello UncleHamid;
I am sorry to say that the picture you have inserted does not appear correctly, so I am unable to understand your question properly. Did you use the "Attach files" button available on your reply page?
In the meantime,based on what I feel is your concern, I can suggest the following FAQ discussing the use of FC1 and FC2 in your program. All points are important, but I suggest you look especially at point 5: Data communication beteen CPU, CP and slaves, and the Programming Recommendations you find at the bottom of the document.
http://support.automation.siemens.com/WW/view/en/18208090

Once your exchange between the CP and the CPU have been properly done using FC1 and FC2, you can transfer the data from 1 slave from your Recieve_DB (chosen by you in FC2) to any DB you desire, using SFC20("BLKMOV") for example.
Hope this helps,
Daniel Chartier
 
Last edited:
With DP_SEND and DP_RECV you transfer the i/o data from the entire i/o image. You dont have to worry about different DP stations addresses. It is all the same i/o image.
The various DP slaves simply have to be setup in the HW Configuration. The CP then will take care of exchanging the i/o data with the configured DP slave stations.
 
Hi Jesper

What about the speed?
It stay a same.
If Its work like DP Master,what the different between Master and Slave?If both of them can initiate communication.
 
Hi Arik.

The CP 342-5 (6GK7 342-5DA02-0XE0) can work as either master or slave.
In this application it must be master because it controls the ET200M DP slaves.
I think you have missed that the CP342-5 is in the rack with the 312C.

A slave can never initiate comms. It waits for the master to query, only the does it respond.
 
Hello Arik;
As Jesper pointed out, the CP 342-5 may be setup as master or slave on the Profibus-DP network.
Maybe the catalog extract you are quoting is incomplete. Here is a link to the Product Description for the CP 342-5 from the A&D Mall, the Siemens electronic catalog:
https://mall.automation.siemens.com...0053&mlfb=6GK7342-5DA02-0XE0&aktTab=4&lang=en

The Functions tab is very clear about master and slave capabilities of the CP 342-5.

However, that is between the CP and the Profibus network, where the CP 342-5 acts autonomoulsly.. Between the CP and the CPU, you must use asynchronous exchange functions DP-Send and DP-Recv over the backplane connections to transfer the data to/from the network (in the CP) to the CPU memory. This is the issue UncleHamid is trying to deal with.

Hope this helps,
Daniel Chartier
 
thanks all of you
as I found out until now cpu send data by fc1 to an image table in cp342-5 or recieve data from that table by fc2 but data in this table is related to I/O address of each slave
for example in my et200m(byte 0,1 input and byte 0,1 output are assigned)if I had an et200m with (byte 100 output it was related to byte number 100 of cp342-5 image table)
 
Hello Jesper&Daniel

Thanks for your answer.
What confused me,when I went to the Step 7 hardware configuration
"6GK7 342-5DA0x-0XE0
appear as
CP 342-5 as PROFIBUS DP Slave"
From my previous experience master should call DP Master.
With IM-151-8 that the name of the unit.
It seems I have a lot to learn with Siemens.

Thanks for widening my knowledge.
 

Similar Topics

I'm using a SLC typed write from the ControlLogix5572 to the MicroLogix 1400, with path: 2, (MicroLogix IP). The ControlLogix equipment has a...
Replies
0
Views
87
Hello, As part of our project, we are using an M241 controller. This controller interfaces with an industrial computer and a router via a switch...
Replies
2
Views
99
Here's what happened, Operator turned on the disconnect for an auger while it was still running to cut power. Auger DID in fact turn off, but the...
Replies
8
Views
335
What has been your experience with year over year price increases on your Tech-connect service contracts? Is it up to the distributor? 30% seems...
Replies
5
Views
286
Hello, friends, I am trying to upgrade a system that uses an Onrom incremental encoder (E6B2-CWZ6C) connected to a Danfoss VFD (FC360), but now...
Replies
4
Views
271
Back
Top Bottom