| | |
| | | ByteBuffer tmpbuf = bf;
|
| | | int crc0 = tmpbuf.getShort(BYTE_LEN-2) & 0xFFFF;
|
| | | int crc1 = FBS5100_Crc16.CalCRC16(tmpbuf, BYTE_LEN-2);
|
| | | if(crc0 != crc1)
|
| | | return false;
|
| | | |
| | | if(crc0 != crc1) {
|
| | | System.err.println("FBS5100_ChargeState:"+crc0+"=="+crc1);
|
| | | //return false;
|
| | | }
|
| | | tmpbuf.position(0);
|
| | | StartDT.year = FBS5100_ComBase.changeByteToInt(tmpbuf.get());
|
| | | StartDT.month = FBS5100_ComBase.changeByteToInt(tmpbuf.get());
|
| | |
| | | for(int n=0; n<BATTGROUP_COUNT; n++)
|
| | | MonMinValue[n] = FBS5100_ComBase.changeShortToDouble(tmpbuf.getShort()) / 1000;
|
| | |
|
| | | for(int n=0; n<BATTGROUP_COUNT; n++) {
|
| | | TestCap[n] = tmpbuf.getDouble();
|
| | | }
|
| | | //System.out.println(this);
|
| | | tmpbuf.compact();
|
| | | tmpbuf.flip();
|
| | |
|