Sponsored by IEEE Singapore SMC, R&A, and Control Chapters Organized and invited by Professor Sam Ge, NUS Wireless Sensor Networks for Monitoring Machinery, Human Biofunctions, and BCW Agents F.L. Lewis, Assoc. Director for Research Moncrief-O’Donnell Endowed Chair Head, Controls, Sensors, MEMS Group Automation & Robotics Research Institute (ARRI) The University of Texas at Arlington F.L. Lewis, Assoc. Director for Research Moncrief-O’Donnell Endowed Chair Head, Controls, Sensors, MEMS Group Automation & Robotics Research Institute (ARRI) The University of Texas at Arlington Discrete Event Control & Decision-Making http://ARRI.uta.edu/acs Discrete Event Control $75K in ARO Funding for Networked Robot Workcell Control $80K in NSF Funding for research and USA/Mexico Network Objective: Dr. Jose Mireles- co-PI • • • • • • • • Develop new DE control algorithms for decision-making, supervision, & resource assignment WITH PROOFS Apply to manufacturing workcell control, battlefield C&C systems, & internetworked systems Patent on Discrete Event Supervisory Controller New DE Control Algorithms based on Matrices Complete Dynamic Description for DE Systems Formal Deadlock Avoidance Techniques Implemented on Intelligent Robotic Workcell Internet- Remote Site Control and Monitoring USA/Mexico Collaboration Exploring Applications to Battlefield Systems Intelligent Robot Workcell Man/Machine User Interface Texas USA/Mexico Internetworked Control Matrix Formulation: Definition Based on Manufacturing Bill of Materials DE Model State Equation: x Fv vc Fr rc Fu u FDuD Where multiply = AND & addition = OR x is the task or state logic where Fv is the job sequencing matrix (Steward) Fr is the resource requirements matrix (Kusiak) Fu is the input matrix FD is the conflict resolution matrix Job Start Equation: Resource Release Equation: Product Output Equation: Vs Sv x rs S r x y Syx Meaning of Matrices Resources required Prerequisite jobs Next job Fv Steward’s Task Sequencing Matrix Conditions fulfilled Next job Sv Next job Fr Kusiak’s Resource Requirements Matrix Bill of Materials (BOM) Conditions fulfilled Release resource Sr EXAMPLE ARRI Intelligent Material Handling (IMH) Cell 3 robots, 3 conveyors, two part paths Layout of the IMH Cell IBM robot R1 Conveyor bidirectional B3 Conveyor unidirectional X1 X9 A B A B1 B X8 X2 X3 M2 X4 ADEPT robot R3 M1 machine X7 machine X5 X6 B2 conveyor PUMA robot R2 Part A job 1 Part B job 1 Part A job 2 Part B job 2 Part A job 3 Part B job 3 Construct Job Sequencing Matrix Fv Used by Steward in Manufacturing Task Sequencing Part A job 1 Part A job 2 Part A job 3 Prerequisite jobs Next jobs Part B job 1 Part B job 2 Part B job 3 Contains same information as the Bill of Materials (BOM) Part A job 1 Part A job 2 Part A job 3 Robot 1- IBM Robot 2- Puma Robot 3- Adept Conveyor 1 Conveyor 3 Fixture 1 Construct Resource Requirements Matrix Fr Used by Kusiak in Manufacturing Resource Assignment Contains information about factory resources Prerequisite resources Part B job 1 Part B job 2 Part B job 3 Next jobs More About Fv J2 J5 J6 J3 J1 J3 J5 J4 1 0 0 0 1 1 1 0 0 J4 Two 1’s in same row = Assembly J2 DECISION NEEDED! J1 J6 Two 1’s in same col. = Routing (Job Shop) More About Fr R1 J2 J5 J6 R2 R2 R3 1 0 0 0 1 1 1 0 0 Two 1’s in same row = Job needs multiple res. Two 1’s in same col. = Shared Resource J5 R3 J2 R1 J6 DECISION NEEDED! Controller based on Matrix Formulation Resource allocation, task planning, task decomposition, Bill of Materials Dispatching rules Matrix Formulation Discrete Event Controller External Events Start jobs Start resource release Task complete Workcell External events present Jobs completed Resources released Tasks completed uc Dispatching rules Rule-Based Real-Time Controller Controller state monitoring logic x Fv v Fr r Fu u Fu c uC .. . Job start logic v S SV x Resource release logic rS S r x S y x logic Tasky complete Parts present u Parts in pin Start tasks vs Start resource release rs Output y Plant commands Work Cell Tasks completed vc Resource released r c Products pout Plant status Advantages of the Matrix Formulation • • • • • • • • • Formal rigorous framework Complete DE dynamical description Relation to known Manufacturing notions Formal relation to other tools- Petri Nets, MAX-Plus Easy to design, change, debug, and test Formal deadlock analysis technique Easy to apply any conflict resolution (dispatching) strategy Optimization of resources Easy to implement in any platform (MATLAB, LabVIEW, C, C++, visual basic, or any other) Relation to Petri Nets Jobs complete Resources available Trans. Trans. Fv Transition Next jobs Sv Fr Transition Release resource Sr Example r1 t1 pinA p1 t2 p2 t3 poutA r2 pinB t4 p1 p2 p3 p4 t1 t2 t3 t4 t5 t6 0 1 0 Fv 0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 p1 p2 p3 p4 t1 t2 t3 t4 t5 t6 Sv T 1 0 0 0 0 0 t5 p3 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 0 t6 p4 r3 pinA pinB r1 r2 r3 Fr 1 0 0 0 0 0 0 1 0 0 1 0 0 0 0 1 0 0 Fu Sr T 0 0 1 0 0 1 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0 1 0 0 poutA poutB r1 r2 r3 0 1 0 0 0 0 poutB Sy T 0 0 1 0 0 0 0 0 0 0 0 1 OR/AND Algebra- Locating transitions firing from current marking r1 t1 pinA p1 t2 p2 t3 poutA r2 pinB t4 t5 p3 t6 p4 poutB r3 0 1 0 x 0 0 0 x= 0 0 1 0 1 1 Fv 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 1 1 0 0 0 0 0 v 1 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 Fr 0 1 0 0 1 0 = r 0 0 0 1 0 0 1 0 1 0 1 1 , 1 0 0 Fu 1 0 0 0 0 0 so x = u 0 0 0 1 0 0 0 1 0 1 0 0 0 0 i.e. fire t2 and t4 Complete DE Dynamic Formulation Activity Completion Matrix F: F [ Fu Fv Fr Fy ] Activity Start Matrix S: S [ Su T Sv T Sr T T Sy ] PN Incidence Matrix: M S F [Su Fu , Sv Fv , Sr Fr , S y Fy ] T T T T T PN marking transition equation: m(t 1) m(t ) M T x m(t ) [ S T F ]x Allowable marking vector: xk F mk [ Fu Fv Fr Fy ] [ PI v r PO]k Petri Net Marking Transition Equation-need to add Job Duration Times m(t ) ma (t ) m p (t ) PN Marking Vector Split transition equation in two steps m p (t 1) m p (t ) S T x(t ) Add tokens ma (t 1) ma (t ) F x(t ) Subtract tokens when job complete T [O, vtimesT , rtimes T , O]T Add Time Duration Vector Tpend (t 1) diag{ m p (t ) }[Tpend (t ) t sample] diag{ S T x(t )}T m p (t ) m p (t ) m finish(t ) ma (t ) ma (t ) m finish (t ) Corresponds to Timed Places Allows Direct Simulations- e.g. MATLAB c.f. DE version of ODE23 Jobs completed by Robot 1 Robot 1 busy or idle Conflict Resolution for Shared Resources r1 t1 pinA p1 t2 p2 Which one to fire? pinB t4 t3 poutA r2 t5 p3 t6 p4 poutB r3 0 1 0 x 0 0 0 Fv 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 1 Fr v 1 0 0 0 0 0 0 1 0 1 0 1 0 0 1 0 r 0 0 0 1 0 0 1 0 1 Fu 1 0 0 0 0 0 u 0 0 0 1 0 0 0 0 Shared Resource- Two entries in same column 0 0 1 0 0 1 1 0 0 1 0 0 0 0 0 0 0 0 = 1 0 1 1 0 1 , so x = 0 1 0 0 1 0 But gives negative marking! Cannot fire both. Conflict resolution, add extra CR input and new matrix Fuc: r1 p1 t1 pinA t2 p2 r2 pinB poutA r2 p3 t4 t3 t5 t6 p4 poutB r3 0 1 0 x 0 0 0 Fv 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 1 0 0 0 0 0 1 1 0 0 1 0 0 Fr v 0 1 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0 1 0 0 1 0 r 0 0 0 1 0 0 0 1 0 0 0 0 = 1 0 1 1 1 1 1 0 1 Fu 1 0 0 0 0 0 u 0 0 0 1 0 0 , so x = 0 0 0 0 0 0 1 0 Fuc 0 1 0 0 0 0 0 0 0 0 1 0 r2 1 0 Now only t5 fires Application- Intelligent Material Handling Machine 1 Adept Puma Machine 2 CRS 12 Sensors!! ARRI Intelligent Material Handling (IMH) Cell 3 robots, 3 conveyors, two part paths Layout of the IMH Cell IBM robot R1 Conveyor bidirectional B3 Conveyor unidirectional X1 X9 A B A B1 B X8 X2 X3 M2 X4 ADEPT robot R3 M1 machine X7 machine X5 X6 B2 conveyor PUMA robot R2 Multipart Reentrant Flow Line PART B OUT PART A PART A OUT A(1)R2 A(1)R1 CRS ROBOT 1 PART B c.f. Kumar PUMA B(1)R1 B(1)R2 A(2)R1 ROBOT 2 B(2)R1 A(2)R2 Machine 1 ADEPT B(1)R3 ROBOT 3 Machine 2 B(2)R3 A(1)R3 Petri Net flow chart B1AA PAI X1 R1U1 X2 B1AS X3 R2U1 X4 B3AA B2AA M1A M1P X5 R2U3 X6 B2AS R3U1 X10 PAO X8 B3AS X9 R1U3 X17 R3U3 X18 B3BS X19 R1U4 X20 X7 R3A R2A R1A PBI X11 R1U2 X12 B1BA B1BS X13 R2U2 X14 B2BS B2BA X15 R3U2 X16 M2A M2P B3BA PBO PC with High Level Controller c.f. Saridis Jim Albus Rule -Based Real -Time Controller Controller state monitoring logic x Fv v Fr r Fu u FD u D FuC u C Start tasks/jobs uc Dispatching rules To Generate uc Job start logic vS =S v x Resource release logic rs S r x Task complete logic y =S y x Tasks: vSA Medium Level Tasks Controllers Robot 1 Task 4 Task 3 Task 2 Task 1 Robot 2 Task 3 Task 2 Task 1 Robot 3 v~SA Task 3 Task 2 Task 1 Workcell data gathering u v r p Parts out ~ p in , ~ rS , v~SB DAQ -card RS232 -1 RS232 -2 RS232-3 Analog & digital I/0 Jobs vSB rSB vSB Low level PD & PID controllers CRS controller Puma 560 controller ADEPT One controller rSA, pin Machines Sensors Robots LabVIEW diagram of Controller LabVIEW Controller's interface: Resources Fv Fr Results of LabVIEW Implementation on Actual Workcell R1u1 R1u2 R1u3 R1u4 R2u1 R2u2 R2u3 R3u1 R3u2 Discrete events Compare with MATLAB simulation! We can now simulate a DE controller and then implement it, Exactly as for continuous state controllers!! U.S.-Mexico shared research DE control via internet Texas Using Matrix DEC in LabVIEW