终端一体化运控平台
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

79 rivejä
2.8 KiB

  1. using System;
  2. using System.Collections.Generic;
  3. using System.Collections.ObjectModel;
  4. using System.Diagnostics;
  5. using System.Linq;
  6. using System.Text;
  7. using System.Threading.Tasks;
  8. using BPA.Helper;
  9. namespace BPASmartClient.DosingSystemSingle
  10. {
  11. /// <summary>
  12. /// 基础参数
  13. /// </summary>
  14. public class BasePar : NotifyBase
  15. {
  16. /// <summary>
  17. /// 设备扫描网段
  18. /// </summary>
  19. public string NetworkSegAddress { get { return _mNetworkSegAddress; } set { _mNetworkSegAddress = value; OnPropertyChanged(); } }
  20. private string _mNetworkSegAddress = "192.168.0.";
  21. /// <summary>
  22. /// 输送带设备 PLC IP 地址
  23. /// </summary>
  24. public string DeviceAddress { get { return _mDeviceAddress; } set { _mDeviceAddress = value; OnPropertyChanged(); } }
  25. private string _mDeviceAddress = "192.168.0.15";
  26. /// <summary>
  27. /// 输送带数量
  28. /// </summary>
  29. public int ConveyerBeltCount
  30. {
  31. get { return _mConveyerBeltCount; }
  32. set
  33. {
  34. _mConveyerBeltCount = value;
  35. //var temp = ConveyerBeltModels;
  36. //App.Current.Dispatcher.Invoke(() => { ConveyerBeltModels.Clear(); });
  37. //for (int i = 0; i < value; i++)
  38. //{
  39. // App.Current.Dispatcher.Invoke(() =>
  40. // {
  41. // ConveyerBeltModels.Add(new ConveyerBeltModel()
  42. // {
  43. // Name = $"输送带{i + 1}速度",
  44. // Num = i + 1,
  45. // Speed = (i >= 0 && i < temp.Count) ? temp.ElementAt(i).Speed : 0
  46. // });
  47. // });
  48. //}
  49. OnPropertyChanged();
  50. }
  51. }
  52. private int _mConveyerBeltCount = 0;
  53. /// <summary>
  54. /// 升降气缸数量
  55. /// </summary>
  56. public int LiftCylinderCount { get { return _mLiftCylinderCount; } set { _mLiftCylinderCount = value; OnPropertyChanged(); } }
  57. private int _mLiftCylinderCount = 0;
  58. /// <summary>
  59. /// 阻挡气缸数量
  60. /// </summary>
  61. public int BlockCylinderCount { get { return _mBlockCylinderCount; } set { _mBlockCylinderCount = value; OnPropertyChanged(); } }
  62. private int _mBlockCylinderCount = 0;
  63. /// <summary>
  64. /// 托盘气缸数量
  65. /// </summary>
  66. public int PalletCylinderCount { get { return _mPalletCylinderCount; } set { _mPalletCylinderCount = value; OnPropertyChanged(); } }
  67. private int _mPalletCylinderCount = 0;
  68. //public ObservableCollection<ConveyerBeltModel> ConveyerBeltModels { get; set; } = new ObservableCollection<ConveyerBeltModel>();
  69. }
  70. }