Вверх ↑
Ответов: 83
Рейтинг: 0
#1: 2018-12-05 08:38:31 ЛС | профиль | цитата
Вот что у меня получилось.

Add(MainForm,2953706,21,105)
{
Width=635
Height=525
link(onCreate,7366341:doEvent1,[(111,125)(111,188)])
}
Add(If_else,14926331,539,308)
{
Type=5
Op2=String()
link(onTrue,16418445:doSearch,[])
}
Add(Image,1372838,504,101)
{
Left=20
Top=10
Width=150
Height=145
Color=-16777216
Ctl3D=0
WinStyle=4
}
Add(Button,13788814,210,108)
{
Left=90
Top=115
Width=60
Height=30
Font=[MS Sans Serif,8,1,0,1]
WinStyle=4
Caption="закрыт"
Point(doCaption)
link(onClick,3440661:doSwitch,[(258,114)(258,125)])
}
Add(ComboBox,15701961,462,199)
{
Left=90
Top=85
Width=60
Height=21
Color=-16777194
WinStyle=4
Strings=#3:300|3:600|4:1200|4:2400|4:4800|4:9600|5:14400|5:19200|5:28800|5:38400|5:57600|6:115200|
Text=""
Point(doSelect)
Point(doEnabled)
}
Add(ComboBox,12845684,413,171)
{
Left=90
Top=60
Width=40
Height=21
Color=-16777194
WinStyle=4
Text=""
DataType=1
Point(doSelect)
Point(doEnabled)
}
Add(Label,6975071,462,101)
{
Left=45
Top=65
Width=38
Height=17
Color=-16777216
WinStyle=4
Caption="Номер"
}
Add(Label,7375579,504,143)
{
Left=50
Top=35
Width=84
Height=20
Color=-16777216
Font=[MS Sans Serif,10,1,0,1]
WinStyle=4
Caption="СОМ-ПОРТ"
}
Add(Label,175544,462,143)
{
Left=30
Top=90
Width=52
Height=17
Color=-16777216
WinStyle=4
Caption="Скорость"
}
Add(LED,4919888,413,101)
{
Left=40
Top=115
Width=30
Height=30
Color=-16777216
WinStyle=4
Blick=1
ColorOn=32768
ColorOff=65280
Value=0
link(onChange,7757098:doEvent1,[(450,107)(450,175)(324,175)(324,237)])
}
Add(Hub,16033944,336,147)
{
link(onEvent1,4919888:doOff,[(374,153)(374,114)])
link(onEvent2,16655693:doOpen,[(392,160)(392,307)])
}
Add(Hub,4850852,336,126)
{
link(onEvent1,4919888:doOn,[(382,132)(382,121)])
link(onEvent2,16655693:doClose,[(399,139)(399,314)])
}
Add(Switch,3440661,273,119)
{
DataOn=String(открыт)
DataOff=String(закрыт)
Point(State)
Point(onOff)
Point(onOn)
link(onSwitch,13788814:doCaption,[(317,125)(318,126)(318,111)(204,111)(204,114)])
link(onOff,4850852:doEvent1,[])
link(onOn,16033944:doEvent1,[(324,139)(324,153)])
}
Add(COM,16655693,462,301)
{
link(onRead,14926331:doCompare,[])
link(Port,12845684:String,[(468,283)(426,283)])
link(BaudRate,15701961:String,[])
}
Add(DoData,695163,273,252)
{
Data=Integer(7)
link(onEventData,15701961:doSelect,[(383,258)(383,247)])
}
Add(EnumCOM,1016600,273,182)
{
OutType=0
link(onEnumPorts,12845684:doAdd,[(359,188)(359,177)])
}
Add(Hub,7366341,168,182)
{
OutCount=3
link(onEvent1,1016600:doEnumPorts,[])
link(onEvent2,695163:doData,[(248,195)(248,258)])
link(onEvent3,4404277:doTimer,[(210,202)(210,314)])
}
Add(Hub,7757098,336,231)
{
link(onEvent1,12845684:doEnabled,[(382,237)(382,226)])
link(onEvent2,15701961:doEnabled,[(361,244)(361,254)])
}
Add(Timer,4404277,238,308)
{
Interval=200
link(onTimer,13091773:doData,[])
}
Add(DoData,13091773,294,308)
{
Data=Integer(48)
link(onEventData,16655693:doRead,[(394,314)(394,335)])
}
Add(BlockFind,16418445,651,308)
{
IncludeBlock=1
StartBlock="T="
EndBlock="C"
link(onSearch,9453662:doEvent1,[])
}
Add(Label,6604675,504,189)
{
Left=250
Top=15
Width=212
Height=41
Font=[MS Sans Serif,24,0,0,1]
Caption="Температура "
}
Add(PlotLines,11145754,826,364)
{
Grapher="температура в КИПе КТСМ"
Size=5
Step=1
Name="A1"
link(ValueY,12123648:GetData,[])
}
Add(Hub,9453662,735,308)
{
OutCount=3
link(onEvent1,6991285:doText,[(773,314)(773,272)])
link(onEvent2,12123648:doData,[])
link(onEvent3,11145754:doAdd,[(787,328)(787,370)])
}
Add(Plotter,6761042,826,217)
{
Left=20
Top=195
Width=600
Height=290
Name="температура в КИПе КТСМ"
MaxH=40
}
Add(Edit,6991285,826,266)
{
Left=300
Top=75
Width=105
Height=40
Font=[MS Sans Serif,24,1,0,1]
Text=""
}
Add(EventFromData,12123648,826,315)
{
}

Как по оси Х сделать, что бы график начинался с нуля, а не с первого значения

--- Добавлено в 2018-12-05 08:39:28

смотреть тут сории

Add(MainForm,2953706,21,105)
{
Width=635
Height=525
link(onCreate,7366341:doEvent1,[(111,125)(111,188)])
}
Add(If_else,14926331,539,308)
{
Type=5
Op2=String()
link(onTrue,16418445:doSearch,[])
}
Add(Image,1372838,504,101)
{
Left=20
Top=10
Width=150
Height=145
Color=-16777216
Ctl3D=0
WinStyle=4
}
Add(Button,13788814,210,108)
{
Left=90
Top=115
Width=60
Height=30
Font=[MS Sans Serif,8,1,0,1]
WinStyle=4
Caption="закрыт"
Point(doCaption)
link(onClick,3440661:doSwitch,[(258,114)(258,125)])
}
Add(ComboBox,15701961,462,199)
{
Left=90
Top=85
Width=60
Height=21
Color=-16777194
WinStyle=4
Strings=#3:300|3:600|4:1200|4:2400|4:4800|4:9600|5:14400|5:19200|5:28800|5:38400|5:57600|6:115200|
Text=""
Point(doSelect)
Point(doEnabled)
}
Add(ComboBox,12845684,413,171)
{
Left=90
Top=60
Width=40
Height=21
Color=-16777194
WinStyle=4
Text=""
DataType=1
Point(doSelect)
Point(doEnabled)
}
Add(Label,6975071,462,101)
{
Left=45
Top=65
Width=38
Height=17
Color=-16777216
WinStyle=4
Caption="Номер"
}
Add(Label,7375579,504,143)
{
Left=50
Top=35
Width=84
Height=20
Color=-16777216
Font=[MS Sans Serif,10,1,0,1]
WinStyle=4
Caption="СОМ-ПОРТ"
}
Add(Label,175544,462,143)
{
Left=30
Top=90
Width=52
Height=17
Color=-16777216
WinStyle=4
Caption="Скорость"
}
Add(LED,4919888,413,101)
{
Left=40
Top=115
Width=30
Height=30
Color=-16777216
WinStyle=4
Blick=1
ColorOn=32768
ColorOff=65280
Value=0
link(onChange,7757098:doEvent1,[(450,107)(450,175)(324,175)(324,237)])
}
Add(Hub,16033944,336,147)
{
link(onEvent1,4919888:doOff,[(374,153)(374,114)])
link(onEvent2,16655693:doOpen,[(392,160)(392,307)])
}
Add(Hub,4850852,336,126)
{
link(onEvent1,4919888:doOn,[(382,132)(382,121)])
link(onEvent2,16655693:doClose,[(399,139)(399,314)])
}
Add(Switch,3440661,273,119)
{
DataOn=String(открыт)
DataOff=String(закрыт)
Point(State)
Point(onOff)
Point(onOn)
link(onSwitch,13788814:doCaption,[(317,125)(318,126)(318,111)(204,111)(204,114)])
link(onOff,4850852:doEvent1,[])
link(onOn,16033944:doEvent1,[(324,139)(324,153)])
}
Add(COM,16655693,462,301)
{
link(onRead,14926331:doCompare,[])
link(Port,12845684:String,[(468,283)(426,283)])
link(BaudRate,15701961:String,[])
}
Add(DoData,695163,273,252)
{
Data=Integer(7)
link(onEventData,15701961:doSelect,[(383,258)(383,247)])
}
Add(EnumCOM,1016600,273,182)
{
OutType=0
link(onEnumPorts,12845684:doAdd,[(359,188)(359,177)])
}
Add(Hub,7366341,168,182)
{
OutCount=3
link(onEvent1,1016600:doEnumPorts,[])
link(onEvent2,695163:doData,[(248,195)(248,258)])
link(onEvent3,4404277:doTimer,[(210,202)(210,314)])
}
Add(Hub,7757098,336,231)
{
link(onEvent1,12845684:doEnabled,[(382,237)(382,226)])
link(onEvent2,15701961:doEnabled,[(361,244)(361,254)])
}
Add(Timer,4404277,238,308)
{
Interval=200
link(onTimer,13091773:doData,[])
}
Add(DoData,13091773,294,308)
{
Data=Integer(48)
link(onEventData,16655693:doRead,[(394,314)(394,335)])
}
Add(BlockFind,16418445,651,308)
{
IncludeBlock=1
StartBlock="T="
EndBlock="C"
link(onSearch,9453662:doEvent1,[])
}
Add(Label,6604675,504,189)
{
Left=250
Top=15
Width=212
Height=41
Font=[MS Sans Serif,24,0,0,1]
Caption="Температура "
}
Add(PlotLines,11145754,826,364)
{
Grapher="температура в КИПе КТСМ"
Size=5
Step=1
Name="A1"
link(ValueY,12123648:GetData,[])
}
Add(Hub,9453662,735,308)
{
OutCount=3
link(onEvent1,6991285:doText,[(773,314)(773,272)])
link(onEvent2,12123648:doData,[])
link(onEvent3,11145754:doAdd,[(787,328)(787,370)])
}
Add(Plotter,6761042,826,217)
{
Left=20
Top=195
Width=600
Height=290
Name="температура в КИПе КТСМ"
MaxH=40
}
Add(Edit,6991285,826,266)
{
Left=300
Top=75
Width=105
Height=40
Font=[MS Sans Serif,24,1,0,1]
Text=""
}
Add(EventFromData,12123648,826,315)
{
}

карма: 0

0
Редактировалось 1 раз(а), последний 2018-12-05 08:39:28