Skip to content

Commit

Permalink
poop πŸ’©πŸ’©πŸ’©πŸ’©πŸ’©
Browse files Browse the repository at this point in the history
  • Loading branch information
KnockbackNemo committed Jul 11, 2024
1 parent 49788a1 commit ac9cd86
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Apps/Src/ReadCarCAN.c
Original file line number Diff line number Diff line change
Expand Up @@ -373,12 +373,12 @@ void Task_ReadCarCAN(void *p_arg){
}

case SUPPLEMENTAL_VOLTAGE: {
SBPV = dataBuf.data[0] << 8 | dataBuf.data[1];
SBPV = *(uint16_t *)dataBuf.data;
UpdateDisplay_SetSBPV(SBPV); // Receive value in mV
break;
}
case STATE_OF_CHARGE:{
SOC = (dataBuf.data[0] << 24 | dataBuf.data[1] << 16 | dataBuf.data[2] << 8 | dataBuf.data[3])/(SOC_SCALER);
SOC = (*(uint32_t *) dataBuf.data)/(SOC_SCALER); // Convert to integer percent
UpdateDisplay_SetSOC(SOC);
break;
}
Expand Down

0 comments on commit ac9cd86

Please sign in to comment.