设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8788|回复: 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'
- i/ f3 S' j1 f*/
8 K3 g2 F( I/ ?is
* F( A; q; }, r1 e; U3 M% \* v% E- B        part, GlobalDistObj, assignLObj:object;row,Lan:integer;) s- ~5 ]1 }7 a% ?
do
1 h2 F. ]1 E9 {/ n4 N0 }        Lan := rootfolder.Internal.Tools.AOLlanguage;
6 L  ~- u4 I2 p" {5 a# Y2 O        if current = @.Destination -- else return$ j) y1 K4 Y) s2 ?* ?; @& E7 B
        then% e1 `( @2 ^+ D. z* a+ \1 I8 O6 e* z
                @.Destination := void;
7 h: R! g- D) ]9 v. {                if @.occupied then& z, k+ R* }9 {" @
                        part := @.cont;5 D" S7 f8 M# Z+ o1 V. e; V
                        @.transpOrder := void;8 P) Y4 W% S, {% P
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,2 |, [2 r, r; ~8 I: j
                                @,root.eventcontroller.simTime);/ Q4 n9 o3 |& @& Z4 a
                        @.HasOrder := false;
/ U* n7 z6 V2 ]% A  Z                        @.DrivingHome := true;3 _0 c3 l' s* s; e  F
                        rgManager.tryToStartTransOrder;
8 w) N, Q: q% |. S2 G' o8 j; U& G                        if @.Destination = void5 R/ F/ P( E/ c: o7 |" q6 R( @
                        then -- no transport order for vehicle @
8 \* v: \  h0 B5 e$ g3 u                                @.Destination :=
  b9 ~% d4 ~- t/ ?0 G                                rgManager.nearestFreeStation(@,track.~);0 x! S$ W6 n# G. {' F
                                newDirection(@);   
- Y  u, ?/ e- A9 X) y6 U' h* o                                if @.Destination /= void then) v- W+ d" N" F' d% T9 H& x' c
                                        @.Destination.NumReservation :=
8 U. j1 U) q" P, _" ?) G- J+ }                                        @.Destination.NumReservation + 1;& I  J0 C- f4 Y! w4 ~! U" [
                                end;
1 @$ W8 T& O3 \5 E; q- x                                @.CurrIcon := "drivingHome";
" L9 t0 T( |' j                                @.DrivingHome := true;" l( H1 p) Y4 @# h
                        end;, o+ S, Z7 J' _' ^5 k( i* o
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station+ d& Y, V$ P9 i. U
                        part := @.transpOrder;6 J4 Q: d& ?9 _8 f
                        part.move(@);-- load part
% G( _" j/ Q1 r. B                        @.CurrIcon := "load";
$ C, }1 ~5 |8 W% t1 g                        GlobalDistObj := part.globDestination;
3 X; C5 p( j: d  s' P$ Q                        assignLObj := rgmanager.rgAssignL;
/ W5 }/ p6 `7 D' D1 E! A                        row := assignLObj.getRowNo(GlobalDistObj);* B% [: }- k, h8 _8 K: _6 U
                        if Row = -1 then -- since 700 e' D; f: F4 S( `, w
                                if lan=1 then7 N2 }; O1 z* j+ q& p, W
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
; C" r, G: ~' v7 g" J' r, R- e                                                to_str("in der Andockstation: \"",?.~.name,"\""));+ o$ ?- k& O" p
                                else
7 t$ j" q& o! F/ o5 u8 P+ L                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
  k; H; n% r, E& B0 V  i                                                to_str("in docking station: \"",?.~.name,"\""));                                ( |9 X2 S( m% Z
                                end;
0 E# q2 f( ~3 H: g& G                        else
1 M0 O5 c  H$ C6 s8 w3 Z4 f5 c                                @.Destination := assignLObj[1,row];
. t! W0 w3 M, `# q4 o7 `" F                        end;                       
. b+ D9 P  X4 e0 g6 {8 w% d1 E" E                        newDirection(@);* W  g! N! _, U. Q
                        @.HasOrder := true;. K# u- N  ]# y- r$ g" ?
                end;
) R+ I  J) ], h2 I$ o# b$ f        end;. G3 T2 m5 r) Y. [+ Q, M" ~
end;        -- of the method
* F8 H8 Q4 E) n1 n" i8 P  C) G% }
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 . U6 y7 s  {) H

" m# n9 G! d- _这是AGV_putin中arrive的method。
( |6 T- f7 n1 [
* Z9 D! j$ R5 _" n4 u2 o- F( F+ ?当到达物料速度越高时,这个报警更多,
1 }5 d) i) ^+ Y9 g" n+ z% s- s( v! Y可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。1 E- x6 T' R( R8 |: c1 l1 }5 x
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?; k: `, i/ N3 ]- ?  B8 G) h4 A

+ r5 y$ T1 Q  O另外一个小建议,就是move,所有的move都可以这样( W( I: z- I: `0 w6 R# H
if not move() then debug end
: h/ H5 G9 L& u$ w. N这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
. O( T. g! O* {& g. f7 ^7 \; oplant simulation中的free libraries有AGV模板,
% l2 \" W- c+ t" j3 ~; Y- D里面也有案例。
; g1 c# q7 v6 x2 p; n我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。& t+ N! [# H; C1 G, b: e+ E0 h) y
) `" S2 `: B7 c+ j- h; H/ E7 J
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
- O7 Y5 B9 [0 Q$ @/ Q
+ _+ D1 ?: S  L, Z那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
, s. N1 Q+ d7 y% ~  c) X这是AGV_putin中arrive的method。7 I& ^1 T8 ~! k7 W
5 f( n3 M+ Q3 W: X% k# H% A
当到达物料速度越高时,这个报警更多,
( [! @) g6 C; P2 `  q" A
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-26 04:51 , Processed in 0.018046 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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