PIMtg6 00

50 %
50 %
Information about PIMtg6 00
Entertainment

Published on January 12, 2008

Author: Durante

Source: authorstream.com

Slide1:  Rapid Prototyping Reliable Autonomous Maneuvering Reconfiguration Robustness Reactive Design Verification Real-time Programming Reuse of Software Components REACTIVE SWITCHING STRATEGIES FOR THE CONTROL OF UNINHABITED AIR VEHICLES Yale University Peter Belhumeur Paul Hudak A. Stephen Morse Key Research Themes: Autonomous Coordinated Motion Visual Servoing Programming Language Design With help from: John Peterson, Stephen Elliott, Brenda Ng, Samuel Elder, Alexander Potter Motivation:  Motivation There is interest at Yale in: Unmanned air vehicles (Darpa SEC) Unmanned underwater vehicles (NSF KDI/LIS) Unmanned surface vehicles (Darpa MARS) Not to mention Robocup (Melbourne 2000) We believe that autonomous coordinated motion is inherently interesting and important, and is an abstraction and distillation of the above projects. Issues: real-time control, autonomy, communications, software, - mobility, - locomotion, - planning, - sensing Recent Activity:  Recent Activity Focus on autonomous coordinated motion. Acquisition of small robots for unmanned surface vehicle testbed. Simulation of coordinated motion of autonomous vehicles. Comparison of Matlab/Simulink with FRP. Improvements to FRP and its implementation. Collaboration with OGI on FRP and other Haskell-based infrastructure. Autonomous Coordinated Motion:  Autonomous Coordinated Motion Natural behavior amongst living animals: flocking, herding, schooling, swarming Specific tasks of interest to us: congregation, navigation, “escortation”, formation motion, obstacle avoidance, dispersion, etc. Key technologies of interest: computational vision and control (visual servoing) programming language support: domain specific design Functional Reactive Programming (FRP) Experimental Testbeds:  Experimental Testbeds Unmanned underwater vehicle testbed NSF KDI/LIS grant (w/ Princeton and U. Washington) Small autonomous underwater vehicles 3D context may extrapolate to UAV’s Unmanned surface vehicle testbed Small vision-controlled robots (Probotics “Cye-bots”) Goal: no sensors other than passive vision Communication via wireless Ethernet Programmed using FRP and Fvision Example: AV Simulation:  Example: AV Simulation Goal: to move a group of autonomous vehicles (AV’s) through a barrier and then to have them surround a target at a given distance autonomy achieved via local control laws only nearest neighbor, potential fields, etc. modularity achieved via hierarchical control a “virtual circle” surrounds each AV each AV positions itself within its circle the circles position themselves within environment adaptability achieved via mode switching Simulated in Matlab/Simulink and FRP AV Animated Simulation:  AV Animated Simulation Hierarchical Control:  Hierarchical Control Coordinated Task Control Schooling Control Collision Avoidance (between virtual circles) Local AV positioning (within virtual circle) AV Animation w/ virtual circles:  AV Animation w/ virtual circles FRP (Functional Reactive Programming):  FRP (Functional Reactive Programming) High-level, declarative, domain-specific language (DSL) and environment for programming complex hybrid systems. Two key concepts: Continuous, time-varying behaviors. Discrete streams of events. Current Uses of FRP Graphics and Animation (Fran) Robotics (Frob) Vision (Fvision) User Interfaces (FranTk) Behaviors:  Behaviors Continuous behaviors capture any time-varying quantity, whether input (sonar, temperature, video, etc.), output (actuator voltage, velocity vector, etc.), or intermediate values internal to a program. Operations on behaviors include: Generic operations such as arithmetic, integration, differentiation, and time-transformation. Domain-specific operations such as edge-detection and filtering for vision, scaling and rotation for animation and graphics, etc. Events:  Events Discrete event streams include user input as well as domain-specific sensors, asynchronous messages, interrupts, etc. They also include tests for dynamic constraints (predicate events) on behaviors (temperature too high, level too low, etc.) Operations on event streams include: Mapping, filtering, reduction, etc. Reactive behavior modification. Behavior “snapshots”. Matlab and Simulink:  Matlab and Simulink Simulink is a visual programming language designed for model-based control. Very popular, very successful, and very effective. Tough competition for FRP! FRP vs Simulink:  FRP vs Simulink Shortcomings of Simulink: Visual programming is not always best. Studies have shown that experts prefer text. Logic-based control is awkward to express. Simulink lacks a “reactive semantics”. It is difficult to replicate functionality. Simulink lacks data structures and other conventional programming conveniences. It is difficult to abstract functionality. Simulink lacks higher-order abstractions. Example from AV Simulator:  Example from AV Simulator 1 -- s 1 -- s 1 2 1 2 Force Vector Vel Vector k Gain Velocity Position Position Vector Non-state Robot Vector Speed Limiter + + + FRP equivalent code: vel = integral (f + speedLim vel + k*vel) pos = integral vel rob = (pos,vel) Mux Mux vel pos rob X Force Y Force f Replication in AV Simulator:  Replication in AV Simulator Fifteen AV’s with identical functionality Expanded View:  Expanded View Simplified Replication:  Simplified Replication fn fn fn fn proc v Mux Mux out FRP Equivalent code: out = map snd xs xs = map fn args args = proc (map fst xs) xs args Data Structures:  Data Structures Another AV simulator example: finding the two nearest neighbors in a group of AV’s. No convenient mechanism in Simulink. Solution: revert to Matlab (using s-functions) – but then we’ve lost the model-level abstraction. In FRP, we can remain in the model. Slide20:  % cycle through all other robots to determine two closest robots % and apply a configuration force for i=2:numrobots xi = u( (i - 1)*4 + 1); yi = u( (i - 1)*4 + 2); vxi = u( (i - 1)*4 + 3); vyi = u( (i - 1)*4 + 4); magdr = sqrt( (xi-xj)^2 + (yi-yj)^2 ); if i ~= j, if magdr <= closest(j,2), secondclosest(j,1) = closest(j,1); secondclosest(j,2) = closest(j,2); closest(j,1) = i; closest(j,2) = magdr; elseif magdr <= secondclosest(j,2), secondclosest(j,1) = i; secondclosest(j,2) = magdr; end end S-Function Code Reactivity (where the continuous meets the discrete):  Reactivity (where the continuous meets the discrete) The ability to react to either internal or external stimuli. Critical notion for hybrid systems. Awkward to express in Simulink (often best to resort to Matlab via s-functions). Example: mode switching in AV simulation. S-Function Code:  S-Function Code %if robot is on targetside, apply force to attract it to target if ontargetside & magdrcenter ~= 0, output( (j - 1)*2 + 1) = output( (j - 1)*2 + 1) + tempk3*(rcenter - magdrcenter)*drcenter(1)/magdrcenter; output( (j - 1)*2 + 2) = output( (j - 1)*2 + 2) + tempk3*(rcenter - magdrcenter)*drcenter(2)/magdrcenter; end; %if robot is not on target side, apply force to attract it to gap in barrier r = [xj,yj]; magr = sqrt(xj^2 + yj^2); if ~ontargetside & magr ~= 0, output( (j - 1)*2 + 1) = output( (j - 1)*2 + 1) – gapattractionconstant*r(1)/(10 + magr^2); output( (j - 1)*2 + 2) = output( (j - 1)*2 + 2) – gapattractionconstant*r(2)/(10 + magr^2); end Reactivity in FRP:  Reactivity in FRP Given continuous behaviors b1 and b2, b1 `until` e ==> b2 means: “Behave as b1 until event e, then behave as b2.” Well-founded semantics. Rich algebra of transformations. Previous example in FRP: Or even better: if ontargetside & magdrcenter ~= 0 then tempk3*(rcenter - magdrcenter)*drcenter(1)/magdrcenter else gapattractionconstant*r(1)/(10 + magr^2) gapattractionconstant*r(1)/(10 + magr^2) `until` pred ~(ontargetside & magdrcenter ~= 0) ==> tempk3*(rcenter - magdrcenter)*drcenter(1)/magdrcenter Future Work:  Future Work Coordinated motion Task elaboration and analysis Control algorithms design “Monster truck” testbed Computer vision tasks FRP research (next slide) Future FRP Research:  Future FRP Research Collaboration with OGI FRP standard, FRP infrastructure, etc. Integration with OCP as “plug-in MoC” Interoperability with other OCP Moc’s Visual FRP Ability to shift between views, and edit either Can FRP be a front-end to Simulink? Performance Interpreted FRP performs worse than Simulink This will improve with algebraic optimization, meta-programming, and conventional compilation Space leaks are a problem; but garbage collection is not (it’s real-time) Execution on real-time platform FRP extensions Behavior sustainment Multi-rate behaviors Preemptive interrupts How to Hide a Flock of Turkeys:  How to Hide a Flock of Turkeys

Add a comment

Related presentations