Jump to content

Recommended Posts

Posted

Hi all.

I'm trying to read and write some data from a ultrasonic generator via Ethercat.

Reading single variables it works , but if I try to read an array with 22 elements (show all the values in this array) it doesn't work .

Please see the image attached.

The idea was to read all the values in the ARRAY[0..21] OF UINT at the same time, is that possible or I have to do 1 by one ?

Speaking with technical support of the welding generators they can do this with TIA Portal.

I added to attached files an exemple from backhoff as well.

Reading the manual for the Weld Generator from Telsonic the index, and Subindex should be

Read_Struc.Index:=UINT#16#2013;
Read_Struc.Subindex:=UsINT#16#16;
Read_Struc.IsCompleteAccess:=FALSE;

Buts as I said above I can only read the first element of the array or Read_data[0]

Thanks

 

 

Read_Function.PNG

Beckhoff.PNG

Read_Function.PNG

Posted

Hi.

Thanks for your reply

Yes, I tried that but no success so far.

I tried as well with the sub index Read_Struc.Subindex:=USINT#16#16;

"For ADOs which consist of several values (array), where only one individual value is accessed,
the subindex “0” is the size of the array (read-only).
The subindexes 1...N correspond to the values 0...N-1 of the corresponding ADO"

Any Ideas ?

Thanks again

Read_Function.PNG

Posted

You are close.

Your error code - 1803 - indicates reception buffer overflow. Your ReadDat variable needs to be N+1 so resize it to [23] and try the same method.

You should always give yourself a few extra bytes with the comm instructions, I would go [30] to start.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...