8/4/2015 11:55 AM | |
Joined: 12/16/2012 Last visit: 9/11/2023 Posts: 646 Rating:
|
Hi! Regarding the example with DB1.DB0.0 INT 100, I just wanted to show you what the attached document states on page 6: "The user may enter an “absolute” form of the ANY pointer, or the user may apply a symbolic variable to the parameter. When a symbol name is applied to the ANY pointer input of a function or function block, it is converted to an “absolute” ANY pointer whose starting address is the address of the symbol, whose data type is BYTE, and whose length if the byte length of the defined symbol (for instance, a REAL element would have a byte length of 4)." Regarding the second part with #MyArray, I do not see any BLKMOV in your example code. Anyway, looks like something is wrong with the source and destination memory areas (see last point of link). Maybe the local stack of OB1 is too small for your array - I don't know. You could try to construct an ANY pointer which points to #MyArray as in smiffy's example, and use that with BLKMOV: pAnySRC.S7Code := 16#10; PS another good example from smiffy: https://support.industry.siemens.com/tf/ww/en/posts/any-pointer-in-scl/50677/?page=0&pageSize=10 |
Last edited by: Kahl at: 8/4/2015 11:56:22 AMLast edited by: Kahl at: 8/4/2015 11:59:48 AMLast edited by: Kahl at: 8/4/2015 2:14:33 PM |
|
8/4/2015 1:03 PM | |
Joined: 12/16/2012 Last visit: 9/11/2023 Posts: 646 Rating:
|
Hi! What does not work? What happens? |
9/12/2017 8:54 PM | |
Joined: 1/20/2011 Last visit: 3/15/2023 Posts: 4 Rating:
|
It appears the command, ReadFromArrayDB is only for S7-1500. |
Last edited by: ORION500 at: 9/12/2017 8:57:12 PM |
|
Follow us on