求帮忙,delphi 代码转成java...

因开发条屏的需要,厂家没有开发文档,只给了段delphi代码,看不太懂,需要把这段代码转换成java的,求大神帮忙...

 procedure TFmain.sendled(addr: Integer; sendstr: string);
var
  TmpWord:Word;
  str:string;
  cd:Integer;
begin
  cd:=Length(sendstr);
  sbuf[0]:= addr;  //地址
  sbuf[1]:= Byte($AE);
  sbuf[2]:= cd;     //
  sbuf[3]:= Ord(sendstr[1]);
  sbuf[4]:= Ord(sendstr[2]);
  sbuf[5]:= Ord(sendstr[3]);
  sbuf[6]:= Ord(sendstr[4]);
  TmpWord := dm.Crc16(sbuf,6);
  sbuf[7]:= HiByte(TmpWord);//高字节
  sbuf[8]:= LoByte(TmpWord);//低字节
  Str := IntToHex(sbuf[0],2)+' '+IntToHex(sbuf[1],2)+' '+IntToHex(sbuf[2],2)+' '+
         IntToHex(sbuf[3],2)+' '+IntToHex(sbuf[4],2)+' '+IntToHex(sbuf[5],2)+' '+
         IntToHex(sbuf[6],2)+' '+IntToHex(sbuf[7],2)+' '+IntToHex(sbuf[8],2);
  Send_S_String(Hex_Str.HexStrToStr(Str));
  AddInfo(str,True,2);
  Sleep(25);
end;

只会java,不会delphi......