设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5646|回复: 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'
7 J$ X7 D2 k) |7 O- K*/
' T$ @1 Q5 J8 P3 W5 l! _! b  R1 ois- y/ r6 ~! w- @$ k4 ]' N% X
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
6 Y/ H: |# P* l) Ddo
+ h& Z/ ]: o" X. i& o$ K! ^0 R        Lan := rootfolder.Internal.Tools.AOLlanguage;
7 d1 b- z! M* h, X% X9 W        if current = @.Destination -- else return" s3 w9 ]! D" a3 m
        then
6 z4 Z% V+ f0 p* s' C1 h" o                @.Destination := void;
7 `" T: f' k. y8 {7 \  N                if @.occupied then
% F8 a1 {3 `; {. |6 M/ b! [6 G, ~                        part := @.cont;2 V+ d' ?3 N0 o
                        @.transpOrder := void;
$ d' E' V6 r3 I. t  F( I( F                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,) I! N3 h& Z; m  J0 X( Y
                                @,root.eventcontroller.simTime);
  \, w) x- [5 v( W+ n1 b: g                        @.HasOrder := false;3 R, P) m% u* U8 [
                        @.DrivingHome := true;
/ J. A9 s  o; J3 O# k8 e1 a# l$ _! V                        rgManager.tryToStartTransOrder;
& n+ X; q8 f& [( ]  Z# m" M4 O2 E                        if @.Destination = void# S6 M# R5 T: S& z$ G0 p# m
                        then -- no transport order for vehicle @7 F0 k8 E4 N3 x0 B  q1 m
                                @.Destination :=
& f( i2 S- o8 k+ h                                rgManager.nearestFreeStation(@,track.~);
# k& G4 p" t  v6 |7 ^, ]: K                                newDirection(@);   ; E, D. U: c5 E5 }2 ?' `
                                if @.Destination /= void then
4 [7 Y* c% P6 o. M! M, _+ L% E  y                                        @.Destination.NumReservation :=8 p( U# V" l. v$ x. t# ?+ Z
                                        @.Destination.NumReservation + 1;
; }. y7 N. q% ]5 y, I( b" C! v                                end;; c! n  F; |. ~7 R
                                @.CurrIcon := "drivingHome";0 F7 P" w2 q; ~$ Q
                                @.DrivingHome := true;3 a' |1 X  a1 M7 [
                        end;
; f  r. q* g& t5 F% ^                else -- the vehicle @ is empty, both vehicle and part are in the same dock station" g7 g8 @: t" a7 L
                        part := @.transpOrder;9 U: I2 Z# v% T7 D7 C" \
                        part.move(@);-- load part; V9 u# _' s. |  |2 u- p
                        @.CurrIcon := "load";
- b8 @6 @5 L% U, ~                        GlobalDistObj := part.globDestination;* ~- w" w1 t* N- [0 A  T8 T& }
                        assignLObj := rgmanager.rgAssignL;
, H% X; {$ ]* O                        row := assignLObj.getRowNo(GlobalDistObj);
3 c  A) l6 y  O+ c0 m5 }! j                        if Row = -1 then -- since 700 M: \. i6 t3 _8 t" ^0 N# l( F; Q
                                if lan=1 then
( N; v' U  O9 ~1 p- y                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
5 F3 d6 V5 C! P% d/ X$ k                                                to_str("in der Andockstation: \"",?.~.name,"\""));
' v8 y+ x3 l+ r9 @5 ^( [" A                                else2 G6 j1 }0 h4 t5 ~, Y$ ~2 ]9 P7 ?
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
- e$ h3 e5 Q0 m$ P) @                                                to_str("in docking station: \"",?.~.name,"\""));                                . f& x& [8 i# \: V
                                end;
. F$ i1 v" k$ S% b( @8 q' e! ?                        else5 p3 X& C* C% g  f' s8 W0 [
                                @.Destination := assignLObj[1,row];
8 f6 a! X, G& U& h- Y  P! n7 _                        end;                        ( M, c9 L+ M- G
                        newDirection(@);6 s7 b/ W  L7 q7 Z5 P% c' I
                        @.HasOrder := true;6 `; @$ z5 [+ V
                end;
& v) w6 H& K8 w: u  R6 ?9 e" ]% R/ W        end;
9 T1 {4 H1 p( j) \end;        -- of the method
! Z' i! ]; A2 N) {+ p+ j# w. W
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 % e2 }* z2 u' h1 H  [

! Q  N4 l1 ?( [. S这是AGV_putin中arrive的method。
5 A9 A7 G" O  R& }) Y$ ]& _+ Z& w' y0 p$ o
当到达物料速度越高时,这个报警更多,7 B( ^9 A5 N' i, H4 N
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
3 b. E. V5 c1 P% J  ], {程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
0 N$ L( I  N% {  @' T1 H
/ D1 M* K' z% J3 s另外一个小建议,就是move,所有的move都可以这样) f5 g# c4 Y0 x0 H
if not move() then debug end
) |8 y5 P% J, h9 n5 D这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
+ H, h4 t: J! M0 Jplant simulation中的free libraries有AGV模板,) Q& L: D! W7 }, o2 b) Z3 K
里面也有案例。1 ^, W6 ^  Z% P0 r# ~
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( W/ x7 G% t" g- P% f: [

( B$ E! h. _5 n4 w& b/ x! u我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ( o# r5 i0 Y4 }% N8 |  }+ k! n& Y9 a

" Y9 m) Y, X$ G; U4 ^那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
. ?! f# I6 \7 O; \7 d: B# Y这是AGV_putin中arrive的method。5 ]( q4 |5 n+ p/ p% V$ M% s

; j+ f2 U+ q+ L) h当到达物料速度越高时,这个报警更多,
* c4 V, s: @+ \7 l& d4 R
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-12-11 07:55 , Processed in 0.020047 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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