using Misc; using System; using System.Collections.Generic; using System.Collections.ObjectModel; using System.Linq; using System.Net; using System.Text; using System.Threading.Tasks; namespace FlyADBase { /// /// 客户端AD盒附加的功能 /// public interface IFlyADClientAdv : IFlyADClient { /// /// 通过脉冲计算速度,不使用AD盒的输出 /// bool IsCalSpeed { get; set; } /// /// 机架修正 /// CorrectADsHandler CorrectADs { get; set; } /// /// grid 滤波 /// int GridSmooth { get; set; } /// /// 脉冲比例 Ratio02(编码器脉冲) / Ratio01(电机脉冲) /// double Speed1Scale { get; } #region 备份参数 MOTORTYPE Backup_MotorType { get; } UInt16 Backup_PosOfGrid { get; } UInt16 Backup_Ratio01 { get; } UInt16 Backup_Ratio02 { get; } Int16 Backup_PosOffset { get; } UInt32 Backup_JogVelocity { get; } #endregion /// /// 机架总长 /// int PosLen { get; set; } /// /// 使用独立的脉冲最大最小值 /// bool HasPosMaxMin { get; set; } /// /// 最小脉冲,默认是0 /// int PosMin { get; set; } /// /// 最大脉冲,默认于PosLen 一样 /// int PosMax { get; set; } /// /// Runto(0), 不同于 Backward /// void RuntoMin(); /// /// Runto(PosLen), 不同于 Forward /// void RuntoMax(); /// /// 设置输出 /// /// /// void SetOutputBit(int index, bool is1); /// /// 从正反缓存区, 获取grid数据 /// /// 方向, 只有 正,反 /// grid 开始位置 /// grid 长度 /// grid 数据 void GetGrid(DIRECTION direction, int grid_start, int grid_len, out int[] dat); /// /// 从正反缓存区, 获取全部grid数据 /// /// 方向, 只有 正,反 /// grid 数据 void GetGrid(DIRECTION direction, out int[] dat); /// /// 动作完成 /// bool IsFinish { get; } #region 滞后处理 /// /// ad滞后修正 单位ms /// int ADLag { get; set; } /// /// 以timegrid 为单位,推送数据 /// event TimeGridAdv2EventHandler TimeGridAdv2Event; #endregion } /// /// 机架修正 /// /// /// /// public delegate void CorrectADsHandler(Misc.DIRECTION direction, int start_grid, int[] dat); }