Add Intake Air Temperature, Add Fuel Level (#4028)

Co-authored-by: hugovw1976 <hugovw1976@hotmail.com>
This commit is contained in:
rusefillc 2022-03-30 18:15:55 -04:00 committed by GitHub
parent 9202b29ef8
commit 4d7efd7fbc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 4 deletions

View File

@ -1045,8 +1045,9 @@ void canDashboardHaltech(CanCycle cycle) {
msg[0] = (tmp >> 8);
msg[1] = (tmp & 0x00ff);
/* Air Temperature */
msg[2] = 0x00;
msg[3] = 0x00;
tmp = ((Sensor::getOrZero(SensorType::Iat) + 273.15) * 10);
msg[2] = (tmp >> 8);
msg[3] = (tmp & 0x00ff);
/* Fuel Temperature */
msg[4] = 0x00;
msg[5] = 0x00;
@ -1073,8 +1074,9 @@ void canDashboardHaltech(CanCycle cycle) {
{
CanTxMessage msg(0x3E2, 2);
/* Fuel Level in Liters */
msg[0] = 0x00;
msg[1] = 0xff;
tmp = (Sensor::getOrZero(SensorType::FuelLevel)* 10);
msg[0] = (tmp >> 8);
msg[1] = (tmp & 0x00ff);
}
/* 0x3E3 = 5Hz rate */