|
脚本如下:
#include "lrs.h"
Action()
{
lrs_create_socket("socket0", "TCP", "RemoteHost=NKOSZS21:1433", LrsLastArg);
lrs_send("socket0", "buf0", LrsLastArg);
lrs_receive("socket0", "buf1", LrsLastArg);
lrs_send("socket0", "buf2", LrsLastArg);
lrs_receive("socket0", "buf3", LrsLastArg);
lrs_send("socket0", "buf4", LrsLastArg);
lrs_receive("socket0", "buf5", LrsLastArg);
lrs_send("socket0", "buf6", LrsLastArg);
lrs_receive("socket0", "buf7", LrsLastArg);
lrs_create_socket("socke1", "TCP", "RemoteHost=NKOSZS21:1433", LrsLastArg);
lrs_send("socket1", "buf8", LrsLastArg);
lrs_receive("socket1", "buf9", LrsLastArg);
lrs_send("socket1", "buf10", LrsLastArg);
。。。。。。。。。。。。。后面还有
data.ws中的内容:
recv buf7 140
"\x04\x01\x00\x8c\x00"
"4"
"\x01\x00\x81\x02\x00\x00\x00\x00\x00"
"\b"
"\x00"
"4\bS"
"\x00"
"t"
"\x00"
"a"
"\x00"
"t"
"\x00"
"e"
"\x00"
"_"
"\x00"
"I"
"\x00"
"D"
"\x00\x00\x00\x00\x00"
"\t"
"\x00"
""
"\x00\x04"
"\b"
"\xd0\x00\x00"
"\n"
"S"
"\x00"
"t"
"\x00"
"a"
"\x00"
"t"
"\x00"
"e"
"\x00"
"_"
"\x00"
"N"
"\x00"
"a"
"\x00"
"m"
"\x00"
"e"
"\x00\xd1\x01\x00\x04\x00"
"扫描"
"\xd1\x02\x00"
"\b"
"\x00"
"图像检查"
"\xd1\x03\x00"
"\b"
"\x00"
"文档索引"
"\xd1\x04\x00\x04\x00"
"发行"
"\xd1\x05\x00"
"\b"
"\x00"
"质量控制"
"\xfd\x10\x00\xc1\x00\x05\x00\x00\x00\x00\x00\x00\x00"
运行的时候报的错
Action.c(31): lrs_receive(socket0, buf7)
Action.c(31): Error : socket0 - Software caused connection abort. Error code : 10053.
是在lrs_receive(socket0, buf7)这里报的错
有的人说是连接不上服务器,那为什么前面的语句就不报错了。高手指点下。多谢! |
|