danielhrisca / asammdf

Fast Python reader and editor for ASAM MDF / MF4 (Measurement Data Format) files
GNU Lesser General Public License v3.0
612 stars 216 forks source link

extract_bus_logging mix J1939 and non j1939 frames #921

Closed Karstensson closed 9 months ago

Karstensson commented 9 months ago

Python version

3.11

Code

MDF version

4.1

Code snippet

mdf_file.extract_bus_logging(database_files = database)

Traceback

canmatrix.canmatrix.J1939NeedsExtendedIdentifier:

Description

The problem is that I have a DBC-file that is J1939, canmatrix reports can_matridJ1939: True, however not all frames are extended causing it to crash. Shoul'nt we look at frame level to check if CAN Frame is also J1939 before trying to get the PDU?

The error happens on line 5018 in mdf.py