Closed yangyixizg closed 4 months ago
Hi, I am sorry, but I will not accept this Pull Request. I think you have misunderstood how to use that service.
If your data has a custom type, write your own codec. It's all documented
https://udsoncan.readthedocs.io/en/latest/udsoncan/examples.html#reading-a-did-with-readdatabyidentifier https://udsoncan.readthedocs.io/en/latest/udsoncan/helper_classes.html#didcodec
Thank you for your hints, you are right, I have to create my own codec.
You can use pack string such as "HH" if you have 2 values also
Yes exactly, I did it and it returned the desired respond data, thank you!
When use rdbi and the DID constains multiple signals with the same data type (e.g. sint16), the offset and the val-tuple-concatenation have to be modified. In my main file, the DID is configured with:
config['data_identifiers'] = {'default': '>H', 0x4FD3: udsoncan.DidCodec('>h')}
The DID 0x4FD3 contains 2 signals of the same data type e.g. sint16. Or find other method to handle the rdbi when DID contains multiple signals of the same data type, and how to handle it when the signals have different data types?