2/10/2017 5:15 PM | |
Joined: 12/9/2010 Last visit: 10/8/2022 Posts: 623 Rating: (76) |
Hi List, 1. For IN type we have to L Variable and then LAR1 and for TEMP we can LAR1 P## XXX, having any significance? --> ANY pointer is 10 bytes long so 10 bytes are reserved for this IN parameter in parameter variable memory. All types of addresses in STEP-7 can be represented by ANY data type with the help of 10 bytes. LAR1 P##XXX can be written without any problem. But for FCs, u should not access another IN/INOUT/TEMP/OUT parameter as CPU OS uses AR1 to calculate block parameters. In case of FBs, AR2 will be used by CPU OS to calculate parameter addresses. 2. After Executing What will be the Data in AR1 ? AR2 will have the value of temp address [L0.0], what will be the value of AR2 for IN variable? --> Now #Data_Temp has the absolute address -P#L0.0 byte 10. U should not bother about IN addresses as it can't be accessed in STEP-7. Rather it will tell u what is connected to IN parameters. Eg. u have connected M6.0 to IN ANY parameters, AR2 will give 10 byte long ANY pointer of M6.0. B[AR2, p#0.0] to B[AR2, p#9.0]. |
Last edited by: Sachinpatke at: 2/11/2017 6:27:56 PMIf you like the comment, rate it (right top) or thank it (left bottom). |
|
Follow us on