|
|
@@ -121,7 +121,7 @@ public class Home1Fragment extends BaseFragment { |
|
|
|
|
|
|
|
|
|
|
|
@BindView(R.id.btn_jiaoban) |
|
|
|
Button btn_jiaoban;// |
|
|
|
SwitchButton btn_jiaoban;// |
|
|
|
@BindView(R.id.btn_zhuandong_control_left) |
|
|
|
Button btn_zhuandong_control_left;// |
|
|
|
@BindView(R.id.btn_zhuandong_control_Rift) |
|
|
@@ -387,14 +387,15 @@ public class Home1Fragment extends BaseFragment { |
|
|
|
} |
|
|
|
}; |
|
|
|
|
|
|
|
//搅拌 |
|
|
|
btn_jiaoban.setOnClickListener(new View.OnClickListener() { |
|
|
|
btn_jiaoban.setOnCheckedChangeListener(new SwitchButton.OnCheckedChangeListener() { |
|
|
|
@Override |
|
|
|
public void onClick(View view) { |
|
|
|
if (!IsMake(false)) |
|
|
|
{ |
|
|
|
return; |
|
|
|
} |
|
|
|
public void onCheckedChanged(SwitchButton view, boolean isChecked) { |
|
|
|
boolean ischick= btn_jiaoban.isChecked(); |
|
|
|
|
|
|
|
// if (!IsMake(false)) |
|
|
|
// { |
|
|
|
// return; |
|
|
|
// } |
|
|
|
int jd = (int) nifty_slider2.getValue(); |
|
|
|
ExecuteTheRecipe.WritePLC("搅拌速度", jd, new IWriteCallBack() { |
|
|
|
@Override |
|
|
@@ -402,7 +403,7 @@ public class Home1Fragment extends BaseFragment { |
|
|
|
if (jd == 0) { |
|
|
|
ExecuteTheRecipe.WritePLC("搅拌", false, null); |
|
|
|
} else { |
|
|
|
ExecuteTheRecipe.WritePLC("搅拌", true, null); |
|
|
|
ExecuteTheRecipe.WritePLC("搅拌", ischick, null); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
@@ -420,10 +421,10 @@ public class Home1Fragment extends BaseFragment { |
|
|
|
if(motionEvent.getAction()==MotionEvent.ACTION_DOWN) |
|
|
|
{ |
|
|
|
Log.e("鼠标", "按下: "); |
|
|
|
if (!IsMake(false)) |
|
|
|
{ |
|
|
|
return false; |
|
|
|
} |
|
|
|
// if (!IsMake(false)) |
|
|
|
// { |
|
|
|
// return false; |
|
|
|
// } |
|
|
|
int jd = (int) nifty_slider3.getValue(); |
|
|
|
ExecuteTheRecipe.WritePLC("转动速度", jd, new IWriteCallBack() { |
|
|
|
@Override |
|
|
@@ -455,10 +456,10 @@ public class Home1Fragment extends BaseFragment { |
|
|
|
if(motionEvent.getAction()==MotionEvent.ACTION_DOWN) |
|
|
|
{ |
|
|
|
Log.e("鼠标", "按下: "); |
|
|
|
if (!IsMake(false)) |
|
|
|
{ |
|
|
|
return false; |
|
|
|
} |
|
|
|
// if (!IsMake(false)) |
|
|
|
// { |
|
|
|
// return false; |
|
|
|
// } |
|
|
|
int jd = (int) nifty_slider3.getValue(); |
|
|
|
ExecuteTheRecipe.WritePLC("转动速度", jd, new IWriteCallBack() { |
|
|
|
@Override |
|
|
|