textual-notation-of-model/packages/features/driving/closed_loop_driving_functional_architecture.sysml
5 view(s) · 157 declared member(s) Jump to source ↓
view closedLoopDrivingFunctionBreakdownViewsource ↓
| Viewpoint | selected (System |
|---|---|
| Framed concerns |
|
| Render | as |
| Exposes | closed |
| Source | textual-notation-of-model/ |
Hover a model element for details open raw SVG.
view closedLoopDrivingRequirementFunctionMappingViewsource ↓
| Viewpoint | selected (System |
|---|---|
| View type | MVD:: |
| Framed concerns |
|
| Exposes | reqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqreqclosedclosedclosedclosedclosedclosedclosedDE4 |
| Source | textual-notation-of-model/ |
Hover a model element for details open raw SVG.
view closedLoopDrivingSystemProcessViewsource ↓
| Viewpoint | selected (System |
|---|---|
| View type | Action |
| Framed concerns |
|
| Exposes | ClosedClosedClosedClosedClosed |
| Source | textual-notation-of-model/ |
Hover a model element for details open raw SVG.
view closedLoopDrivingModeDependenceTableViewsource ↓
| Viewpoint | selected (System |
|---|---|
| View type | TVD:: |
| Framed concerns |
|
| Exposes | ClosedClosedClosed |
| Source | textual-notation-of-model/ |
Hover a model element for details open raw SVG.
view closedLoopDrivingFunctionalInterfaceViewsource ↓
| Viewpoint | selected (System |
|---|---|
| Framed concerns |
|
| Render | as |
| Exposes | CameraEgoOperationalRouteVehicle |
| Source | textual-notation-of-model/ |
Hover a model element for details open raw SVG.
Source
1/*2 * DE4SDV closed-loop driving functional architecture.3 *4 * INC-DRIVING-001, phase 6: the functions of the candidate driving system5 * and the requirements of phase 5 each carries. Seven functions identify6 * the run, assemble the inputs the checkpoint takes, plan by checkpoint7 * inference, supervise the inputs and the plans, command the vehicle, apply8 * the commands at the actuation and publish the operational state. The stop9 * response is a mode of the one command path, not a second command source;10 * the actuation applies it itself only when commands stop arriving there.11 * Every requirement but REQ-DRIVING-014 is allocated to a function.12 * REQ-DRIVING-014 constrains how the plan and the commands are carried13 * between the functions, over Eclipse S-CORE communication, not what a14 * function does: phase 8 carries it by the S-CORE elements it places on15 * those exchanges. An allocation assigns responsibility only (allocatedTo);16 * it asserts no satisfaction. No logical element, platform, transport or17 * technology is chosen, and no safety claim is made.18 *19 * The loop around the system is a process, not a second architecture:20 * navigation gives the route, the vehicle's cameras and motion sensing give21 * the images and the ego motion, its actuation applies the commands and the22 * state observer presents the published state. Those are functions of the23 * context elements, outside the scope of the driving system, and24 * ClosedLoopDrivingSystemProcess runs the system as one action between them.25 * Its participants are the parts of the one operational context of phase 2,26 * bound by reference: the process declares no context of its own.27 * The functions whose behavior differs by mode depend on the modes of28 * ClosedLoopDrivingModes, and the conceptual interfaces of the system are29 * the ports of ClosedLoopDrivingFunctionalBoundary, whose items specialize30 * the items of phase 2. No vehicle signal specification is imported or used31 * anywhere in this package: the interface items are conceptual, their32 * quantities are ISQ quantity values, and the signal typing of an interface33 * starts in phase 8, at the port where an item enters a software contract.34 *35 * Amended on the owner's decision of 2026-11-06 (GAP-DRIVING-005 of phase36 * 8): the actuation reports its state to the publication, so the stop it37 * applies itself reaches the observer with its cause. Described the same38 * day: what the camera images and the motion samples carry at the boundary.39 */4041package DE4SDV_ClosedLoopDrivingFunctionalArchitecture {42 private import DE4SDV_Stakeholders::*;43 private import DE4SDV_TraceVocabulary::AllocatableFunction;44 private import DE4SDV_ClosedLoopDrivingFraming::degradedInputBehaviorConcern;45 private import DE4SDV_ClosedLoopDrivingFraming::ClosedLoopDrivingSystem;46 private import DE4SDV_OperationalContext::SubjectVehicle;47 private import DE4SDV_ClosedLoopDrivingOperationalContext::CameraImages;48 private import DE4SDV_ClosedLoopDrivingOperationalContext::EgoMotionState;49 private import DE4SDV_ClosedLoopDrivingOperationalContext::Route;50 private import DE4SDV_ClosedLoopDrivingOperationalContext::VehicleMotionCommand;51 private import DE4SDV_ClosedLoopDrivingOperationalContext::DrivingOperationalState;52 private import DE4SDV_ClosedLoopDrivingOperationalContext::NavigationSystem;53 private import DE4SDV_ClosedLoopDrivingOperationalContext::DrivingStateObserverApplication;54 private import DE4SDV_ClosedLoopDrivingOperationalContext::closedLoopDrivingOperationalContext;55 private import DE4SDV_ClosedLoopDrivingNeedsRequirements::*;56 private import ScalarValues::Positive;57 private import SAF_Viewpoints::*;58 private import StandardViewDefinitions::*;59 private import SysideViews::**;60 private import Views::*;6162 /* ───────────── Items the functions exchange inside the driving system ───────────── */6364 item def CheckpointInputs {65 doc /*66 * The inputs of one step in the form the checkpoint takes: the camera67 * images with their histories and projection operators, the map_context68 * and route_mask rasters, and the ego-motion history (REQ-DRIVING-003 to69 * REQ-DRIVING-008).70 */71 }7273 item def InputCondition {74 doc /*75 * For one step: whether the camera history and the ego-motion history are76 * complete, and the capture times and the validity of the newest camera77 * images, of the newest motion sample and of the route.78 */79 }8081 item def DrivingPlan {82 doc /*83 * A plan as the terms of the requirements define it, marked with the84 * capture time of its newest camera image, its production time and the85 * run record that identifies its checkpoint.86 */87 }8889 item def DrivingMode {90 doc /* The mode of ClosedLoopDrivingModes the driving system is in, with the cause of a stop. */91 }9293 item def RunRecord {94 doc /*95 * The identity of a run: the SHA-256 of the checkpoint file it loaded, the96 * AutoE2E source revision it runs and the SHA-256 of its complete97 * configuration.98 */99 }100101 item def ActuationState {102 doc /*103 * For each step, what the actuation did: the command it applied with its104 * actuation time, or that its own stop response is in force, since when105 * and why, when no valid command reached it in the limit of106 * REQ-DRIVING-028. It goes to the publication only, so that the stop the107 * actuation decides is published with its cause (REQ-DRIVING-029) like108 * the stop the supervision decides; nothing of it enters the loop.109 */110 }111112 /* ────────────── The loop functions of the context elements of phase 2 ────────────── */113114 action def ContextElementFunction {115 doc /*116 * A behavior of a context element of phase 2 in the closed loop. It is117 * outside the scope of the driving system: the system does not provide it118 * and no requirement of phase 5 is allocated to it.119 */120 }121122 action def GiveRoute :> ContextElementFunction {123 doc /*124 * Navigation: gives the route to the destination the driver chose, over125 * its map. It chooses no trajectory, and it takes nothing from the126 * driving system.127 */128 out route : Route;129 }130131 action def CaptureCameraImages :> ContextElementFunction {132 doc /* The vehicle's cameras: capture the road environment and give the images with their capture times. */133 out cameraImages : CameraImages;134 }135136 action def SampleEgoMotion :> ContextElementFunction {137 doc /* The vehicle's motion sensing: sample its own motion and give the samples with their times. */138 out egoMotion : EgoMotionState;139 }140141 action def ApplyMotionCommands :> ContextElementFunction {142 doc /* The vehicle's actuation: apply the steering and acceleration commands it is given and move the vehicle. */143 in command : VehicleMotionCommand;144 }145146 action def PresentDrivingState :> ContextElementFunction {147 doc /* The state observer: present the published plan, vehicle state and health to the driver and send nothing back. */148 in operationalState : DrivingOperationalState;149 }150151 /* ─────────────────────────────── Functions ─────────────────────────────── */152153 action def IdentifyRun :> AllocatableFunction {154 doc /*155 * Before the first plan of a run: compares the SHA-256 of the checkpoint156 * file with the one the configuration names, refuses to plan when they157 * differ or the configuration names none, and records the run identity.158 */159 out runRecord : RunRecord;160 }161162 action def AssembleCheckpointInputs :> AllocatableFunction {163 doc /*164 * Marks each camera image and each motion sample with its capture time and165 * builds, for each step, the inputs the checkpoint takes: the images in its166 * camera order and sizes with their histories and projection operators,167 * the two rasters of the route and its map, and the ego-motion history,168 * all from inputs captured in the run. Reports whether the histories are169 * complete and how old and how valid the newest inputs are.170 */171 in cameraImages : CameraImages;172 in egoMotion : EgoMotionState;173 in route : Route;174 out checkpointInputs : CheckpointInputs;175 out inputCondition : InputCondition;176 }177178 action def PlanTrajectory :> AllocatableFunction {179 doc /*180 * Makes the plan of a step by inference of the pinned checkpoint on the181 * inputs of the step, and marks it with the capture time of its newest182 * camera image, its production time and the run record.183 */184 in checkpointInputs : CheckpointInputs;185 in runRecord : RunRecord;186 out plan : DrivingPlan;187 }188189 action def SuperviseDrivingLoop :> AllocatableFunction {190 doc /*191 * Detects degraded input and plans in the limits of REQ-DRIVING-023 to192 * REQ-DRIVING-027: camera images missing, invalid or too old, a motion193 * sample invalid or too old, a route too old or without a route corridor,194 * a newest valid plan too old at a command, and a plan that is not valid.195 * Sets the mode: priming until both histories are complete, then driving;196 * stopped, with the cause, from its first detection. Passes the newest197 * valid plan on.198 */199 in inputCondition : InputCondition;200 in plan : DrivingPlan;201 out mode : DrivingMode;202 out validPlan : DrivingPlan;203 }204205 action def CommandVehicle :> AllocatableFunction {206 doc /*207 * Computes the steering and acceleration commands within the limits of the208 * vehicle its configuration names: while priming, commands that hold the209 * vehicle at standstill; while driving, commands from the newest valid plan210 * and the current motion of the vehicle; while stopped, the stop response,211 * deceleration to standstill with the steering held, then standstill until212 * the run ends. Marks each command with the plan it was computed from and213 * its issue time.214 */215 in validPlan : DrivingPlan;216 in mode : DrivingMode;217 in currentMotion : EgoMotionState;218 out command : VehicleMotionCommand;219 }220221 action def ApplyCommandsAtActuation :> AllocatableFunction {222 doc /*223 * Gives each command to the actuation of the vehicle and marks it with its224 * actuation time. When no valid command has reached the actuation in the225 * limit of REQ-DRIVING-028, it applies the stop response there itself, so226 * the vehicle stops also when the command path does not deliver. It227 * reports its actuation state to the publication: the applied command228 * with its time, or its own stop with the cause.229 */230 in command : VehicleMotionCommand;231 out actuatedCommand : VehicleMotionCommand;232 out actuationState : ActuationState;233 }234235 action def PublishOperationalState :> AllocatableFunction {236 doc /*237 * Publishes for observation each plan, the motion sample of each step, the238 * health at least periodically and the stop with its cause, whether the239 * supervision decided it (the mode) or the actuation did (the actuation240 * state), each with its producer and its time. Publication is one way and241 * never waits for a receiver, so how the state observer receives it does242 * not change the plans, the commands or the planning time.243 */244 in plan : DrivingPlan;245 in motion : EgoMotionState;246 in mode : DrivingMode;247 in actuationState : ActuationState;248 out operationalState : DrivingOperationalState;249 }250251 /* ─────────────────── The functional breakdown of one step ─────────────────── */252253 action def ClosedLoopDrivingFunctionalFlow {254 doc /*255 * The driving system broken into its functions, and the items they256 * exchange in one step. The camera images, the ego-motion state and the257 * route come from the context of phase 2; the commands go to the258 * actuation of the vehicle, and the operational state to the state259 * observer. Only the commands of CommandVehicle reach the actuation, and260 * nothing the publication gives flows back into the loop.261 */262 in item cameraImages : CameraImages;263 in item egoMotion : EgoMotionState;264 in item route : Route;265 out item vehicleCommand : VehicleMotionCommand;266 out item operationalState : DrivingOperationalState;267268 action identifyRun : IdentifyRun {269 out runRecord;270 }271272 action assembleInputs : AssembleCheckpointInputs {273 in cameraImages = ClosedLoopDrivingFunctionalFlow::cameraImages;274 in egoMotion = ClosedLoopDrivingFunctionalFlow::egoMotion;275 in route = ClosedLoopDrivingFunctionalFlow::route;276 out checkpointInputs;277 out inputCondition;278 }279280 action planTrajectory : PlanTrajectory {281 in checkpointInputs;282 in runRecord;283 out plan;284 }285 flow from assembleInputs.checkpointInputs to planTrajectory.checkpointInputs;286 flow from identifyRun.runRecord to planTrajectory.runRecord;287 first assembleInputs then planTrajectory;288289 action superviseLoop : SuperviseDrivingLoop {290 in inputCondition;291 in plan;292 out mode;293 out validPlan;294 }295 flow from assembleInputs.inputCondition to superviseLoop.inputCondition;296 flow from planTrajectory.plan to superviseLoop.plan;297 first planTrajectory then superviseLoop;298299 action commandVehicle : CommandVehicle {300 in validPlan;301 in mode;302 in currentMotion = ClosedLoopDrivingFunctionalFlow::egoMotion;303 out command;304 }305 flow from superviseLoop.validPlan to commandVehicle.validPlan;306 flow from superviseLoop.mode to commandVehicle.mode;307 first superviseLoop then commandVehicle;308309 action applyCommands : ApplyCommandsAtActuation {310 in command;311 out actuatedCommand = ClosedLoopDrivingFunctionalFlow::vehicleCommand;312 out actuationState;313 }314 flow from commandVehicle.command to applyCommands.command;315 first commandVehicle then applyCommands;316317 action publishState : PublishOperationalState {318 in plan;319 in motion = ClosedLoopDrivingFunctionalFlow::egoMotion;320 in mode;321 in actuationState;322 out operationalState = ClosedLoopDrivingFunctionalFlow::operationalState;323 }324 flow from planTrajectory.plan to publishState.plan;325 flow from superviseLoop.mode to publishState.mode;326 flow from applyCommands.actuationState to publishState.actuationState;327 }328329 action closedLoopDrivingFunctionalFlow : ClosedLoopDrivingFunctionalFlow;330331 /* ─────────── The system process: the system between the context elements ─────────── */332333 action def ClosedLoopDrivingSystemProcess {334 doc /*335 * One cycle of the loop as a process. The participants are the context336 * parts of phase 2 themselves and the system of interest, bound by337 * reference as the story's actors are: the process declares no part of338 * its own, so the increment has one context. Each participant owns and339 * performs its functions of the loop, as the swim lane of its function:340 * navigation gives the route, the vehicle's cameras and motion sensing341 * give the images and the ego motion, the driving system plans and342 * commands as one action of the process, the vehicle's actuation applies343 * the commands, and the state observer presents the published state. The344 * functions of the context elements are outside the scope of the driving345 * system; the driving system's functional scope is the one functional346 * flow usage it performs. The items that cross its boundary are the flows347 * of the process, each chained through the participant that gives and348 * the one that takes, in the order the loop runs, and nothing the349 * observation gives flows back into it. The process states the functional scope, the services the350 * context elements are expected to give and the exchanges only: no351 * planning, transport or display technology, no response deadline and no352 * timing claim is fixed here.353 */354 ref part navigation : NavigationSystem = closedLoopDrivingOperationalContext::navigation {355 doc /* Navigation of phase 2: it gives the route, and nothing else. */356 perform action giveRoute : GiveRoute;357 }358359 ref part vehicle : SubjectVehicle = closedLoopDrivingOperationalContext::vehicle {360 doc /* The vehicle of phase 2: its cameras and motion sensing give the input, and its actuation applies the commands. */361 perform action captureImages : CaptureCameraImages;362 perform action sampleEgoMotion : SampleEgoMotion;363 perform action applyCommands : ApplyMotionCommands;364 }365366 ref part drivingSystem : ClosedLoopDrivingSystem = closedLoopDrivingOperationalContext::drivingSystem {367 doc /* The system of interest of phase 2: it performs its whole functional flow, the one usage its functional boundary performs, from the inputs of the checkpoint to the commands and the published state. */368 perform closedLoopDrivingFunctionalFlow;369 }370371 ref part stateObserver : DrivingStateObserverApplication = closedLoopDrivingOperationalContext::aaosSDVGuest::stateObserver {372 doc /* The state observer of phase 2: it presents the published state and sends nothing back. */373 perform action presentState : PresentDrivingState;374 }375376 flow from navigation.giveRoute.route to drivingSystem.closedLoopDrivingFunctionalFlow.route;377 flow from vehicle.captureImages.cameraImages to drivingSystem.closedLoopDrivingFunctionalFlow.cameraImages;378 flow from vehicle.sampleEgoMotion.egoMotion to drivingSystem.closedLoopDrivingFunctionalFlow.egoMotion;379 flow from drivingSystem.closedLoopDrivingFunctionalFlow.vehicleCommand to vehicle.applyCommands.command;380 flow from drivingSystem.closedLoopDrivingFunctionalFlow.operationalState to stateObserver.presentState.operationalState;381 }382383 action closedLoopDrivingSystemProcess : ClosedLoopDrivingSystemProcess;384385 /* ────────────────────────────────── Modes ────────────────────────────────── */386387 state def ClosedLoopDrivingModes {388 doc /*389 * The modes the health of the driving system names. Priming holds the390 * vehicle at standstill until both histories are complete; driving391 * commands from the newest valid plan; stopped is the stop response, then392 * standstill until the run ends, with no transition out. The first393 * detection of SuperviseDrivingLoop leads to stopped, from priming as from394 * driving; CommandVehicle computes the commands of each mode.395 */396 state priming {397 doc /*398 * Both histories are incomplete: CommandVehicle holds the vehicle at399 * standstill while plans are produced, and PublishOperationalState400 * publishes the mode.401 */402 }403 state driving {404 doc /*405 * Both histories are complete and no detection has stopped the loop:406 * CommandVehicle commands from the newest valid plan, and407 * PublishOperationalState publishes the plan, the vehicle state and the408 * health.409 */410 }411 state stopped {412 doc /*413 * The stop response, from the first detection of SuperviseDrivingLoop:414 * CommandVehicle computes the stop response, deceleration to standstill415 * with the steering held, then standstill, and PublishOperationalState416 * publishes the stop with its cause. There is no transition out.417 */418 }419 transition first priming then driving; // both histories complete420 transition first priming then stopped; // a detection of SuperviseDrivingLoop421 transition first driving then stopped; // a detection of SuperviseDrivingLoop422 }423424 /* ────────── The functions whose behavior differs by mode depend on it ────────── */425426 dependency commandVehicleDependsOnPrimingMode427 from ClosedLoopDrivingFunctionalFlow::commandVehicle428 to ClosedLoopDrivingModes::priming;429 dependency commandVehicleDependsOnDrivingMode430 from ClosedLoopDrivingFunctionalFlow::commandVehicle431 to ClosedLoopDrivingModes::driving;432 dependency commandVehicleDependsOnStoppedMode433 from ClosedLoopDrivingFunctionalFlow::commandVehicle434 to ClosedLoopDrivingModes::stopped;435 dependency publishStateDependsOnStoppedMode436 from ClosedLoopDrivingFunctionalFlow::publishState437 to ClosedLoopDrivingModes::stopped;438439 /* ────────── The conceptual interfaces of the system: one functional chain ────────── */440441 enum def CameraPosition {442 doc /*443 * The six camera positions of the vehicle, in the order REQ-DRIVING-003444 * fixes for the checkpoint's input.445 */446 front;447 frontLeft;448 frontRight;449 rearLeft;450 rear;451 rearRight;452 }453454 item def CameraImage {455 doc /*456 * One image of one of the vehicle's cameras: its position, its capture457 * time in simulation time (REQ-DRIVING-030), its size in pixels, and the458 * calibration of its camera, the intrinsic matrix and the pose in the459 * vehicle frame, from which the projection operator of REQ-DRIVING-005460 * is built once the image is scaled to the size the checkpoint takes461 * (REQ-DRIVING-003). The calibration is the camera's and travels with its462 * images; the driving system builds no calibration of its own.463 */464 attribute position : CameraPosition;465 attribute captureTime : ISQ::DurationValue;466 attribute widthPixels : Positive;467 attribute heightPixels : Positive;468 }469470 item def CameraImageInput :> CameraImages {471 doc /*472 * The camera images as they enter the driving system at its input: for473 * each step one image per position, the six in the order of474 * CameraPosition (REQ-DRIVING-003), each with its capture time475 * (REQ-DRIVING-030) and its camera's calibration (REQ-DRIVING-005).476 */477 item image : CameraImage[6] ordered;478 }479480 item def EgoMotionSample {481 doc /*482 * One sample of the vehicle's own motion: its position and its heading in483 * the frame of the route's map, its speed, its longitudinal and lateral484 * acceleration and its yaw rate, as ISQ quantities, with its sample time485 * in simulation time (REQ-DRIVING-030). The position is two lengths along486 * the axes of the map's plane, and the heading is the direction of the487 * vehicle's longitudinal axis in that plane. From the positions the488 * system works out the speed and acceleration of the checkpoint's history489 * (REQ-DRIVING-008); at the position and heading of a step it draws the490 * two rasters of the route and its map (REQ-DRIVING-006,491 * REQ-DRIVING-007). The curvature of the checkpoint's history492 * (REQ-DRIVING-008) is no sampled quantity: the checkpoint's data derive493 * it from the yaw rate and the speed. Under the bounded deviation of494 * asmSourceAuthenticity, the driving system gives the checkpoint yaw rate495 * and curvature as zero.496 */497 attribute positionX : ISQ::LengthValue;498 attribute positionY : ISQ::LengthValue;499 attribute heading : ISQ::AngularMeasureValue;500 attribute speed : ISQ::SpeedValue;501 attribute longitudinalAcceleration : ISQ::AccelerationValue;502 attribute lateralAcceleration : ISQ::AccelerationValue;503 attribute yawRate : ISQ::AngularVelocityValue;504 attribute sampleTime : ISQ::DurationValue;505 }506507 item def EgoMotionInput :> EgoMotionState {508 doc /*509 * The vehicle's motion as it enters the driving system at its input: its510 * samples in the order of their sample times, each with the vehicle's511 * position and heading, from which the system works out the history512 * REQ-DRIVING-008 asks for.513 */514 item sample : EgoMotionSample[*] ordered;515 }516517 item def RouteInput :> Route {518 doc /* The route as it enters the driving system at its input: destination, route and map, with their times. */519 }520521 item def VehicleCommandOutput :> VehicleMotionCommand {522 doc /* The steering and acceleration commands as they leave the driving system for the vehicle's actuation. */523 }524525 item def OperationalStateOutput :> DrivingOperationalState {526 doc /* The published plan, vehicle state and health as they leave the driving system for observation. */527 }528529 port def CameraImagesInbound {530 doc /* The input port of the image item: the vehicle's cameras provide it. */531 in item cameraImages : CameraImageInput;532 }533534 port def EgoMotionInbound {535 doc /* The input port of the ego-motion item: the vehicle's motion sensing provides it. */536 in item egoMotion : EgoMotionInput;537 }538539 port def RouteInbound {540 doc /* The input port of the route item: navigation provides it. */541 in item route : RouteInput;542 }543544 port def VehicleCommandOutbound {545 doc /* The output port of the command item: the vehicle's actuation takes it. */546 out item vehicleCommand : VehicleCommandOutput;547 }548549 port def OperationalStateOutbound {550 doc /* The output port of the operational state: the state observer takes it. */551 out item operationalState : OperationalStateOutput;552 }553554 part def ClosedLoopDrivingFunctionalBoundary :> ClosedLoopDrivingSystem {555 doc /*556 * The driving system at its functional boundary, the one place its557 * conceptual interfaces are stated: three input ports the context elements558 * provide and two output ports they take, each with one directed item559 * typed by an item definition of this package that specializes the item560 * of phase 2. It performs the functional flow and binds its inputs and561 * outputs to the ports. It is not a logical element: neither it nor its562 * ports names a computer, a process, a transport or a technology.563 */564 port cameraImagesIn : CameraImagesInbound;565 port egoMotionIn : EgoMotionInbound;566 port routeIn : RouteInbound;567 port vehicleCommandOut : VehicleCommandOutbound;568 port operationalStateOut : OperationalStateOutbound;569570 perform closedLoopDrivingFunctionalFlow : ClosedLoopDrivingFunctionalFlow {571 in item cameraImages = cameraImagesIn.cameraImages;572 in item egoMotion = egoMotionIn.egoMotion;573 in item route = routeIn.route;574 out item vehicleCommand = vehicleCommandOut.vehicleCommand;575 out item operationalState = operationalStateOut.operationalState;576 }577 }578579580 /* ─────────────── Requirement-to-function allocations (allocatedTo) ─────────────── */581582 /* Identifying the run. */583 allocation runIdentityResponsibility584 allocate reqRecordRunIdentity to ClosedLoopDrivingFunctionalFlow::identifyRun;585 allocation unpinnedCheckpointResponsibility586 allocate reqRefuseUnpinnedCheckpoint to ClosedLoopDrivingFunctionalFlow::identifyRun;587588 /* Assembling the inputs the checkpoint takes. */589 allocation cameraFormResponsibility590 allocate reqCameraImagesInCheckpointForm to ClosedLoopDrivingFunctionalFlow::assembleInputs;591 allocation cameraHistoryResponsibility592 allocate reqCameraHistory to ClosedLoopDrivingFunctionalFlow::assembleInputs;593 allocation projectionOperatorResponsibility594 allocate reqProjectionOperators to ClosedLoopDrivingFunctionalFlow::assembleInputs;595 allocation mapContextResponsibility596 allocate reqMapContextRaster to ClosedLoopDrivingFunctionalFlow::assembleInputs;597 allocation routeMaskResponsibility598 allocate reqRouteMaskRaster to ClosedLoopDrivingFunctionalFlow::assembleInputs;599 allocation egoMotionHistoryResponsibility600 allocate reqEgoMotionHistory to ClosedLoopDrivingFunctionalFlow::assembleInputs;601 allocation capturedInputsResponsibility602 allocate reqHistoriesFromCapturedInputs to ClosedLoopDrivingFunctionalFlow::assembleInputs;603 allocation inputStampResponsibility604 allocate reqStampInputs to ClosedLoopDrivingFunctionalFlow::assembleInputs;605606 /* Planning. */607 allocation planEachStepResponsibility608 allocate reqPlanEachStep to ClosedLoopDrivingFunctionalFlow::planTrajectory;609 allocation checkpointInferenceResponsibility610 allocate reqPlansByCheckpointInference to ClosedLoopDrivingFunctionalFlow::planTrajectory;611 allocation planningPeriodResponsibility612 allocate reqPlanWithinPlanningPeriod to ClosedLoopDrivingFunctionalFlow::planTrajectory;613 allocation planStampResponsibility614 allocate reqStampPlans to ClosedLoopDrivingFunctionalFlow::planTrajectory;615 allocation planRunRecordResponsibility616 allocate reqPlansNameRunRecord to ClosedLoopDrivingFunctionalFlow::planTrajectory;617618 /* Supervising the inputs and the plans. */619 allocation degradedCameraResponsibility620 allocate reqStopOnDegradedCameraImages to ClosedLoopDrivingFunctionalFlow::superviseLoop;621 allocation degradedMotionResponsibility622 allocate reqStopOnDegradedMotion to ClosedLoopDrivingFunctionalFlow::superviseLoop;623 allocation degradedRouteResponsibility624 allocate reqStopOnDegradedRoute to ClosedLoopDrivingFunctionalFlow::superviseLoop;625 allocation stalePlanResponsibility626 allocate reqStopOnStalePlan to ClosedLoopDrivingFunctionalFlow::superviseLoop;627 allocation invalidPlanResponsibility628 allocate reqStopOnInvalidPlan to ClosedLoopDrivingFunctionalFlow::superviseLoop;629630 /* Commanding the vehicle, the stop response included. */631 allocation primingHoldResponsibility632 allocate reqHoldUntilHistoriesComplete to ClosedLoopDrivingFunctionalFlow::commandVehicle;633 allocation newestValidPlanResponsibility634 allocate reqCommandsFromNewestValidPlan to ClosedLoopDrivingFunctionalFlow::commandVehicle;635 allocation actuationLimitsResponsibility636 allocate reqCommandsWithinActuationLimits to ClosedLoopDrivingFunctionalFlow::commandVehicle;637 allocation stopDecelerationResponsibility638 allocate reqStopResponseDeceleration to ClosedLoopDrivingFunctionalFlow::commandVehicle;639 allocation stopSteeringResponsibility640 allocate reqStopResponseSteeringHeld to ClosedLoopDrivingFunctionalFlow::commandVehicle;641 allocation standstillAfterStopResponsibility642 allocate reqStandstillAfterStop to ClosedLoopDrivingFunctionalFlow::commandVehicle;643 allocation commandStampResponsibility644 allocate reqStampCommands to ClosedLoopDrivingFunctionalFlow::commandVehicle;645646 /* Applying the commands at the actuation. */647 allocation lostCommandsResponsibility648 allocate reqStopOnLostCommands to ClosedLoopDrivingFunctionalFlow::applyCommands;649 allocation actuationStampResponsibility650 allocate reqStampCommands to ClosedLoopDrivingFunctionalFlow::applyCommands;651652 /* Publishing the operational state. */653 allocation planPublicationResponsibility654 allocate reqPublishPlans to ClosedLoopDrivingFunctionalFlow::publishState;655 allocation vehicleStatePublicationResponsibility656 allocate reqPublishVehicleState to ClosedLoopDrivingFunctionalFlow::publishState;657 allocation healthPublicationResponsibility658 allocate reqPublishHealthPeriodically to ClosedLoopDrivingFunctionalFlow::publishState;659 allocation stopPublicationResponsibility660 allocate reqPublishStop to ClosedLoopDrivingFunctionalFlow::publishState;661 allocation planIndependenceResponsibility662 allocate reqPlansIndependentOfObservation to ClosedLoopDrivingFunctionalFlow::publishState;663 allocation planningTimeIndependenceResponsibility664 allocate reqPlanningTimeIndependentOfObservation to ClosedLoopDrivingFunctionalFlow::publishState;665666 /* ─────────────────────────────── Views ─────────────────────────────── */667668 concern closedLoopDrivingFunctionsConcern : FunctionalBehaviorConcern {669 doc /*670 * System architects and verification engineers need the functions of the671 * driving system and each requirement of phase 5 mapped to the functions672 * that carry it: phase 7 gives the functions to logical elements, and673 * phase 10 verifies each requirement on its functions.674 */675 subject;676 stakeholder systemArchitect : SystemArchitect;677 stakeholder verificationEngineer : VerificationEngineer;678 }679680 view closedLoopDrivingFunctionBreakdownView {681 viewpoint selectedFunctionalBreakdownViewpoint : SystemFunctionalBreakdownStructureViewpoint {682 frame closedLoopDrivingFunctionsConcern;683 }684 expose closedLoopDrivingFunctionalFlow;685 render asTreeDiagram;686 }687688 view closedLoopDrivingRequirementFunctionMappingView : MVD::MatrixView {689 viewpoint selectedRequirementFunctionViewpoint : SystemRequirementTraceabilityViewpoint {690 frame closedLoopDrivingFunctionsConcern;691 frame degradedInputBehaviorConcern;692 }693 view :>> rowView {694 expose reqPlanEachStep;695 expose reqPlansByCheckpointInference;696 expose reqCameraImagesInCheckpointForm;697 expose reqCameraHistory;698 expose reqProjectionOperators;699 expose reqMapContextRaster;700 expose reqRouteMaskRaster;701 expose reqEgoMotionHistory;702 expose reqHoldUntilHistoriesComplete;703 expose reqHistoriesFromCapturedInputs;704 expose reqCommandsFromNewestValidPlan;705 expose reqCommandsWithinActuationLimits;706 expose reqPlanWithinPlanningPeriod;707 expose reqPlansAndCommandsOverSCORE;708 expose reqPublishPlans;709 expose reqPublishVehicleState;710 expose reqPublishHealthPeriodically;711 expose reqPlansIndependentOfObservation;712 expose reqPlanningTimeIndependentOfObservation;713 expose reqStopResponseDeceleration;714 expose reqStopResponseSteeringHeld;715 expose reqStandstillAfterStop;716 expose reqStopOnDegradedCameraImages;717 expose reqStopOnDegradedMotion;718 expose reqStopOnDegradedRoute;719 expose reqStopOnStalePlan;720 expose reqStopOnInvalidPlan;721 expose reqStopOnLostCommands;722 expose reqPublishStop;723 expose reqStampInputs;724 expose reqStampPlans;725 expose reqStampCommands;726 expose reqRecordRunIdentity;727 expose reqPlansNameRunRecord;728 expose reqRefuseUnpinnedCheckpoint;729 attribute :>> includeReferenceElements = true;730 attribute :>> representation = Rep::name;731 }732 view :>> columnView {733 expose closedLoopDrivingFunctionalFlow::identifyRun;734 expose closedLoopDrivingFunctionalFlow::assembleInputs;735 expose closedLoopDrivingFunctionalFlow::planTrajectory;736 expose closedLoopDrivingFunctionalFlow::superviseLoop;737 expose closedLoopDrivingFunctionalFlow::commandVehicle;738 expose closedLoopDrivingFunctionalFlow::applyCommands;739 expose closedLoopDrivingFunctionalFlow::publishState;740 attribute :>> includeReferenceElements = true;741 attribute :>> representation = Rep::name;742 }743 view :>> cellView {744 expose DE4SDV_ClosedLoopDrivingFunctionalArchitecture::*;745 attribute :>> direction = SysideViews::MatrixTraceabilityDirection::row2col;746 }747 }748749 /* ─────────── The loop as a process: the system and its context elements ─────────── */750751 concern closedLoopDrivingProcessConcern : SystemProcessConcern {752 doc /*753 * System architects and systems engineers need the loop as a process: the754 * functions navigation, the vehicle's cameras and motion sensing, its755 * actuation and the state observer perform, which of those functions are756 * outside the scope of the driving system, what the driving system757 * provides and what it expects from each context element, and which items758 * cross its boundary in which direction. No response deadline or timing759 * claim follows from it.760 */761 subject;762 stakeholder systemArchitect : SystemArchitect;763 stakeholder systemsEngineer : SystemsEngineer;764 }765766 view closedLoopDrivingSystemProcessView : ActionFlowView {767 viewpoint selectedSystemProcessViewpoint : SystemProcessViewpoint {768 frame closedLoopDrivingProcessConcern;769 }770 expose ClosedLoopDrivingSystemProcess::*;771 expose ClosedLoopDrivingSystemProcess::navigation::*;772 expose ClosedLoopDrivingSystemProcess::vehicle::*;773 expose ClosedLoopDrivingSystemProcess::drivingSystem::*;774 expose ClosedLoopDrivingSystemProcess::stateObserver::*;775 attribute showAnnotationRows = false;776 attribute maxCompartmentEntries = 0;777 }778779 /* ───────────── The modes, and the functions that depend on them ───────────── */780781 concern closedLoopDrivingModeDependenceConcern : SystemStateConcern {782 doc /*783 * System architects and software developers need the modes of the784 * driving system and each function whose behavior differs by mode: what785 * CommandVehicle commands while priming, while driving and while stopped,786 * and what PublishOperationalState publishes of the stop and its cause,787 * so that the behavior of each function is designed and built per mode.788 */789 subject;790 stakeholder systemArchitect : SystemArchitect;791 stakeholder softwareDeveloper : SoftwareDeveloper;792 }793794 view closedLoopDrivingModeDependenceTableView : TVD::TableView {795 viewpoint selectedSystemStateTableViewpoint : SystemStateViewpoint {796 frame closedLoopDrivingModeDependenceConcern;797 frame degradedInputBehaviorConcern;798 }799 expose ClosedLoopDrivingModes::priming;800 expose ClosedLoopDrivingModes::driving;801 expose ClosedLoopDrivingModes::stopped;802 filter @ SysML::StateUsage;803 attribute :>> maxRowHeight = 300;804 view Mode :> columnViews {805 attribute :>> featureToRender = CT::declaredName;806 }807 view DependentFunctions :> columnViews {808 attribute :>> featureToRender = CT::documentation;809 attribute :>> columnWidth = 360;810 }811 }812813 /* ─────────────── The conceptual interfaces of the system ─────────────── */814815 concern closedLoopDrivingInterfaceConcern : FunctionalInterfaceConcern {816 doc /*817 * Systems engineers and software developers need the conceptual interfaces818 * of the driving system before phase 7 allocates the functions and phase 8819 * places software on them: the port of the functional chain for each item820 * that crosses its boundary, the direction of that item, and the item of821 * phase 2 the port's item specializes. Signal typing at a software822 * contract belongs to phase 8.823 */824 subject;825 stakeholder systemsEngineer : SystemsEngineer;826 stakeholder softwareDeveloper : SoftwareDeveloper;827 }828829 view closedLoopDrivingFunctionalInterfaceView {830 viewpoint selectedFunctionalInterfaceViewpoint : SystemInterfaceDefinitionViewpoint {831 frame closedLoopDrivingInterfaceConcern;832 }833 expose CameraImagesInbound;834 expose EgoMotionInbound;835 expose OperationalStateOutbound;836 expose RouteInbound;837 expose VehicleCommandOutbound;838 attribute showAnnotationRows = false;839 render asTreeDiagram;840 }841}842