设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6582|回复: 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'+ n0 M6 ]6 I, V: P8 |) G% _% U6 ?
*/
) d! R  K/ C7 m6 Vis
# j4 ^8 X; O# W6 H& z        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
2 K% p3 F8 a% ddo# V, a, ?" i1 W" B2 ~
        Lan := rootfolder.Internal.Tools.AOLlanguage;
/ S3 W* _- h1 t$ w# K        if current = @.Destination -- else return
  R# \. @' ~! T5 S5 q        then
) \% `# ?2 i' H; y                @.Destination := void;
/ B9 M) N2 p$ Q$ B" a8 C6 T' w                if @.occupied then
* o: x7 c; _8 U9 J) Y                        part := @.cont;
, K! D) x4 C0 c* u0 W- C                        @.transpOrder := void;
) X0 e, J3 A! L) I                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
4 F- p( z: m* h5 t" I2 R                                @,root.eventcontroller.simTime);  b' N4 K0 @: Z* h7 q9 s1 b
                        @.HasOrder := false;
3 \+ F# t0 U, L1 S2 ]                        @.DrivingHome := true;' s2 Z4 J& Z% H3 C% J
                        rgManager.tryToStartTransOrder;# }2 Y& \' ]; {( q1 }' y0 ?1 m' I
                        if @.Destination = void- A0 I3 a: y& @( l
                        then -- no transport order for vehicle @
7 T5 ~& Z( Y6 s) o" ?) z                                @.Destination :=
6 z) F7 q! M, W                                rgManager.nearestFreeStation(@,track.~);6 l( z7 C( h6 l5 O" X' ^
                                newDirection(@);   
2 b7 q( \" i2 f9 E6 H# r                                if @.Destination /= void then" X$ K* C3 Y6 T7 O# e
                                        @.Destination.NumReservation :=' k' @0 }1 l; y2 b
                                        @.Destination.NumReservation + 1;
3 \- h8 D7 X2 }3 b4 a- w                                end;
3 l8 A. Z3 A1 H9 }4 r# }$ Q4 {( J. L                                @.CurrIcon := "drivingHome";) u6 i2 _6 k7 ?+ B. Z0 i
                                @.DrivingHome := true;
8 Q  @# g/ N: |+ j6 i/ O/ Z                        end;- T  m1 p9 Z8 i
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 t8 X% d, i& C+ P, O# D: e                        part := @.transpOrder;, ?6 Y3 H5 o9 W
                        part.move(@);-- load part
% S$ }1 C8 ~/ {                        @.CurrIcon := "load";5 q$ f# t+ n& l) |' r7 Y* `# P
                        GlobalDistObj := part.globDestination;
2 f% k# S. ?3 q+ k( K7 u# f: Z                        assignLObj := rgmanager.rgAssignL;
" d  Z* V, s/ x! s                        row := assignLObj.getRowNo(GlobalDistObj);9 N. y) y" t0 f# F# M7 P# _: ^/ i
                        if Row = -1 then -- since 70" X5 G1 k  H8 m3 ?* A" x% ~
                                if lan=1 then
* G( `: e- i2 I* Z+ h1 j: x, @                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
% v5 r' w% @% w1 g5 D                                                to_str("in der Andockstation: \"",?.~.name,"\""));) E; n7 I6 b4 H3 X2 T
                                else8 J5 D. V/ H" Q1 w' b# u
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
' [0 N3 B! v9 y! l5 Q: r                                                to_str("in docking station: \"",?.~.name,"\""));                                6 A8 J0 q/ q4 i1 s1 E
                                end;5 o9 o; w2 L1 l  S
                        else
; M7 }7 U- c) A# V/ J                                @.Destination := assignLObj[1,row];
: |$ V4 M0 J) c- X                        end;                       
) p! L5 H. w5 X& L' I                        newDirection(@);
9 k6 k: M9 y+ Q2 ?  v                        @.HasOrder := true;- X# y, F+ R% p2 i) r7 C
                end;6 X" o$ m0 I  G8 n" }* j
        end;
9 [& o9 \% h1 O, `end;        -- of the method- H- x9 ~' k0 G& P) ^" T
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 5 F: V" F( e6 I6 \2 c" q5 V
! B& u% f3 C5 F" c3 C! P0 p( L' g# h* q& g
这是AGV_putin中arrive的method。$ h9 w% p! E- O: j: o. k  P

5 w: C3 l+ C4 E9 Q* b当到达物料速度越高时,这个报警更多,
: M) Z+ s: k1 k( |可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
4 H1 _0 Z  s; e& O" A+ {$ _程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?8 d5 `* k7 J) G

0 S) ^* I- O. I' g$ W3 P另外一个小建议,就是move,所有的move都可以这样
3 _& _6 D9 e) }9 pif not move() then debug end6 L( P5 A& ^. W  j0 z& C
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
* J/ L2 Y5 s8 u: q4 _$ j4 J: T; Yplant simulation中的free libraries有AGV模板,5 \  k! ?; x2 ~. m6 N
里面也有案例。; D  Y" y& z& T* y
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。7 |  i. }$ o8 E( o* f! B1 ?

7 ]0 ~5 }1 l3 H我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 . b9 o9 }+ k3 Z

! `2 k: y/ w( {+ i, x那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 $ o# t# L+ d, H4 }: D4 i" Y
这是AGV_putin中arrive的method。
7 x$ k# `6 m0 N) a( ^' K. H( z' h( F( \3 G1 Y
当到达物料速度越高时,这个报警更多,
9 {2 C& c% n4 X) ]7 n
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-14 03:38 , Processed in 0.020816 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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