public override bool Recv(byte[] buf) {
if(buf[0]==ADDR) {
if(buf[1]==0x10 && _st==2 && buf.Length==6) {
_val.value=(long)(((buf[4]<<8) | buf[5])/1.2);
_present.value=true;
_pt=DateTime.Now.AddSeconds(_rand.Next(45, 75));
_st=0;
} else {
_present.value=false;
_pt=DateTime.Now.AddSeconds(_rand.Next(135, 165));
_st=0;
}
return true;
}
return false;
}
public override bool Poll(out byte[] buf) {