GM PDR Data Extraction

Started by JSenek, June 17, 2020, 08:28:28 PM

Previous topic - Next topic

Phil Harvey

Quote from: oosheixe on October 20, 2020, 07:59:39 AM
@PhilHarvey, if it is possible to extract the referenced metadata, would you demonstrate how to do so?

My last post shows how to extract the marl in hex form.  It can't currently be extracted in binary form (I hacked ExifTool to get the marl.dat file I attached to my last post).

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

oosheixe

Hi Phil,

I was a bit vague/imprecise when I said "the referenced metadata".
Rather than the "marl" sensor data stream, what I am interested in using exiftool to extract is the following metadata fields within the mp4 file:
-  a Header ('mrlh')
-  a Values ('mrlv')
-  a Dictionary ('mrld')

are these able to be accessed via exiftool in its current form?
or is this something that would need to be added into exiftool to be able to print out normally (ie. not hexdump)?

thanks again

Phil Harvey

Yes, these are available with command like this:

exiftool -u -unknown_mrlh -b FILE > mrlh.dat

But most of the interesting stuff is in the marl data, which can't be extracted like this.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

jparrish88

Here's the dictionary mrld decoded (Thanks for the help on this) :


[['Channel Number', 'Channel Quantity', 'Channel Units', 'Units String', 'Flags', 'Interval', 'Min Reading', 'Max Reading', 'Disp Min', 'Disp Max', 'Multiplier', 'Offset', Channel Name', 'Channel Description'],
[1, 0, 0, '', 1, 50000000, 0, 3, 0.0, 3.0, 1.0, 0.0, 'System Power Mode', 'System Power Mode'],
[2, 0, 0, '', 1, 50000000, 0, 1, 0.0, 1.0, 1.0, 0.0, 'System Backup Power Enabled', 'System Backup Power Enabled'],
[3, 0, 0, '', 1, 50000000, 0, 3, 0.0, 3.0, 1.0, 0.0, 'System Backup Power Mode', 'System Backup Power Mode'],
[4, 0, 0, '', 1, 0, 0, 15, 0.0, 15.0, 1.0, 0.0, 'Steering 1 Switch', 'Steering 1 Switch'],
[5, 0, 0, '', 1, 0, 0, 15, 0.0, 15.0, 1.0, 0.0, 'Steering 2 Switch', 'Steering 2 Switch'],
[6, 0, 0, '', 1, 0, 0, 1, 0.0, 1.0, 1.0, 0.0, 'Transport Storage Mode', 'Transport Storage Mode'],
[7, 0, 0, '', 1, 0, 0, 1, 0.0, 1.0, 1.0, 0.0, 'Infotain Op Mode', 'Infotain Op Mode'],
[8, 0, 0, '', 1, 0, 0, 1, 0.0, 1.0, 1.0, 0.0, 'Valet Mode', 'Valet Mode'],
[9, 16, 1, '%', 7, 1000000, 0, 255, 0.0, 100.0, 0.00392157, 0.0, 'Boost Pressure Ind', 'Boost Pressure Ind'],
[10, 4, 1, '°C', 7, 5000000, 0, 255, -40.0, 215.0, 1.0, 233.14999999999998, 'Coolant Temp', 'Coolant Temp'],
[11, 9, 5, 'kPa', 7, 120000, 0, 127, -40.0, 120.0, 1000.0, -40000.0, 'Intake Boost Pressure', 'Intake Boost Pressure'],
[12, 9, 5, 'kPa', 7, 5000000, 0, 255, 0.0, 1020.0, 4000.0, 0.0, 'Oil Pressure', 'Oil Pressure'],
[13, 4, 1, '°C', 7, 5000000, 0, 255, -40.0, 215.0, 1.0, 233.14999999999998, 'Oil Temp', 'Oil Temp'],
[14, 8, 1, 'rpm', 7, 120000, 0, 65535, 0.0, 16383.75, 0.026179938779915, 0.0, 'RPM', 'RPM'],
[15, 16, 1, '%', 7, 120000, 0, 255, 0.0, 100.0, 0.00392157, 0.0, 'Accel Pos', 'Accel Pos'],
[16, 16, 1, '%', 7, 250000, 0, 255, 0.0, 100.0, 0.00392157, 0.0, 'Clutch Pos', 'Clutch Pos'],
[17, 16, 1, '%', 7, 100000, 0, 255, 0.0, 100.0, 0.00392157, 0.0, 'Brake Pos', 'Brake Pos'],
[18, 9, 5, 'kPa', 7, 10000000, 0, 255, 0.0, 1020.0, 4000.0, 0.0, 'LF Tyre Pressure', 'LF Tyre Pressure'],
[20, 9, 5, 'kPa', 7, 10000000, 0, 255, 0.0, 1020.0, 4000.0, 0.0, 'RF Tyre Pressure', 'RF Tyre Pressure'],
[19, 9, 5, 'kPa', 7, 10000000, 0, 255, 0.0, 1020.0, 4000.0, 0.0, 'LR Tyre Pressure', 'LR Tyre Pressure'],
[21, 9, 5, 'kPa', 7, 10000000, 0, 255, 0.0, 1020.0, 4000.0, 0.0, 'RR Tyre Pressure', 'RR Tyre Pressure'],
[22, 4, 1, '°C', 7, 10000000, 0, 255, -20.0, 107.0, 1.0, 253.14999999999998, 'LF Tyre Temp', 'LF Tyre Temp'],
[24, 4, 1, '°C', 7, 10000000, 0, 255, -20.0, 107.0, 1.0, 253.14999999999998, 'RF Tyre Temp', 'RF Tyre Temp'],
[23, 4, 1, '°C', 7, 10000000, 0, 255, -20.0, 107.0, 1.0, 253.14999999999998, 'LR Tyre Temp', 'LR Tyre Temp'],
[25, 4, 1, '°C', 7, 10000000, 0, 255, -20.0, 107.0, 1.0, 253.14999999999998, 'RR Tyre Temp', 'RR Tyre Temp'],
[26, 0, 0, '', 1, 250000, 0, 15, 0.0, 15.0, 1.0, 0.0, 'Gear', 'Gear'],
[27, 4, 1, '°C', 7, 5000000, 0, 255, -40.0, 215.0, 1.0, 233.14999999999998, 'Trans Oil Temp', 'Trans Oil Temp'],
[28, 16, 1, '%', 7, 1000000, 0, 255, 0.0, 100.0, 0.00392157, 0.0, 'Fuel Level', 'Fuel Level'],
[29, 2, 1, 'ltr', 7, 5000000, 0, 4095, 0.0, 511.875, 0.000125, 0.0, 'Fuel Capacity', 'Fuel Capacity'],
[30, 7, 1, '°', 7, 100000, 0, 65535, -180.0, 180.0, 0.0010908307824964562, -35.744343080843876, 'Steering Angle', 'Steering Angle'],
[31, 1, 4, 'km', 15, 50000000, 0, 2147483647, 0.0, 33554431.0, 15.625, 0.0, 'Distance', 'Distance'],
[32, 3, 3, 'kph', 7, 1000000, 0, 32767, 0.0, 511.0, 0.0043402777777777814, 0.0, 'Speed', 'Speed'],
[33, 0, 0, '', 1, 200000, 0, 1, 0.0, 1.0, 1.0, 0.0, 'ABS Active', 'ABS Active'],
[34, 0, 0, '', 1, 200000, 0, 1, 0.0, 1.0, 1.0, 0.0, 'Traction Control Active', 'Traction Control Active'],
[35, 0, 0, '', 1, 200000, 0, 1, 0.0, 1.0, 1.0, 0.0, 'Vehicle Stability Active', 'Vehicle Stability Active'],
[36, 0, 0, '', 1, 1000000, 0, 16, 0.0, 16.0, 1.0, 0.0, 'Corner Exit Setting', 'Corner Exit Setting'],
[37, 0, 0, '', 1, 120000, 0, 1, 0.0, 1.0, 1.0, 0.0, 'Speed Request Intervention', 'Speed Request Intervention'],
[38, 0, 0, '', 1, 120000, 0, 1, 0.0, 1.0, 1.0, 0.0, 'Speed Control Response', 'Speed Control Response'],
[39, 8, 1, 'rpm', 3, 120000, 0, 1023, 0.0, 8184.0, 0.83775804095728, 0.0, 'Engine Speed Request', 'Engine Speed Request'],
[40, 15, 0, 'Nm', 7, 250000, 0, 4095, -848.0, 1199.5, 0.5, -848.0, 'Engine Torqure Req', 'Engine Torqure Req'],
[41, 11, 0, 'V', 7, 1000000, 0, 255, 3.0, 28.5, 0.1, 3.0, 'Battery Voltage', 'Battery Voltage'],
[42, 10, 1, 'G', 7, 2000000, -32768, 32767, -97.0, 97.0, 0.02884331898, -1890.2757212919998, 'Lateral Acceleration', 'Lateral Acceleration'],
[43, 10, 1, 'G', 7, 2000000, -32768, 32767, -97.0, 97.0, 0.02884331898, -1890.2757212919998, 'Longitudinal Acceleration', 'Longitudinal Acceleration'],
[44, 10, 1, 'G', 7, 2000000, -32768, 32767, -97.0, 97.0, 0.02884331898, -1890.2757212919998, 'Vertical Acceleration', 'Vertical Acceleration'],
[45, 7, 1, '°', 7, 2000000, 0, 42, -90.0, 90.0, 1.7453292519943297e-09, 0.0, 'Latitude', 'Latitude'],
[46, 7, 1, '°', 7, 2000000, 0, 42, -180.0, 180.0, 1.7453292519943297e-09, 0.0, 'Longitude', 'Longitude'],
[47, 1, 0, 'm', 7, 2000000, -3000000, 3000000, -30000.0, 30000.0, 0.01, 0.0, 'Altitude', 'Altitude'],
[48, 7, 1, '°', 7, 2000000, 0, 36000, 0.0, 360.0, 0.000174532925199433, 0.0, 'Heading', 'Heading'],
[49, 0, 0, '', 1, 2000000, 0, 99, 0.0, 99.0, 1.0, 0.0, 'GPS Fix', 'GPS Fix'],
[50, 0, 0, '', 1, 0, 0, 1000, 0.0, 1000.0, 1.0, 0.0, 'Beacon', 'Beacon']
]


I'd be willing to provide the python I used to get here, if anyone wants it.

oosheixe

i'm interested in the python code you mentioned

would you go ahead and just attach it rather than PM?
that way others can benefit as well

jparrish88

Here's the MRLV decoded. I didn't spend time yet to decode the date and time stamps for their corresponding ISOs.

[[b'id  ', b'strs', ''], [b'time', b'time', '21-32-23'], [b'date', b'date', '2020-05-13'], [b'tstm', b'tstm', [4658689210913863680]], [b'ltim', b'time', '21-32-23'], [b'ldat', b'date', '2020-05-13'], [b'zone', b'strs', 'UNK'], [b'swvs', b'strs', '23258874AQ 0.1'], [b'lang', b'strs', 'en-US'], [b'cntr', b'strs', ''], [b'unit', b'focc', 'usim'], [b'flap', b'tstm',
  • ], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', ''], [b'    ', b'strs', '']]

jparrish88

Here are the two files I used for just working with the files that were already attached to this Forum Topic. I eventually plan to have this operate out of one file and directly parse from a video themselves. But I'm not there yet, and I wasn't sure how useful it would be yet until I fully understood how to grab each .dat file.

I put an MIT as it's compatible with Phil's license on EXIF.

sidepipe

This is an old topic but has there been any more progress with this? I've been in contact with Phil and sent him another video, and he also pointed me to this thread. Thought I'd better check to see if anyone's got further to avoid him ( and me if I get a chance ) wasting more time than necessary!

Phil Harvey

#23
From the sample that sidepipe sent me, I can decode the mrld and mrlv (see below).  Decoding the timed metadata from the marl data is trickier, but after about 4 hours searching, I think I can finally see where the GPS latitude/longitude are stored.  I still have a lot of work to do, but there is hope that I'll be able to decode this.

mrld data:

Chan Num Fmt Units Flags Interval Min Reading Max Reading Disp Min Disp Max   Multiplier          Offset            Channel Name                        Channel Description
1    16  1   %     7     1000000  0           255         0        100        0.00392157          0                 Boost Pressure Ind                  Boost Pressure Ind
2    4   1   °C    7     5000000  0           255         -40      215        1                   233.15            Coolant Temp                        Coolant Temp
3    9   5   kPa   7     120000   0           255         -128     127        1000                -128000           Intake Boost Pressure               Intake Boost Pressure
4    9   5   kPa   7     5000000  0           255         0        1020       4000                0                 Oil Pressure                        Oil Pressure
5    4   1   °C    7     5000000  0           255         -40      215        1                   233.15            Oil Temp                            Oil Temp
6    8   1   rpm   7     120000   0           65535       0        16383.75   0.026179938779915   0                 RPM                                 RPM
7    16  1   %     7     120000   0           255         0        100        0.00392157          0                 Accel Pos                           Accel Pos
8    16  1   %     7     250000   0           255         0        100        0.00392157          0                 Clutch Pos                          Clutch Pos
9    16  1   %     7     100000   0           255         0        100        0.00392157          0                 Brake Pos                           Brake Pos
10   9   5   kPa   7     10000000 0           255         0        1020       4000                0                 LF Tyre Pressure                    LF Tyre Pressure
12   9   5   kPa   7     10000000 0           255         0        1020       4000                0                 RF Tyre Pressure                    RF Tyre Pressure
11   9   5   kPa   7     10000000 0           255         0        1020       4000                0                 LR Tyre Pressure                    LR Tyre Pressure
13   9   5   kPa   7     10000000 0           255         0        1020       4000                0                 RR Tyre Pressure                    RR Tyre Pressure
14   4   1   °C    7     10000000 0           255         -20      107        1                   253.15            LF Tyre Temp                        LF Tyre Temp
16   4   1   °C    7     10000000 0           255         -20      107        1                   253.15            RF Tyre Temp                        RF Tyre Temp
15   4   1   °C    7     10000000 0           255         -20      107        1                   253.15            LR Tyre Temp                        LR Tyre Temp
17   4   1   °C    7     10000000 0           255         -20      107        1                   253.15            RR Tyre Temp                        RR Tyre Temp
18   0   0         1     250000   0           15          0        15         1                   0                 Gear                                Gear
19   4   1   °C    7     5000000  0           255         -40      215        1                   233.15            Trans Oil Temp                      Trans Oil Temp
20   16  1   %     7     1000000  0           255         0        100        0.00392157          0                 Fuel Level                          Fuel Level
21   2   1   ltr   7     5000000  0           4095        0        511.875    0.000125            0                 Fuel Capacity                       Fuel Capacity
22   7   1   °     7     100000   0           65535       -180     180        0.00109083078249646 -35.7443430808439 Steering Angle                      Steering Angle
23   1   4   km    15    50000000 0           2147483647  0        33554431   15.625              0                 Distance                            Distance
24   3   3   kph   7     1000000  0           32767       0        511        0.00434027777777778 0                 Speed                               Speed
25   0   0         1     200000   0           1           0        1          1                   0                 ABS Active                          ABS Active
26   0   0         1     200000   0           1           0        1          1                   0                 Traction Control Active             Traction Control Active
27   0   0         1     200000   0           1           0        1          1                   0                 Vehicle Stability Active            Vehicle Stability Active
28   0   0         1     1000000  0           16          0        16         1                   0                 Corner Exit Setting                 Corner Exit Setting
33   0   0         1     1000000  0           16          0        16         1                   0                 Driver Performance Mode             Driver Performance Mode
29   0   0         1     120000   0           1           0        1          1                   0                 Speed Request Intervention          Speed Request Intervention
30   0   0         1     120000   0           1           0        1          1                   0                 Speed Control Response              Speed Control Response
31   8   1   rpm   3     120000   0           1023        0        8184       0.83775804095728    0                 Engine Speed Request                Engine Speed Request
32   15  0   Nm    7     250000   0           4095        -848     1199.5     0.5                 -848              Engine Torqure Req                  Engine Torqure Req
45   11  0   V     7     1000000  0           255         3        28.5       0.1                 3                 Battery Voltage                     Battery Voltage
46   10  1   G     7     2000000  4294934528  32767       -97      97         0.02884331898       -1890.275721292   Lateral Acceleration                Lateral Acceleration
47   10  1   G     7     2000000  4294934528  32767       -97      97         0.02884331898       -1890.275721292   Longitudinal Acceleration           Longitudinal Acceleration
48   10  1   G     7     2000000  4294934528  32767       -97      97         0.02884331898       -1890.275721292   Vertical Acceleration               Vertical Acceleration
49   7   1   °     7     2000000  0           42          -90      90         1.74532925199433e-09 0                Latitude                            Latitude
50   7   1   °     7     2000000  0           42          -180     180        1.74532925199433e-09 0                Longitude                           Longitude
51   1   0   m     7     2000000  4291967296  3000000     -30000   30000      0.01                0                 Altitude                            Altitude
52   7   1   °     7     2000000  0           36000       0        360        0.000174532925199433 0                Heading                             Heading
53   0   0         1     2000000  0           99          0        99         1                   0                 GPS Fix                             GPS Fix
54   0   0         1     0        0           1000        0        1000       1                   0                 Beacon                              Beacon
55   16  1   %     6     10000000 0           255         0        100        0.00392157          0                 CPU User                            CPU User
56   16  1   %     6     10000000 0           255         0        100        0.00392157          0                 CPU System                          CPU System
57   16  1   %     6     10000000 0           255         0        100        0.00392157          0                 CPU Free                            CPU Free
58   16  1   %     6     10000000 0           255         0        100        0.00392157          0                 CPU IO                              CPU IO
59   16  1   %     6     10000000 0           255         0        100        0.00392157          0                 CPU IRQ                             CPU IRQ
60   0   0   B/s   0     10000000 0           2147483647  0        2147483647 1                   0                 Disk Read Rate                      Disk Read Rate
61   0   0   Op/s  6     10000000 0           65535       0        65535      1                   0                 Disk Read Operations                Disk Read Operations
62   6   4   ms    2     10000000 0           65535       0        65535      0.001               0                 Disk Read Time                      Disk Read Time
63   0   0   B/s   0     10000000 0           2147483647  0        2147483647 1                   0                 Disk Write Rate                     Disk Write Rate
64   0   0   Op/s  6     10000000 0           65535       0        65535      1                   0                 Disk Write Operations               Disk Write Operations
65   6   4   ms    2     10000000 0           65535       0        65535      0.001               0                 Disk Write Time                     Disk Write Time
66   1   4   km    15    10000000 0           2147483647  0        2097152    0.976573            0                 Recording Event Odometer            Recording Event Odometer
34   3   3   kph   7     500000   0           16383       0        511.96875  0.00868055555555556 0                 Wheelspeed Left Driven              Wheelspeed Left Driven
35   3   3   kph   7     500000   0           16383       0        511.96875  0.00868055555555556 0                 Wheelspeed Right Driven             Wheelspeed Right Driven
36   3   3   kph   7     500000   0           16383       0        511.96875  0.00868055555555556 0                 Wheelspeed Left Non-Driven          Wheelspeed Left Non-Driven
37   3   3   kph   7     500000   0           16383       0        511.96875  0.00868055555555556 0                 Wheelspeed Right Non-Driven         Wheelspeed Right Non-Driven
38   1   5   mm    7     250000   0           65535       -256     255        0.001               -0.256            Suspension Displacement Left Front  Suspension Displacement Left Front
39   1   5   mm    7     250000   0           65535       -256     255        0.001               -0.256            Suspension Displacement Right Front Suspension Displacement Right Front
40   1   5   mm    7     250000   0           65535       -256     255        0.001               -0.256            Suspension Displacement Left Rear   Suspension Displacement Left Rear
41   1   5   mm    7     250000   0           65535       -256     255        0.001               -0.256            Suspension Displacement Right Rear  Suspension Displacement Right Rear
42   8   3   °/sec 7     200000   0           65535       -128     127.9375   0.00109083078249646 -2.23402144255274 Yaw Rate                            Yaw Rate
43   4   1   °C    7     2500000  0           255         -40      87.5       0.5                 233.15            Outside Air Temperature             Outside Air Temperature
44   4   1   °C    7     5000000  0           255         -40      215        1                   233.15            Intake Air Temperature              Intake Air Temperature

mrlv data:

Time Stamp                      : 12:05:06
Date Stamp                      : 2024:03:30
Date Time                       : 2024:03:30 08:04:39-04:00
Time Stamp 2                    : 12:04:39
Date Stamp 2                    : 2024:03:30
Time Zone                       : UNK
Software Version                : 84377136AC 0.1
Language                        : en-US
Units                           : U.S. Imperial

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

Phil Harvey

Wow.  OK. Complication.  There are GPS latitude values at regular intervals for a total of 1844 points in this video, but there is only 1 GPS longitude value.  :(  I hope I'm missing something.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

sidepipe

Firstly sorry that example file I sent was so big ( it happened to match with the other dashcam footage but maybe I need to go out specifically and record a much shorter sample? )

Anyway, I've had a quick look at that patent and the key seems to be that compact readings use channel numbers which are offset from the previous reading rather than absolute, which presumably means that all such compact readings ( after a full reading ) need to be decoded in order to find all info ( sorry, thinking out loud, I guess everyone already realises this! ) The problem for me is I'm starting from zero - with exiftool as well as this PDR, so the amount of time it would take me to even get at the extracted data to look at would be massive!

If someone could let me know the exact exiftool parameters that would get me the mrl(h|v|d) blocks in binary form from the file then I can have a look myself to see if I can make any sense of it. I can see ( in a -ee3 -U -G3:1 output: )

[Track3]        0x0004 Other Format                    : marl
[Track3]             - Unknown mrlh                    : (Binary data 4 bytes, use -b option to extract)
[Track3]             - Unknown mrlv                    : (Binary data 1716 bytes, use -b option to extract)
[Track3]             - Unknown mrld                    : (Binary data 29568 bytes, use -b option to extract)

but I don't have a clue what ( besides "-b" ) I need to use to get at these specific blocks.

The good news is that the patents do seem to contain the info required to decode these things....

Phil Harvey

We've been communicating by email, but for anyone else reading the other blocks may be extracted like this:

exiftool -u -unknown_mrld -b FILE > mrld.dat

We're making progress (well, sidepipe has made a real breakthrough anyway), and will post back here if/when we have a solution.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

Phil Harvey

#27
We've managed to decode everything.  It is very impressive the amount of information stored in PDR data.

ExifTool 12.82 will have the ability to extract all this.

Here is an example of the output:

> exiftool test.mp4 gm:all -ee -G0:3
[GM:Main]       Version                         : 3.1
[GM:Main]       Time 1                          : 18:41:11
[GM:Main]       Date 1                          : 2020:06:27
[GM:Main]       Start Time                      : 2020:06:27 18:41:11.236000
[GM:Main]       Time 2                          : 18:41:11
[GM:Main]       Date 2                          : 2020:06:27
[GM:Main]       Time Zone                       : UNK
[GM:Main]       Software Version                : 23258874AQ 0.1
[GM:Main]       Language                        : en-US
[GM:Main]       Units                           : U.S. Imperial
[GM:Main]       Channel 01 Type                 : 0
[GM:Main]       Channel 01 Num                  : 0
[GM:Main]       Channel 01 Units                :
[GM:Main]       Channel 01 Flags                : 1
[GM:Main]       Channel 01 Interval             : 50000000
[GM:Main]       Channel 01 Min                  : 0
[GM:Main]       Channel 01 Max                  : 3
[GM:Main]       Channel 01 Disp Min             : 0
[GM:Main]       Channel 01 Disp Max             : 3
[GM:Main]       Channel 01 Multiplier           : 1
[GM:Main]       Channel 01 Offset               : 0
[GM:Main]       Channel 01 Name                 : System Power Mode
[GM:Main]       Channel 01 Description          : System Power Mode
[GM:Main]       Channel 02 Type                 : 0
[GM:Main]       Channel 02 Num                  : 0
[GM:Main]       Channel 02 Units                :
[GM:Main]       Channel 02 Flags                : 1
[GM:Main]       Channel 02 Interval             : 50000000
[GM:Main]       Channel 02 Min                  : 0
[GM:Main]       Channel 02 Max                  : 1
[GM:Main]       Channel 02 Disp Min             : 0
[GM:Main]       Channel 02 Disp Max             : 1
[GM:Main]       Channel 02 Multiplier           : 1
[GM:Main]       Channel 02 Offset               : 0
[GM:Main]       Channel 02 Name                 : System Backup Power Enabled
[GM:Main]       Channel 02 Description          : System Backup Power Enabled
    <remaining channel parameters except Name omitted for brevity>
[GM:Main]       Channel 03 Name                 : System Backup Power Mode
[GM:Main]       Channel 04 Name                 : Steering 1 Switch
[GM:Main]       Channel 05 Name                 : Steering 2 Switch
[GM:Main]       Channel 06 Name                 : Transport Storage Mode
[GM:Main]       Channel 07 Name                 : Infotain Op Mode
[GM:Main]       Channel 08 Name                 : Valet Mode
[GM:Main]       Channel 09 Name                 : Boost Pressure Ind
[GM:Main]       Channel 10 Name                 : Coolant Temp
[GM:Main]       Channel 11 Name                 : Intake Boost Pressure
[GM:Main]       Channel 12 Name                 : Oil Pressure
[GM:Main]       Channel 13 Name                 : Oil Temp
[GM:Main]       Channel 14 Name                 : RPM
[GM:Main]       Channel 15 Name                 : Accel Pos
[GM:Main]       Channel 16 Name                 : Clutch Pos
[GM:Main]       Channel 17 Name                 : Brake Pos
[GM:Main]       Channel 18 Name                 : LF Tyre Pressure
[GM:Main]       Channel 20 Name                 : RF Tyre Pressure
[GM:Main]       Channel 19 Name                 : LR Tyre Pressure
[GM:Main]       Channel 21 Name                 : RR Tyre Pressure
[GM:Main]       Channel 22 Name                 : LF Tyre Temp
[GM:Main]       Channel 24 Name                 : RF Tyre Temp
[GM:Main]       Channel 23 Name                 : LR Tyre Temp
[GM:Main]       Channel 25 Name                 : RR Tyre Temp
[GM:Main]       Channel 26 Name                 : Gear
[GM:Main]       Channel 27 Name                 : Trans Oil Temp
[GM:Main]       Channel 28 Name                 : Fuel Level
[GM:Main]       Channel 29 Name                 : Fuel Capacity
[GM:Main]       Channel 30 Name                 : Steering Angle
[GM:Main]       Channel 31 Name                 : Distance
[GM:Main]       Channel 32 Name                 : Speed
[GM:Main]       Channel 33 Name                 : ABS Active
[GM:Main]       Channel 34 Name                 : Traction Control Active
[GM:Main]       Channel 35 Name                 : Vehicle Stability Active
[GM:Main]       Channel 36 Name                 : Corner Exit Setting
[GM:Main]       Channel 37 Name                 : Speed Request Intervention
[GM:Main]       Channel 38 Name                 : Speed Control Response
[GM:Main]       Channel 39 Name                 : Engine Speed Request
[GM:Main]       Channel 40 Name                 : Engine Torqure Req
[GM:Main]       Channel 41 Name                 : Battery Voltage
[GM:Main]       Channel 42 Name                 : Lateral Acceleration
[GM:Main]       Channel 43 Name                 : Longitudinal Acceleration
[GM:Main]       Channel 44 Name                 : Vertical Acceleration
[GM:Main]       Channel 45 Name                 : Latitude
[GM:Main]       Channel 46 Name                 : Longitude
[GM:Main]       Channel 47 Name                 : Altitude
[GM:Main]       Channel 48 Name                 : Heading
[GM:Main]       Channel 49 Name                 : GPS Fix
[GM:Main]       Channel 50 Name                 : Beacon
[GM:Doc2]       Time Stamp                      : 2020:06:27 18:41:11.239285
[GM:Doc2]       Accel Pos                       : 17.25 %
[GM:Doc2]       Intake Boost Pressure           : -40.00 kPa
[GM:Doc2]       RPM                             : 2351.74 rpm
[GM:Doc3]       Time Stamp                      : 2020:06:27 18:41:11.251286
[GM:Doc3]       Brake Pos                       : 1.96 %
[GM:Doc4]       Time Stamp                      : 2020:06:27 18:41:11.252285
[GM:Doc4]       Accel Pos                       : 17.25 %
[GM:Doc4]       Intake Boost Pressure           : -40.00 kPa
[GM:Doc4]       RPM                             : 2350.43 rpm
[GM:Doc5]       Time Stamp                      : 2020:06:27 18:41:11.261286
[GM:Doc5]       Brake Pos                       : 1.18 %
[GM:Doc6]       Time Stamp                      : 2020:06:27 18:41:11.265285
[GM:Doc6]       Accel Pos                       : 17.25 %
[GM:Doc6]       Intake Boost Pressure           : -40.00 kPa
[GM:Doc6]       RPM                             : 2352.27 rpm
[GM:Doc7]       Time Stamp                      : 2020:06:27 18:41:11.272285
[GM:Doc7]       Speed                           : 58.31 km/h
[GM:Doc8]       Time Stamp                      : 2020:06:27 18:41:11.273286
[GM:Doc8]       Oil Pressure                    : 284.00 kPa
[GM:Doc8]       Oil Temp                        : 59 C
[GM:Doc8]       Fuel Level                      : 82.75 %
[GM:Doc8]       Fuel Capacity                   : 69.625 L
[GM:Doc9]       Time Stamp                      : 2020:06:27 18:41:11.277286
[GM:Doc9]       Accel Pos                       : 17.25 %
[GM:Doc9]       Intake Boost Pressure           : -40.00 kPa
[GM:Doc9]       RPM                             : 2349.39 rpm
[GM:Doc10]      Time Stamp                      : 2020:06:27 18:41:11.290286
[GM:Doc10]      Accel Pos                       : 17.25 %
[GM:Doc10]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc10]      RPM                             : 2350.43 rpm
[GM:Doc11]      Time Stamp                      : 2020:06:27 18:41:11.302286
[GM:Doc11]      Accel Pos                       : 17.25 %
[GM:Doc11]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc11]      RPM                             : 2351.74 rpm
[GM:Doc12]      Time Stamp                      : 2020:06:27 18:41:11.314286
[GM:Doc12]      Accel Pos                       : 17.25 %
[GM:Doc12]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc12]      RPM                             : 2349.65 rpm
[GM:Doc13]      Time Stamp                      : 2020:06:27 18:41:11.327286
[GM:Doc13]      Accel Pos                       : 17.25 %
[GM:Doc13]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc13]      RPM                             : 2350.70 rpm
[GM:Doc14]      Time Stamp                      : 2020:06:27 18:41:11.334456
[GM:Doc14]      Latitude                        : 34.681183 N
[GM:Doc14]      Longitude                       : 82.820822 W
[GM:Doc14]      Altitude                        : 254.1 m
[GM:Doc14]      Heading                         : 236.46
[GM:Doc14]      GPS Fix                         : 1
[GM:Doc15]      Time Stamp                      : 2020:06:27 18:41:11.339286
[GM:Doc15]      Accel Pos                       : 17.25 %
[GM:Doc15]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc15]      RPM                             : 2349.91 rpm
[GM:Doc16]      Time Stamp                      : 2020:06:27 18:41:11.351285
[GM:Doc16]      Brake Pos                       : 1.96 %
[GM:Doc17]      Time Stamp                      : 2020:06:27 18:41:11.352286
[GM:Doc17]      Accel Pos                       : 17.25 %
[GM:Doc17]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc17]      RPM                             : 2352.27 rpm
[GM:Doc18]      Time Stamp                      : 2020:06:27 18:41:11.361285
[GM:Doc18]      Brake Pos                       : 1.18 %
[GM:Doc19]      Time Stamp                      : 2020:06:27 18:41:11.364285
[GM:Doc19]      Accel Pos                       : 17.25 %
[GM:Doc19]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc19]      RPM                             : 2350.17 rpm
[GM:Doc20]      Time Stamp                      : 2020:06:27 18:41:11.371286
[GM:Doc20]      Speed                           : 58.38 km/h
[GM:Doc21]      Time Stamp                      : 2020:06:27 18:41:11.377285
[GM:Doc21]      Accel Pos                       : 17.25 %
[GM:Doc21]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc21]      RPM                             : 2356.72 rpm
[GM:Doc22]      Time Stamp                      : 2020:06:27 18:41:11.390285
[GM:Doc22]      Accel Pos                       : 17.25 %
[GM:Doc22]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc22]      RPM                             : 2355.67 rpm
[GM:Doc23]      Time Stamp                      : 2020:06:27 18:41:11.401286
[GM:Doc23]      Brake Pos                       : 1.96 %
[GM:Doc24]      Time Stamp                      : 2020:06:27 18:41:11.411286
[GM:Doc24]      Brake Pos                       : 1.18 %
[GM:Doc25]      Time Stamp                      : 2020:06:27 18:41:11.412039
[GM:Doc25]      Lateral Acceleration            : 0.000 G
[GM:Doc26]      Time Stamp                      : 2020:06:27 18:41:11.413183
[GM:Doc26]      Longitudinal Acceleration       : 0.000 G
[GM:Doc27]      Time Stamp                      : 2020:06:27 18:41:11.413278
[GM:Doc27]      Vertical Acceleration           : 0.941 G
[GM:Doc28]      Time Stamp                      : 2020:06:27 18:41:11.415286
[GM:Doc28]      Accel Pos                       : 17.25 %
[GM:Doc28]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc28]      RPM                             : 2353.58 rpm
[GM:Doc29]      Time Stamp                      : 2020:06:27 18:41:11.427286
[GM:Doc29]      Accel Pos                       : 17.25 %
[GM:Doc29]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc29]      RPM                             : 2356.46 rpm
[GM:Doc30]      Time Stamp                      : 2020:06:27 18:41:11.439286
[GM:Doc30]      Accel Pos                       : 17.25 %
[GM:Doc30]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc30]      RPM                             : 2355.93 rpm
[GM:Doc31]      Time Stamp                      : 2020:06:27 18:41:11.451286
[GM:Doc31]      Brake Pos                       : 1.96 %
[GM:Doc32]      Time Stamp                      : 2020:06:27 18:41:11.452286
[GM:Doc32]      Accel Pos                       : 17.25 %
[GM:Doc32]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc32]      RPM                             : 2357.77 rpm
[GM:Doc33]      Time Stamp                      : 2020:06:27 18:41:11.461286
[GM:Doc33]      Brake Pos                       : 1.18 %
[GM:Doc34]      Time Stamp                      : 2020:06:27 18:41:11.465286
[GM:Doc34]      Accel Pos                       : 17.25 %
[GM:Doc34]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc34]      RPM                             : 2355.93 rpm
[GM:Doc35]      Time Stamp                      : 2020:06:27 18:41:11.468286
[GM:Doc35]      Engine Torqure Req              : 63.5 Nm
[GM:Doc36]      Time Stamp                      : 2020:06:27 18:41:11.472286
[GM:Doc36]      Speed                           : 58.48 km/h
[GM:Doc37]      Time Stamp                      : 2020:06:27 18:41:11.477286
[GM:Doc37]      Accel Pos                       : 17.25 %
[GM:Doc37]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc37]      RPM                             : 2356.98 rpm
[GM:Doc38]      Time Stamp                      : 2020:06:27 18:41:11.490286
[GM:Doc38]      Accel Pos                       : 17.25 %
[GM:Doc38]      Intake Boost Pressure           : -40.00 kPa
[GM:Doc38]      RPM                             : 2359.60 rpm
[GM:Doc39]      Time Stamp                      : 2020:06:27 18:41:11.492285
[GM:Doc39]      Engine Torqure Req              : 63 Nm
[GM:Doc40]      Time Stamp                      : 2020:06:27 18:41:11.501286
[GM:Doc40]      Brake Pos                       : 1.96 %
...

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

sidepipe

I think Phil uses the word "we" far too generously - I'd like to think I helped a bit, but really he did all the hard work, and again I want to thank him for this and for exiftool generally.

As for the PDR itself, as Phil says it's really incredible how much data you get considering it's fitted to GM cars - probably similar to the info race teams have to hand.

Phil Harvey

#29
Thanks Sidepipe.

Attached is a format file from Sidepipe that may be useful for others who want to create a CSV file for importing into RaceRender. --> (see Edit2 below)

exiftool -ee -n -m -p pdrcsv.fmt FILE > out.csv

And please let me know if anyone has a Corvette C8 PDR video to share -- I would like to test the code against this new version of PDR.

- Phil

Edit: Note that processing large PDR videos may be slow and require a lot of memory.  On my system, extracting all of the information from a 680 MB video produces 920,000 tags, takes 78 seconds (or 10x longer using Sidepipe's format file), and requires 1 GB of RAM.  However, there are ways to speed things up and reduce the memory requirements if you don't need to extract all of the information (eg. the API IgnoreTags option).

Edit2: I've added an optimized API PrintCSV option that prints all PDR data in CSV format directly.  With this option, the processing time drops to 6.4 seconds, and memory usage to 37 MB for the above-mentioned 680 MB video.  Also, the corresponding command is much simpler:

exiftool -api printcsv FILE > out.csv
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).