设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8446|回复: 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'  f6 j, G% j% u7 n
*// \! V; P) f0 A1 [
is% t: f3 w, B9 ?4 Q  I! N
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
/ u$ k/ `$ b; f. s, Pdo. b6 Y/ j  g% k$ r! U! F% k, T
        Lan := rootfolder.Internal.Tools.AOLlanguage;
2 c* m% {7 G/ x* ^6 i; Q) Y/ f0 t1 Q        if current = @.Destination -- else return
9 w* [! S6 k+ G% X0 G1 c        then. q5 b7 c& {& s! Q5 M8 _
                @.Destination := void;
* G6 c) Q% B2 i! F. Q; ]: r                if @.occupied then
) j6 j/ B& O/ u- R1 D. c                        part := @.cont;
; N! z7 `1 u( ~; j. U; H1 B0 _                        @.transpOrder := void;
! E) S, d' P! e                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,4 k9 g% B# g  l" u. Q4 F5 [
                                @,root.eventcontroller.simTime);
: f7 p. \0 }  m) t                        @.HasOrder := false;
+ {/ W1 [# Z6 l. M9 {3 w2 G                        @.DrivingHome := true;
" A8 s& P, X/ i$ N& P! S                        rgManager.tryToStartTransOrder;
. \$ T; j6 e- o, Q                        if @.Destination = void  R  C# p/ ?, k2 I# [* w* ~* z
                        then -- no transport order for vehicle @" u2 H4 w$ }) j* s* E  l& M4 Q) \( @
                                @.Destination :=. ~2 A0 o6 ~4 b, O' C2 ]
                                rgManager.nearestFreeStation(@,track.~);
" w8 o7 @) Z0 V' u                                newDirection(@);   
; y( S% k$ d4 _/ z, x1 x. a                                if @.Destination /= void then
+ D* B: `" H) X- o+ F                                        @.Destination.NumReservation :=
/ W' [% G3 {- \1 \4 N9 A: j                                        @.Destination.NumReservation + 1;
) i: D5 V1 b( V1 ]: P  F+ ~! i1 f1 t                                end;( L/ p- Y6 ~5 s: q
                                @.CurrIcon := "drivingHome";% \; z! Y/ j; m
                                @.DrivingHome := true;
8 r: T$ W/ V/ \+ M                        end;
' _3 ?, F  T0 M: a0 R/ P                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
; v1 ]) ?% J$ p                        part := @.transpOrder;! c8 G4 T2 Z1 o: H
                        part.move(@);-- load part3 m% D% P  r  a2 p* `+ `
                        @.CurrIcon := "load";
8 ~4 P9 \4 \& F, M. _                        GlobalDistObj := part.globDestination;
0 s$ R. p. W1 q) O7 K  Y! _                        assignLObj := rgmanager.rgAssignL;
3 E: O  J( W3 f. }# t                        row := assignLObj.getRowNo(GlobalDistObj);4 j1 s3 C+ N1 V& s0 @
                        if Row = -1 then -- since 70, c; o" y( `2 R9 S( j: V
                                if lan=1 then) O3 d2 c# u/ o; K: R- _
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),6 m3 T5 R1 l. |9 r5 x' j, K' z/ i
                                                to_str("in der Andockstation: \"",?.~.name,"\""));! y  \2 A  H8 S3 E* n
                                else
- U$ l) W. t( s                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 s: n3 h+ n/ R7 q/ j
                                                to_str("in docking station: \"",?.~.name,"\""));                               
* @% A( ^2 H# q( {- C                                end;
4 {3 i* |7 v" n7 z' O! w( p& \                        else
/ S6 N# c( a" \3 [4 A. k. W                                @.Destination := assignLObj[1,row];
& F8 \0 u2 V* w6 v# s' E                        end;                        # x4 R$ D& s" T
                        newDirection(@);
0 N2 t! P9 D# Z3 t$ V                        @.HasOrder := true;
& c2 c9 f4 j8 t% B                end;
' d! x) R' {9 `7 c; O" b* F% X        end;
& |5 M. F! c: n) B& z/ jend;        -- of the method
# l6 w' H! T; ^6 J4 l6 o
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
. {. R9 q2 y# y, X, \: m- Z  e) o) e3 l# z* y
这是AGV_putin中arrive的method。* N* o7 s6 `& R# M8 L0 F1 X

5 x5 u2 c9 C- D$ I5 X% l, G& J当到达物料速度越高时,这个报警更多,8 w- k0 S4 `" y; ~2 c- ?
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: G6 U  F9 q. X% y+ a
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?) h% W0 [9 G- }& b" F( K& C0 [3 |, W6 Z; r

$ |# q1 E# g( b" M: F/ S* F: z另外一个小建议,就是move,所有的move都可以这样/ F: f4 A/ u1 D8 `
if not move() then debug end
! }  P6 ^$ U3 W9 _9 Z  u0 q% A这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。/ A: z- ^2 F, m: F+ q! `
plant simulation中的free libraries有AGV模板,
% _5 q2 S7 N# G" h5 A7 i& y. c里面也有案例。+ }$ D4 S- O6 m7 @
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。9 W& D+ w6 |" r& ^" W1 [
( f1 y0 U$ p# n1 a
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 7 w4 Y! H. r/ q0 v$ M  |3 j

5 s7 T( I! ?) @. [8 m6 J那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
- s1 W# _4 N  R- K5 X2 s6 N这是AGV_putin中arrive的method。
1 W9 n; g7 i3 @( |$ I& f/ h
# h" E% c$ M* F) F0 U1 i3 B当到达物料速度越高时,这个报警更多,
3 ^, U! n' i7 D/ i# D8 \) f" W
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-4 10:52 , Processed in 0.019011 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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