📄 bcmd.h
字号:
文件头:
/* Mserver_B_getdata.c */
/*#include <stdio.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <netdb.h>
#include <string.h>
#include <errno.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <stdlib.h>
#include <stdio.h>
#include"sg.h"
#include"switch.h"
#include"main.h"*/
int port_revcmd=8100;
int change_table(int tableId,int value)/*改编动态表*/
{
if((tableId>=0x8000)&&(tableId<=0x8018))
{
aw->SgNode_DynTab[tableId-0x8000][1]=value;
aw->flag_SG[tableId-0x8000]=1;
g_print("/************8888888/%3x\n", aw->SgNode_DynTab[tableId-0x8000][1]);
}
else if ((tableId>=0x4000)&&(tableId<=0x4010))
{
aw->SwNode_DynTab[tableId-0x4000][1]=value;
g_print("/************/%3x\n", aw->SwNode_DynTab[tableId-0x4000][1]);
}
}
int change_table_FD(int Id1,int Id2,int Id3)/*改编区段动态表*/
{
aw->FdNode_DynTab[Id1-0x2000][1]=Id2;
aw->FdNode_DynTab[Id1-0x2000][2]=Id3;
}
B_receivecmd()/*主?/textarea><BR>
<table width=756 border=0>
<tr><td width=1 bgcolor=#B0B0B0></td><td>
<script type="text/javascript"><!--
google_ad_client = "pub-8055710228382273";
google_ad_width = 728;
google_ad_height = 90;
google_ad_format = "728x90_as";
google_ad_type = "text_image";
google_ad_channel ="0099118804";
google_color_border = "FFFFFF";
google_color_bg = "FFFFFF";
google_color_link = "0000FF";
google_color_text = "333333";
google_color_url = "666666";
//--></script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
</td>
<td width=15 bgcolor=#E4E0D8></td></tr></table>
<textarea cols=105 rows=12>文件尾:
chine: %s\n",buf);
int k,rev[3]={};
char *sp="#";
char *tmp;
int i=1;
rev[0]=strtoul(strtok(buf,sp),NULL,16);
while(tmp=strtok(NULL,sp))
rev[i++]=strtoul(tmp,NULL,16);
if(i==2)
{change_table(rev[0],rev[1]);
char cod[10]="";
char codstr[10]="";
for(i=0;i<2;i++)
{
snprintf(cod,sizeof(cod),"%x",rev[i]);
strcat(cod," ");
strcat(codstr,cod);
}
aw->flag_revInfo=1;
strcpy(aw->ID,codstr);
}//i=2
else if(i==3)
{change_table_FD(rev[0],rev[1],rev[2]);
char cod[10]="";
char codstr[10]="";
for(i=0;i<3;i++)
{
snprintf(cod,sizeof(cod),"%x",rev[i]);
strcat(cod," ");
strcat(codstr,cod);
}
aw->flag_revInfo=1;
strcpy(aw->ID,codstr);
}//i=3
}//if(buf)
close(temp_sock_descriptor);
}//while nei bu
}//while wai bu
}//main
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -