Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC: Code / Compilation discrepancy

Code / Compilation discrepancy 12 years 7 months ago #2626

  • Snarf77
  • Snarf77's Avatar
  • OFFLINE
  • Platinum Boarder
  • Posts: 847
  • Thank you received: 2
  • Karma: 5
Hi all,

I have a problem I'va never faced for now.

I have an aggregate in my class which uses another comonenet, the plc code of which has been modified. Indeed there is three level of inclusion (main object - sub object - sub sub object) and this is the last one that has been modified.

I compiled and save the class volume and then update the classes within my project root volume.

When I edit the related PLC sub Window I can read the right code I have modified.

But when I compiled (even with force compile) the volume / node and then load the runtime (in simulation on my dev station for the moment) if I open the plc in runtime I still read the old code.

I can't update it correctly.

I guess it has something to do with the template of code which are re used within the class object but I tried to delete the Template wihtout success. I don't know where to check where the discrepancy is.

Any help appreciated

Snarf
The administrator has disabled public write access.

Re:Code / Compilation discrepancy 12 years 7 months ago #2628

  • deiKruve
  • deiKruve's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 65
  • Karma: 0
snarf,
here is a long shot (out of Proview for dummies)

Is there somewhere in the toplayers a symbol that still links to the old code
and did not get reset to point to the new code?

jan.
The administrator has disabled public write access.

Re:Code / Compilation discrepancy 12 years 7 months ago #2631

  • claes
  • claes's Avatar
  • OFFLINE
  • Platinum Boarder
  • Posts: 3178
  • Thank you received: 502
  • Karma: 133
Hi Snarf,

If you can see the correct code in the root volume, and have built the node correctly, the code you are running is probably the correct one, and the problem is only the display in plc trace. The display is fetched from the file $pwrp_load/pwr_'classname'.flw that is generated when you save the template code in the class volume. Enter the template code and save again and check that this file is updated.

/Claes
The administrator has disabled public write access.

Re:Code / Compilation discrepancy 12 years 7 months ago #2641

  • Snarf77
  • Snarf77's Avatar
  • OFFLINE
  • Platinum Boarder
  • Posts: 847
  • Thank you received: 2
  • Karma: 5
Hi Claes,

Indeed the .flw of the component has been updated correctly but not the one of the component that used it (I have a three level inclusion aggregate).

I saved again the three involved object and that worked.

You guess right, my code was working correctly but a parameter error made me think the contrary at the beginning. It was effectively only a display problem.

Just for my understanding, does the .flw of an aggregate includes the code of the depending componenet or is it only a link to the other .flw ??

Anyway many thanks for this one, I started becoming crazy ...

Snarf
The administrator has disabled public write access.
  • Page:
  • 1
Time to create page: 8.928 seconds