Is IEEE 754 not supported in *.dbc files?

Please provide the following info (check/uncheck the boxes after clicking “+ Create Topic”):
Software Version
DRIVE OS Linux 5.2.0
DRIVE OS Linux 5.2.0 and DriveWorks 3.5
NVIDIA DRIVE™ Software 10.0 (Linux)
NVIDIA DRIVE™ Software 9.0 (Linux)
other DRIVE OS version
other

Target Operating System
Linux
QNX
other

Hardware Platform
NVIDIA DRIVE™ AGX Xavier DevKit (E3550)
NVIDIA DRIVE™ AGX Pegasus DevKit (E3550)
other

SDK Manager Version
1.4.1.7402
other

Host Machine Version
native Ubuntu 18.04
other

Hello,

while implementing a vehilceIO driver to communicate with a vehicle controller, I saw, that encoding a command does not result in the intended values in the CAN message.

Using this DBC file: oscc/oscc.dbc at master · PolySync/oscc · GitHub
With the following code:

status = dwCANInterpreter_encodef32(0.7f,
                                    OSCC_ID_THROTTLE_COMMAND_PEDAL_REQUEST,
                                    &msgCAN, gIntp);
checkError(result, status, "encode OSCC_ID_THROTTLE_COMMAND_PEDAL_REQUEST failed");

Results in the following message on the bus:

$candump -i vcan1,92:FF
 vcan1  092   [8]  11001100 00000101 00000001 00000000 00000000 00000000 00000000 00000000

Trying to encode the value ‘1’ has the exact same result. Using ‘100.5’ leads to:

vcan1 092 [8] 11001100 00000101 01100101 00000000 00000000 00000000 00000000 00000000

Which is ‘101’.

So it seems the value is round and then not encoded using IEEE 754, but just encoded as integer number. Is “SIG_VALTYPE_ … :1” in *.dbc files not supported?
Are there any workarounds?

Regards

Hi @f.petry ,

We will check internally and get back to you. Thanks.