摘要:
//获取数据中bit为1的位置和总数int32_t ParseBitOfData(uint32_t uiData, uint8_t usBitTotal, ListData *pRes){ int32_t iRet = 0; uint8_t i = 0; uint8_t usTotal = 0; uint32_t uiTmp = uiData; printf("Data:0x%X; Bit:%d.\n", uiData, usBitTotal); if (usBitTotal > 32) { return RET_FAIL; } ... 阅读全文