4/17/2015 8:23 AM | |
Joined: 10/7/2005 Last visit: 6/5/2023 Posts: 2966 Rating:
|
Hello houssem11 LRD adds the specified constant to the value in the BR register and then loads the doubleword from the absolute memory location addressed in this way into ACCU 1 (LRW works in the same way but loads words instead of doublewords). In order to work out how to replace this S5 instruction in an S7, you need to first determine what the contents of the BR register is. This information is missing from your code snippet and the BR Register is typically loaded with an absolute memory address via the MAB instruction so have a look for that instruction. I suggest you also search for and download the manual for your specific 135U CPU from this Siemens site. It will contain the information about the memory allocation in your CPU which you need to reference to work out what memory area the BR register points too (as well as helping you with understanding these type of instructions). I hope this helps |
Cheers |
|
Follow us on