Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## demos.powerwindow.models
Class WindowModel

    java.lang.Object
      modhelxs.abstractsemantics.NamedEntity
          modhelxs.abstractsemantics.ObservableEntity
              modhelxs.abstractsemantics.Model<Unit>
                  demos.powerwindow.models.WindowModel

All Implemented Interfaces:
  Model, NamedEntity, ObservableEntity

    public class WindowModel

extends Model<Unit>

The model of the mechanical part of the window. This is an SDF model whose inputs and outputs are: - motor_cmd: the command of the motor, with positive values closing the window, negative value opening the value, and 0 stopping the motor - window_pos: the position of the window, 0.0 being fully opened, and 5.0 being fully closed - window_end: the end stops, 0 means that no end stop is reached, -1 means fully opened end stop 1 means fully closed end stop The demultiplication of the motor and mechanical part of the window is set by the "scale" property of the model. The value of motor_cmd is multiplied by this scale to compute by how much the window moves at each update.

Author:
  boulange

Field Summary
`private Pin` | `motor_cmd`
`private Pin` | `window_end`
`private Pin` | `window_pos`

Constructor Summary
`WindowModel(java.lang.String name, java.lang.Object... properties)`

Method Summary
`Pin` | `motor_cmd()`
`Pin` | `window_end()`
`Pin` | `window_pos()`

Methods inherited from class modhelxs.abstractsemantics.Model
`add, connect, connectFromInterfaceBlock, connectFromModel, connectFromRegularBlock, createRelation, emitObservationRequests, endOfSnapshot, endOfUpdate, getEngine, getInputPins, getMoC, getOutputPins, getParent, getStructure, prep, reset, sanityCheck, setEngine, setParent, setup, startOfSnapshot, startOfUpdate, update, validate, wrapup`

Methods inherited from class modhelxs.abstractsemantics.ObservableEntity
`addPin, getInterface, getPin`

Methods inherited from class modhelxs.abstractsemantics.NamedEntity
`getName, getProperties, getProperty, hasProperty, removeProperty, setName, setProperties, setProperty, toString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Methods inherited from interface modhelxs.ecore.ObservableEntity
`getInterface`

Methods inherited from interface modhelxs.ecore.NamedEntity
`getName, getProperties, setName`

Field Detail

### motor_cmd

    private final Pin motor_cmd

### window_pos

    private final Pin window_pos

### window_end

    private final Pin window_end

Constructor Detail

### WindowModel

    public WindowModel(java.lang.String name,
                       java.lang.Object... properties)

Method Detail

### motor_cmd

    public Pin motor_cmd()

### window_pos

    public Pin window_pos()

### window_end

    public Pin window_end()

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD