question

liyinhai avatar image
0 Likes"
liyinhai asked liyinhai commented

不连接对象的任务

4-fm - 问题点.fsm像这种情况,不连接Queue1和Queue2的情况下,怎么只对Operator1发布任务,将Box从Queue1搬到Queue2?

Other
task
4-fm-问题点.fsm (35.4 KiB)
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

·
CSN avatar image
0 Likes"
CSN answered liyinhai commented

您好,您的模型有几个问题:

首先,您的模型没有连接Source,也没有设置创建box到Queue1的逻辑,所以Queue1里面不会有box出现,建议将Source1与Queue1先A连接。

其次,您在Operator1的重置触发里写的任务,但是重置触发内是不存在box的,模型重置时所有的box都会销毁,所以建议任务脚本写在Queue1的进入触发里。

然后,您的脚本里对于box的定义是错误的,Queue1没有输入端口,所以没有inobject,您如果将任务写在Queue1的进入触发里,box就是item,不需要再定义了。

最后,这种情况建议使用PF,可以很方便的实现您想要的逻辑,且不需要写脚本。以下是使用PF的示例模型:

PF示意模型V23.2.fsm


· 1
5 |100000

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

liyinhai avatar image liyinhai commented ·
好的,谢谢
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.