设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6871|回复: 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'
5 h; N7 X8 e* E0 s: a. d" R*/+ P( q8 G9 E  |! Q9 s- q
is( M2 r6 g6 a, D6 r% p
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;9 E3 j0 f4 J3 h  i/ N/ [4 ^
do
3 h/ c9 r3 {2 d% l0 {% Q, @        Lan := rootfolder.Internal.Tools.AOLlanguage;
, C8 M: D: Q9 C: U" V$ S3 }        if current = @.Destination -- else return
" p" X; M  Y( \; h+ }7 ^% A        then
: @/ S- h; y( y                @.Destination := void;
3 `: H( \* d% r                if @.occupied then
1 K9 g2 L" M# a) W                        part := @.cont;
; @$ ~1 q. F" [% m' K' \  P                        @.transpOrder := void;
) @2 I9 a/ u8 b5 V1 E- [1 e+ m                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,  s4 r- u4 y/ n/ @1 z" u% T& o. [
                                @,root.eventcontroller.simTime);4 X# j0 O, u4 q- t$ ^
                        @.HasOrder := false;
% F4 a' D' y9 J7 v: W3 H( H+ r* S                        @.DrivingHome := true;
* B) y  v2 I% q! z) x$ D                        rgManager.tryToStartTransOrder;
7 C" s- O: s6 M5 L$ @4 i( }( t' s6 _                        if @.Destination = void. w% y, I1 k! b, p
                        then -- no transport order for vehicle @
* \7 C5 C6 D" j5 ]# s                                @.Destination :=. F5 @; A) w$ o# R/ ]! n
                                rgManager.nearestFreeStation(@,track.~);
' a5 @+ j* i7 a                                newDirection(@);   
' I) s' }* p2 h; N$ f3 a                                if @.Destination /= void then
& e& Q) ~( N4 B+ V3 t0 _' j/ q                                        @.Destination.NumReservation :=, l, S  U5 S6 [
                                        @.Destination.NumReservation + 1;
' _' u7 P2 o, q6 K7 {9 j                                end;  n- l. v9 T6 l+ e0 `
                                @.CurrIcon := "drivingHome";
0 t4 v1 y/ v+ Y/ t7 I6 `                                @.DrivingHome := true;" K% |: q) X* M- d
                        end;: j# R8 W6 {3 M! U
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station/ \1 H$ J) ]# `6 j4 k" ^0 Y7 H
                        part := @.transpOrder;
+ c' t) ]* v" y                        part.move(@);-- load part
6 Q/ K7 {* {- o& ?1 r0 g; U" \  g                        @.CurrIcon := "load";1 e$ B4 x6 n4 B1 A1 z" }
                        GlobalDistObj := part.globDestination;
( F. e. y; g6 F4 p/ Z4 O                        assignLObj := rgmanager.rgAssignL;6 m: v8 K, X2 n: D/ J* r& S
                        row := assignLObj.getRowNo(GlobalDistObj);/ Y0 S2 R1 B, I# V2 l9 V
                        if Row = -1 then -- since 702 h% c0 C& f: }9 S$ W8 J' u+ ?
                                if lan=1 then
7 _+ @4 P9 l% e$ y: d# m                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),* e0 I3 T; \# s% ~
                                                to_str("in der Andockstation: \"",?.~.name,"\""));2 _% @2 R- `( @0 U1 g! J
                                else' i6 }4 N* A$ @+ L' u# ^
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; z) ^8 g& O, `& n/ @
                                                to_str("in docking station: \"",?.~.name,"\""));                               
# @2 {/ T# L; U6 J* C# `7 ~                                end;; c" g) D8 N' G, @
                        else
% i, B4 ^% Q8 m( v1 j                                @.Destination := assignLObj[1,row];
6 `2 A5 \7 c8 y/ \0 P                        end;                       
5 ?) M% Z0 N6 B                        newDirection(@);
( t' Y( C% @) A& ^* w& `3 e* V# x                        @.HasOrder := true;
. H& v% |2 l+ N# [! f3 Z: S" @                end;6 N5 q# x. K3 H; Y, F& X9 Z
        end;
; u# o$ P  c1 \- _1 Oend;        -- of the method
: K/ X4 e% Q& r; S
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
+ a. O  Q, D- }5 f! M' p
7 \7 ~% i1 ?" ]/ u* z/ C( m7 w* T这是AGV_putin中arrive的method。
( F, {0 `1 K- Y( e2 ?, j+ x: Y7 L1 m3 Z* [& [. G+ E
当到达物料速度越高时,这个报警更多,: p7 [1 [/ J$ h
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。+ Y& f) S4 ^3 N2 I# Q0 v9 |
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?3 e/ m; d" \# m) q) S" l; C( X
% `. D) j& n0 l" l; z1 B. ?
另外一个小建议,就是move,所有的move都可以这样9 m; O" Q0 E( J( `
if not move() then debug end
) Y+ W# {+ B! C6 o这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
6 x' [; g. Z5 ~/ Nplant simulation中的free libraries有AGV模板,( v6 [* t* T$ U. Y7 Y7 \  m9 d. |
里面也有案例。
# c3 g, A% f- L, O我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
- A3 G( F! R. v0 c9 J; ~+ F; m
0 {5 f0 S! d1 V1 z我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
6 b  P" Q" l9 c3 ?& D! u& o0 }: j+ h& X0 C3 n
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ) G% ?. o9 a- F1 K
这是AGV_putin中arrive的method。
. k( P  A; `  L# f5 t1 u
9 P4 B  j, G  S7 R. b当到达物料速度越高时,这个报警更多,
4 F# [8 [4 J! B  U7 @( O% T& I% I
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-3 22:08 , Processed in 0.018218 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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