C#运动控制系统:雷赛控制卡实用完整例子 C#雷赛开发快速入门 C#雷赛运动控制系统实战例子 C#快速开发雷赛控制卡
雷赛控制技术 DMC系列运动控制卡是一款新型的 PCI/PCIe 总线运动控制卡。可以控制多个步进电机或数字式伺服电机;适合于多轴点位运动、插补运动、轨迹规划、手轮控制、编码器位置检测、IO 控制、位置比较、位置锁存等功能的应用。
DMC3000 系列卡的运动控制函数库功能丰富、易学易用,用户开发应用软件十分方便。随卡免费提供的雷赛控制卡 Motion 调试软件,不但可以演示 DMC系列卡的控制功能,而且可用于控制卡及运动控制系统的硬件测试。
源码下载----》 源码下载
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*" />
<RowDefinition Height="2.5*" />
</Grid.RowDefinitions>
<GroupBox Margin="5" Header="轴位置和状态">
<DockPanel>
<Button
Width="120"
Margin="10"
VerticalAlignment="Top"
Command="{Binding InitCommand}"
Content="位置清零"
DockPanel.Dock="Right" />
<UniformGrid Columns="4">
<DockPanel Height="25" Margin="5">
<TextBlock Text="X轴位置:" />
<TextBox IsReadOnly="True" Text="{Binding Xpos}" />
</DockPanel>
<DockPanel Height="25" Margin="5">
<TextBlock Text="Y轴位置:" />
<TextBox IsReadOnly="True" Text="{Binding Ypos}" />
</DockPanel>
<DockPanel Height="25" Margin="5">
<TextBlock Text="Z轴位置:" />
<TextBox IsReadOnly="True" Text="{Binding Zpos}" />
</DockPanel>
<DockPanel Height="25" Margin="5">
<TextBlock Text="运动状态:" />
<TextBox IsReadOnly="True" Text="{Binding CrdStatu}" />
</DockPanel>
<DockPanel Height="25" Margin="5">
<TextBlock Text="X轴速度:" />
<TextBox IsReadOnly="True" Text="{Binding Xspeed}" />
</DockPanel>
<DockPanel Height="25" Margin="5">
<TextBlock Text="Y轴速度:" />
<TextBox IsReadOnly="True" Text="{Binding Yspeed}" />
</DockPanel>
<DockPanel Height="25" Margin="5">
<TextBlock Text="Z轴速度:" />
<TextBox IsReadOnly="True" Text="{Binding Zspeed}" />
</DockPanel>
</UniformGrid>
</DockPanel>
</GroupBox>
<GroupBox
Grid.Row="1"
Margin="5"
Header="插补运动">
<UniformGrid Columns="2">
<Grid Margin="10">
<Grid.RowDefinitions>
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<TextBlock
Grid.Row="0"
Grid.Column="0"
Text="坐标系号" />
<TextBlock
Grid.Row="1"
Grid.Column="0"
Text="起始速度" />
<TextBlock
Grid.Row="2"
Grid.Column="0"
Text="运行速度" />
<TextBlock
Grid.Row="3"
Grid.Column="0"
Text="加速时间" />
<TextBlock
Grid.Row="4"
Grid.Column="0"
Text="减速时间" />
<TextBlock
Grid.Row="5"
Grid.Column="0"
Text="停止速度" />
<TextBlock
Grid.Row="6"
Grid.Column="0"
Text="运动模式:0-相对 1-绝对" />
<TextBox
Grid.Row="0"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding crdNumLN}" />
<TextBox
Grid.Row="1"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding StartVelLN}" />
<TextBox
Grid.Row="2"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding MaxVelLN}" />
<TextBox
Grid.Row="3"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding TaccLN}" />
<TextBox
Grid.Row="4"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding TdecLN}" />
<TextBox
Grid.Row="5"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding StopVelLN}" />
<TextBox
Grid.Row="6"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding ModeLN}" />
<Button
Grid.Row="7"
Grid.Column="0"
Margin="5,0"
Command="{Binding SrartLNCommand}"
Content="直线插补" />
<Button
Grid.Row="7"
Grid.Column="1"
Margin="5,0"
Command="{Binding StopCommand}"
Content="停止" />
</Grid>
<Grid Margin="10">
<Grid.RowDefinitions>
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<TextBlock
Grid.Row="0"
Grid.Column="0"
Text="坐标系号" />
<TextBlock
Grid.Row="1"
Grid.Column="0"
Text="起始速度" />
<TextBlock
Grid.Row="2"
Grid.Column="0"
Text="运行速度" />
<TextBlock
Grid.Row="3"
Grid.Column="0"
Text="加速时间" />
<TextBlock
Grid.Row="4"
Grid.Column="0"
Text="减速时间" />
<TextBlock
Grid.Row="5"
Grid.Column="0"
Text="停止速度" />
<TextBlock
Grid.Row="6"
Grid.Column="0"
Text="运动模式:0-相对 1-绝对" />
<TextBlock
Grid.Row="7"
Grid.Column="0"
Text="圆弧方向:0-顺时针 1逆时针" />
<TextBox
Grid.Row="0"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding crdNumArc}" />
<TextBox
Grid.Row="1"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding StartVelArc}" />
<TextBox
Grid.Row="2"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding MaxVelArc}" />
<TextBox
Grid.Row="3"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding TaccArc}" />
<TextBox
Grid.Row="4"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding TdecArc}" />
<TextBox
Grid.Row="5"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding StopVelArc}" />
<TextBox
Grid.Row="6"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding ModeArc}" />
<TextBox
Grid.Row="7"
Grid.Column="1"
Style="{x:Null}"
Text="{Binding DirArc}" />
<Button
Grid.Row="8"
Grid.Column="0"
Margin="5,0"
Command="{Binding SrartArcCommand}"
Content="圆弧插补" />
<Button
Grid.Row="8"
Grid.Column="1"
Margin="5,0"
Command="{Binding StopCommand}"
Content="停止" />
</Grid>
</UniformGrid>
</GroupBox>
</Grid>