using System;
using Zaber.Motion;
using Zaber.Motion.Ascii;
namespace ZaberMotion
{
class Program
{
static Axis x_axis;
static Device device1;
public static void Main(string[] args)
{
Library.EnableDeviceDbStore();
using (var connection = Connection.OpenSerialPort("COM3"))
{
var deviceList = connection.DetectDevices();
Console.WriteLine($"Found {deviceList.Length} devices.");
var speed = x_axis.Settings.Get("maxspeed",Units.Velocity_MillimetresPerSecond);
Console.WriteLine("Maximum speed [mm/s]: {0}", speed);
x_axis.Settings.Set("maxspeed", speed /9.0,Units.Velocity_MillimetresPerSecond);
}
}
}
}
我得到 var speed 的空值。简单的错误我不确定如何解决。有小费吗?设备初始化,一切顺利