question

Alessio Merlo avatar image
0 Likes"
Alessio Merlo asked anthony.johnson commented

When is the AGV.currentCP property updated?

Hi,

I would like to ask a very simple question: when is the AGV.currentCP updated?

I created two similar models with only one different: delay = 0.

Without the delay, the model works perfectly. The redirect command updates correctly the currentCP property (model currentCP_redirect_without_delay.fsm).

With the delay, the model returns an exception because after the redirect command the currentCP isn't valid (model currentCP_redirect_with_delay.fsm).

Where is the mistake?

Thanks in advance.

FlexSim 20.2.2
agvflexsim 20.2.2redirectcurrentcp
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

·
anthony.johnson avatar image
0 Likes"
anthony.johnson answered anthony.johnson commented

currentCP will give undefined results when the AGV is moving. You should only access currentCP when the AGV is stopped. In other words, for your purposes, you should only assume that currentCP is updated when an AGV comes to a stop.

· 2
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Alessio Merlo avatar image Alessio Merlo commented ·

Thanks @anthony.johnson!

How can I know which is the last CP for an agv?

0 Likes 0 ·
anthony.johnson avatar image anthony.johnson ♦♦ Alessio Merlo commented ·

You listen for the AGV pre-arrival and then set a label to the involved control point for that pre-arrival event.

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.