📄 a2d.mdl
字号:
Line {
SrcBlock "Pulse\nGenerator"
SrcPort 1
Points [150, 0]
DstBlock "temperature"
DstPort trigger
}
Line {
SrcBlock "temperature"
SrcPort 2
Points [10, 0; 0, 49]
DstBlock "adc_filter"
DstPort trigger
}
Line {
SrcBlock "temperature"
SrcPort 1
DstBlock "Mux"
DstPort 1
}
Line {
SrcBlock "Mux"
SrcPort 1
DstBlock "results"
DstPort 1
}
Line {
SrcBlock "Sine Wave"
SrcPort 1
DstBlock "adc_filter"
DstPort 1
}
Line {
SrcBlock "adc_filter"
SrcPort 1
Points [75, 0]
Branch {
DstBlock "Mux"
DstPort 2
}
Branch {
Points [0, 55; -325, 0; 0, -170]
DstBlock "temperature"
DstPort 1
}
}
}
}
# Finite State Machines
# -- File save dated 10-Mar-1999 09:11:39
#
# Stateflow Version 2.0 (R11) dated Jan 21 1999, 19:12:04
#
#
Stateflow {
machine {
id 1
name "a2d"
created "24-Feb-1999 09:50:15"
firstTarget 23
sfVersion 20011061
}
chart {
id 2
name "temperature"
windowPosition [417.75 76.5 293.25 303.75]
viewLimits [1.158460633432711 247.8415393665673 0 264.4620393625497]
zoomFactor 0.9877200349675058
screen [1 1 1024 768 1.333333333333333]
treeNode [0 3 0 0]
machine 1
decomposition CLUSTER_CHART
firstEvent 18
firstData 20
chartFileNumber 1
}
state {
id 3
labelString "Temperature"
position [8.5 5.294507692208072 232 251.2389373944222]
fontSize 14
arrowSize 10
chart 2
treeNode [2 4 0 0]
firstTransition 10
firstJunction 7
type OR_STATE
decomposition CLUSTER_STATE
}
state {
id 4
labelString "HIGH\n"
"range=1;"
position [170 186.6820807471505 66.25 59.19442970221411]
fontSize 14
arrowSize 10
chart 2
treeNode [3 0 0 5]
type OR_STATE
decomposition CLUSTER_STATE
}
state {
id 5
labelString "LOW\n"
"range=-1;"
position [17.24999999999999 186.705749577689 65.49999999999999 59.19340062262546]
fontSize 14
arrowSize 10
chart 2
treeNode [3 0 4 6]
type OR_STATE
decomposition CLUSTER_STATE
}
state {
id 6
labelString "MEDIUM\n"
"range=0;"
position [92.75 187.4325952869449 64.75000000000003 58.44365789252265]
fontSize 14
arrowSize 10
chart 2
treeNode [3 0 5 0]
type OR_STATE
decomposition CLUSTER_STATE
}
junction {
id 7
position [63.75 43.69449604225048 8]
chart 2
linkNode [3 0 8]
type CONNECTIVE_JUNCTION
}
junction {
id 8
position [131.75 72.81508928398063 8]
chart 2
linkNode [3 7 9]
type CONNECTIVE_JUNCTION
}
junction {
id 9
position [115 144.7438255224682 8]
chart 2
linkNode [3 8 0]
type CONNECTIVE_JUNCTION
}
transition {
id 10
labelPosition [33.91996840190809 34.07920150862302 9.630270340933183 17.7789606294151]
fontSize 14
src {
id 3
intersection [4 1 0 0.8468139290601172 8.5 43.78081337877081]
}
dst {
id 7
intersection [0 -0.8285031319032356 -0.5599844287357729 -1 57.12197494477412
39.21462061236429]
}
midPoint [23.54210869842284 38.71801115752278]
chart 2
linkNode [3 0 11]
dataLimits [8.50000000000005 57.12197494477412 32.50639949895715 43.78081337877079]
}
transition {
id 11
labelString "{adc_fire();}"
labelPosition [97.81809252919324 35.33821158687081 74.07900262256295 17.7789606294151]
fontSize 14
src {
id 7
intersection [0 0.9998200190453952 -0.01897180845532943 -1 71.74856015236315
43.54272157460784]
}
dst {
id 8
intersection [0 -0.9030839334216827 -0.4294640953509638 -1 124.5253285326266
69.37937652117292]
}
midPoint [89.11092967277776 47.50433578849576]
chart 2
linkNode [3 10 12]
dataLimits [71.74856015236318 124.5253285326266 43.54272157460785 69.37937652117292]
}
transition {
id 12
labelPosition [40.86934762902597 65.30185799583947 9.630270340933183 17.7789606294151]
fontSize 14
src {
intersection [0 0 0 0 38 69]
}
dst {
id 7
intersection [0 -0.7786211342393336 0.6274943261224389 -1 57.52103092608533
48.71445065122999]
}
midPoint [42.86406332575138 63.13693951962485]
chart 2
linkNode [3 11 13]
dataLimits [38 57.52103092608533 48.71445065122999 69]
}
transition {
id 13
labelString "[adc_busy()]"
labelPosition [151.051043900759 78.33231989215332 78.52374277991672 17.7789606294151]
fontSize 14
src {
id 8
intersection [0 0.8805487577672823 -0.4739555730176578 -1 138.7943900621383
69.02344469983936]
}
dst {
id 8
intersection [0 0.817771692970746 0.5755427509540537 -1 138.292173543766
77.41943129161305]
}
midPoint [156.75 72.79733766107685]
chart 2
linkNode [3 12 14]
dataLimits [138.292173543766 156.7135676006469 68.09128513919299 83.98642536237527]
}
transition {
id 14
labelString "{adc_read;}"
labelPosition [40.34210348301397 91.20755319059819 73.33821259633731 17.7789606294151]
fontSize 14
src {
id 8
intersection [0 -0.4938971758433887 0.8695203158603742 -1 127.7988225932529
79.77125181086362]
}
dst {
id 9
intersection [0 0.4992450395362414 -0.8664608418725319 -1 118.9939603162899
137.812138787488]
}
midPoint [125.3043283664362 97.0698333901516]
chart 2
linkNode [3 13 15]
dataLimits [118.9939603162899 127.798822593253 79.77125181086367 137.812138787488]
}
transition {
id 15
labelString "[value>0.5]"
labelPosition [150.5176578559274 125.9778080204219 69.63426246520918 17.7789606294151]
fontSize 14
arrowSize 10
src {
id 9
intersection [0 0.9944016874112431 -0.1056659078117079 -1 122.9552134992899
143.8984982599746]
}
dst {
id 4
intersection [1 0 -1 0.497907949790795 202.9864016736402 186.6820807471505]
}
midPoint [157.3786248736368 144.1702522688625]
chart 2
linkNode [3 14 16]
dataLimits [122.9552134992903 205.9864016736402 142.7975815823997 186.6820807471505]
}
transition {
id 16
labelPosition [125.3703143424389 166.5884073371224 9.630270340933183 17.7789606294151]
fontSize 14
arrowSize 10
src {
id 9
intersection [0 0.753784088931555 0.6571221707366337 -1 121.0302727114524
150.0008028883613]
}
dst {
id 6
intersection [1 0 -1 0.4602510460251046 122.5512552301255 187.4325952869449]
}
midPoint [125.7280615787429 158.4861396543739]
chart 2
linkNode [3 15 17]
dataLimits [119.5512552301255 126.0152935305172 150.0008028883613 187.4325952869449]
}
transition {
id 17
labelString "[value<-0.5]"
labelPosition [24.16858039055828 140.5680058803927 74.07900262256295 17.7789606294151]
fontSize 14
arrowSize 10
src {
id 9
intersection [0 -0.3376753145513762 0.9412626530053283 -1 112.298597483589
152.2739267465109]
}
dst {
id 5
intersection [1 0 -1 0.4309623430962346 45.47803347280335 186.705749577689]
}
midPoint [89.89834926161907 163.5345097322301]
chart 2
linkNode [3 16 0]
dataLimits [42.47803347280335 112.2985974835889 152.2739267465107 186.705749577689]
}
event {
id 18
name "CLOCK"
linkNode [2 0 19]
scope INPUT_EVENT
trigger EITHER_EDGE_EVENT
machine 1
}
event {
id 19
name "adc_read"
linkNode [2 18 0]
scope OUTPUT_EVENT
trigger FUNCTION_CALL_EVENT
machine 1
}
data {
id 20
name "value"
linkNode [2 0 21]
scope INPUT_DATA
machine 1
dataType "double"
}
data {
id 21
name "range"
linkNode [2 20 0]
scope OUTPUT_DATA
machine 1
dataType "double"
}
instance {
id 22
name "temperature"
machine 1
chart 2
}
target {
id 23
name "sfun"
description "Default Simulink S-Function Target."
customCode "void adc_fire(void)\n"
"{\n"
"}\n"
"\n"
"unsigned char adc_busy(void)\n"
"{\n"
"return 0;\n"
"}"
machine 1
linkNode [1 0 0]
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -