voidconvertUnCharToStr(char*str,unsignedchar*UnChar,intucLen){inti=0;for(i=0;i<ucLen;i++){//格式化输str,每unsignedchar转换字符占两位置%x写输%X写输sprintf(str+i*2,"%02x",UnChar[i]);}}voidconvertStrToUnChar(char*str,unsignedchar*UnChar){inti=strlen(str),j=0,counter=0;charc[2];unsignedintbytes[2];for(j=0;j<i;j+=2){if(0