I've narrowed it down to the Fault Description and Action Description fields. If I read these fields:
Code: Select all
J1939DTC dtcData;
//...
ListManagerGetItem(ListDataType.Dm1ListType, i, dtcData);
string actionDescription = "";
dtcData.ReadActionDescription(actionDescription);
string faultDescription = "";
dtcData.ReadFaultDescription(faultDescription);
// ...
CustomListData listData;
listData.WriteString(CustomListColumn.HistoricFaults_ActionDescription, actionDescription);
listData.WriteString(CustomListColumn.HistoricFaults_FaultDescription, faultDescription);
//...
ListManagerAddItem(ListDataType.HistoricFaults, listData);
This has been pretty consistent with the action description, so I removed it. However I just started to see the same behavior with fault description, even when the string is empty rather than null.
It doesn't appear that I can do a simple 'if (actionDescription == null)' check with how strings are implemented. Is there a good way to check that the data in J1939DTC is filled?
I'm currently on 2.9.20040 using a PV480. We are trying to wrap this up this week and this just became a bigger issue, so if there is any advice I'd greatly appreciate it.
Thanks,