Chalpa Posted November 26, 2007 Report Posted November 26, 2007 (edited) Hi: I´m actually developing an application where i receive infor from a server using a RS232 serial port. Initially I only have to store the info for 10-15 units in the production line but now the customer wants that I store the info for 180-200 units in the PLC. I think the memory is not a problem (each units uses 8 register of info) but I need to known if it is possible to use indirect addresing to store and retrieve this info from the FX2 Memory so I don´t have to program each option separately using a Counter and a BMOV instruction. Is it this possible? Regards Edited November 26, 2007 by Chalpa Quote
Gambit Posted November 27, 2007 Report Posted November 27, 2007 (edited) Well You don't have indirect programming like the system Q Addrset but it is possible to using indexing All you need to do is place a Z0 - Z7 after the word device. This means that the value of Z is added to the register you are using. For instance if Z0=5 than D23Z0 = D28 For instance your program would look a little like this. M8002 ------- [MOV K0 Z0] {Read serial comm unit 1} [CALL P0] {Read serial comm unit 2} [MOV K8 Z0] [CALL P0] {Read serial comm unit 3} [MOV K16 Z0] [CALL P0] FEND P0 ----[bMOV D0 D1000Z0 K8] END Unit1 info will be on D1000-D1007 Unit2 info will be on D1008-D1015 Unit3 info will be on D1016-D1023 Edited November 27, 2007 by Gambit Quote
Recommended Posts
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.