设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10147|回复: 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'
8 B( p& S" T4 K; b. M*/
* ^1 j+ \0 N; }is
4 m% E8 `; E" W2 }" H* k5 H        part, GlobalDistObj, assignLObj:object;row,Lan:integer;# ]& |' A# v; g6 C) h# B6 g/ p
do
  |; @( }4 J$ x. i' p# @# K8 h5 ~        Lan := rootfolder.Internal.Tools.AOLlanguage;
$ {8 U; n- I5 X6 Q* ~        if current = @.Destination -- else return
6 L$ A) E4 ]# Z: H# ]        then5 T0 Q# i2 I, B9 _
                @.Destination := void;+ T' w9 E! w) z* M! a- m( `5 ?
                if @.occupied then
5 j+ V2 Z2 s& v! I8 n0 G                        part := @.cont;
  W/ y- c2 [0 s7 p                        @.transpOrder := void;" i# t1 `  c: q2 e7 \6 ^$ K# N
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,. Y8 ^6 S0 t9 W: M  Z, ?( H: }* _
                                @,root.eventcontroller.simTime);- {  r4 _4 w$ S0 T, ?& }0 F* L$ U6 y
                        @.HasOrder := false;# u2 Q5 }- m3 \+ O/ s
                        @.DrivingHome := true;; J' n. C9 e7 B2 {: K/ J. e
                        rgManager.tryToStartTransOrder;. g. T9 c4 [9 B1 l4 V
                        if @.Destination = void0 w! @  e& S9 L$ _5 f( e  ]- _
                        then -- no transport order for vehicle @. x" ]! \' |% |# n4 w
                                @.Destination :=
, o) x" l( c7 B1 h& U                                rgManager.nearestFreeStation(@,track.~);; F2 g) o! w9 [( Q( _$ L! }* @
                                newDirection(@);   
7 C3 ~4 I" F9 Z2 c                                if @.Destination /= void then0 a/ A# ?* ?3 X& j$ H7 q! b
                                        @.Destination.NumReservation :=
! J' `" M& ^/ T0 X& r5 d                                        @.Destination.NumReservation + 1;
' ?0 A/ J% i. u                                end;3 I* A+ ^$ ?0 r- M
                                @.CurrIcon := "drivingHome";
4 s7 x) ~; I) r* ]$ V9 w                                @.DrivingHome := true;
4 o- {1 |8 {! z  J% H3 F                        end;
! M* D% M5 Z% v$ I& k4 l* B  E) E* M! b                else -- the vehicle @ is empty, both vehicle and part are in the same dock station. @1 O$ x9 g7 o
                        part := @.transpOrder;
( f% \: R+ j9 f6 R# c' y; M" z$ X! v- v2 i6 b                        part.move(@);-- load part6 S+ o4 W' n2 n
                        @.CurrIcon := "load";
6 n$ s! o+ [: C, V" Y2 Q& [                        GlobalDistObj := part.globDestination;
/ I, }1 i8 d, F4 j  K                        assignLObj := rgmanager.rgAssignL;
. [- K; `% t3 M                        row := assignLObj.getRowNo(GlobalDistObj);
; o6 [7 J8 h: J                        if Row = -1 then -- since 70
7 \% g" [9 m  _" N: z  {4 `( @                                if lan=1 then2 f9 ?" L! Q4 |! _9 ?
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
7 y; o9 T8 {/ [$ r& x                                                to_str("in der Andockstation: \"",?.~.name,"\""));
2 W8 Z! n/ E: v5 q0 i: L9 E) k4 x                                else) ]* r9 v9 f# J
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),% z5 s: @5 O' Z
                                                to_str("in docking station: \"",?.~.name,"\""));                                % ^" d' o! q1 J2 U  U. D, h
                                end;
0 L' s6 m+ q4 ~$ @$ D+ y3 O6 A                        else
- ?. y) N3 ]7 K' M" R- h                                @.Destination := assignLObj[1,row];
* Y0 v' \0 V* Z  Z3 r, c6 @                        end;                        / C2 g* ~3 u) }: H
                        newDirection(@);
2 A( ~9 ?- Z/ ^2 w4 j: H& q                        @.HasOrder := true;
! D7 `1 z1 Q" W7 \* L- ~. N                end;
7 Q* ]+ {! U2 ?" @        end;
/ ~- s2 X! q( e0 v% pend;        -- of the method# n" I9 q# B' J! v- j1 m
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
  h7 b# b$ [- V1 K
( x! q' q) \2 ]& c! K  s这是AGV_putin中arrive的method。
* ]9 s1 c, B4 i( N; R& W& Y- h1 X9 u0 {9 d
当到达物料速度越高时,这个报警更多,
3 q9 g6 `2 ]6 Y1 h3 C可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。; \, v+ [$ t# Q$ n( g2 q
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?1 d9 A* `, @, {; T: ^
9 o- K8 A9 S; Q
另外一个小建议,就是move,所有的move都可以这样5 Q5 \9 B& z" }2 t% U5 f. D
if not move() then debug end
" ^8 j! e/ X8 Z& E# j这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。5 [+ Q# o; E) B0 o* j
plant simulation中的free libraries有AGV模板,# q' q. U, o+ H$ T# i- T
里面也有案例。
# a" p( U- h- k1 u& S我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。& M+ d, p" q' r8 d# K

; A) B; c0 i# G4 f我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
% o5 H, n6 s) j4 q0 G$ T$ ^0 h4 L+ E7 l
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 7 C2 L- ?& O, E. r0 Y6 H
这是AGV_putin中arrive的method。
* ~/ K8 ]/ F/ A. Z6 t5 t+ h5 ~4 ^0 X  G- |$ O
当到达物料速度越高时,这个报警更多,

9 E! Q/ o% g9 O3 |4 s另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-16 03:30 , Processed in 0.017230 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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