设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9856|回复: 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') R8 ?0 m+ a, B* l0 c# E
*/9 A: d! V. N% x5 I, X
is3 H& ?0 b" t" n* ]
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;7 D% t. r, m! w+ v
do5 `( e+ M5 a. b: D: k! {4 t
        Lan := rootfolder.Internal.Tools.AOLlanguage;
; t. Z+ _" k: }9 p' ^+ Q) V4 y) Q        if current = @.Destination -- else return
/ [7 N* r- ~/ h* l8 b        then1 X8 {) V4 v" `. B; L. j$ d! v
                @.Destination := void;
, Z  U, d+ |. _9 i                if @.occupied then
/ M2 Y: C4 }( Y7 u$ `+ c                        part := @.cont;/ i$ T# p$ F/ y- `" [/ ?7 M* |
                        @.transpOrder := void;! x9 t3 ~* {& f1 j2 T- I$ c  n
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,9 f6 C9 G: T9 B6 K. x
                                @,root.eventcontroller.simTime);% C- I9 U& I( C4 H7 R
                        @.HasOrder := false;
+ ?% k7 Q, \% V# |                        @.DrivingHome := true;6 j6 ?+ X9 Y% t5 [
                        rgManager.tryToStartTransOrder;- N7 q/ g2 \+ q# @, m% Y+ X
                        if @.Destination = void- U8 u4 r9 k) b/ W
                        then -- no transport order for vehicle @; w7 [  H9 c; I& e
                                @.Destination :=/ c: p; g. Q% ^
                                rgManager.nearestFreeStation(@,track.~);
2 V/ l& m7 N( }0 j                                newDirection(@);   ; i7 F4 o) c& X
                                if @.Destination /= void then! `# `9 @% r+ b7 N
                                        @.Destination.NumReservation :=" R. D$ P+ ?  x- Y$ f0 C( v7 S0 m, A+ Z
                                        @.Destination.NumReservation + 1;
) N+ d* U$ c+ k: ~! G                                end;. h0 L! d9 r  }3 S2 F3 j
                                @.CurrIcon := "drivingHome";- a( \  k6 ~& F4 i" [
                                @.DrivingHome := true;# P" q* I$ o4 R8 W" P
                        end;' R5 H3 _5 ]% G' O/ B% [) n
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station' `+ f& `" y# H! h& [2 c9 x
                        part := @.transpOrder;
2 S: \/ W* G% |" s0 e% b8 p) x                        part.move(@);-- load part
$ b0 ?5 X5 w8 t) l5 N. ~5 ]  k1 k                        @.CurrIcon := "load";5 F) a* W8 S4 V
                        GlobalDistObj := part.globDestination;
  G  D: L& d0 N; P( f                        assignLObj := rgmanager.rgAssignL;/ q! Z+ L/ n- B' \' n. X
                        row := assignLObj.getRowNo(GlobalDistObj);
. W$ ]* e2 @5 }$ K) w5 B% z& k8 A                        if Row = -1 then -- since 70, @/ k0 F5 H9 c! X2 s
                                if lan=1 then
0 t, D- o- X0 h. Y$ U                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
7 @  D% {6 x6 }  U$ E; g. J! P                                                to_str("in der Andockstation: \"",?.~.name,"\""));. ~: \% C" c$ }' h# p
                                else
1 b- X$ L4 |- z( t& l6 X# r% ]                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),, ^6 W7 a; w8 _1 Q& W2 c. `
                                                to_str("in docking station: \"",?.~.name,"\""));                               
) L+ O* B. J/ L# s                                end;  m2 {" n5 N4 @0 k" o: X) b8 r
                        else+ T  `9 A( P$ K, [
                                @.Destination := assignLObj[1,row];6 k( H5 v: B  k+ ], w. }3 {% m
                        end;                       
2 B- ^5 N8 [. {% z- c' ?5 F                        newDirection(@);
6 X5 @- V$ z+ U! z" e  _: ]                        @.HasOrder := true;
0 v. R5 G2 f- Q, h+ u! A                end;
5 s+ I' O1 P  i. f# \- q; G        end;: ]5 H9 U8 q' Q; S
end;        -- of the method7 o( i% F1 P' @: Q' y. @3 m* p( z2 R! g$ u
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 / S& N/ f& I" ^5 k

( [7 Z2 |7 y! i" P3 Z8 A& X这是AGV_putin中arrive的method。* Z, c4 Z9 X* ]& U; M% F
2 ]$ E5 A5 [" u0 T9 T! C
当到达物料速度越高时,这个报警更多,
7 w% ^, ?7 P! S8 j; G; C; k- p7 k可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
: n8 q* A8 h5 C+ C8 f程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?$ a# `! U& q* V: \

6 K6 N8 d" O5 k另外一个小建议,就是move,所有的move都可以这样
# E5 b( e; s/ r& o( gif not move() then debug end# h* q9 V! [$ o6 M
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
1 C4 V0 A% D) `plant simulation中的free libraries有AGV模板,, I9 x2 k4 h* l4 J. ^
里面也有案例。
$ o7 z* L2 d# K. A3 N1 b) R2 D我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。, l1 f+ X- ?) I1 _! A9 X. N
6 R7 A& z9 A4 d  q6 ~0 {1 E
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
8 j# q- [6 p/ `) ?0 E% a1 L7 t. A# o7 {2 v
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
: |7 q+ H2 `! y$ @- J) r* @这是AGV_putin中arrive的method。
& |" B% X5 Q/ K- @  c9 Y; _* a/ ?" N5 Y6 c+ i& S
当到达物料速度越高时,这个报警更多,
: ~- o, }1 A4 U+ m3 G; E
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-29 18:03 , Processed in 0.017350 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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