Skip to content

Commit

Permalink
Merge pull request #7 from jshiv/support_long_signal_names
Browse files Browse the repository at this point in the history
Support Long Signal Names
  • Loading branch information
naveenv92 authored Aug 2, 2021
2 parents 623b114 + eb9bd02 commit 2514e7c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
3 changes: 3 additions & 0 deletions internal/generate/compile.go
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,9 @@ func (c *compiler) addMetadata() {
if def.AttributeName == "GenSigStartValue" {
sig.DefaultValue = int(def.IntValue)
}
if def.AttributeName == "SystemSignalLongSymbol" {
sig.LongName = def.StringValue
}
}
}
}
Expand Down
4 changes: 3 additions & 1 deletion pkg/descriptor/signal.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,10 @@ import (

// Signal describes a CAN signal.
type Signal struct {
// Description of the signal.
// Name of the signal.
Name string
// LongName of the signal.
LongName string
// Start bit.
Start uint16
// Length in bits.
Expand Down

0 comments on commit 2514e7c

Please sign in to comment.