设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7527|回复: 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'' l% S* Q( k. j; a
*/
6 L, c  Y$ R6 Cis
: H* m: `: }) W* I- X# x        part, GlobalDistObj, assignLObj:object;row,Lan:integer;3 w1 `6 S+ ]! u! i- n; Q+ W
do
1 F7 v/ M$ v' z* \2 e# N        Lan := rootfolder.Internal.Tools.AOLlanguage;
/ Y" X4 M! F* r; M( B! V8 M        if current = @.Destination -- else return
, M9 H+ i6 o9 Z5 Q        then% I! E8 I& r5 F/ s' `# @
                @.Destination := void;
7 u- k9 H9 P7 v- I0 W% g                if @.occupied then
( T2 W$ \9 _% ^+ i: w: V, Q2 d; p                        part := @.cont;2 j0 |( O+ t' p% v5 \% Q4 Z
                        @.transpOrder := void;- z5 w5 D: ?6 ^; `. l
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' o. C$ X- f3 F+ N' ]! L! b6 W8 f
                                @,root.eventcontroller.simTime);
. h. Y; m- s8 p9 \/ c4 s, w                        @.HasOrder := false;& i6 w) S6 u$ J! K. V" w% I
                        @.DrivingHome := true;8 U+ D$ F6 }1 w6 C4 `. N4 t* g  t
                        rgManager.tryToStartTransOrder;4 X7 T3 o9 O4 y3 \2 ^
                        if @.Destination = void
! E6 l: Y" \4 z0 Y3 g9 ?8 r                        then -- no transport order for vehicle @1 {) A) f( g2 w# N) b
                                @.Destination :=
4 N2 {7 J3 k; _- c- C/ K+ a7 h! G                                rgManager.nearestFreeStation(@,track.~);
6 R# F7 L3 C6 f5 f0 [- p0 Z! X                                newDirection(@);   / h. \% h0 Y3 _/ x3 C6 {# q3 n) b
                                if @.Destination /= void then! I! L! F  u3 r  H6 y  ~# ~
                                        @.Destination.NumReservation :=
9 M; U6 O1 R! U: z' w                                        @.Destination.NumReservation + 1;
$ l. Q( R7 @2 ^: _; z                                end;3 f5 H8 N, n/ j- {
                                @.CurrIcon := "drivingHome";
7 e6 ]0 o! i# F7 h& T                                @.DrivingHome := true;8 D8 i3 {1 t. _, f: \
                        end;* D2 G; P* G' E
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station: G7 ]9 T9 A( p( D* M) S
                        part := @.transpOrder;6 Q  Q6 H5 g( d% h' E! G* y3 i. y
                        part.move(@);-- load part
! r" l0 W1 F1 z  [5 x3 ?                        @.CurrIcon := "load";& y3 ~7 t8 W8 ]" |
                        GlobalDistObj := part.globDestination;
: E: h9 h% i$ k. E! k8 A                        assignLObj := rgmanager.rgAssignL;
$ d3 e; i% b- v* s5 u                        row := assignLObj.getRowNo(GlobalDistObj);
8 Q6 j; {1 k+ y2 O- I                        if Row = -1 then -- since 70
# H' k$ p  R& L3 b3 p                                if lan=1 then* c' R; c& t0 B1 x
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),3 L$ p: K+ r: z. c$ I
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
4 m. k0 V- _, U/ y& _: S                                else
0 [7 p0 z5 z4 X/ W                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
# T# q2 t( h! L2 s  }2 s- s                                                to_str("in docking station: \"",?.~.name,"\""));                                7 y+ j. F# d* }% P3 D. w
                                end;
3 F- m- u3 y$ i7 @" b4 |& C, k                        else- t3 m* Z( e" d: K0 Y2 R& i, y
                                @.Destination := assignLObj[1,row];- H$ G' M  k$ O
                        end;                        : w' W/ i* ~; Q: x
                        newDirection(@);# P! N( D( i9 e4 T. n
                        @.HasOrder := true;
0 d8 K, ^; F! p/ T0 ]8 E, h                end;- R% P! B& Y1 ]5 t; v0 |
        end;* B/ @- k6 V0 N( M3 U
end;        -- of the method
: f( k! J2 g9 q) a0 @
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
" ^; F! T$ Y" A; T
. c- @$ t8 R, }这是AGV_putin中arrive的method。' W' T, c3 K/ W& p' {% B
) o2 T9 |0 ^4 w) E+ |- w" C$ m3 }
当到达物料速度越高时,这个报警更多,
3 C: ]9 k+ w- t" m: u% e可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
  Z7 m" z( s9 g  J5 I+ \( [程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?) t1 c' i7 l; P: K* B5 i
+ T  _6 k7 L7 N+ F$ i0 I
另外一个小建议,就是move,所有的move都可以这样
3 {0 w& d' c9 D+ `, I3 Yif not move() then debug end
4 x: p1 T, d: h这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。6 H! X, K+ E9 l4 u5 ]3 h, L" R
plant simulation中的free libraries有AGV模板,
  U! |7 s4 l! k6 [* Y) f4 H里面也有案例。
6 k& p' z; L; V* O3 F我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( J1 @; q! ], ?6 o

) Z6 w& a6 v( P7 V" ~6 }7 L; [3 Z我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
( Z; L% ?1 W- K/ S# V. I
& O) \+ E  {0 m) t( i! ]% d那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 7 f! Q) n; R6 H0 S/ W6 z/ a; \
这是AGV_putin中arrive的method。1 T* t) l2 U" H: ~- x) x( |) P

5 V+ P1 s& h9 N2 }当到达物料速度越高时,这个报警更多,

) ~0 T" h) b3 z" M; N, b9 z7 M另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-16 19:10 , Processed in 0.020719 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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