Hi I just came back from a project where I had to help someone else with his PLC where he was using a CP342-5 to exchange data with a Profibus slave. It is my first time with using a CP342-5. I went OK, but 2 things struck me.
1. It is really odd that you have to exchange all i/o with the CP starting from byte 0. If you have say 4 bytes i/o via the CP but they are assigned the adresses IB100-IB103, then you have to exchange 104 bytes, and not just the 4 relevant bytes.
2. What happens with input image when you read all the inputs from the CP starting from IB0 ? Do the input bytes get overwritten ?
If so, what then with the inputs you have in the rack (not via Profibus) ?
Because I became unsure about this I decided to use a DB as target for the DP_RECV block, and then only use the relevant inputs from this DB.
Both of the above would not be a problem if you could read/write only the exact number of input/output bytes that are attached to the CP as Profibus slaves.
1. It is really odd that you have to exchange all i/o with the CP starting from byte 0. If you have say 4 bytes i/o via the CP but they are assigned the adresses IB100-IB103, then you have to exchange 104 bytes, and not just the 4 relevant bytes.
2. What happens with input image when you read all the inputs from the CP starting from IB0 ? Do the input bytes get overwritten ?
If so, what then with the inputs you have in the rack (not via Profibus) ?
Because I became unsure about this I decided to use a DB as target for the DP_RECV block, and then only use the relevant inputs from this DB.
Both of the above would not be a problem if you could read/write only the exact number of input/output bytes that are attached to the CP as Profibus slaves.