Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement remaining compumethods #345

Merged
merged 4 commits into from
Sep 23, 2024

Conversation

andlaus
Copy link
Collaborator

@andlaus andlaus commented Sep 19, 2024

This PR implements the compu methods specified by the ODX standard which have so far been MIA in odxtools. These are COMPUCODE, RAT-FUNC and SCALE-RAT-FUNC.

Andreas Lauser <andreas.lauser@mercedes-benz.com>, on behalf of MBition GmbH.
Provider Information

andlaus and others added 4 commits September 19, 2024 10:17
Rather "implement": Being a python library, `odxtools` cannot en- or
decode any parameters which use this compumethod because the ODX
standard mandates the referenced program code to be Java source code
using a specific Java interface. That said, files which use such compu
methods get properly parsed now (hopefully).

Signed-off-by: Andreas Lauser <andreas.lauser@mbition.io>
Signed-off-by: Christian Hackenbeck <christian.hackenbeck@mbition.io>
This compu method uses transfer functions based on a rational
functions. Note that, since rational functions are not invertible in
general, the physical-to-internal mapping is only available if it is
explicitly specified via COMPU-PHYS-TO-INTERNAL and thus parameters
which use such compu methods can only be encoded if both directions
are specified. (TODO: Add possibility to directly specify internal
values for the purpose of encoding messages.)

Signed-off-by: Andreas Lauser <andreas.lauser@mbition.io>
Signed-off-by: Christian Hackenbeck <christian.hackenbeck@mbition.io>
Signed-off-by: Andreas Lauser <andreas.lauser@mbition.io>
Signed-off-by: Christian Hackenbeck <christian.hackenbeck@mbition.io>
we now ignore some files autogenerated by git and emacs as well as
most of the stuff contained within PDX archives.

Signed-off-by: Andreas Lauser <andreas.lauser@mbition.io>
Signed-off-by: Christian Hackenbeck <christian.hackenbeck@mbition.io>
@andlaus andlaus requested a review from kayoub5 September 19, 2024 08:19
@andlaus
Copy link
Collaborator Author

andlaus commented Sep 19, 2024

@nada-ben-ali: it would be great if you could test this with one of your data sets featuring a SCALE-RAT-FUNC compu method...

@nada-ben-ali
Copy link
Collaborator

@andlaus yes sure I'll do that.

@andlaus
Copy link
Collaborator Author

andlaus commented Sep 23, 2024

Ok, I merge this now.

@nada-ben-ali: if you find any issues with your datasets don't hesitate to open an issue (or -- even better -- a pull request)

@andlaus andlaus merged commit 7296617 into mercedes-benz:main Sep 23, 2024
7 checks passed
@nada-ben-ali
Copy link
Collaborator

@andlaus I've just tested the changes with a certain pdx file that contains SCALE-RAT-FUNC and I haven't observed any problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants