Industrial Communications

cancel
Showing results for 
Search instead for 
Did you mean: 

s7-300 with comsoft df profi II

I posted this in the General LabView board by mistake.  Here is a copy. 

 

I'm trying to use a DF PROFI II CPCI card in my PXI to communicate with a Siemens S7-300 PLC.  The data I am sending is a 32-bit value.  Siemens claims that it will spread this value over 4 bytes automatically.  My problem is I am only getting the first byte.  The next 3 bytes are zero's, then I get the first byte of my next value.

 

Is there a setup procedure to allow this?  Is my problem in the PLC?

 

Thanks for any help I can get.

 

Ralph

0 Kudos
Message 1 of 13
(11,536 Views)

What 32 bit value are you sending out (Signed or Unsigned?), would you expect the later 3 bytes to be all zeros?

How are you connecting to your PLC?

 

You need to make sure you are using the right driver in the OPC device setup.

0 Kudos
Message 2 of 13
(11,522 Views)

Hunter,

I am trying to send a 32-bit Real (floating point) value.  I have a Profibus Comsoft DF Profi II card (CPCI) in my PXI.  I have the NI-VISA 4.2 driver installed.  I was thinking this would take the place of an OPC server, or would at least server as one.

 

There are no expected zero's in my value.  I am connected to the PLC and viewing the data realtime.

 

I have my PLC setup as the Master and my NI PXI card setup as the Slave.

 

As a side question.  What is the "consist." when choosing my Input/Output sizing?

 

Thanks for any help you can offer.

 

Ralph

0 Kudos
Message 3 of 13
(11,506 Views)

Which driver are you using in relation to Step 4 of this doccument?

Also can you post a screenshot of the consist value you are talking about?

0 Kudos
Message 4 of 13
(11,489 Views)

Thanks for the response again.  I did not install an OPC server.  I used this document and installed the NI-VISA 4.2 driver.  My Comsoft PXI card is setup to be the slave and my Siemens PLC is setup to be the Master.

 

In figure 10 in the left hand pane, you can see the number of Input/Output bytes.  You can see there are 2 options for every value of I/O.  The second has "consist." added to it.  The word is cutoff in the figure, but hopefully it will be enough.  I will try to get an actual screen shot from the laptop, but it may be a day or 2.  We share it in the department, and some else is using.

 

Thanks again,

 

Ralph

0 Kudos
Message 5 of 13
(11,471 Views)
Post the image when you get a chance. These instructions have you configuring the Comsoft board as master; did you configure it to be a slave? Does your device need a GSD file or is a generic one acceptable?
Matt
Applications Engineer
National Instruments
0 Kudos
Message 6 of 13
(11,456 Views)

I have a GSD files (DFPR0961.gsd) that I got from the NI website.  I did configure the Comsoft board as a Slave.  Is there another manual that shows this better?  If so, I'd like a copy of it.

 

Thanks,

 

Ralph

0 Kudos
Message 7 of 13
(11,449 Views)

Hello rapuckett,

 

if i understand you right, you're not sure if the Siemens S7 is sending the valueon the profibus?

Are you able to log the profibus telegrams  with a bus monitor?

 

Maybe the DF PROFI II only gets the first byte of your 32-bit-value and the S7 doesn't send the other values?

 

Kind regards,

 

Sven

0 Kudos
Message 8 of 13
(11,447 Views)

Sven,

 

You are correct.  I am not 100% sure that the S7 is sending all 32 bits.  I am only seeing the lowest byte. 

 

My problem could very well be my PLC setup.  I did read where the "Move" command in the S7, which I am using, will truncate if you move a 32-bit value (DWORD) to a 8-bit value (BYTE).  The result would be exactly what I am seeing.  I also heard that when sending a DWORD to a Profibus BYTE, it would spread out to following additional BYTES as needed.  It may simply be in my S7 command, but I couldn't find another command.

 

Thanks,

 

Ralph

0 Kudos
Message 9 of 13
(11,440 Views)

I have a screen shot showing the "consist" at the end of the choice for I/O.

 

I still don't have it figured out.  I had to start from scratch with this.  The equipment that I need to put this on has become unavailable for a while.  In the mean time, I am working in a Lab setting, which should isolate a few things.

 

Thanks again for any help you can provide.

 

Ralph

 

0 Kudos
Message 10 of 13
(11,383 Views)