# $Revision: 1.1.4.2 $
Model {
  Name			  "sf_gfexport"
  Version		  6.2
  MdlSubVersion		  0
  GraphicalInterface {
    NumRootInports	    0
    NumRootOutports	    0
    ParameterArgumentNames  ""
    ComputedModelVersion    "1.21"
    NumModelReferences	    0
    NumTestPointedSignals   0
  }
  SavedCharacterEncoding  "US-ASCII"
  SaveDefaultBlockParams  on
  SampleTimeColors	  off
  LibraryLinkDisplay	  "none"
  WideLines		  off
  ShowLineDimensions	  off
  ShowPortDataTypes	  off
  ShowLoopsOnError	  on
  IgnoreBidirectionalLines off
  ShowStorageClass	  off
  ShowTestPointIcons	  on
  ShowViewerIcons	  on
  SortedOrder		  off
  ExecutionContextIcon	  off
  ShowLinearizationAnnotations on
  RecordCoverage	  off
  CovPath		  "/"
  CovSaveName		  "covdata"
  CovMetricSettings	  "dcmtr"
  CovNameIncrementing	  off
  CovHtmlReporting	  on
  covSaveCumulativeToWorkspaceVar on
  CovSaveSingleToWorkspaceVar on
  CovCumulativeVarName	  "covCumulativeData"
  CovCumulativeReport	  off
  CovReportOnPause	  on
  ScopeRefreshTime	  0.035000
  OverrideScopeRefreshTime on
  DisableAllScopes	  off
  DataTypeOverride	  "UseLocalSettings"
  MinMaxOverflowLogging	  "UseLocalSettings"
  MinMaxOverflowArchiveMode "Overwrite"
  BlockNameDataTip	  off
  BlockParametersDataTip  off
  BlockDescriptionStringDataTip	off
  ToolBar		  on
  StatusBar		  on
  BrowserShowLibraryLinks off
  BrowserLookUnderMasks	  off
  Created		  "Mon Jul 30 16:08:33 2001"
  Creator		  "The MathWorks Inc."
  UpdateHistory		  "UpdateHistoryNever"
  ModifiedByFormat	  "%<Auto>"
  LastModifiedBy	  "batserve"
  ModifiedDateFormat	  "%<Auto>"
  LastModifiedDate	  "Sat Jan 22 19:12:06 2005"
  ModelVersionFormat	  "1.%<AutoIncrement:21>"
  ConfigurationManager	  "None"
  LinearizationMsg	  "none"
  Profile		  off
  ParamWorkspaceSource	  "MATLABWorkspace"
  AccelSystemTargetFile	  "accel.tlc"
  AccelTemplateMakefile	  "accel_default_tmf"
  AccelMakeCommand	  "make_rtw"
  TryForcingSFcnDF	  off
  ExtModeBatchMode	  off
  ExtModeEnableFloating	  on
  ExtModeTrigType	  "manual"
  ExtModeTrigMode	  "normal"
  ExtModeTrigPort	  "1"
  ExtModeTrigElement	  "any"
  ExtModeTrigDuration	  1000
  ExtModeTrigDurationFloating "auto"
  ExtModeTrigHoldOff	  0
  ExtModeTrigDelay	  0
  ExtModeTrigDirection	  "rising"
  ExtModeTrigLevel	  0
  ExtModeArchiveMode	  "off"
  ExtModeAutoIncOneShot	  off
  ExtModeIncDirWhenArm	  off
  ExtModeAddSuffixToVar	  off
  ExtModeWriteAllDataToWs off
  ExtModeArmWhenConnect	  on
  ExtModeSkipDownloadWhenConnect off
  ExtModeLogAll		  on
  ExtModeAutoUpdateStatusClock off
  BufferReuse		  on
  StrictBusMsg		  "None"
  ProdHWDeviceType	  "32-bit Generic"
  ShowModelReferenceBlockVersion off
  ShowModelReferenceBlockIO off
  Array {
    Type		    "Handle"
    Dimension		    1
    Simulink.ConfigSet {
      $ObjectID		      1
      Version		      "1.1.0"
      Array {
	Type			"Handle"
	Dimension		7
	Simulink.SolverCC {
	  $ObjectID		  2
	  Version		  "1.1.0"
	  StartTime		  "0.0"
	  StopTime		  "inf"
	  AbsTol		  "auto"
	  FixedStep		  "auto"
	  InitialStep		  "auto"
	  MaxNumMinSteps	  "-1"
	  MaxOrder		  5
	  ExtrapolationOrder	  4
	  NumberNewtonIterations  1
	  MaxStep		  "auto"
	  MinStep		  "auto"
	  RelTol		  "1e-3"
	  SolverMode		  "Auto"
	  Solver		  "ode45"
	  SolverName		  "ode45"
	  ZeroCrossControl	  "UseLocalSettings"
	  AlgebraicLoopSolver	  "TrustRegion"
	  SolverResetMethod	  "Fast"
	  PositivePriorityOrder	  off
	  AutoInsertRateTranBlk	  off
	  SampleTimeConstraint	  "Unconstrained"
	  RateTranMode		  "Deterministic"
	}
	Simulink.DataIOCC {
	  $ObjectID		  3
	  Version		  "1.1.0"
	  Decimation		  "1"
	  ExternalInput		  "[t, u]"
	  FinalStateName	  "xFinal"
	  InitialState		  "xInitial"
	  LimitDataPoints	  on
	  MaxDataPoints		  "1000"
	  LoadExternalInput	  off
	  LoadInitialState	  off
	  SaveFinalState	  off
	  SaveFormat		  "Array"
	  SaveOutput		  on
	  SaveState		  off
	  SignalLogging		  on
	  SaveTime		  on
	  StateSaveName		  "xout"
	  TimeSaveName		  "tout"
	  OutputSaveName	  "yout"
	  SignalLoggingName	  "logsout"
	  OutputOption		  "RefineOutputTimes"
	  OutputTimes		  "[]"
	  Refine		  "1"
	}
	Simulink.OptimizationCC {
	  $ObjectID		  4
	  Array {
	    Type		    "Cell"
	    Dimension		    5
	    Cell		    "ZeroExternalMemoryAtStartup"
	    Cell		    "ZeroInternalMemoryAtStartup"
	    Cell		    "InitFltsAndDblsToZero"
	    Cell		    "OptimizeModelRefInitCode"
	    Cell		    "NoFixptDivByZeroProtection"
	    PropName		    "DisabledProps"
	  }
	  Version		  "1.1.0"
	  BlockReduction	  on
	  BooleanDataType	  off
	  ConditionallyExecuteInputs on
	  InlineParams		  off
	  InlineInvariantSignals  on
	  OptimizeBlockIOStorage  on
	  BufferReuse		  on
	  EnforceIntegerDowncast  on
	  ExpressionFolding	  on
	  FoldNonRolledExpr	  on
	  LocalBlockOutputs	  on
	  ParameterPooling	  on
	  RollThreshold		  5
	  SystemCodeInlineAuto	  off
	  StateBitsets		  off
	  DataBitsets		  off
	  UseTempVars		  off
	  ZeroExternalMemoryAtStartup on
	  ZeroInternalMemoryAtStartup on
	  InitFltsAndDblsToZero	  on
	  NoFixptDivByZeroProtection off
	  EfficientFloat2IntCast  off
	  OptimizeModelRefInitCode off
	  LifeSpan		  "inf"
	  BufferReusableBoundary  on
	}
	Simulink.DebuggingCC {
	  $ObjectID		  5
	  Version		  "1.1.0"
	  RTPrefix		  "error"
	  ConsistencyChecking	  "none"
	  ArrayBoundsChecking	  "none"
	  SignalInfNanChecking	  "none"
	  AlgebraicLoopMsg	  "warning"
	  ArtificialAlgebraicLoopMsg "warning"
	  CheckSSInitialOutputMsg on
	  CheckExecutionContextPreStartOutputMsg off
	  CheckExecutionContextRuntimeOutputMsg	off
	  SignalResolutionControl "TryResolveAllWithWarning"
	  BlockPriorityViolationMsg "warning"
	  MinStepSizeMsg	  "warning"
	  SolverPrmCheckMsg	  "none"
	  InheritedTsInSrcMsg	  "warning"
	  DiscreteInheritContinuousMsg "warning"
	  MultiTaskDSMMsg	  "warning"
	  MultiTaskRateTransMsg	  "error"
	  SingleTaskRateTransMsg  "none"
	  TasksWithSamePriorityMsg "warning"
	  CheckMatrixSingularityMsg "none"
	  IntegerOverflowMsg	  "warning"
	  Int32ToFloatConvMsg	  "warning"
	  ParameterDowncastMsg	  "error"
	  ParameterOverflowMsg	  "error"
	  ParameterPrecisionLossMsg "warning"
	  UnderSpecifiedDataTypeMsg "none"
	  UnnecessaryDatatypeConvMsg "none"
	  VectorMatrixConversionMsg "none"
	  InvalidFcnCallConnMsg	  "error"
	  FcnCallInpInsideContextMsg "Use local settings"
	  SignalLabelMismatchMsg  "none"
	  UnconnectedInputMsg	  "warning"
	  UnconnectedOutputMsg	  "warning"
	  UnconnectedLineMsg	  "warning"
	  SFcnCompatibilityMsg	  "none"
	  UniqueDataStoreMsg	  "none"
	  BusObjectLabelMismatch  "warning"
	  RootOutportRequireBusObject "warning"
	  AssertControl		  "UseLocalSettings"
	  EnableOverflowDetection off
	  ModelReferenceIOMsg	  "none"
	  ModelReferenceVersionMismatchMessage "none"
	  ModelReferenceIOMismatchMessage "none"
	  ModelReferenceCSMismatchMessage "none"
	  ModelReferenceSimTargetVerbose off
	  UnknownTsInhSupMsg	  "warning"
	  ModelReferenceDataLoggingMessage "warning"
	  ModelReferenceSymbolNameMessage "warning"
	  ModelReferenceExtraNoncontSigs "error"
	}
	Simulink.HardwareCC {
	  $ObjectID		  6
	  Version		  "1.1.0"
	  ProdBitPerChar	  8
	  ProdBitPerShort	  16
	  ProdBitPerInt		  32
	  ProdBitPerLong	  32
	  ProdIntDivRoundTo	  "Undefined"
	  ProdEndianess		  "Unspecified"
	  ProdWordSize		  32
	  ProdShiftRightIntArith  on
	  ProdHWDeviceType	  "32-bit Generic"
	  TargetBitPerChar	  8
	  TargetBitPerShort	  16
	  TargetBitPerInt	  32
	  TargetBitPerLong	  32
	  TargetShiftRightIntArith on
	  TargetIntDivRoundTo	  "Undefined"
	  TargetEndianess	  "Unspecified"
	  TargetWordSize	  32
	  TargetTypeEmulationWarnSuppressLevel 0
	  TargetPreprocMaxBitsSint 32
	  TargetPreprocMaxBitsUint 32
	  TargetHWDeviceType	  "Specified"
	  TargetUnknown		  on
	  ProdEqTarget		  on
	}
	Simulink.ModelReferenceCC {
	  $ObjectID		  7
	  Version		  "1.1.0"
	  UpdateModelReferenceTargets "IfOutOfDateOrStructuralChange"
	  CheckModelReferenceTargetMessage "error"
	  ModelReferenceNumInstancesAllowed "Multi"
	  ModelReferencePassRootInputsByReference on
	  ModelReferenceMinAlgLoopOccurrences off
	}
	Simulink.RTWCC {
	  $BackupClass		  "Simulink.RTWCC"
	  $ObjectID		  8
	  Array {
	    Type		    "Cell"
	    Dimension		    1
	    Cell		    "IncludeHyperlinkInReport"
	    PropName		    "DisabledProps"
	  }
	  Version		  "1.1.0"
	  SystemTargetFile	  "grt.tlc"
	  GenCodeOnly		  off
	  MakeCommand		  "make_rtw"
	  TemplateMakefile	  "grt_default_tmf"
	  GenerateReport	  off
	  SaveLog		  off
	  RTWVerbose		  on
	  RetainRTWFile		  off
	  ProfileTLC		  off
	  TLCDebug		  off
	  TLCCoverage		  off
	  TLCAssert		  off
	  ProcessScriptMode	  "Default"
	  ConfigurationMode	  "Optimized"
	  ConfigAtBuild		  off
	  IncludeHyperlinkInReport off
	  LaunchReport		  off
	  TargetLang		  "C"
	  Array {
	    Type		    "Handle"
	    Dimension		    2
	    Simulink.CodeAppCC {
	      $ObjectID		      9
	      Array {
		Type			"Cell"
		Dimension		9
		Cell			"IgnoreCustomStorageClasses"
		Cell			"InsertBlockDesc"
		Cell			"SFDataObjDesc"
		Cell			"SimulinkDataObjDesc"
		Cell			"DefineNamingRule"
		Cell			"SignalNamingRule"
		Cell			"ParamNamingRule"
		Cell			"InlinedPrmAccess"
		Cell			"CustomSymbolStr"
		PropName		"DisabledProps"
	      }
	      Version		      "1.1.0"
	      ForceParamTrailComments off
	      GenerateComments	      on
	      IgnoreCustomStorageClasses on
	      IncHierarchyInIds	      off
	      MaxIdLength	      31
	      PreserveName	      off
	      PreserveNameWithParent  off
	      ShowEliminatedStatement off
	      IncAutoGenComments      off
	      SimulinkDataObjDesc     off
	      SFDataObjDesc	      off
	      IncDataTypeInIds	      off
	      PrefixModelToSubsysFcnNames on
	      CustomSymbolStr	      "$R$N$M"
	      MangleLength	      1
	      DefineNamingRule	      "None"
	      ParamNamingRule	      "None"
	      SignalNamingRule	      "None"
	      InsertBlockDesc	      off
	      SimulinkBlockComments   on
	      EnableCustomComments    off
	      InlinedPrmAccess	      "Literals"
	      ReqsInCode	      off
	    }
	    Simulink.GRTTargetCC {
	      $BackupClass	      "Simulink.TargetCC"
	      $ObjectID		      10
	      Array {
		Type			"Cell"
		Dimension		12
		Cell			"IncludeMdlTerminateFcn"
		Cell			"CombineOutputUpdateFcns"
		Cell			"SuppressErrorStatus"
		Cell			"ERTCustomFileBanners"
		Cell			"GenerateSampleERTMain"
		Cell			"MultiInstanceERTCode"
		Cell			"PurelyIntegerCode"
		Cell			"SupportNonFinite"
		Cell			"SupportComplex"
		Cell			"SupportAbsoluteTime"
		Cell			"SupportContinuousTime"
		Cell			"SupportNonInlinedSFcns"
		PropName		"DisabledProps"
	      }
	      Version		      "1.1.0"
	      TargetFcnLib	      "ansi_tfl_tmw.mat"
	      TargetLibSuffix	      ""
	      TargetPreCompLibLocation ""
	      GenFloatMathFcnCalls    "ANSI_C"
	      UtilityFuncGeneration   "Auto"
	      GenerateFullHeader      on
	      GenerateSampleERTMain   off
	      IsPILTarget	      off
	      ModelReferenceCompliant on
	      IncludeMdlTerminateFcn  on
	      CombineOutputUpdateFcns off
	      SuppressErrorStatus     off
	      IncludeFileDelimiter    "Auto"
	      ERTCustomFileBanners    off
	      SupportAbsoluteTime     on
	      LogVarNameModifier      "rt_"
	      MatFileLogging	      on
	      MultiInstanceERTCode    off
	      SupportNonFinite	      on
	      SupportComplex	      on
	      PurelyIntegerCode	      off
	      SupportContinuousTime   on
	      SupportNonInlinedSFcns  on
	      ExtMode		      off
	      ExtModeStaticAlloc      off
	      ExtModeTesting	      off
	      ExtModeStaticAllocSize  1000000
	      ExtModeTransport	      0
	      ExtModeMexFile	      "ext_comm"
	      RTWCAPISignals	      off
	      RTWCAPIParams	      off
	      RTWCAPIStates	      off
	      GenerateASAP2	      off
	    }
	    PropName		    "Components"
	  }
	}
	PropName		"Components"
      }
      Name		      "Configuration"
      SimulationMode	      "normal"
      CurrentDlgPage	      "Solver"
    }
    PropName		    "ConfigurationSets"
  }
  Simulink.ConfigSet {
    $PropName		    "ActiveConfigurationSet"
    $ObjectID		    1
  }
  BlockDefaults {
    Orientation		    "right"
    ForegroundColor	    "black"
    BackgroundColor	    "white"
    DropShadow		    off
    NamePlacement	    "normal"
    FontName		    "Helvetica"
    FontSize		    10
    FontWeight		    "normal"
    FontAngle		    "normal"
    ShowName		    on
  }
  BlockParameterDefaults {
    Block {
      BlockType		      Constant
      Value		      "1"
      VectorParams1D	      on
      OutDataTypeMode	      "Inherit from 'Constant value'"
      OutDataType	      "sfix(16)"
      ConRadixGroup	      "Use specified scaling"
      OutScaling	      "2^0"
      SampleTime	      "inf"
    }
    Block {
      BlockType		      Demux
      Outputs		      "4"
      DisplayOption	      "none"
      BusSelectionMode	      off
    }
    Block {
      BlockType		      Ground
    }
    Block {
      BlockType		      SignalConversion
      OverrideOpt	      off
    }
    Block {
      BlockType		      Inport
      UseBusObject	      off
      BusObject		      "BusObject"
      BusOutputAsStruct	      off
      PortDimensions	      "-1"
      SampleTime	      "-1"
      DataType		      "auto"
      OutDataType	      "sfix(16)"
      OutScaling	      "2^0"
      SignalType	      "auto"
      SamplingMode	      "auto"
      Interpolate	      on
    }
    Block {
      BlockType		      Outport
      Port		      "1"
      UseBusObject	      off
      BusObject		      "BusObject"
      BusOutputAsStruct	      off
      PortDimensions	      "-1"
      SampleTime	      "-1"
      DataType		      "auto"
      OutDataType	      "sfix(16)"
      OutScaling	      "2^0"
      SignalType	      "auto"
      SamplingMode	      "auto"
      OutputWhenDisabled      "held"
      InitialOutput	      "[]"
    }
    Block {
      BlockType		      Scope
      Floating		      off
      ModelBased	      off
      TickLabels	      "OneTimeTick"
      ZoomMode		      "on"
      Grid		      "on"
      TimeRange		      "auto"
      YMin		      "-5"
      YMax		      "5"
      SaveToWorkspace	      off
      SaveName		      "ScopeData"
      LimitDataPoints	      on
      MaxDataPoints	      "5000"
      Decimation	      "1"
      SampleInput	      off
      SampleTime	      "0"
    }
    Block {
      BlockType		      "S-Function"
      FunctionName	      "system"
      SFunctionModules	      "''"
      PortCounts	      "[]"
    }
    Block {
      BlockType		      SubSystem
      ShowPortLabels	      on
      Permissions	      "ReadWrite"
      PermitHierarchicalResolution "All"
      SystemSampleTime	      "-1"
      RTWFcnNameOpts	      "Auto"
      RTWFileNameOpts	      "Auto"
      SimViewingDevice	      off
      DataTypeOverride	      "UseLocalSettings"
      MinMaxOverflowLogging   "UseLocalSettings"
    }
    Block {
      BlockType		      Switch
      Criteria		      "u2 >= Threshold"
      Threshold		      "0"
      InputSameDT	      on
      OutDataTypeMode	      "Inherit via internal rule"
      RndMeth		      "Floor"
      SaturateOnIntegerOverflow	on
      ZeroCross		      on
      SampleTime	      "-1"
    }
    Block {
      BlockType		      Terminator
    }
    Block {
      BlockType		      TriggerPort
      TriggerType	      "rising"
      StatesWhenEnabling      "inherit"
      ShowOutputPort	      off
      OutputDataType	      "auto"
      SampleTimeType	      "triggered"
      SampleTime	      "1"
      ZeroCross		      on
    }
  }
  AnnotationDefaults {
    HorizontalAlignment	    "center"
    VerticalAlignment	    "middle"
    ForegroundColor	    "black"
    BackgroundColor	    "white"
    DropShadow		    off
    FontName		    "Helvetica"
    FontSize		    10
    FontWeight		    "normal"
    FontAngle		    "normal"
  }
  LineDefaults {
    FontName		    "Helvetica"
    FontSize		    9
    FontWeight		    "normal"
    FontAngle		    "normal"
  }
  System {
    Name		    "sf_gfexport"
    Location		    [53, 290, 580, 716]
    Open		    on
    ModelBrowserVisibility  off
    ModelBrowserWidth	    200
    ScreenColor		    "white"
    PaperOrientation	    "landscape"
    PaperPositionMode	    "auto"
    PaperType		    "usletter"
    PaperUnits		    "inches"
    ZoomFactor		    "118"
    ReportName		    "simulink-default.rpt"
    Block {
      BlockType		      SubSystem
      Name		      "Callee"
      Ports		      [0, 1]
      Position		      [125, 155, 200, 215]
      TreatAsAtomicUnit	      off
      MinAlgLoopOccurrences   off
      RTWSystemCode	      "Auto"
      MaskType		      "Stateflow"
      MaskDescription	      "Stateflow diagram"
      MaskDisplay	      "plot(sf('Private','sfblk','xIcon'),sf('Private'"
",'sfblk','yIcon'));text(0.5,0,sf('Private', 'sfblk', 'tIcon'),'HorizontalAl',"
"'Center','VerticalAl','Bottom');"
      MaskSelfModifiable      on
      MaskIconFrame	      off
      MaskIconOpaque	      off
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      System {
	Name			"Callee"
	Location		[257, 457, 812, 717]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  Demux
	  Name			  " Demux "
	  Ports			  [1, 1]
	  Position		  [270, 160, 320, 200]
	  Outputs		  "1"
	}
	Block {
	  BlockType		  Ground
	  Name			  " Ground "
	  Position		  [20, 121, 40, 139]
	}
	Block {
	  BlockType		  "S-Function"
	  Name			  " SFunction "
	  Tag			  "Stateflow S-Function sf_gfexport 2"
	  Ports			  [1, 2]
	  Position		  [180, 100, 230, 160]
	  FunctionName		  "sf_sfun"
	  PortCounts		  "[1 2]"
	  Port {
	    PortNumber		    2
	    Name		    "output"
	    RTWStorageClass	    "Auto"
	    DataLoggingNameMode	    "SignalName"
	    ShowSigGenPortName	    on
	  }
	}
	Block {
	  BlockType		  Terminator
	  Name			  " Terminator "
	  Position		  [460, 171, 480, 189]
	}
	Block {
	  BlockType		  Outport
	  Name			  "output"
	  Position		  [460, 101, 480, 119]
	  IconDisplay		  "Port number"
	  BusOutputAsStruct	  off
	}
	Line {
	  SrcBlock		  " SFunction "
	  SrcPort		  1
	  Points		  [0, 65]
	  DstBlock		  " Demux "
	  DstPort		  1
	}
	Line {
	  SrcBlock		  " Ground "
	  SrcPort		  1
	  DstBlock		  " SFunction "
	  DstPort		  1
	}
	Line {
	  SrcBlock		  " Demux "
	  SrcPort		  1
	  DstBlock		  " Terminator "
	  DstPort		  1
	}
	Line {
	  Name			  "output"
	  Labels		  [0, 0]
	  SrcBlock		  " SFunction "
	  SrcPort		  2
	  DstBlock		  "output"
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "Caller"
      Ports		      [0, 0, 0, 1]
      Position		      [245, 69, 305, 121]
      TreatAsAtomicUnit	      on
      MinAlgLoopOccurrences   off
      RTWSystemCode	      "Auto"
      MaskType		      "Stateflow"
      MaskDescription	      "Stateflow diagram"
      MaskDisplay	      "plot(sf('Private','sfblk','xIcon'),sf('Private'"
",'sfblk','yIcon'));text(0.5,0,sf('Private', 'sfblk', 'tIcon'),'HorizontalAl',"
"'Center','VerticalAl','Bottom');"
      MaskSelfModifiable      on
      MaskIconFrame	      off
      MaskIconOpaque	      off
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      System {
	Name			"Caller"
	Location		[257, 457, 812, 717]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Block {
	  BlockType		  TriggerPort
	  Name			  "E"
	  Ports			  [0, 1]
	  Position		  [20, 101, 40, 119]
	  TriggerType		  "either"
	  ShowOutputPort	  on
	}
	Block {
	  BlockType		  Demux
	  Name			  " Demux "
	  Ports			  [1, 1]
	  Position		  [270, 100, 320, 140]
	  Outputs		  "1"
	}
	Block {
	  BlockType		  "S-Function"
	  Name			  " SFunction "
	  Tag			  "Stateflow S-Function sf_gfexport 1"
	  Ports			  [1, 1]
	  Position		  [180, 100, 230, 140]
	  FunctionName		  "sf_sfun"
	  PortCounts		  "[1 1]"
	}
	Block {
	  BlockType		  Terminator
	  Name			  " Terminator "
	  Position		  [460, 111, 480, 129]
	}
	Line {
	  SrcBlock		  " SFunction "
	  SrcPort		  1
	  DstBlock		  " Demux "
	  DstPort		  1
	}
	Line {
	  SrcBlock		  " Demux "
	  SrcPort		  1
	  DstBlock		  " Terminator "
	  DstPort		  1
	}
	Line {
	  SrcBlock		  "E"
	  SrcPort		  1
	  DstBlock		  " SFunction "
	  DstPort		  1
	}
      }
    }
    Block {
      BlockType		      Reference
      Name		      "Manual Switch"
      Ports		      [2, 1]
      Position		      [115, 37, 145, 73]
      SourceBlock	      "simulink/Signal\nRouting/Manual Switch"
      SourceType	      "Manual Switch"
      ShowPortLabels	      on
      sw		      "0"
      action		      "0"
    }
    Block {
      BlockType		      SubSystem
      Name		      "More Info"
      Ports		      []
      Position		      [290, 266, 420, 343]
      DropShadow	      on
      ShowName		      off
      FontName		      "Arial"
      FontSize		      12
      TreatAsAtomicUnit	      off
      MinAlgLoopOccurrences   off
      RTWSystemCode	      "Auto"
      MaskDisplay	      "disp('Double click\\nhere for\\ninformation on"
"\\nthis demonstration')"
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      System {
	Name			"More Info"
	Location		[223, 136, 795, 511]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
	Annotation {
	  Name			  "Graphical Function Demonstration"
	  Position		  [263, 22]
	  FontSize		  14
	  FontWeight		  "bold"
	}
	Annotation {
	  Name			  "This demonstration illustrates how graphica"
"l functions can be exported and used as a means for \naccessing data. The out"
"put shown in the scope block, is equal to 1 when the manual switch is in the"
"\nOn_switch state, or 0 when the switch is in the Off_switch state. \n\nThe C"
"aller chart is triggered by the Manual Switch. Graphical functions which are "
"defined in the Callee\nchart, are then called by the Caller chart. In the Cal"
"lee chart, the output is set to 0 in state A and set to\n1 in state B. The gr"
"aphical functions which are called by the Caller chart, first check if state "
"A is active\nand then send and transition even signal to the appropriate stat"
"e. This method allows you to create\nflexible models which contain different "
"triggering events that define the final output.\n "
	  Position		  [14, 46]
	  HorizontalAlignment	  "left"
	  VerticalAlignment	  "top"
	  FontName		  "Arial"
	  FontSize		  12
	}
      }
    }
    Block {
      BlockType		      SubSystem
      Name		      "More Info1"
      Ports		      []
      Position		      [15, 261, 139, 340]
      DropShadow	      on
      ShowName		      off
      OpenFcn		      "simcad(bdroot);"
      FontName		      "Arial"
      FontSize		      12
      TreatAsAtomicUnit	      off
      MinAlgLoopOccurrences   off
      RTWSystemCode	      "Auto"
      MaskDisplay	      "disp('Double click\\nhere for\\nSimulink\\State"
"flow\\n Help')"
      MaskIconFrame	      on
      MaskIconOpaque	      on
      MaskIconRotate	      "none"
      MaskIconUnits	      "autoscale"
      System {
	Name			"More Info1"
	Location		[128, 280, 487, 453]
	Open			off
	ModelBrowserVisibility	off
	ModelBrowserWidth	200
	ScreenColor		"white"
	PaperOrientation	"landscape"
	PaperPositionMode	"auto"
	PaperType		"usletter"
	PaperUnits		"inches"
	ZoomFactor		"100"
      }
    }
    Block {
      BlockType		      Constant
      Name		      "Off_switch"
      Position		      [40, 70, 70, 100]
      Value		      "0"
    }
    Block {
      BlockType		      Constant
      Name		      "On_switch"
      Position		      [40, 15, 70, 45]
    }
    Block {
      BlockType		      Scope
      Name		      "Scope"
      Ports		      [1]
      Position		      [305, 169, 335, 201]
      Location		      [638, 365, 962, 604]
      Open		      on
      NumInputPorts	      "1"
      List {
	ListType		AxesTitles
	axes1			"%<SignalLabel>"
      }
      TimeRange		      "10"
      YMin		      "-1"
      YMax		      "1.3"
      DataFormat	      "StructureWithTime"
    }
    Line {
      SrcBlock		      "On_switch"
      SrcPort		      1
      Points		      [5, 0; 0, 15]
      DstBlock		      "Manual Switch"
      DstPort		      1
    }
    Line {
      SrcBlock		      "Off_switch"
      SrcPort		      1
      Points		      [5, 0; 0, -20]
      DstBlock		      "Manual Switch"
      DstPort		      2
    }
    Line {
      SrcBlock		      "Manual Switch"
      SrcPort		      1
      Points		      [125, 0]
      DstBlock		      "Caller"
      DstPort		      trigger
    }
    Line {
      SrcBlock		      "Callee"
      SrcPort		      1
      DstBlock		      "Scope"
      DstPort		      1
    }
  }
}

# Finite State Machines
#
#    Stateflow Version 6.2 (R14SP2) dated Jan 21 2005, 03:46:19
#
#

Stateflow {

	machine {
		id                   		1
		name                 		"sf_gfexport"
		created              		"30-Jul-2001 16:08:34"
		isLibrary            		0
		firstTarget          		29
		sfVersion            		62014000
		sfDemoChecksum       		[2897395508 276407336 2824271417 3940088006]
	}

	chart {
		id                                        		2
		name                                      		"Caller"
		windowPosition                            		[428.414 336.199 317.948 235.339]
		viewLimits                                		[0 271.548 0 196.339]
		screen                                    		[1 1 1600 1200 1.25]
		firstTransition                           		7
		firstJunction                             		4
		viewObj                                   		2
		visible                                   		1
		machine                                   		1
		subviewS {
		}
		decomposition                             		CLUSTER_CHART
		firstEvent                                		8
		chartFileNumber                           		1
	}

	junction {
		id         		3
		position   		[187.875 59.25 7]
		chart      		2
		linkNode   		[2 4 0]
		subviewer  		2
		type       		CONNECTIVE_JUNCTION
	}

	junction {
		id         		4
		position   		[60.75 59.25 7]
		chart      		2
		linkNode   		[2 0 3]
		subviewer  		2
		type       		CONNECTIVE_JUNCTION
	}

	transition {
		id             		5
		labelString    		"[is_A_active()]\n"
						"{send_event_to_A();}"
		labelPosition  		[65.188 13.168 112.945 27.934]
		fontSize       		12
		src {
			id          		4
			intersection		[0 1 0 -1 67.75 59.25 0 0]
		}
		dst {
			id          		3
			intersection		[0 -1 0 -1 180.875 59.25 0 0]
		}
		midPoint       		[122.511 59.25]
		chart          		2
		linkNode       		[2 7 6]
		dataLimits     		[67.75 180.875 56.85 61.65]
		subviewer      		2
		drawStyle      		SMART
		executionOrder 		1
	}

	transition {
		id             		6
		labelString    		"{send_event_to_B();}"
		labelPosition  		[74.682 122.068 111.343 15.164]
		fontSize       		12
		src {
			id          		4
			intersection		[0 0.4326 0.9016 -1 63.7782 65.5611 0 0]
		}
		dst {
			id          		3
			intersection		[0 -0.4326 0.9016 -1 184.8468 65.5611 0 0]
		}
		midPoint       		[124.3125 111.0208]
		chart          		2
		linkNode       		[2 5 0]
		dataLimits     		[63.778 184.847 65.561 111.02]
		stampAngle     		1.1234
		subviewer      		2
		drawStyle      		SMART
		slide {
			sticky        		SRC_STICK
		}
		executionOrder 		2
	}

	transition {
		id             		7
		labelPosition  		[33.129 59.283 8.01 15.164]
		fontSize       		12
		src {
			intersection		[0 1 0 0 17.125 59.25 0 0]
		}
		dst {
			id          		4
			intersection		[0 -1 0 -1 53.75 59.25 0 0]
		}
		midPoint       		[31.973 59.25]
		chart          		2
		linkNode       		[2 0 5]
		dataLimits     		[17.125 53.75 56.85 61.65]
		subviewer      		2
		drawStyle      		SMART
		executionOrder 		1
	}

	event {
		id         		8
		name       		"E"
		linkNode   		[2 0 0]
		scope      		INPUT_EVENT
		trigger    		EITHER_EDGE_EVENT
		machine    		1
	}

	instance {
		id     		9
		name   		"Caller"
		machine		1
		chart  		2
	}

	chart {
		id                                        		10
		name                                      		"Callee"
		windowPosition                            		[64.358 185.39 329.475 395.754]
		viewLimits                                		[2.988 286.063 0 356.754]
		screen                                    		[1 1 1600 1200 1.25]
		treeNode                                  		[0 12 0 0]
		firstTransition                           		19
		viewObj                                   		10
		visible                                   		1
		machine                                   		1
		subviewS {
		}
		decomposition                             		CLUSTER_CHART
		firstEvent                                		26
		firstData                                 		27
		chartFileNumber                           		2
		exportChartFunctions                      		1
	}

	state {
		id                  		11
		labelString         		"A\n"
						"entry: output = 0;"
		position            		[35.799 38.078 82.934 42.345]
		chart               		10
		treeNode            		[10 0 12 14]
		superState          		GROUPED
		subviewer           		10
		type                		OR_STATE
		decomposition       		CLUSTER_STATE
	}

	state {
		id                  		12
		labelString         		"B\n"
						"entry: output = 1;"
		position            		[190.983 37.328 70.669 44.699]
		chart               		10
		treeNode            		[10 0 0 11]
		superState          		GROUPED
		subviewer           		10
		type                		OR_STATE
		decomposition       		CLUSTER_STATE
	}

	state {
		id                  		13
		labelString         		"activity = is_A_active()"
		position            		[27.57 192.084 189.927 62.792]
		fontSize            		12
		chart               		10
		treeNode            		[10 0 14 15]
		firstTransition     		22
		firstJunction       		16
		superState          		GROUPED
		subviewer           		10
		type                		FUNC_STATE
		decomposition       		CLUSTER_STATE
		firstData           		25
	}

	state {
		id                  		14
		labelString         		"send_event_to_A()"
		position            		[28.581 118.246 187.494 61.965]
		fontSize            		12
		chart               		10
		treeNode            		[10 0 11 13]
		firstTransition     		23
		firstJunction       		17
		superState          		GROUPED
		subviewer           		10
		type                		FUNC_STATE
		decomposition       		CLUSTER_STATE
	}

	state {
		id                  		15
		labelString         		"send_event_to_B()"
		position            		[27.4 267.157 189.493 62.715]
		fontSize            		12
		chart               		10
		treeNode            		[10 0 13 0]
		firstTransition     		24
		firstJunction       		18
		superState          		GROUPED
		subviewer           		10
		type                		FUNC_STATE
		decomposition       		CLUSTER_STATE
	}

	junction {
		id         		16
		position   		[113.2245 236.8069 5.6225]
		arrowSize  		6.426
		chart      		10
		linkNode   		[13 0 0]
		isGrouped  		1
		subviewer  		10
		type       		CONNECTIVE_JUNCTION
	}

	junction {
		id         		17
		position   		[107.34 168.6927 6.4165]
		arrowSize  		7.333
		chart      		10
		linkNode   		[14 0 0]
		isGrouped  		1
		subviewer  		10
		type       		CONNECTIVE_JUNCTION
	}

	junction {
		id         		18
		position   		[106.9988 318.2138 6.4896]
		arrowSize  		7.417
		chart      		10
		linkNode   		[15 0 0]
		isGrouped  		1
		subviewer  		10
		type       		CONNECTIVE_JUNCTION
	}

	transition {
		id             		19
		labelPosition  		[75.192 20.6 6.397 11.998]
		src {
			intersection		[0 0 1 0 75.1922 8.0775 0 0]
		}
		dst {
			id          		11
			intersection		[1 0 -1 0.475 75.1922 38.0775 0 0]
		}
		midPoint       		[75.1922 19.469]
		chart          		10
		linkNode       		[10 0 20]
		dataLimits     		[72.792 77.592 8.078 38.078]
		subviewer      		10
		drawStyle      		SMART
		executionOrder 		1
	}

	transition {
		id             		20
		labelString    		"SWITCH"
		labelPosition  		[130.064 39.034 33.585 11.998]
		src {
			id          		12
			intersection		[4 -1 0 0.5805 190.9825 56.0786 0 13.5]
		}
		dst {
			id          		11
			intersection		[2 1 0 0.4251 118.7325 56.0786 0 -11.25]
		}
		midPoint       		[157.5476 56.0786]
		chart          		10
		linkNode       		[10 19 21]
		dataLimits     		[118.733 190.982 53.679 58.479]
		subviewer      		10
		drawStyle      		SMART
		executionOrder 		1
	}

	transition {
		id             		21
		labelString    		"SWITCH"
		labelPosition  		[133.052 78.087 33.585 11.998]
		src {
			id          		11
			intersection		[2 1 0 0.8614 118.7325 74.5524 0 14.8752]
		}
		dst {
			id          		12
			intersection		[4 -1 0 0.1672 190.9825 74.5524 0 -14.8752]
		}
		midPoint       		[152.1674 74.5524]
		chart          		10
		linkNode       		[10 20 0]
		dataLimits     		[118.733 190.982 72.152 76.952]
		subviewer      		10
		drawStyle      		SMART
		executionOrder 		1
	}

	transition {
		id             		22
		labelString    		"{activity = in(A);}"
		labelPosition  		[74.978 209.957 75.966 13.598]
		fontSize       		9.638
		arrowSize      		6.426
		src {
			intersection		[0 0.9901 0.1402 0 46.2038 227.4613 0 0]
		}
		dst {
			id          		16
			intersection		[7 -0.9901 -0.1402 -1 107.6575 236.0184 0 0]
		}
		midPoint       		[74.8195 231.4516]
		chart          		10
		linkNode       		[13 0 0]
		isGrouped      		1
		dataLimits     		[46.204 107.657 227.461 237.026]
		subviewer      		10
		drawStyle      		SMART
		slide {
			sticky        		BOTH_STICK
		}
		executionOrder 		1
	}

	transition {
		id             		23
		labelString    		"{send(SWITCH,A);}"
		labelPosition  		[67.455 142.559 103.954 15.198]
		fontSize       		11
		arrowSize      		7.333
		src {
			intersection		[0 0.9921 0.1254 0 46.813 158.1424 0 0]
		}
		dst {
			id          		17
			intersection		[7 -0.9921 -0.1254 -1 100.9741 167.8881 0 0]
		}
		midPoint       		[71.1915 162.7683]
		chart          		10
		linkNode       		[14 0 0]
		isGrouped      		1
		dataLimits     		[46.813 100.974 158.142 169.151]
		subviewer      		10
		drawStyle      		SMART
		slide {
			sticky        		BOTH_STICK
		}
		executionOrder 		1
	}

	transition {
		id             		24
		labelString    		"{send(SWITCH,B);}"
		labelPosition  		[66.48 291.531 102.355 15.198]
		fontSize       		11.125
		arrowSize      		7.417
		src {
			intersection		[0 0.9858 0.168 0 45.826 307.5358 0 0]
		}
		dst {
			id          		18
			intersection		[7 -0.9858 -0.168 -1 100.6014 317.1235 0 0]
		}
		midPoint       		[70.597 311.8597]
		chart          		10
		linkNode       		[15 0 0]
		isGrouped      		1
		dataLimits     		[45.826 100.601 307.536 318.071]
		subviewer      		10
		executionOrder 		1
	}

	data {
		id                            		25
		name                          		"activity"
		linkNode                      		[13 0 0]
		scope                         		FUNCTION_OUTPUT_DATA
		machine                       		1
		dataType                      		"double"
		fixptType {
			bias    		0
			slope   		1
			exponent		0
			baseType		SF_INT16_TYPE
			lock    		0
		}
		dlgFixptMode                  		0
		props {
			range {
				minimum		""
				maximum		""
			}
		}
	}

	event {
		id         		26
		name       		"SWITCH"
		linkNode   		[10 0 0]
		scope      		LOCAL_EVENT
		trigger    		EITHER_EDGE_EVENT
		machine    		1
	}

	data {
		id                            		27
		name                          		"output"
		linkNode                      		[10 0 0]
		scope                         		OUTPUT_DATA
		machine                       		1
		dataType                      		"double"
		fixptType {
			bias    		0
			slope   		1
			exponent		0
			baseType		SF_INT16_TYPE
			lock    		0
		}
		dlgFixptMode                  		0
		props {
			range {
				minimum		""
				maximum		""
			}
		}
	}

	instance {
		id     		28
		name   		"Callee"
		machine		1
		chart  		10
	}

	target {
		id                        		29
		name                      		"sfun"
		description               		"Default Simulink S-Function Target."
		codeFlags                 		" debug=1 overflow=1 echo=1"
		machine                   		1
		linkNode                  		[1 0 0]
	}
}
