设为首页收藏本站

最大的系统仿真与系统优化公益交流社区

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6365|回复: 9

[求助] 用AGV模板发生了以下错误,请解!

  [复制链接]
发表于 2011-11-5 16:38:28 | 显示全部楼层 |阅读模式
问题在哪里?

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?注册

x
 楼主| 发表于 2011-11-14 10:37:54 | 显示全部楼层
没有解决,再顶一下。
 楼主| 发表于 2011-11-17 11:03:27 | 显示全部楼层
/* called by:        entrance ctrl of the object 'track'3 K. [8 L( S  I# r+ C* |
*/* o( c4 w0 }/ R+ T
is
  F  ^. \- o" J# E- S9 `        part, GlobalDistObj, assignLObj:object;row,Lan:integer;6 d# ~5 _6 }4 ]$ S. M3 ^* D
do
$ F9 S9 m4 z- X) p2 k" [% J        Lan := rootfolder.Internal.Tools.AOLlanguage;2 P  ^( V) p  @
        if current = @.Destination -- else return
! d1 }" W( h& t' u        then
; r! ~2 W" j. T* |9 A7 F# h                @.Destination := void;( ?5 c. t4 s( z* G; n# g/ @
                if @.occupied then
5 I; s# J" b: U( [6 E5 H                        part := @.cont;# Y/ R0 h. l' J, t2 n
                        @.transpOrder := void;
$ d! x/ h8 s* W, h0 O  }; u                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,+ O% r& Q# ]7 R! V$ E
                                @,root.eventcontroller.simTime);
0 g8 K( x$ ^/ }8 l. }1 C7 O% j                        @.HasOrder := false;
' n6 i0 l' ^( Q" Z* K( y9 n# c  b, Z                        @.DrivingHome := true;3 ]; a, V1 N5 s1 o3 x& ~4 @
                        rgManager.tryToStartTransOrder;% t1 E0 _+ G# R) y5 U3 x
                        if @.Destination = void
% ^+ p, S% L7 @: B                        then -- no transport order for vehicle @
) t. D- Z0 D5 R. s1 ]5 H, f+ ^                                @.Destination :=
- t5 u. C5 g6 A7 x* z5 ~: A                                rgManager.nearestFreeStation(@,track.~);: C0 T4 a6 N& z6 ?5 I1 C9 \
                                newDirection(@);   
8 W# e; B% G9 m7 ?9 V  a. W                                if @.Destination /= void then
3 B+ B. z1 c: a7 a2 A* \4 W                                        @.Destination.NumReservation :=
* w3 A6 g: E. i1 \                                        @.Destination.NumReservation + 1;
. g# |  G5 ^6 v4 C2 Y+ t0 Q                                end;7 d% R7 z, P0 ?& q, K
                                @.CurrIcon := "drivingHome";) p# z6 b* o3 {- o* J4 z
                                @.DrivingHome := true;/ \2 a4 J" t5 B+ @& u  l
                        end;
) b$ e4 t% g: `3 K) b                else -- the vehicle @ is empty, both vehicle and part are in the same dock station6 \! a  g* }+ q/ f
                        part := @.transpOrder;( Z$ U* u% z0 [! a$ D2 l
                        part.move(@);-- load part  @6 Y& z. }  A7 P+ ]
                        @.CurrIcon := "load";
" U! R8 b7 D7 u; Q# ]                        GlobalDistObj := part.globDestination;7 m/ F$ \. e' j+ `
                        assignLObj := rgmanager.rgAssignL;% Q7 d5 W$ J6 ^3 d9 @5 S" l
                        row := assignLObj.getRowNo(GlobalDistObj);3 E% N+ u! B) F  D/ t  _  ^
                        if Row = -1 then -- since 70
% i: a9 i) \/ O4 g4 d                                if lan=1 then% x# C' u% j. c6 W( t  F
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),& O9 D8 S6 v' I5 C
                                                to_str("in der Andockstation: \"",?.~.name,"\""));# O3 ?4 ~% x- X. i: |
                                else
! i& q: o  w" n1 e0 j                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
* w* ~1 j0 s) _                                                to_str("in docking station: \"",?.~.name,"\""));                                + a# m3 P" J$ r6 L) J( |
                                end;3 x1 a/ x2 c% T+ ?. V
                        else, ?/ ?7 j3 E: m  |3 G8 ?: ^3 ?. U
                                @.Destination := assignLObj[1,row];
, |7 p$ g: {5 e: h                        end;                       
2 Q2 n7 J' I, I# z# T3 V                        newDirection(@);% K9 g2 G  @1 X4 w, r) l: T1 [9 o
                        @.HasOrder := true;
. w) P$ ?* A0 Z- N                end;
6 |. ^6 Z' ~2 H& ^1 U1 S) f  b        end;
6 h( D" V  j7 Q" W. c% Send;        -- of the method$ ~1 G( s: v0 t& w, R( e
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
7 _/ L& \2 w) B5 }0 M0 `0 v
5 K) r" `% c% @0 D* U5 _这是AGV_putin中arrive的method。+ n& H0 M. E0 U4 B

) O; z# P8 q$ ]当到达物料速度越高时,这个报警更多,% L: n! u2 S! D9 ?+ G" Z: \
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。* W7 V% J  j4 Q0 ~, L
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?4 {& H. G  e3 z' R5 [# y, V
7 g. U: @6 R/ O) `/ `2 ^
另外一个小建议,就是move,所有的move都可以这样
1 I. M/ P% L7 A- i0 E% f  k+ m0 eif not move() then debug end5 z  P3 O/ G$ d: w7 k
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。; M. x. d; G, `/ i: r* r
plant simulation中的free libraries有AGV模板,* ~$ L% n6 @6 Z; o. R5 E
里面也有案例。
) F: M: r( F2 e" u0 T5 s我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。0 a0 {6 z' c( X, Z: Y  c; g
- T1 w; r  Z! d5 e7 u
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ; Q' Y; E& W0 R- b$ e! g5 G% N2 g* a

) l* q6 p# i8 A6 \那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
' m( T/ H/ K/ s% w: L1 }9 d9 c2 w这是AGV_putin中arrive的method。7 {7 ?' O% j( X; q1 X; E9 e
$ B5 t0 S. \1 i$ N! v: ~  S
当到达物料速度越高时,这个报警更多,

* g7 w& _+ _5 E0 p' A- n. f  k另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|Archiver|手机版|SimulWay 道于仿真   

GMT+8, 2026-2-2 01:33 , Processed in 0.021805 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表