|
|
|
@ -51,9 +51,9 @@ namespace HighWayIot.TouchSocket
|
|
|
|
|
};//有客户端断开连接
|
|
|
|
|
service.Received = (client, e) =>
|
|
|
|
|
{
|
|
|
|
|
//从客户端收到信息
|
|
|
|
|
var mes = Encoding.ASCII.GetString(e.ByteBlock.Buffer, 0, e.ByteBlock.Len);//注意:数据长度是byteBlock.Len
|
|
|
|
|
logHelper.Info($"已从{client.IP}:{client.Port}接收到信息:{mes}");
|
|
|
|
|
////从客户端收到信息
|
|
|
|
|
//var mes = Encoding.ASCII.GetString(e.ByteBlock.Buffer, 0, e.ByteBlock.Len);//注意:数据长度是byteBlock.Len
|
|
|
|
|
//logHelper.Info($"已从{client.IP}:{client.Port}接收到信息:{mes}");
|
|
|
|
|
|
|
|
|
|
BufferMemory(BufferAnalysis.SplitByteArray(e.ByteBlock.Buffer, 0, e.ByteBlock.Len));
|
|
|
|
|
|
|
|
|
|