- How to use CuteCom to record a specific type of log
- Using OpenLogViewer (OLV) to view FreeEMS binary logs
- Basic predefined log with fairly full information in it Available in MTX (~20Hz) and CuteCom (~100Hz)
- Logic Analyser (LA) log types 8 bit is available now! 16 and 32 bit NOT Available Yet!
- Buffered Logic Analyser (BLA) log types NOT Available Yet!
- Position (RPM) log type NOT Available Yet!
- Structs (STR) log types NOT Available Yet!
- Scratch pad (SPD) log type NOT Available Yet!
Reading FreeEMS Logs
Reading FreeEMS Logs
FreeEMS currently has two types of logs, that will be expanding to 11 types in the future, or maybe more. I'll update them with one post per type of log and information on how to obtain and interpret them. This post will just be an index to those posts! In general you can get logs from FreeEMS in two ways. For the time being, the preferred way is with a terminal application such as CuteCom and the provided binary packets to control things. You can also use MegaTunix to record logs, however the polled textual types are nearly 5x lower resolution than binary types and binary types with MTX can be interrupted by packets from MTX if you perform any actions.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Re: Reading FreeEMS Logs
How to use CuteCom to record a specific type of log
EDIT by request:
Using an application like cutecom to record a FreeEMS binary log is very straight forward. Just connect the cable to the device, turn the device on, open the correct device in your application, and start saving/recording the stream to a file with .bin extension.
The correct serial settings are the following: 8,O,1
Note, O stands for ODD, this is not the default configuration, if you fail to change it, you'll still get a data stream, however it will be very (95%+) corrupted and FreeEMS will reject all and any packets that you send it/it receives.
It should be possible to configure the serial port as 8,O,1 and then just cat the device file out to a file, however you need to configure the port correctly first. How to do that without an app, I'm not sure.
I'm unsure which applications are best to use on windows for this task, suggestions are welcome.
EDIT by request:
Using an application like cutecom to record a FreeEMS binary log is very straight forward. Just connect the cable to the device, turn the device on, open the correct device in your application, and start saving/recording the stream to a file with .bin extension.
The correct serial settings are the following: 8,O,1
Note, O stands for ODD, this is not the default configuration, if you fail to change it, you'll still get a data stream, however it will be very (95%+) corrupted and FreeEMS will reject all and any packets that you send it/it receives.
It should be possible to configure the serial port as 8,O,1 and then just cat the device file out to a file, however you need to configure the port correctly first. How to do that without an app, I'm not sure.
I'm unsure which applications are best to use on windows for this task, suggestions are welcome.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Re: Reading FreeEMS Logs
Using OpenLogViewer (OLV) to view FreeEMS binary logs
EDIT by request:
Once you have a binary stream captured into a .bin file with some other application such as cutecom, you can view it with OLV.
Simply choose the file in the File >> Open dialog box and it will load. If it is very big, and you're using standard memory settings, it could fail. Ask on the forum if that happens to you. If it's reasonably sized you'll get some statistics from the file in the console and a window of fields to choose from. Drag the fields of interest into the division box to the lower left and create additional division boxes as required.
EDIT by request:
Once you have a binary stream captured into a .bin file with some other application such as cutecom, you can view it with OLV.
Simply choose the file in the File >> Open dialog box and it will load. If it is very big, and you're using standard memory settings, it could fail. Ask on the forum if that happens to you. If it's reasonably sized you'll get some statistics from the file in the console and a window of fields to choose from. Drag the fields of interest into the division box to the lower left and create additional division boxes as required.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Re: Reading FreeEMS Logs
Basic (BIN) predefined log with fairly full information in it
Available in MTX (~30Hz in CSV) and CuteCom (~90Hz)
Available in MTX (~30Hz in CSV) and CuteCom (~90Hz)
Code: Select all
String[] coreStatusAFlagNames = {
"CS-FuelPumpPrime",
"CS-unused1",
"CS-unused2",
"CS-unused3",
"CS-unused4",
"CS-unused5",
"CS-unused6",
"CS-unused7"
};
String[] decoderFlagsFlagNames = {
"DF-CombustionSync",
"DF-CrankSync",
"DF-CamSync",
"DF-LAST_TIMESTAMP_VALID",
"DF-LAST_PERIOD_VALID",
"DF-LAST_MATCH_VALID",
"DF-Spare-6",
"DF-Spare-7"
};
String[] flaggableFlagsNames = {
"FF-callsToUISRs", // to ensure we aren't accidentally triggering unused ISRs.
"FF-lowVoltageConditions", // low voltage conditions.
"FF-decoderSyncLosses", // Number of times cam, crank or combustion sync is lost.
"FF-decoderSyncCorrections", // Definite decoder syncs found while already synced in a different position.
"FF-decoderSyncStateClears", // Sync loss called when not synced yet, thus discarding data and preventing sync.
"FF-serialNoiseErrors", // Incremented when noise is detected
"FF-serialFramingErrors", // Incremented when a framing error occurs
"FF-serialParityErrors", // Incremented when a parity error occurs
"FF-serialOverrunErrors", // Incremented when overrun occurs (duplicated in KeyUserDebug below)
"FF-serialEscapePairMismatches", // Incremented when an escape is found but not followed by an escapee
"FF-serialStartsInsideAPacket", // Incremented when a start byte is found inside a packet
"FF-serialPacketsOverLength", // Incremented when the buffer fills up before the end
"FF-serialChecksumMismatches", // Incremented when calculated checksum did not match the received one
"FF-serialPacketsUnderLength", // Incremented when a packet is found that is too short
"FF-commsDebugMessagesNotSent", // Incremented when a debug message can't be sent due to the TX buffer
"FF-commsErrorMessagesNotSent" // Incremented when an error message can't be sent due to the TX buffer
};
private LogField[] fields = { // This should be read from a file at some point, as it's going to be flexible. See FreeEMS/src/inc/structs.h for definitive answers.
// CoreVars struct contents:
new LogField("IAT", 100), // Inlet Air Temperature : 0.0 - 655.35 (0.01 Kelvin (/100))
new LogField("CHT", 100), // Coolant / Head Temperature : 0.0 - 655.35 (0.01 Kelvin (/100))
new LogField("TPS", 640), // Throttle Position Sensor : 0.0 - 102.398438 (0.0015625 % (/640))
new LogField("EGO", 32768), // Exhaust Gas Oxygen : 0.0 - 1.99996948 (0.0000305175781 lambda (/32768))
new LogField("MAP", 100), // Manifold Absolute Pressure : 0.0 - 655.35 (0.01 kPa (/100))
new LogField("AAP", 100), // Atmospheric Absolute Pressure : 0.0 - 655.35 (0.01 kPa (/100))
new LogField("BRV", 1000), // Battery Reference Voltage : 0.0 - 65.535 (0.001 Volts (/1000))
new LogField("MAT", 100), // Manifold Air Temperature : 0.0 - 655.35 (0.01 Kelvin (/100))
new LogField("EGO2", 32768), // Exhaust Gas Oxygen : 0.0 - 1.99996948 (0.0000305175781 lambda (/32768))
new LogField("IAP", 100), // Intercooler Absolute Pressure : 0.0 - 655.35 (0.01 kPa (/100))
new LogField("MAF"), // Mass Air Flow : 0.0 - 65535.0 (raw units from lookup)
new LogField("DMAP"), // Delta MAP kPa/second or similar : 0.0 - 65535.0 (raw units from lookup)
new LogField("DTPS"), // Delta TPS %/second or similar : 0.0 - 65535.0 (raw units from lookup)
new LogField("RPM", 2), // Revolutions Per Minute (Calced) : 0.0 - 32767.5 (0.5 RPM (/2))
new LogField("DRPM"), // Delta RPM (Calced) : 0.0 - 65535.0 (raw units from lookup)
new LogField("DDRPM"), // Delta Delta RPM (Calced) : 0.0 - 65535.0 (raw units from lookup)
// DerivedVars struct contents:
new LogField("LoadMain", 512), // Configurable unit of load, scale same as map by default
new LogField("VEMain", 512), // Volumetric Efficiency in 0 - 128%
new LogField("Lambda", 32768), // Integral Lambda 0 - 2.0
new LogField("AirFlow"), // raw intermediate, remove
new LogField("densityAndFuel"), // raw intermediate, remove
new LogField("BasePW", 1250), // Raw PW before corrections 0 - ~52ms
new LogField("ETE", (100.0/32768.0)), // Engine Temperature Enrichment percentage correction 0 - 200%
new LogField("TFCTotal", 1250), // Transient fuel correction PW (+/-) 0 - ~52ms
new LogField("EffectivePW", 1250), // Actual PW of fuel delivery 0 - ~52ms
new LogField("IDT", 1250), // PW duration before fuel flow begins 0 - ~52ms
new LogField("RefPW", 1250), // Reference electrical PW 0 - ~52ms
new LogField("Advance", 50), // Ignition advance (scaled degrees / oneDegree(currently 50) = degrees) 0 - ~64*
new LogField("Dwell", 1250), // Dwell period, s 0 - ~52ms
// KeyUserDebugs struct contents
new LogField("tempClock", types.UINT8), // Incremented once per log sent, to be moved to a char TODO
new LogField("spareChar", types.UINT8), // Spare
new LogField("coreStatusA", types.BITS8, coreStatusAFlagNames), // Duplicated, migrate here, remove global var
new LogField("decoderFlags", types.BITS8, decoderFlagsFlagNames), // Various decoder state flags
new LogField("flaggableFlags", types.BITS16, flaggableFlagsNames),///< Flags to go with our flaggables struct.
new LogField("currentEvent", types.UINT8), // Which input event was last to come in
new LogField("syncLostWithThisID", types.UINT8), // A unique identifier for the reason behind a loss of sync
new LogField("syncLostOnThisEvent", types.UINT8), // Where in the input pattern it all went very badly wrong
new LogField("syncCaughtOnThisEvent", types.UINT8), // Where in the input pattern that things started making sense
new LogField("syncResetCalls", types.UINT8), // Sum of losses, corrections and state clears
new LogField("primaryTeethSeen", types.UINT8), // Free running counters for number of input events, useful at lower RPM
new LogField("secondaryTeethSeen", types.UINT8), // Free running counters for number of input events, useful at lower RPM
new LogField("serialOverrunErrors", types.UINT8), // Incremented when an overrun occurs due to high interrupt load, not a fault, just a fact of life at high RPM
new LogField("serialHardwareErrors", types.UINT8), // Sum of noise, parity, and framing errors
new LogField("serialAndCommsCodeErrors", types.UINT8), // Sum of checksum, escape mismatches, starts inside, and over/under length
new LogField("inputEventTimeTolerance"), // Required to tune noise rejection over RPM TODO add to LT1 and MissingTeeth
new LogField("zsp10"), // Spare US variable
new LogField("zsp9"), // Spare US variable
new LogField("zsp8"), // Spare US variable
new LogField("zsp7"), // Spare US variable
new LogField("zsp6"), // Spare US variable
new LogField("zsp5"), // Spare US variable
new LogField("zsp4"), // Spare US variable
new LogField("zsp3"), // Spare US variable
new LogField("clockInMilliSeconds"), // Migrate to start of all large datalogs once analysed
new LogField("clock8thMSsInMillis", 8) // Migrate to start of all large datalogs once analysed
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Re: Reading FreeEMS Logs
Logic Analyser (LA) log types
8 bit is available now!
16 and 32 bit NOT Available Yet!
8 bit is available now!
16 and 32 bit NOT Available Yet!
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Re: Reading FreeEMS Logs
Buffered Logic Analyser (BLA) log types
NOT Available Yet!
NOT Available Yet!
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Re: Reading FreeEMS Logs
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Re: Reading FreeEMS Logs
Structs (STR) log types
NOT Available Yet!
NOT Available Yet!
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Re: Reading FreeEMS Logs
Scratch pad (SPD) log type
NOT Available Yet!
NOT Available Yet!
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!