@@ -472,7 +472,7 @@ def add_frame_by_id(frame): # type: (canmatrix.Frame) -> None
472
472
if l .__len__ () == 0 :
473
473
continue
474
474
try :
475
- # if 1==1:
475
+ # if 1==1:
476
476
if followUp == FollowUps .signalComment :
477
477
try :
478
478
comment += "\n " + \
@@ -792,18 +792,18 @@ def add_frame_by_id(frame): # type: (canmatrix.Frame) -> None
792
792
tempba = regexp .match (decoded )
793
793
794
794
if tempba .group (1 ).strip ().startswith ("BO_ " ):
795
- regexp = re .compile (r"^BA_ +\"(.* )\" +BO_ +(. +) +(.+);" )
795
+ regexp = re .compile (r"^BA_ +\"(.+ )\" +BO_ +(\d +) +(.+);" )
796
796
temp = regexp .match (decoded )
797
797
get_frame_by_id (canmatrix .ArbitrationId .from_compound_integer (int (temp .group (2 )))).add_attribute (
798
798
temp .group (1 ), temp .group (3 ))
799
799
elif tempba .group (1 ).strip ().startswith ("SG_ " ):
800
- regexp = re .compile (r"^BA_ +\"(.* )\" +SG_ +(. +) +(. +) +(.+);" )
800
+ regexp = re .compile (r"^BA_ +\"(.+ )\" +SG_ +(\d +) +(\w +) +(.+);" )
801
801
temp = regexp .match (decoded )
802
802
if temp != None :
803
803
get_frame_by_id (canmatrix .ArbitrationId .from_compound_integer (int (temp .group (2 )))).signal_by_name (
804
804
temp .group (3 )).add_attribute (temp .group (1 ), temp .group (4 ))
805
805
elif tempba .group (1 ).strip ().startswith ("EV_ " ):
806
- regexp = re .compile (r"^BA_ +\"(.* )\" +EV_ +(. +) +(.+ );" )
806
+ regexp = re .compile (r"^BA_ +\"(.+ )\" +EV_ +(\w +) +(.* );" )
807
807
temp = regexp .match (decoded )
808
808
if temp != None :
809
809
db .add_env_attribute (temp .group (2 ),temp .group (1 ),temp .group (3 ))
@@ -867,7 +867,7 @@ def add_frame_by_id(frame): # type: (canmatrix.Frame) -> None
867
867
signal .mux_val_min = muxValMin
868
868
signal .mux_val_max = muxValMax
869
869
elif decoded .startswith ("EV_ " ):
870
- pattern = r"^EV_ +([\w\-]+) *\: +([0-9]+) +\[([0-9.+\-eE]+)\|([0-9.+\-eE]+)\] +\"(\w* )\" +([0-9.+\-eE]+) +([0-9.+\-eE]+) +([\w\-]+) +(.*);"
870
+ pattern = r"^EV_ +([\w\-\_ ]+) *\: +([0-9]+) +\[([0-9.+\-eE]+)\|([0-9.+\-eE]+)\] +\"(.*? )\" +([0-9.+\-eE]+) +([0-9.+\-eE]+) +([\w\-]+) +(.*);"
871
871
regexp = re .compile (pattern )
872
872
temp = regexp .match (decoded )
873
873
0 commit comments