设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5876|回复: 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'
) O& c" l/ ~  `1 G5 F*/) e! `" q9 U% C
is
3 f  W5 u) l4 t7 {5 a" F0 j        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
8 R: c8 m) \, o, o! l7 s# V/ V0 m  wdo
5 t% o0 Y: X8 E$ V+ E+ C; f        Lan := rootfolder.Internal.Tools.AOLlanguage;- G' `7 y2 a- s/ A* ?: N( @: g
        if current = @.Destination -- else return
0 B" M# [9 S! L        then) g6 S# I. ~; b# Q. I
                @.Destination := void;
% Q/ ^7 |8 g# u0 S6 |5 b% n1 U                if @.occupied then
# x/ p- i+ f3 l& a                        part := @.cont;
  u% A) E! h1 u9 g+ E                        @.transpOrder := void;8 u, P2 T" `) n
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
( l* T4 f4 C* I. R& r" a6 B                                @,root.eventcontroller.simTime);
2 U0 z9 B# P, U4 U" i# Z                        @.HasOrder := false;
3 _  {; b# |+ Z. ]! X; \( u                        @.DrivingHome := true;
3 i/ Q5 I6 ]# M  n' s, q% ^0 E                        rgManager.tryToStartTransOrder;" A) t5 T" V$ v2 q3 k# u
                        if @.Destination = void
2 w5 F9 |2 Y4 J* Q3 Y- p                        then -- no transport order for vehicle @
  K8 e( C+ J8 _7 f6 }                                @.Destination :=
* u* A; s/ |5 S( A! \% [$ v                                rgManager.nearestFreeStation(@,track.~);
, n( b. n8 I8 M3 t5 ~% k                                newDirection(@);   
, l1 D$ p8 p# h, J0 m9 d/ J                                if @.Destination /= void then
3 \! ?" Y3 w0 R                                        @.Destination.NumReservation :=" g' L+ y0 l2 U2 D% C
                                        @.Destination.NumReservation + 1;
# _- ^+ Z. J, u3 ]8 b7 |3 k                                end;
. X+ s( s- V* H$ L2 P( F                                @.CurrIcon := "drivingHome";' u8 K* F, |& p6 A
                                @.DrivingHome := true;
7 E% v% R5 s& t                        end;7 y$ x' q7 z- C. B8 X- Y9 u
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station! o9 L8 t: C4 i. ~* J
                        part := @.transpOrder;: z. b7 W* f7 Q; X4 G' e
                        part.move(@);-- load part
( I( @! p8 C; F' H! V$ p                        @.CurrIcon := "load";6 j& e, v. ]- T" S
                        GlobalDistObj := part.globDestination;
# x5 T% i/ ]3 P                        assignLObj := rgmanager.rgAssignL;
; z. X& E- U7 }1 u! d5 S                        row := assignLObj.getRowNo(GlobalDistObj);, C8 K# Q8 X- C, f( R5 j+ ?7 K" ^
                        if Row = -1 then -- since 70
2 C# _5 l/ j6 @' K# h1 ~                                if lan=1 then
; n4 L. ]( B- z( H( w                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),  _- F1 G3 D# n+ T
                                                to_str("in der Andockstation: \"",?.~.name,"\""));+ g4 u6 p3 L/ z" h- Y0 E! Z
                                else
8 M' G" y& S0 e; e$ a' J' N% D6 j                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),2 A) F0 C% Q7 ]4 y  z- G
                                                to_str("in docking station: \"",?.~.name,"\""));                               
1 _$ L2 p% Y" A1 v! A" l                                end;, _! C$ i' t8 `/ w4 w& }3 E
                        else! T# A* |, n$ E6 n2 t( v
                                @.Destination := assignLObj[1,row];
3 o- Q) j7 ~9 v# ^) {                        end;                       
$ N  }2 R2 b1 }! e. k8 |                        newDirection(@);( S" ~+ \+ P* d* ~9 J0 N
                        @.HasOrder := true;+ E4 s- f' k# P6 J* W' Z( `
                end;6 B1 k9 @' ~7 R. D' h: w2 P9 Y
        end;/ g% Q4 F3 i* {: y: W
end;        -- of the method9 r- A! q% @. S
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
. k5 h% n( `8 f. S
" X* Z# h& Y1 M( C3 F这是AGV_putin中arrive的method。' r6 u, c, O& Q1 y7 ?! N

0 q6 b, l6 t) @' ?; [当到达物料速度越高时,这个报警更多,7 H: x6 B2 f# g
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
% |* w+ S/ k3 f% C程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
) T+ P5 }3 U4 d
4 ]/ |) A9 g1 L另外一个小建议,就是move,所有的move都可以这样0 l: s; |6 `- ?! P, Z8 D
if not move() then debug end
9 z9 g9 T4 E" d$ M0 P: x( n这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
$ k6 y/ M; |8 gplant simulation中的free libraries有AGV模板,4 n) F: T- f8 S) t1 u- @  D
里面也有案例。
* w( Z! g8 _' a4 Z# N/ ~$ r4 y, ?我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。. ?, q2 b* r7 x  B  C
: d1 c9 E  J- i* G. c2 _7 r
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 - t' ^( Q; n2 \4 H6 g
4 G6 d: D) o0 V1 [
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 " E/ V6 ]; E+ j* G3 E: J
这是AGV_putin中arrive的method。
. t% q4 y% [* k
) J. H  U  I5 E当到达物料速度越高时,这个报警更多,
9 b4 L- R8 |2 o0 B0 z, y* t4 A
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-12-28 23:00 , Processed in 0.018664 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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