Dyno report templates

Dyno2 measurement reports can be customized with use of HTML style template file.

Example dynamometer report
Example dyno report

To create your own template go to /home/pi/.dyno2/report/ directory. You will find report_example.html file. Copy or rename it to report.html. This file will be used for custom dyno report creation.

File syntax is a mix of common HTML language with custom commands that will insert dyno specific information into the report. Example template file looks like this:

${img "./perek logo.png" *,15}
<h2 style="text-align: center;">${project_info 0 customerName} - ${project_info 0 vehicleId} - ${project_info 0 projectName}</h2>
${main_graph 160,100 96}
${user_graph 160,75 96}
${page_break}
<p>Power correction: ${run_info 0 enginePowerCorrectionStandard}</p>
${run_table}

HTML syntax can be learned here: https://www.w3schools.com/html/

Custom dyno information is inserted into the file with use of commands. Example command looks like this:

${main_graph 160,100 96}

${ – start of command
main_graph – command name
600,450 – first argument – in this case it is main graph size
96 – second argument – in this case it is main graph dpi
} – end of command

While writing your own template, the dyno application doesn’t need to be restarted. The template file is read every time you select Save / Print pdf action.
If syntax errors are present in your file, debug information can be found in /home/pi/.dyno2/debug.txt

Command description

${img path size}

Command inserts image.
path – relative or absolute path to image file. If path contains white-space it is required to place it in quotes.
size – inserted image dimensions in millimeters. The format is width,height. One of the dimensions can be replaced with *. It will be calculated automatically to keep aspect ratio.

${img ./my_logo.jpg 100,20}
${img "/home/pi/Desktop/my other logo.jpg" *,15}

${main_graph size dpi}

Dynamometer power and torque vs engine speed

${user_graph size dpi}

Custom dyno graph

Commands main_graph and user_graph insert graphs from analyze tab. Main graph is the upper one with power and torque information. User graph is the lower one with channels selected by user.

size – graph size in millimeters. The format is width,height. Dimensions can’t be replaced with * wildcard.
dpi – dots per inch of the graph. The graph elements like lines and text have constant dot size. Increasing dpi will make all graph elements appear smaller. 96dpi will make printout look like the graph on the monitor. By setting 150dpi you will make the graph illegible on the print preview, but the printout will look good, because printer usually has higher dpi resolution than a screen.

${main_graph 160,100 96}
${user_graph 160,75 150}

${page_break}

Inserts page break. Everything inserted after this command will be on next printout page.

${run_info number id}

Inserts information about run.

Correction standard: ${run_info 0 enginePowerCorrectionStandard}
<br>
<ul>
  <li>${run_info 0 enginePowerCorrectionValue}</li>
  <li>${run_info 1 enginePowerCorrectionValue}</li>
  <li>${run_info 2 enginePowerCorrectionValue}</li>
<ul>

number – run number. 0 is the first run.
id – information id
Available information id:

idDatabase entry ID
projectIdParent project database ID
filenameRun data filename
favouriteMarked favourite
creationTimestampCreation timestamp
modificationTimestampLast modification timestamp
lastAccessTimestampLast access timestamp
runLengthRun length
engineSpeedSourceEngine speed source
engineSpeedRatioEngine speed ratio
enginePowerCorrectionStandardEngine power correction standard
enginePowerCorrectionValueEngine power correction value
ambientTemperatureAmbient temperature
ambientPressureAmbient pressure
ambientHumidityAmbient humidity
measuredEnginePowerPeak measured engine power
measuredEnginePowerRPMPeak measured engine power engine speed
measuredEngineTorquePeak measured engine torque
measuredEngineTorqueRPMPeak measured engine torque engine speed
measuredWheelPowerPeak measured power on wheels
measuredWheelPowerRPMPeak measured power on wheels engine speed
peakRoadSpeedPeak road speed
peakEngineSpeedPeak engine speed
commentRun comment
selectionStartSelection start
selectionEndSelection end
createdWithSoftwareVersionSoftware version at file creation

${project_info number id}

Inserts information about project.

Customer name: ${project_info 0 customerName}<br>
Registration number: ${project_info 0 vehicleId}<br>
Project name: ${project_info 0 projectName}<br>

number – run number. 0 is the first run.
id – information id
Available information id:

idDatabase entry ID
favouriteMarked favourite
creationTimestampCreation timestamp
lastRunTimestampLast run timestamp
lastAccessTimestampLast access timestamp
customerNameCustomer name
runCountRun count
vehicleIdVehicle registration number, VIN, etc.
projectNameProject name
vehicleTypeVehicle Type
brandVehicle Brand
modelVehicle Model
seriesVehicle Series
productionYearProduction Year
massVehicle mass
frontalAreaVehicle frontal area
CxAerodynamic drag coefficient
driveWheelsDrive wheels
wheelbaseWheelbase
frontTrackFront Track
rearTrackRear Track
engineCodeEngine codename
engineFuelTypeEngine fuel type
engineBoostTypeEngine boost type
engineConfigurationEngine cylinder layout configuration
displacementEngine displacement
cylinderCountCylinder count
valveCountValve count
compressionRatioCompression ratio
cylinderBoreCylinder bore
pistonStrokePiston stroke
gearboxTypeGearbox type
gearCountGear count
engineInertiaEngine-to-clutch elements moment of inertia
drivetrainInertiaVehicle clutch-to-dyno elements moment of inertia
stockEnginePowerPeak stock engine power
stockEnginePowerRPMPeak stock power engine speed
stockEngineTorquePeak stock engine torque
stockEngineTorqueRPMPeak stock torque engine speed
measuredEnginePowerPeak measured engine power
measuredEnginePowerRPMPeak measured engine power engine speed
measuredEngineTorquePeak measured engine torque
measuredEngineTorqueRPMPeak measured engine torque engine speed
measuredWheelPowerPeak measured power on wheels
measuredWheelPowerRPMPeak measured power on wheels engine speed
peakRoadSpeedPeak road speed
peakEngineSpeedPeak engine speed
descriptionProject description

${run_table}

Table with dynamometer text results

Inserts predefined table with run information.