设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7684|回复: 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') q9 s8 `6 G# n6 O% `
*/' V# m! q: K9 R) r/ r
is
7 j1 z( c) F5 g5 X        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
2 ^9 [4 C4 U/ C  k% ?% A" u, \do
6 _# t' W4 }1 {; r. V        Lan := rootfolder.Internal.Tools.AOLlanguage;3 D6 B6 J2 x1 j+ b; D4 l% v
        if current = @.Destination -- else return+ R8 f* {0 k5 d) C9 w, }, J7 ^0 s
        then
4 ~" f# W) b6 J                @.Destination := void;6 g1 H4 M: g+ b# d3 [
                if @.occupied then
) l5 N. M0 g4 G4 D) U2 N! v                        part := @.cont;5 v( x2 w! A8 J% x
                        @.transpOrder := void;
2 ^  ^- l, v3 |3 e$ O                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,$ C/ I0 `  |# l* k! i9 V4 D, |
                                @,root.eventcontroller.simTime);6 n! j( B, K: ]" Q
                        @.HasOrder := false;8 v* g3 }4 G! j2 T& B% g  k
                        @.DrivingHome := true;- W1 Z: ?. S3 F& `% B8 m" }
                        rgManager.tryToStartTransOrder;* ?! g7 S3 x/ V5 u8 N  J) \) ^
                        if @.Destination = void0 T' G+ }$ }3 H9 K' m  [. n
                        then -- no transport order for vehicle @5 g' }2 w; U: e  j; `$ z
                                @.Destination :=
# b2 z6 f. _  ~2 i5 U& q3 j                                rgManager.nearestFreeStation(@,track.~);! C& V- b3 k' s; W8 q* x1 j
                                newDirection(@);   9 a( a% K0 a/ G, a1 J4 Q# ]+ f+ f4 f6 v
                                if @.Destination /= void then
0 O* V: x1 p/ u+ s- A% v, A; L                                        @.Destination.NumReservation :=0 r3 z- {7 s0 j
                                        @.Destination.NumReservation + 1;
; a+ ]4 y. B9 I! K) U$ _                                end;+ N8 ~! M7 r. l
                                @.CurrIcon := "drivingHome";2 P& l5 b1 L9 q0 H" L
                                @.DrivingHome := true;( N! x$ u6 I% P( l# o
                        end;5 X" O  A" y: `: r
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station( I+ D, l% Z% _7 N5 q6 z
                        part := @.transpOrder;
2 Y- f8 S+ M3 y+ x! ?( {                        part.move(@);-- load part7 `! K& |. ^8 U, D) s
                        @.CurrIcon := "load";
9 `, j' n; Q( C4 O6 E3 B9 b6 s% S                        GlobalDistObj := part.globDestination;
. p' m' x# L) Q                        assignLObj := rgmanager.rgAssignL;
/ c& J4 g5 K( l' J                        row := assignLObj.getRowNo(GlobalDistObj);
+ {: G" W! H+ E# R" S% K6 o, F                        if Row = -1 then -- since 70
* I1 t3 v  @7 O3 G4 N7 F                                if lan=1 then
9 D4 M& E; N) B5 n/ z) b) p9 w                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),! V# D7 n7 }+ F+ t
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
! \# [3 x5 `2 Y% x# i2 b) o: d$ K                                else
/ f% ~2 ]) \! ], S% a# H" [                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
4 @- T* X2 E$ y% P                                                to_str("in docking station: \"",?.~.name,"\""));                               
; h3 }" E* e7 I/ b1 E                                end;5 |, s3 T, V5 V+ `, ?/ V( F
                        else) X) N& g3 Y9 j2 j
                                @.Destination := assignLObj[1,row];" ]% X- t3 M! C5 f" r- N
                        end;                        . @/ f* b# Y, Z2 N: `6 W1 [
                        newDirection(@);
- Q6 L* ^$ N8 C) X                        @.HasOrder := true;
( l1 }8 \& p, Z+ d' p                end;
, p; `; r6 q$ a# M6 s        end;
8 B& |  }$ @* K) x' Mend;        -- of the method  R8 z6 @9 v$ |% l2 p
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
8 o9 N1 p4 L7 i/ }4 ?$ o+ H7 Y& O5 M/ w7 [
这是AGV_putin中arrive的method。
" r: w/ @! S- {% p" R# x( ?3 ~) n( R* C. c- W, c& b
当到达物料速度越高时,这个报警更多,
& ~1 s! e# z; u可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。# `# ~3 g0 l8 o3 Z$ R0 s
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?% u' y8 U" P% @2 d  U# Q" |( S

- }  d! B& X3 V1 |6 R- P7 c另外一个小建议,就是move,所有的move都可以这样  s4 |& r& t7 q7 a
if not move() then debug end
5 L! E; k' B5 P  \; S4 \这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
9 X/ R( S: R0 P: p- s9 Pplant simulation中的free libraries有AGV模板,& P5 Q! S8 I2 b3 V0 ~) a
里面也有案例。
! p9 @# S  h8 o5 U0 j1 t我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
2 v& h2 H5 l( r6 T- @% x
% u  E) p5 `9 |% J# {4 e我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
8 l! f! E& h" n' L; B# Z4 q- J
: e2 H4 h3 v5 S) ^( I* L* l那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 6 g6 G8 F- Q- X+ @. Z" d) B* g
这是AGV_putin中arrive的method。
7 t/ T* l) B, ^! B' U
: R. \" A  F2 m& X1 g/ z当到达物料速度越高时,这个报警更多,
( X  e; h8 _9 U5 w
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-24 02:47 , Processed in 0.015811 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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