02-24-2016 10:19 AM
Hi all! I stumbled across a bit of a weird scenario yesterday and I'm hoping I'm not the only one that's had this problem. I'm using the Diagnostics Communications Custom Device, which is built around the ADCS Toolkit, for those not familiar. I can successfully read any DID I want, but I found that there's at least one DID that uses a -1 as a valid value, and of course the array of U8 produced by the ReadDatabyIdentifier VI can't handle this. If it was an I8 array it could, but that would bork pretty much all the other DID reads.
Any ideas on how to handle this?
Thanks!
Wraith
02-25-2016 03:49 PM
Hi Wraith,
Have you tried just converting the U8 to an I8 on the output using the To Byte Integer.vi? The function should return the bits that were sent by the ECU, you can interpret them in any way you want.
02-25-2016 04:22 PM
Do you mean right at the output of the ReadDatabyIdentifier VI? No, I haven't tried that since the vast majority of the data I'll get back needs to be U8. I was quite surprised to run across this particular signed integer as literally everything else I've been dealing with has been unsigned. Is the ReadDatabyIdentifier VI's output U8 because that's standard for UDS? This is a really odd problem and I think it might just lead to this one particular value getting ignored...
02-25-2016 04:48 PM