using BPA.Helper; using FryPot_DosingSystem.Control; using BPA.Helper; using System; using System.Collections.Generic; using System.Collections.ObjectModel; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Input; namespace FryPot_DosingSystem.ViewModel { internal class DebugViewModel : NotifyBase { public ObservableCollection LineOneRollerCode { get; set; } = new ObservableCollection() { 101,102,103,104,105,106,107,108,401,402,403,404,405,406,407,408}; public ObservableCollection LineTwoRollerCode { get; set; } = new ObservableCollection() {201,202,203,204,205,206,207,208,501,502,503,504,505,506,507,508 }; public ObservableCollection LineThreeRollerCode { get; set; } = new ObservableCollection() { 301,302,303,304,305,306,307,308}; //滚筒线1绑定命令 public BPARelayCommand RollerLineRunning { get; set; } public BPARelayCommand EightWorkLoc { get; set; } public BPARelayCommand FryPotInputArrive { get; set; } public BPARelayCommand FryPotEmptyRollerArrive { get; set; } public BPARelayCommand LineOneTaskExit { get; set; } public BPARelayCommand LineOneRecipeComSignal { get; set; } public BPARelayCommand AGVLOneArrive { get; set; } public BPARelayCommand AGVFryPotDownArrive { get; set; } public BPARelayCommand AGVFryPotUpArrive { get; set; } public BPARelayCommand AGVFryPotGetEmptyRoller { get; set; } public BPARelayCommand AGVLineOneLoadCom { get; set; }//线体1上料完成 //滚筒线2绑定命令 public BPARelayCommand RollerLineTwoRunning { get; set; } //public BPARelayCommand EightWorkLoc { get; set; } public BPARelayCommand FryPotTwoInputArrive { get; set; } public BPARelayCommand FryPotTwoEmptyRollerArrive { get; set; } public BPARelayCommand LineTwoTaskExit { get; set; } public BPARelayCommand LineTwoRecipeComSignal { get; set; } public BPARelayCommand AGVLTwoArrive { get; set; } public BPARelayCommand AGVFryPotTwoDownArrive { get; set; } public BPARelayCommand AGVFryPotTwoUpArrive { get; set; } public BPARelayCommand AGVFryPotTwoGetEmptyRoller { get; set; } public BPARelayCommand AGVLineTwoLoadCom { get; set; }//线体2上料完成 //滚筒线3绑定命令 public BPARelayCommand RollerLineThreeRunning { get; set; } //public BPARelayCommand EightWorkLoc { get; set; } public BPARelayCommand FryPotThreeInputArrive { get; set; } public BPARelayCommand FryPotThreeEmptyRollerArrive { get; set; } public BPARelayCommand LineThreeTaskExit { get; set; } public BPARelayCommand LineThreeRecipeComSignal { get; set; } public BPARelayCommand AGVLThreeArrive { get; set; } public BPARelayCommand AGVFryPotThreeDownArrive { get; set; } public BPARelayCommand AGVFryPotThreeUpArrive { get; set; } public BPARelayCommand AGVFryPotThreeGetEmptyRoller { get; set; } public BPARelayCommand AGVLineThreeLoadCom { get; set; }//线体3上料完成 //AGV接口联调 public BPARelayCommand AgvDebug { get; set; } //线体123空桶清洗以及回收 public BPARelayCommand AgvArriveLineOneEmptyRollerLoc { get; set; } public BPARelayCommand AgvLineOneLoadEmptyCom { get; set; } public BPARelayCommand AgvArriveLineTwoEmptyRollerLoc { get; set; } public BPARelayCommand AgvLineTwoLoadEmptyCom { get; set; } public BPARelayCommand AgvArriveLineThreeEmptyRollerLoc { get; set; } public BPARelayCommand AgvLineThreeLoadEmptyCom { get; set; } public BPARelayCommand CleanPlateCallAgv { get; set; } public BPARelayCommand AgvArriveCleanPlateLoc { get; set; }//下料 public BPARelayCommand AgvArriveCleanPlateLocCom { get; set; }//下料完成 public BPARelayCommand AgvArriveLineFourLoc { get; set; }//下料 public BPARelayCommand AgvArriveLineFourLocCom { get; set; }//4号线空桶下料完成 public BPARelayCommand AgvArriveCleanPlateLocLoad { get; set; }//上料 public BPARelayCommand AgvArriveCleanPlateLocLoadCom { get; set; }//上料完成 public BPARelayCommand EmptyRollerCleanTaskRestart { get; set; } public BPARelayCommand LineTwoEmptyRollerCleanTaskRestart { get; set; } public BPARelayCommand LineThreeEmptyRollerCleanTaskRestart { get; set; } public DebugViewModel() { AgvDebug = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AgvDebug"); })); AgvArriveCleanPlateLocCom = new BPARelayCommand(() => { ActionManage.GetInstance.Send("AgvArriveCleanPlateLocCom"); }); AgvArriveLineFourLocCom = new BPARelayCommand(() => { ActionManage.GetInstance.Send("AgvArriveLineFourLocCom"); }); AgvArriveCleanPlateLocLoadCom = new BPARelayCommand(() => { ActionManage.GetInstance.Send("AgvArriveCleanPlateLocLoadCom"); }); LineOneRecipeComSignal = new BPARelayCommand(() => { ActionManage.GetInstance.Send("LineOneRecipeComSignal"); }); LineTwoRecipeComSignal = new BPARelayCommand(() => { ActionManage.GetInstance.Send("LineTwoRecipeComSignal"); }); LineThreeRecipeComSignal = new BPARelayCommand(() => { ActionManage.GetInstance.Send("LineThreeRecipeComSignal"); }); EmptyRollerCleanTaskRestart = new BPARelayCommand(() => { ActionManage.GetInstance.Send("EmptyRollerCleanTaskRestart"); }); LineTwoEmptyRollerCleanTaskRestart = new BPARelayCommand(() => { ActionManage.GetInstance.Send("LineTwoEmptyRollerCleanTaskRestart"); }); LineThreeEmptyRollerCleanTaskRestart = new BPARelayCommand(() => { ActionManage.GetInstance.Send("LineThreeEmptyRollerCleanTaskRestart"); }); AgvLineOneLoadEmptyCom = new BPARelayCommand(() => { ActionManage.GetInstance.Send("AgvLineOneLoadEmptyCom"); }); AgvLineTwoLoadEmptyCom = new BPARelayCommand(() => { ActionManage.GetInstance.Send("AgvLineTwoLoadEmptyCom"); }); AgvLineThreeLoadEmptyCom = new BPARelayCommand(() => { ActionManage.GetInstance.Send("AgvLineThreeLoadEmptyCom"); }); AGVLineOneLoadCom = new BPARelayCommand(() => { ActionManage.GetInstance.Send("AGVLineOneLoadCom"); }); AGVLineTwoLoadCom = new BPARelayCommand(() => { ActionManage.GetInstance.Send("AGVLineTwoLoadCom"); }); AGVLineThreeLoadCom = new BPARelayCommand(() => { ActionManage.GetInstance.Send("AGVLineThreeLoadCom"); }); AgvArriveLineOneEmptyRollerLoc = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AgvArriveLineOneEmptyRollerLoc"); })); AgvArriveLineTwoEmptyRollerLoc = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AgvArriveLineTwoEmptyRollerLoc"); })); AgvArriveLineThreeEmptyRollerLoc = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AgvArriveLineThreeEmptyRollerLoc"); })); CleanPlateCallAgv = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("CleanPlateCallAgv"); })); AgvArriveCleanPlateLoc = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AgvArriveCleanPlateLoc"); })); AgvArriveCleanPlateLocLoad = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AgvArriveCleanPlateLocLoad"); })); AgvArriveLineFourLoc = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AgvArriveLineFourLoc"); })); RollerLineRunning = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("RollerLineRunning"); })); FryPotInputArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("FryPotInputArrive"); })); FryPotEmptyRollerArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("FryPotEmptyRollerArrive"); })); AGVLOneArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVLOneArrive"); })); AGVFryPotDownArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVFryPotDownArrive"); })); AGVFryPotUpArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVFryPotUpArrive"); })); AGVFryPotGetEmptyRoller = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVFryPotGetEmptyRoller"); })); //滚筒线2 RollerLineTwoRunning = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("RollerLineTwoRunning"); })); FryPotTwoInputArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("FryPotTwoInputArrive"); })); FryPotTwoEmptyRollerArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("FryPotTwoEmptyRollerArrive"); })); AGVLTwoArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVLTwoArrive"); })); AGVFryPotTwoDownArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVFryPotTwoDownArrive"); })); AGVFryPotTwoUpArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVFryPotTwoUpArrive"); })); AGVFryPotTwoGetEmptyRoller = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVFryPotTwoGetEmptyRoller"); })); //滚筒线3 RollerLineThreeRunning = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("RollerLineThreeRunning"); })); FryPotThreeInputArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("FryPotThreeInputArrive"); })); FryPotThreeEmptyRollerArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("FryPotThreeEmptyRollerArrive"); })); AGVLThreeArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVLThreeArrive"); })); AGVFryPotThreeDownArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVFryPotThreeDownArrive"); })); AGVFryPotThreeUpArrive = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVFryPotThreeUpArrive"); })); AGVFryPotThreeGetEmptyRoller = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("AGVFryPotThreeGetEmptyRoller"); })); LineOneTaskExit = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("LineOneTaskExit"); })); LineTwoTaskExit = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("LineTwoTaskExit"); })); LineThreeTaskExit = new BPARelayCommand(new Action(() => { ActionManage.GetInstance.Send("LineThreeTaskExit"); })); } } }