-
-
Notifications
You must be signed in to change notification settings - Fork 534
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
set name option for multiplexer signal #579
set name option for multiplexer signal #579
Conversation
If the multiplexer signal has a name, use the signal name rather than use the signal id.
change the expected value from from `MultiplexedSig` to `MultiplexorSig`
would be nice if a test case actually triggered that condition... (i.e., empty name for the multiplexer selector signal) |
update Co-authored-by: Andreas Lauser <github@poware.org>
Pull Request Test Coverage Report for Build 5360296379
💛 - Coveralls |
update the test case to rename a multiplexer signal to empty to triggered renaming condition
The GitHub action checks failed because the code didn't use the right variable in `test_multiplex_sym_dump`
|
||
# Note: cantools database cannot support multiple multiplexer signal names, so SYM file names the multiplexer | ||
# signal after the multiplexer id (Hence, 2A, not MultiplexerSig) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@samc1213: I don't get that comment. Do you remember what you meant to say here? (In my understanding, assigning more than one multiplexer selector signal to any multiplexed signal does not make sense anyway?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The relevant pull request where this change was added.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andlaus Are there any updates for this? Is there anything we can do to get this move forward?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am just confused why this comment was made in the first place, but I think that it was spurious. (so everything is alright here as far as I can see...) I'll merge the PR once the special treatments for empty signal names (and the corresponding test) are removed...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The files are already updated. Please let me know if there are any other issues. We really hope that this feature can be merged and it's an important feature for our product implementation. Thanks @andlaus
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm sorry for the late reply. I can't recall why I thought SYM multiplexer and cantools database representations didn't match, and decided to use the multiplexer value as the signal name. I thought during parsing we would lose the name of each multiplexer, so we had to use the value or something. I tried to reproduce but couldn't.
* Report an error when meeting an empty signal name rather than set name to signal value. * Generate a test case for testing exception
…_multiplex_sym_with_empty_signal_name_dump`
once the CI is happy (seems like there is a typing mistake somewhere), I'll merge this. |
hm, this is what the github action logs say: |
okay: the linter is not run on the tests, so
fixes the issue. (it is unrelated to this PR...) |
I run this command locally before, but just feel like it's not related to this pull request and then I should not push the changes to this pull request. But anyway, we should fix the issue. Made a new commit for that. |
I think it would have been slightly better if you put the fixes |
That's a great suggestion. Thanks for that. |
@andlaus, may I ask about when you will release a new version of |
The function
_dump_message
uses multiplexer signal id as the signal name. However, it might be incompatible in some platforms, such as the screenshot shown.In addition, using the ID as the name of the multiplexer signal is not clear enough for people to understand the meaning of this multiplexer. For this issue, I'd suggest that if the multiplexer signal has an original name, use the signal name rather than use the signal id.