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

ARXML: Signal name wrong when I-Signal name != System-signal-name #453

Closed
ForestRupicolous opened this issue Feb 25, 2020 · 5 comments
Closed
Assignees

Comments

@ForestRupicolous
Copy link
Contributor

When I'm converting an .arxml to a .dbc the signal names are wrongly converted. I'm not sure about the correct AUTOSAR term but I think the system-signal-name is used instead of the I-signal name. In my case they differ by a leading "I", e.g. "ImySignal", vs. "mySignal". In the test file for arxml.py (src\canmatrix\tests\ARXMLSecuredPDUTest.arxml) they are the same and therefore the test passes.

I think I already tracked down the issue in the code (in arxml.py):

        name = get_child(system_signal, "SHORT-NAME", root_or_cache, ns)  

should be:

        name = get_child(isignal, "SHORT-NAME", root_or_cache, ns)

The next lines for context:

        name = get_child(system_signal, "SHORT-NAME", root_or_cache, ns)
        unit_element = get_child(isignal, "UNIT", root_or_cache, ns)
        display_name = get_child(unit_element, "DISPLAY-NAME", root_or_cache, ns)

Am I correct with my assumptions? Are you interested in a pull-request?

@ForestRupicolous
Copy link
Contributor Author

Ok, I fear my understanding of the code doesn't go far enough for a pull-request. I just tried to update the tests to show the issue. But then I get a lot of other test errors I'm currently not able to fix.

@ForestRupicolous ForestRupicolous changed the title ARXML: Signal name wrong ARXML: Signal name wrong when I-Signal name != System-signal-name Feb 25, 2020
@ebroecker
Copy link
Owner

@ForestRupicolous

Thanks for your input, I'll have a look on it the next days.

@ebroecker ebroecker self-assigned this Feb 26, 2020
@ebroecker
Copy link
Owner

You want the i-signal-shortnames instead of the system-signal-shortnames for the result singal name, right?
I think this depends on your wishes.
Currently I use the system-signal-shortnames.

But I currently plan a big rework of the arxml decoder.
Maybe I could do this configurable.

@ebroecker
Copy link
Owner

fixed now with #571

it is configurable in convert now:
--signalNameFromAttrib [SysSignalName|ISignalName|CompuMethodName]

@ebroecker
Copy link
Owner

should be fixed, otherwise please shout!

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

No branches or pull requests

2 participants