new matlab stateflow
This commit is contained in:
Binary file not shown.
@@ -0,0 +1,49 @@
|
||||
%implements "machineSource" "C"
|
||||
%function CacheMachineDefinitions(block,system) void
|
||||
%openfile tmpFcnBuf
|
||||
%closefile tmpFcnBuf
|
||||
%<SLibCacheCodeToFile("sf_machine_data_defn",tmpFcnBuf)>\
|
||||
|
||||
%endfunction
|
||||
%function DumpMachineInitializer(block) Output
|
||||
|
||||
%openfile tmpFcnBuf
|
||||
|
||||
%closefile tmpFcnBuf
|
||||
%if !WHITE_SPACE(tmpFcnBuf)
|
||||
|
||||
/* Machine initializer */
|
||||
%<tmpFcnBuf>\
|
||||
%endif
|
||||
%endfunction
|
||||
%function GlobalMachineInitializer(block) void
|
||||
%openfile tmpFcnBuf
|
||||
%<DumpMachineInitializer(block)>\
|
||||
%closefile tmpFcnBuf
|
||||
%return tmpFcnBuf
|
||||
%endfunction %% GlobalMachineInitializer
|
||||
|
||||
%function DumpMachineTerminator(block) Output
|
||||
%openfile tmpFcnBuf
|
||||
|
||||
%closefile tmpFcnBuf
|
||||
%if !WHITE_SPACE(tmpFcnBuf)
|
||||
|
||||
/* Machine initializer */
|
||||
%<tmpFcnBuf>\
|
||||
%endif
|
||||
%endfunction
|
||||
%function GlobalMachineTerminator(block) void
|
||||
%openfile tmpFcnBuf
|
||||
%<DumpMachineTerminator(block)>\
|
||||
%closefile tmpFcnBuf
|
||||
%return tmpFcnBuf
|
||||
%endfunction %% GlobalMachineTerminator
|
||||
|
||||
%function CacheMachineFunctions(block,system) void
|
||||
%openfile tmpFcnBuf
|
||||
|
||||
|
||||
%closefile tmpFcnBuf
|
||||
%<SLibCacheCodeToFile("sf_machine_fcn_defn",tmpFcnBuf)>
|
||||
%endfunction
|
||||
@@ -0,0 +1,40 @@
|
||||
%implements "machineHeader" "C"
|
||||
%function CacheOutputs(block,system) void
|
||||
%assign srcFileName = SLibGetFullFileNameForSystemCode("sys_src_incl", system.SystemIdx)
|
||||
%openfile typedefsBuf
|
||||
|
||||
%closefile typedefsBuf
|
||||
%<SLibCacheCodeToFile("sf_machine_typedef",typedefsBuf)>
|
||||
%if !WHITE_SPACE(typedefsBuf)
|
||||
%<SLibUpdateHeadersNeededByFile(srcFileName, SLibGetFullFileNameForCode("sf_machine_typedef"))>
|
||||
%endif
|
||||
%openfile definesBuf
|
||||
%closefile definesBuf
|
||||
%<SLibCacheCodeToFile("sf_machine_data_define",definesBuf)>
|
||||
%if !WHITE_SPACE(definesBuf)
|
||||
%<SLibUpdateHeadersNeededByFile(srcFileName, SLibGetFullFileNameForCode("sf_machine_data_define"))>
|
||||
%endif
|
||||
%openfile externDataBuf
|
||||
%closefile externDataBuf
|
||||
%<SLibCacheCodeToFile("sf_machine_extern_data_decl",externDataBuf)>
|
||||
%if !WHITE_SPACE(externDataBuf)
|
||||
%<SLibUpdateHeadersNeededByFile(srcFileName, SLibGetFullFileNameForCode("sf_machine_extern_data_decl"))>
|
||||
%endif
|
||||
%openfile externDataBuf
|
||||
%closefile externDataBuf
|
||||
%<SLibCacheCodeToFile("sf_machine_public_extern_data_decl",externDataBuf)>
|
||||
%if !WHITE_SPACE(externDataBuf)
|
||||
%<SLibUpdateHeadersNeededByFile(srcFileName, SLibGetFullFileNameForCode("sf_machine_public_extern_data_decl"))>
|
||||
%endif
|
||||
%openfile externDataBuf
|
||||
|
||||
|
||||
|
||||
%closefile externDataBuf
|
||||
%<SLibCacheCodeToFile("sf_machine_extern_fcn_decl",externDataBuf)>
|
||||
%if !WHITE_SPACE(externDataBuf)
|
||||
%<SLibUpdateHeadersNeededByFile(srcFileName, SLibGetFullFileNameForCode("sf_machine_extern_fcn_decl"))>
|
||||
%endif
|
||||
%endfunction %% CacheOutputs
|
||||
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
%implements "chartSource" "C"
|
||||
%function ChartConfig(block, system) void
|
||||
%createrecord chartConfiguration { ...
|
||||
executeAtInitialization 0 ...
|
||||
}
|
||||
%return chartConfiguration
|
||||
%endfunction
|
||||
%function ChartDataMap(block, system) void
|
||||
%createrecord ChartDataElements {\
|
||||
NumChartData 3 \
|
||||
ChartDataDefaults {\
|
||||
RecordType "ChartData"\
|
||||
Dimensions []\
|
||||
IsTestPoint 0\
|
||||
}\
|
||||
ChartData {\
|
||||
Name "is_active_c3_FSMTreppe"\
|
||||
Description "StateIsActive"\
|
||||
SFName ""\
|
||||
Path ""\
|
||||
SrcLocation ""\
|
||||
}\
|
||||
ChartData {\
|
||||
Name "is_c3_FSMTreppe"\
|
||||
Description "StateActiveChild"\
|
||||
SFName ""\
|
||||
Path ""\
|
||||
SrcLocation ""\
|
||||
}\
|
||||
ChartData {\
|
||||
Name "temporalCounter_i1"\
|
||||
Description "TemporalCounter"\
|
||||
SFName ""\
|
||||
Path ""\
|
||||
SrcLocation ""\
|
||||
}\
|
||||
}
|
||||
%return ChartDataElements
|
||||
%endfunction
|
||||
@@ -0,0 +1 @@
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user