|
楼主 |
发表于 2015-5-7 17:26:39
|
显示全部楼层
TurnLeft.setOnTouchListener(new View.OnTouchListener()
{
public boolean onTouch(View v, MotionEvent event)
{
int action = event.getAction();
switch(action)
{
case MotionEvent.ACTION_DOWN:
CmdBuffer[1] = (byte)0x00;
CmdBuffer[2] = (byte)0x03;
CmdBuffer[3] = (byte)0x00;
Send_CMD_Status = -1;
break;
case MotionEvent.ACTION_UP:
CmdBuffer[1] = (byte)0x00;
CmdBuffer[2] = (byte)0x00;
CmdBuffer[3] = (byte)0x00;
Send_CMD_Status = 1;
break;
default:
break;
}
return false;
这种我怎么改,一般下位机都是接受字符比如a,b,c,d等。我的下位机软件就是这样的,我该怎么改呀,求指导,谢谢! |
|