Author Topic: SAVE_EEP  (Read 13577 times)

Lorne Van Dusen

  • Jr. Member
  • Posts: 93
  • I'm a old guy
    • View Profile
SAVE_EEP
« on: February 20, 2018, 02:20:32 PM »
I am still a little confused about the correct way to do a SAVE_EEP on consecutive DM's
If I want to do a SAVE_EEP for DM[700] through DM[704]

Do I use SAVE_EEP [DM700] + 3

Then on first scan what is the proper method to move the value back into DM[700] to DM[704]

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3174
    • View Profile
    • Internet Programmable PLCs
Re:SAVE_EEP
« Reply #1 on: February 21, 2018, 11:25:54 AM »
Which location of EEPROM do you want to save these data to?

E.g. if you want to save DM[700] - DM[704] to EEP location 100 to 105.


FOR I = 0 to 4
   SAVE_EEP DM[700+I],   100+I
NEXT

---------------------------------------------------------------------------------------


To load values from EEP location 100-104 back to DM[700] to DM[704]:

FOR I = 1 to 4
   DM[700+I] = LOAD_EEP(100 + I)
NEXT
« Last Edit: February 21, 2018, 11:26:21 AM by support »
Email: support@triplc.com
Tel: 1-877-TRI-PLCS

Lorne Van Dusen

  • Jr. Member
  • Posts: 93
  • I'm a old guy
    • View Profile
Re:SAVE_EEP
« Reply #2 on: February 22, 2018, 12:00:47 PM »
Thanks for the reply
I must have been having one of those brain freeze days
as I should have figured that out because I have used the same type of circuit before.

Lorne