package JNADell;
|
import java.util.Vector;
|
import java.util.regex.Matcher;
|
import java.util.regex.Pattern;
|
import BaoWen.Udp_Receive;
|
import BaoWen.Urt_7000_port;
|
import DataBase.DatabaseManagement;
|
import Frame.Tool;
|
import Method.BaoWenShow;
|
import Method.ControTag;
|
import Method.GetNowTime;
|
import Method.StringToHex;
|
import PbuliClass.ShowMessage;
|
import anchor.Anchor;
|
import anchor.Anchor_Dell;
|
import person.Person;
|
import person.person_Dell;
|
import tag.Tag;
|
import tag.Tag_Dell;
|
import tbDataModel.UseTagAndAnchor;
|
import tbDataModel_Dell.ReadPeizhiMessage;
|
import urt.Control_urt;
|
|
/**´¦ÀíÐèҪʹÓõıêÇ©*/
|
public class Dell_usetaganchor {
|
|
static Vector<UseTagAndAnchor> useta=new Vector<UseTagAndAnchor> ();
|
|
/**»ñÈ¡±êÇ©ÐèÒªÓÃÀ´¼ÆËãµÄ»ùÕ¾*/
|
public static Vector<UseTagAndAnchor> getUseta() {
|
return useta;
|
}
|
|
/**²åÈëÒ»¸ö±êÇ©ÐèÒªÓÃÀ´²â¾àµÄ»ùÕ¾*/
|
public static void insert_taganchor(String tagid,String anchorid1,String anchorid2,
|
String anchorid3,String anchorid4,boolean use) {
|
if(get_UseTagAndAnchor(tagid)==null) {
|
UseTagAndAnchor newusetaganc=new UseTagAndAnchor();
|
newusetaganc.setTagid(tagid);
|
newusetaganc.setAnchorid1(anchorid1);
|
newusetaganc.setAnchorid2(anchorid2);
|
newusetaganc.setAnchorid3(anchorid3);
|
newusetaganc.setAnchorid4(anchorid4);
|
newusetaganc.setUse(use);
|
useta.add(newusetaganc);
|
}
|
|
}
|
|
/**ѰÕÒij¸ö±êÇ©¶ÔÏó*/
|
public static UseTagAndAnchor get_UseTagAndAnchor(String tagid) {
|
UseTagAndAnchor uta=null;
|
int size=useta.size();
|
if( size!=0) {
|
for(int i=0;i<size;i++) {
|
UseTagAndAnchor uta1=useta.get(i);
|
String tagid1=uta1.getTagid();
|
if(tagid1.equals(tagid)) {
|
uta=uta1;
|
break;
|
}
|
}
|
}
|
return uta;
|
}
|
|
/**¸Ä±ä±êÇ©µÄʹÓÃ״̬*/
|
public static void alert_use(String tagid,boolean use) {
|
if( get_UseTagAndAnchor(tagid) !=null) {
|
get_UseTagAndAnchor(tagid).setUse(use);
|
}
|
}
|
|
|
/**ÐÞ¸Äij¸ö±êÇ©¶ÔÏó*/
|
public static void alert_taganc(String tagid,String anchorid1,String anchorid2,
|
String anchorid3,String anchorid4,boolean use) {
|
get_UseTagAndAnchor( tagid).setAnchorid1(anchorid1);
|
get_UseTagAndAnchor( tagid).setAnchorid2(anchorid2);
|
get_UseTagAndAnchor( tagid).setAnchorid3(anchorid3);
|
get_UseTagAndAnchor( tagid).setAnchorid4(anchorid4);
|
get_UseTagAndAnchor( tagid).setUse(true);
|
}
|
|
|
public static void dell_udp_message(String message) {
|
String[] mess=message.split(",");
|
if(mess.length==5) {
|
//Ö¸ÁîÀàÐÍ
|
String zhiling=replace(mess[1]).toUpperCase();
|
String a3=mess[3];//±êÇ©ID
|
String a2=mess[2];//ÄÚÈÝ
|
switch(zhiling){
|
case "TAG_SHAKE" :
|
TAG_SHAKE(a2,a3);
|
break;
|
case "OPEN_OR_CLOSE_SLEEP" :
|
OPEN_OR_CLOSE_SLEEP(a2,a3);
|
break;
|
|
case "ALERT_SLEEP_TIME" :
|
ALERT_SLEEP_TIME(a2,a3);
|
break;
|
|
case "ALERT_TAG_HZ" :
|
ALERT_TAG_HZ(a2,a3);
|
break;
|
case "USERINFO":
|
USERINFO(a2,a3);
|
break;
|
case "TAG_OLED":
|
oledshow(a2,a3);
|
break;
|
case "TAG_VOICE":
|
voice(a3,a2);
|
break;
|
case "HEIGHTMODIFY":
|
Tool.HeightModify(message);
|
break;
|
}
|
|
//55BB,[±êÇ©id],[»ùÕ¾1id],[»ùÕ¾2id],[»ùÕ¾4id],[¿ªÊ¼]
|
}else if(mess.length==6) {
|
boolean use=false;
|
if(mess[6].equals("1")) {
|
use=true;
|
}
|
//Èç¹û±êÇ©´æÔÚ
|
if(get_UseTagAndAnchor(mess[1])==null) {
|
insert_taganchor(mess[1],mess[2],mess[3],mess[4],mess[5],use);
|
}else {
|
alert_taganc(mess[1],mess[2],mess[3],mess[4],mess[5],use);
|
}
|
}
|
|
}
|
|
/**È¥µô×Ö·û´®ÖеĻ»Ðпոñ»Ø³µ*/
|
public static String replace(String str) {
|
String destination = "";
|
if (str!=null) {
|
Pattern p = Pattern.compile("\\s*|\t|\r|\n");
|
Matcher m = p.matcher(str);
|
destination = m.replaceAll("");
|
}
|
return destination;
|
}
|
|
/**±êÇ©Õñ¶¯*/
|
public static void TAG_SHAKE(String a2,String a3) {
|
String tagid=replace(a3);
|
int time=Integer.parseInt(replace(a2));
|
if(tagid.equals("ALL")) {
|
tagid="ËùÓбêÇ©";
|
|
}
|
Person person=person_Dell.get_Person(tagid);
|
if(person==null) {
|
return;
|
}
|
String type=person.getBaoliu19();
|
if(type.equals("URT+CO")) {
|
Control_urt.say_voice(tagid,"ƽ̨Ï·¢ÁËÒ»ÌõÓïÒô",0,10);
|
}else {
|
ControTag.konghzitag(time, tagid,(byte)(byte)0x10,"","Dell_usetaganchorÏ·¢Õð¶¯");
|
Control_urt.beeper(tagid, time);
|
Control_urt.say_fengming(tagid);
|
}
|
}
|
|
/**¿ª¹Ø±êÇ©ÐÝÃß¹¦ÄÜ*/
|
public static void OPEN_OR_CLOSE_SLEEP(String a2,String a3) {
|
int time=Integer.parseInt(replace(a2));
|
String tagid=replace(a3);
|
if(tagid.equals("ALL")) {
|
tagid="ËùÓбêÇ©";
|
}
|
ControTag.konghzitag(time, tagid,(byte)(byte)0x3e,"","Dell_usetaganchor¿ª¹ØÐÝÃß");
|
}
|
|
/**Ð޸ıêÇ©µÄÐÝÃßʱ¼ä*/
|
public static void ALERT_SLEEP_TIME(String a2,String a3) {
|
int time=Integer.parseInt(replace(a2));
|
String tagid=replace(a3);
|
if(tagid.equals("ALL")) {
|
tagid="ËùÓбêÇ©";
|
}
|
ControTag.konghzitag(time, tagid,(byte)(byte)0x3a,"","Dell_usetaganchorÏ·¢ÐÝÃßʱ¼ä");
|
}
|
|
/**Ð޸ıêÇ©µÄƵÂÊ
|
* 55BB,ALERT_TAG_HZ,10,1860,END
|
* 55BB,ALERT_TAG_HZ,10,ALL,END*/
|
public static void ALERT_TAG_HZ(String zhi,String tag_id) {
|
String time=replace(zhi);
|
String tagid=replace(tag_id);
|
if(tagid.equals("ALL")) {
|
tagid="ËùÓбêÇ©";
|
}
|
ControTag.set_tag_hz(time, tagid);
|
ShowMessage.zidingyi(tagid+"ÊÕµ½Ð޸ıêǩƵÂÊÖ¸Áî"+time);
|
}
|
|
/**Êý¾Ý͸´«¸ñʽ
|
*55BB,userinfo,tagid,message,end
|
*55BB:°üÍ·
|
*userinfo£ºÊý¾ÝÀàÐÍ
|
*tagid£º±êÇ©IDºÅ
|
*message:Óû§Êý¾Ý³¤¶È²»³¬¹ý30byte
|
*end:½áÊø±ê־λ*/
|
public static void USERINFO(String tagid,String message) {//ÏÔʾÎÄ×ÖµÄÖ¸Áî
|
String tou="74302E7478743D22";//t0.txt="
|
if(message.startsWith("music") || message.startsWith("MUSIC") ) {//²¥·ÅÒôÀÖµÄÖ¸Áî
|
tou="7A68696C696E2E7478743D22";//zhilin.txt="
|
}
|
String hexmes=tou+str2HexStr(message)+"22FFFFFF";
|
int a0=hexmes.length();
|
String n=Integer.toHexString(a0/2);
|
int a12=a0+10;
|
String lenth=Integer.toHexString(a12/2);
|
String baotou="55AA0D"+lenth+gettagid(tagid)+n;
|
String jiaoyan=jiaoyan("0D"+lenth+tagid+n+hexmes);
|
String mes=baotou+hexmes+jiaoyan;
|
Tag tag=Tag_Dell.get_tag(tagid);
|
String info=message+"\n"+mes;
|
if(tag==null) {
|
BaoWenShow.show2(info, "TOANC",tagid+"tagid is null",8234);
|
return;
|
}
|
String anchorid=tag.getAnchorid();
|
if(anchorid !=null) {
|
Anchor ac=Anchor_Dell.get_anchor(anchorid);
|
if(ac !=null) {
|
String ip=ac.getAnc_ip();
|
int port=ac.getPort();
|
BaoWenShow.show2(info, "TOANC", ip, port);
|
byte[] byt=ReadPeizhiMessage.toByteArray(mes);
|
//½«Êý¾Ýfa¸øÖ÷»ùÕ¾
|
Udp_Receive.out(byt,byt.length,ac,"Êý¾Ý͸´«");
|
}
|
}else {
|
BaoWenShow.show2(info, "TOANC","anchorid is null",8234);
|
}
|
}
|
|
/** ½«ºº×Öת»»Îª16½øÖÆ×Ö·û´®Êý,¿É°üº¬Êý×Ö¼°·ûºÅ*/
|
public static String str2HexStr(String str) {
|
char [] chars = "0123456789ABCDEF" .toCharArray();
|
StringBuilder sb = new StringBuilder( "" );
|
byte [] bs = str.getBytes();
|
int bit;
|
for ( int i = 0 ; i < bs.length; i++) {
|
bit = (bs[i] & 0x0f0 ) >> 4 ;
|
sb.append(chars[bit]);
|
bit = bs[i] & 0x0f ;
|
sb.append(chars[bit]);
|
}
|
return sb.toString().trim();
|
}
|
|
|
|
|
|
/**½«×Ö½ÚÊý×éת»»Îª16½øÖÆ×Ö·û´®ÎÞ¿Õ¸ñ*/
|
public static String BinaryToHexString2(byte[] bytes) {
|
String hexStr = "0123456789ABCDEF";
|
String result = "";
|
String hex = "";
|
for (byte b : bytes) {
|
hex = String.valueOf(hexStr.charAt((b & 0xF0) >> 4));
|
hex += String.valueOf(hexStr.charAt(b & 0x0F));
|
result += hex + "";
|
}
|
return result;
|
}
|
|
/**
|
* 16½øÖÆ×Ö·û´®×ª×Ö½ÚÊý×é
|
* @param hexString 16½øÖÆ×Ö·û´®
|
* @return ×Ö½ÚÊý×é
|
*/
|
public static byte[] hexString2ByteArray(String hexString) {
|
if (hexString == null || "".equals(hexString)) {
|
return null;
|
}
|
//ÏȰÑ×Ö·û´®×ª»»Îªchar[]£¬ÔÙת»»Îªbyte[]
|
int length = hexString.length() / 2;
|
char[] hexChars = hexString.toCharArray();
|
byte[] bytes = new byte[length];
|
String hexDigits = "0123456789ABCDEF";
|
for (int i = 0; i < length; i++) {
|
int pos = i * 2; // Á½¸ö×Ö·û¶ÔÓ¦Ò»¸öbyte
|
int h = hexDigits.indexOf(hexChars[pos]) << 4; // ×¢1
|
int l = hexDigits.indexOf(hexChars[pos + 1]); // ×¢2
|
if (h == -1 || l == -1) { // ·Ç16½øÖÆ×Ö·û
|
return null;
|
}
|
bytes[i] = (byte) (h | l);
|
}
|
return bytes;
|
}
|
|
/**УÑé*/
|
public static String jiaoyan(String a) {
|
String[] hex=StringToHex.hex(a);
|
int size=hex.length;
|
int sum=0;
|
for(int i=0;i<size;i++) {
|
sum+=Integer.parseInt(hex[i],16);
|
}
|
String hex16=Integer.toHexString(~sum);//È¡·´×ªÎª16½øÖÆ×Ö·û´®
|
int lenth=hex16.length();//×Ö·û´®µÄ³¤¶È
|
String hh=hex16.substring(lenth-4, lenth-2);
|
String ens=hex16.substring(lenth-2, lenth)+hh;
|
return ens;
|
}
|
|
|
public static String gettagid(String id) {
|
String a=id.substring(0, 2);
|
String b=id.substring(2,4);
|
String tagid=b+a;
|
return tagid;
|
}
|
|
/**×Ô½âËãģʽÏÂÊý¾Ý͸´«*/
|
public static String touchuan(String message,String tagid) {
|
String hexmes=str2HexStr(message);
|
int a0=hexmes.length();
|
String n=Integer.toHexString(a0/2);
|
int a12=a0+10;
|
String lenth=Integer.toHexString(a12/2);
|
String baotou="55AA0D"+lenth+gettagid(tagid)+n;
|
String jiaoyan=jiaoyan("0D"+lenth+tagid+n+hexmes);
|
String mes=baotou+hexmes+jiaoyan;
|
return mes;
|
}
|
|
/**¿ØÖƱêÇ©OLEDÎÄ×ÖÏÔʾ
|
* 55BB,[TAG_OLED],[TEXT],[TAGID],[END]
|
* ˵Ã÷£º
|
* 55BB£ºÎª°üÍ·£»
|
* [TAG_OLED]£º ÐèÒªÖ´ÐеÄÖ¸ÁîΪÈñêÇ©OLEDÏÔʾÄÚÈÝ£»
|
* [TEXT]£º ÐèÒªÏÔʾµÄÄÚÈÝ£»
|
* [TAGID]£º ±êÇ©µÄ±àºÅ,ALL±íʾËùÓбêÇ©;
|
* [END]£º ±¨ÎĽáÊø±êÖ¾¡£
|
* ʾ·¶1£ºÈñêÇ©ÏÔʾÄÚÈÝ1£»
|
* 55BB,TAG_OLED,1,2001,END*/
|
public static void oledshow(String info,String tagid) {
|
if(tagid.equals("ALL")) {
|
Dell_usetaganchor.alltagtomessge(info,"ϵͳĬÈÏ");
|
ShowMessage.zidingyi(tagid+"ÐÅϢϷ¢:"+info);
|
}else {
|
Tag tag=Tag_Dell.get_tag(tagid);
|
if(tag==null) {
|
ShowMessage.zidingyi(tagid+"²»´æÔÚoledshow");
|
return;
|
}
|
String tagtype=tag.getTagtype();
|
if(tagtype.equals("ÐÄÂÊ´øÆÁ")) {
|
Dell_usetaganchor.message_to_oled(tagid, info,"ϵͳĬÈÏ");
|
ShowMessage.zidingyi(tagid+"ÐÅϢϷ¢:"+info);
|
}else {
|
ShowMessage.zidingyi(tagid+"²»ÊÇÐÄÂÊ´øÆÁ±êÇ©");
|
}
|
}
|
}
|
|
/**·¢ËÍÊý¾Ý¸ø´øOLEDÆÁÄ»µÄ±êÇ©
|
*55BB,userinfo,tagid,message,end
|
*55BB:°üÍ·
|
*userinfo£ºÊý¾ÝÀàÐÍ
|
*tagid£º±êÇ©IDºÅ
|
*message:Óû§Êý¾Ý³¤¶È²»³¬¹ý30byte
|
*end:½áÊø±ê־λ*/
|
public static void message_to_oled(String tagid,String message,String name) {
|
String infom="";
|
int size=message.length();
|
if(size>24) {
|
ShowMessage.zidingyi("·¢Ëͳ¤¶È"+size+"£¬³¤¶È´óÓÚ24·¢ËÍʧ°Ü");
|
return;
|
}
|
if(size<13) {
|
infom="1"+message+" "+GetNowTime.nowfinename();
|
}else if(size>12 && size<20) {
|
infom="1"+message+" "+GetNowTime.HH_MM_SS();
|
}else if(size>20) {
|
infom="1"+message;
|
}
|
Tag tag=Tag_Dell.get_tag(tagid);
|
if(tag==null) {
|
ShowMessage.zidingyi(tagid+"·¢ËÍÎÄ×Ö±êÇ©²»´æÔÚ");
|
return;
|
}
|
String anchorid=tag.getAnchorid();
|
if(anchorid ==null) {
|
ShowMessage.zidingyi(anchorid+"·¢ËÍÎÄ×ÖÖ÷»ùÕ¾²»´æÔÚ");
|
return;
|
}
|
Anchor ac=Anchor_Dell.get_anchor(anchorid);
|
if(ac !=null) {
|
String mes=getmes(tagid,infom);
|
String info=infom+"\n"+mes;
|
String ip=ac.getAnc_ip();
|
int port=ac.getPort();
|
byte[] byt=ReadPeizhiMessage.toByteArray(mes);
|
Udp_Receive.out(byt,byt.length,ac,"Êý¾Ý͸´«");//½«Êý¾Ýfa¸øÖ÷»ùÕ¾
|
BaoWenShow.show2(info, "TOANC", ip, port);
|
sendmessagejilu_intodata(tagid,message,name);//Êý¾Ý²åÈëÊý¾Ý¿â
|
}
|
}
|
|
/**¸øËùÓÐÐÄÂÊ´øÆÁÄ»±êÇ©·¢ÎÄ×ÖÐÅÏ¢*/
|
public static void alltagtomessge(String message,String name) {
|
Vector<Tag> tagvc=Tag_Dell.getTag_vector();
|
int size=tagvc.size();
|
for(int i=0;i<size;i++) {
|
Tag tag=tagvc.get(i);
|
String tagtype=tag.getTagtype();
|
String tagid=tag.getTag_id();
|
String online=person_Dell.get_Person(tagid).getP_online();
|
if(online.equals("1")) {
|
if(tagtype.equals("ÐÄÂÊ´øÆÁ")) {
|
message_to_oled(tagid, message,name);
|
}else if(tagtype.equals("³µÔØ´øÆÁ")) {
|
USERINFO(tagid, message);
|
}else if(tagtype.equals("ϵͳĬÈÏ")) {
|
ControTag.konghzitag(10, tagid,(byte)0x10,"Õñ¶¯","Dell_usetaganchor1Ï·¢Õð¶¯");
|
}else {
|
ControTag.konghzitag(10, tagid,(byte)0x10,"Õñ¶¯","Dell_usetaganchor2Ï·¢Õð¶¯");
|
}
|
}
|
}
|
}
|
|
/**·¢ËÍʱ¼äºÍIDµÄ·½·¨*/
|
public static void sendid_time(String tagid,Person person) {
|
Tag tag=Tag_Dell.get_tag(tagid);
|
if(tag==null) {
|
return;
|
}
|
String anchorid=tag.getAnchorid();
|
if(anchorid ==null) {
|
return;
|
}
|
Anchor ac=Anchor_Dell.get_anchor(anchorid);
|
if(ac !=null) {
|
String ip=ac.getAnc_ip();
|
int port=ac.getPort();
|
String info="";
|
String mes="";
|
String infom="2ID"+tagid+" "+person.getP_power()+"% "+GetNowTime.HH_MM_SS();
|
ShowMessage.zidingyi(infom);
|
mes=getmes(tagid,infom);
|
info=infom+"\n"+mes;
|
byte[] byt=ReadPeizhiMessage.toByteArray(mes);
|
Udp_Receive.out(byt,byt.length,ac,"Êý¾Ý͸´«");//½«Êý¾Ýfa¸øÖ÷»ùÕ¾
|
BaoWenShow.show2(info, "TOANC", ip, port);
|
}
|
}
|
|
/**»ñÈ¡ÎÄ×ÖÐÅÏ¢*/
|
public static String getmes(String tagid,String message) {
|
String hexmes=str2HexStr(message);//½«ºº×ÖתΪ16½øÖÆ×Ö·û´®Êý
|
int a0=hexmes.length();
|
String n=Integer.toHexString(a0/2);
|
if(n.length()==1) {
|
n="0"+n;
|
}
|
int a12=a0+10;
|
String lenth=Integer.toHexString(a12/2);
|
if(lenth.length()==1) {
|
lenth="0"+lenth;
|
}
|
String baotou="55AA0D"+lenth+gettagid(tagid)+n;
|
String jiaoyan=jiaoyan("0D"+lenth+tagid+n+hexmes);
|
String mes=baotou+hexmes+jiaoyan;
|
return mes;
|
}
|
|
/**
|
* »ñÈ¡ÎÄ×ÖÐÅÏ¢
|
*/
|
public static String getmes2(String tagid, String message, String type) {
|
String hexmes = str2HexStr(message+"end");//½«ºº×ÖתΪ16½øÖÆ×Ö·û´®Êý
|
String mes = null;
|
if (type.equals("88")) {
|
mes = "55BB88" + tagid + hexmes;
|
} else if (type.equals("66")) {
|
mes = "55BB66" + tagid + hexmes;
|
}
|
return mes;
|
}
|
|
|
public static void sendmessagejilu_intodata(String tagid,String info,String username) {
|
Person pr=person_Dell.get_Person(tagid);
|
String bianma=GetNowTime.sss();
|
String sendtime=GetNowTime.now();
|
String name=pr.getP_name();
|
String[] ziduan= {"bianma","tagid","username","info","sendtime","baoliu1" };
|
String[] zhi= {bianma,tagid,username,info,sendtime,name};
|
DatabaseManagement.insertfast("tb_message_history",ziduan, zhi);
|
pr.setMessagerelaystate(0);
|
pr.setMessagebianma(bianma);
|
pr.setMessagesend(info);
|
}
|
|
/**¿ØÖÆÓïÒô²¥·Å
|
* ˵Ã÷£º¸ÄÖ¸ÁîÖ»¶ÔÖ§³ÖÓïÒô¹¦ÄÜÉ豸ÉúЧ
|
* 55BB,TAG_VOICE,TEXT,TAGID,END
|
* Ö¸Áî˵Ã÷£º
|
* 55BB£ºÎª°üÍ·£»
|
* TAG_VOICE£ºÖ¸ÁîÀàÐͲ¥·ÅÓïÒô
|
* TEXT£ºÓïÒôÎÄ×Ö
|
* TAGID£º±êÇ©ID£¬HEX¸ñʽΨһ±êʶ
|
* END£º½áÊø±êÖ¾
|
* ʾ·¶1£ºÈñêÇ©²¥·ÅÄÚÈÝÓïÒô£»
|
* 55BB,TAG_VOICE,²âÊÔÒ»ÏÂÓïÒô²¥·Å,2001,END*/
|
public static void voice(String tagid,String text) {
|
Control_urt.say_voice(tagid,text,0,3);
|
}
|
|
|
/**·¢ËÍÊý¾Ý¸ø´øloraÆÁÄ»µÄ±êÇ©
|
*55BB,tagid,message,end;
|
*55BB:°üÍ·
|
*info:ÀàÐÍ
|
*tagid£º±êÇ©IDºÅ
|
*message:Êý¾ÝÄÚÈÝ
|
*end:½áÊø±ê־λ*/
|
public static void message_to_Lora(String tagid,String message,String name,String type) {
|
Person tag=person_Dell.get_Person(tagid);
|
if(tag==null) {
|
ShowMessage.zidingyi(tagid+"·¢ËÍÎÄ×Ö±êÇ©²»´æÔÚ");
|
return;
|
}
|
int port = Integer.parseInt(tag.getBaoliu9());
|
if ("88".equals(type)){
|
String s = getmes2(tagid, message, type);
|
byte[] byt=ReadPeizhiMessage.toByteArray(s);
|
Urt_7000_port.outlora(byt,byt.length,tag.getBaoliu8(),port,"Êý¾Ý͸´«");//½«Êý¾Ýfa¸øÖ÷»ùÕ¾
|
BaoWenShow.show2(message, "TOANC", tag.getBaoliu8(), port);
|
sendmessagejilu_intodata(tagid,message,name);//Êý¾Ý²åÈëÊý¾Ý¿â
|
}else if ("66".equals(type)){
|
String s = getmes2(tagid, message, type);
|
byte[] byt=ReadPeizhiMessage.toByteArray(s);
|
Urt_7000_port.outlora(byt,byt.length,tag.getBaoliu8(),port,"Êý¾Ý͸´«");//½«Êý¾Ýfa¸øÖ÷»ùÕ¾
|
BaoWenShow.show2(message, "TOANC", tag.getBaoliu8(), port);
|
sendmessagejilu_intodata(tagid,message,name);//Êý¾Ý²åÈëÊý¾Ý¿â
|
}
|
}
|
}
|