设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7734|回复: 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'
  s! v' c% G# g8 D+ V5 T*/
  Q; K- U6 }$ B4 F* M& }7 Y* b' m/ g% s1 Ois
# Q6 V) A9 ~( c$ \4 b        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
8 \- o! w9 q4 O+ r2 A4 tdo$ B5 ?) s. T2 o* ?$ [) B4 b
        Lan := rootfolder.Internal.Tools.AOLlanguage;' I( ?1 j% r" k' u" w6 I
        if current = @.Destination -- else return
- [% V7 Z; C: P8 ~/ s        then
  y3 J" X) o5 t6 t6 m: N                @.Destination := void;. K1 @% g0 k5 O4 d: O
                if @.occupied then  ]! t# F4 W1 k- x
                        part := @.cont;; _. K. _9 Z: ?# d0 {
                        @.transpOrder := void;
9 e. c5 A+ g0 W* \                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
7 M1 x- n* v1 y- ~; B$ G4 @- k4 X                                @,root.eventcontroller.simTime);  f6 l2 g9 b% ^5 Y! W8 _: o
                        @.HasOrder := false;
* _. h" ^) q% A& I7 O$ C                        @.DrivingHome := true;8 ?7 P0 V3 ~8 C
                        rgManager.tryToStartTransOrder;
( ^- C. \( \! C  p, ?) c                        if @.Destination = void
% O. ~. L. C' J                        then -- no transport order for vehicle @3 H5 s' v2 \* k  [+ m$ `1 u
                                @.Destination :=! H* f; W& U9 c' u" V; z
                                rgManager.nearestFreeStation(@,track.~);
  d! o" h$ d1 g& A                                newDirection(@);   % D1 k; v8 w3 ?# w8 u/ s6 [
                                if @.Destination /= void then3 X3 Z0 P3 j! M" A$ k
                                        @.Destination.NumReservation :=$ M/ b: `  r  ]9 I5 U8 u/ `
                                        @.Destination.NumReservation + 1;
, L+ c5 R) {& F. c& d                                end;
9 r* z$ E! N& F7 [4 f; E: }                                @.CurrIcon := "drivingHome";" I- `4 r0 N7 r& ?
                                @.DrivingHome := true;
- q4 A  P0 H; a4 H: @5 b3 V                        end;
1 l  b; p+ Y% y9 l) C! _                else -- the vehicle @ is empty, both vehicle and part are in the same dock station5 E  e6 v' H" j: c& J
                        part := @.transpOrder;
" b$ K) l0 {2 ]4 A! E3 h                        part.move(@);-- load part  F8 S8 b# y* M, [3 Q! S! f6 x
                        @.CurrIcon := "load";0 t! S' u/ S# f5 ]9 f: I+ [
                        GlobalDistObj := part.globDestination;
' x4 T* u$ i* ]# g# U7 d; x                        assignLObj := rgmanager.rgAssignL;, a2 R% w& B& F1 b* r/ t+ u
                        row := assignLObj.getRowNo(GlobalDistObj);* u4 R$ a" Z# @6 H) V6 b
                        if Row = -1 then -- since 70  j7 T  u- y: W+ v! ^- l3 s- S
                                if lan=1 then2 Y; m( K& F2 G
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),4 l; v5 M8 Y7 ~! F  d
                                                to_str("in der Andockstation: \"",?.~.name,"\""));9 c+ D+ v1 K: Z" t3 }
                                else# T% c! _9 l, v/ w
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
* p% v  i) Q; y                                                to_str("in docking station: \"",?.~.name,"\""));                               
+ K3 M) z' D/ e                                end;$ p& N3 R9 K* [+ I$ c7 W
                        else
. `! x3 l0 D. {1 n: S. m7 x                                @.Destination := assignLObj[1,row];' b. @& G  v, V' s
                        end;                        4 ]5 {' S0 F+ O. h8 M
                        newDirection(@);/ {' m, x) s# h, N% J
                        @.HasOrder := true;
* c& p8 B/ {# b) _7 S7 z                end;
0 J4 a9 ?" u6 k+ m        end;" i, P- X( @. y6 P
end;        -- of the method
6 l  n3 B4 x9 q6 m5 Z% s" ]$ }5 @
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
0 E% D3 \: N8 I( O9 @" Z$ n
; M9 G2 K3 i# F; P$ Z- _3 s& A# y这是AGV_putin中arrive的method。
4 Z" B2 s5 [* K; L, K3 Q7 ~; d, p# l
当到达物料速度越高时,这个报警更多,  \; U7 A: n/ m+ F7 @
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
) E( l7 J; j- W程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?1 ?+ @  T4 L7 H. ^4 ^% ]

, q3 Q8 |4 c- v. q# q8 ^# W另外一个小建议,就是move,所有的move都可以这样
/ w" b- w+ A% `1 D# b# u, e, Bif not move() then debug end
1 o; H- Z. a$ q. o2 `这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
8 T. @: x8 }( r, [" e2 jplant simulation中的free libraries有AGV模板,
  ]& T+ q4 T: v" M; l里面也有案例。/ d; y, l2 m5 U
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。1 j: A! `6 E2 u+ |6 m" c) z) B( v
8 T5 v- J4 }& _5 x
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 5 J7 T4 g) ?8 i* Y& w' s7 l1 ~

: d# w$ \; Z( ]9 o那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
0 T0 k2 s& r# k" v# }# E/ F5 e这是AGV_putin中arrive的method。  H4 A. n$ h6 q9 Q5 g
' S  h0 L$ @' J- g
当到达物料速度越高时,这个报警更多,

/ B; a3 Z4 l+ v+ V- w另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-26 16:58 , Processed in 0.018418 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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