Closed nitin710 closed 2 years ago
parsedOutputFormat.json
file to get a list of additional timestamp columns
TL
TL
and LC
TL
, LC
and LM
LC
true in json, but without any TL->LC timestampsLM
true in json, but without any LC->LM timestampsNotes: the curernt implementation creates a map(map). this creates an implicit order dependency [TL][LC].xTimes != [LC][TL].xTimes.(which is incorrect) https://github.com/EmotiBit/ofxEmotiBit/blob/cf306100d54a3fdb4a6842840808100d600c981c/EmotiBitDataParser/src/ofApp.cpp#L912
If the TX packet created is in the order LC, TL rather than TL, LC, then the code will need to be tweaked to accommodate for that.
TL
timeSyncMap
TE0,TE1,TL0,TL1,TimeSyncsReceived,EmotiBitStartTime, EmotiBitEndTime, DataParserVersion
490108.000000,541496.000000,1655242885.738691,1655242938.425221,17,472893,557492,1.5.1.lsl_1_14_0.5
Example data:
LocalTimestamp,EmotiBitTimestamp,PacketNumber,DataLength,TypeTag,ProtocolVersion,DataReliability,AX
1655242868.095860,472900.000,7859,2,AX,1,100,0.037
1655242868.095860,472900.000,7859,2,AX,1,100,0.039
1655242868.136101,472939.250,7876,12,AX,1,100,0.039
1655242868.176343,472978.500,7876,12,AX,1,100,0.038
1655242868.216585,473017.750,7876,12,AX,1,100,0.036
1655242868.256827,473057.000,7876,12,AX,1,100,0.038
1655242868.297069,473096.250,7876,12,AX,1,100,0.040
1655242868.337311,473135.500,7876,12,AX,1,100,0.040
1655242868.377552,473174.750,7876,12,AX,1,100,0.039
1655242868.417794,473214.000,7876,12,AX,1,100,0.038
1655242868.458036,473253.250,7876,12,AX,1,100,0.038
1655242868.498278,473292.500,7876,12,AX,1,100,0.037
1655242868.538520,473331.750,7876,12,AX,1,100,0.038
1655242868.578761,473371.000,7876,12,AX,1,100,0.040
LC
true in json, but without any TL->LC timestamps
timeSyncMap
TE0,TE1,TL0,TL1,LC0,LC1,TimeSyncsReceived,EmotiBitStartTime, EmotiBitEndTime, DataParserVersion
490108.000000,541496.000000,1655242885.738691,1655242938.425221,0.000000,0.000000,17,472893,557492,1.5.1.lsl_1_14_0.5
Sample parsed data
0.000000,1655242870.025416,474782.000,8045,7,PG,1,100,1044
0.000000,1655242870.062582,474818.250,8061,4,PG,1,100,1041
0.000000,1655242870.099748,474854.500,8061,4,PG,1,100,1048
0.000000,1655242870.136914,474890.750,8061,4,PG,1,100,1041
0.000000,1655242870.174080,474927.000,8061,4,PG,1,100,1046
0.000000,1655242870.218850,474970.667,8078,3,PG,1,100,1042
0.000000,1655242870.263620,475014.333,8078,3,PG,1,100,1042
0.000000,1655242870.308390,475058.000,8078,3,PG,1,100,1051
0.000000,1655242870.341712,475090.500,8096,2,PG,1,100,1045
0.000000,1655242870.375033,475123.000,8096,2,PG,1,100,1047
0.000000,1655242870.419120,475166.000,8111,3,PG,1,100,1049
0.000000,1655242870.463206,475209.000,8111,3,PG,1,100,1044
0.000000,1655242870.507293,475252.000,8111,3,PG,1,100,1044
0.000000,1655242870.540614,475284.500,8127,2,PG,1,100,1046
0.000000,1655242870.573935,475317.000,8127,2,PG,1,100,1051
0.000000,1655242870.617680,475359.667,8145,3,PG,1,100,1043
0.000000,1655242870.661425,475402.333,8145,3,PG,1,100,1047
0.000000,1655242870.705170,475445.000,8145,3,PG,1,100,1049
0.000000,1655242870.744472,475483.333,8161,3,PG,1,100,1043
0.000000,1655242870.783774,475521.667,8161,3,PG,1,100,1061
0.000000,1655242870.823076,475560.000,8161,3,PG,1,100,1048
0.000000,1655242870.864599,475600.500,8177,2,PG,1,100,1047
0.000000,1655242870.906122,475641.000,8177,2,PG,1,100,1049
0.000000,1655242870.943288,475677.250,8193,4,PG,1,100,1046
0.000000,1655242870.980454,475713.500,8193,4,PG,1,100,1044
0.000000,1655242871.017620,475749.750,8193,4,PG,1,100,1045
LC
, LM
true in json, but without any LC->LM timestamps
timeSyncMap
TE0,TE1,TL0,TL1,LC0,LC1,LM0,LM1,TimeSyncsReceived,EmotiBitStartTime, EmotiBitEndTime, DataParserVersion
490108.000000,541496.000000,1655242885.738691,1655242938.425221,0.000000,0.000000,0.000000,0.000000,17,472893,557492,1.5.1.lsl_1_14_0.5
Sample parsed data
LslMarkerSourceTimestamp,LslLocalTimestamp,LocalTimestamp,EmotiBitTimestamp,PacketNumber,DataLength,TypeTag,ProtocolVersion,DataReliability,EA
0.000000,0.000000,1655242870.994295,475727.000,8194,1,EA,1,100,0.030303
0.000000,0.000000,1655242871.061963,475793.000,8211,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.129631,475859.000,8211,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.195761,475923.500,8227,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.261891,475988.000,8227,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.328533,476053.000,8245,1,EA,1,100,0.030303
0.000000,0.000000,1655242871.396201,476119.000,8261,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.463869,476185.000,8261,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.529486,476249.000,8277,1,EA,1,100,0.030303
0.000000,0.000000,1655242871.595103,476313.000,8294,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.660720,476377.000,8294,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.727363,476442.000,8311,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.794005,476507.000,8311,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.861673,476573.000,8327,1,EA,1,100,0.030303
0.000000,0.000000,1655242871.927290,476637.000,8345,2,EA,1,100,0.030303
0.000000,0.000000,1655242871.992908,476701.000,8345,2,EA,1,100,0.030303
0.000000,0.000000,1655242872.059550,476766.000,8360,2,EA,1,100,0.030303
TL
and LC
TE0,TE1,TL0,TL1,LC0,LC1,TimeSyncsReceived,EmotiBitStartTime, EmotiBitEndTime, DataParserVersion
58246.000000,150535.000000,1655243883.195380,1655243977.842433,701108.800583,701203.447635,22,39406,157506,1.5.1.lsl_1_14_0.5
sample parsed data
LslLocalTimestamp,LocalTimestamp,EmotiBitTimestamp,PacketNumber,DataLength,TypeTag,ProtocolVersion,DataReliability,GX
701093.040602,1655243867.435400,42878.667,3573,6,GX,1,100,0.305
701093.082308,1655243867.477106,42919.333,3573,6,GX,1,100,0.336
701093.124014,1655243867.518811,42960.000,3573,6,GX,1,100,0.366
701093.165720,1655243867.560517,43000.667,3573,6,GX,1,100,0.397
701093.207425,1655243867.602223,43041.333,3573,6,GX,1,100,0.397
701093.249131,1655243867.643929,43082.000,3573,6,GX,1,100,0.397
701093.288444,1655243867.683241,43120.333,3588,3,GX,1,100,0.366
701093.327757,1655243867.722554,43158.667,3588,3,GX,1,100,0.366
701093.367069,1655243867.761867,43197.000,3588,3,GX,1,100,0.366
701093.408604,1655243867.803401,43237.500,3605,2,GX,1,100,0.366
701093.450139,1655243867.844936,43278.000,3605,2,GX,1,100,0.305
701093.488084,1655243867.882882,43315.000,3622,3,GX,1,100,0.397
701093.526030,1655243867.920827,43352.000,3622,3,GX,1,100,0.366
701093.563975,1655243867.958772,43389.000,3622,3,GX,1,100,0.366
701093.605510,1655243868.000307,43429.500,3639,2,GX,1,100,0.336
701093.647045,1655243868.041842,43470.000,3639,2,GX,1,100,0.397
701093.689092,1655243868.083890,43511.000,3657,4,GX,1,100,0.336
701093.731140,1655243868.125937,43552.000,3657,4,GX,1,100,0.397
701093.773188,1655243868.167985,43593.000,3657,4,GX,1,100,0.366
701093.815235,1655243868.210032,43634.000,3657,4,GX,1,100,0.336
701093.856770,1655243868.251567,43674.500,3674,2,GX,1,100,0.336
701093.898305,1655243868.293102,43715.000,3674,2,GX,1,100,0.336
701093.937276,1655243868.332073,43753.000,3688,3,GX,1,100,0.305
TL
, LC
and LM
timeSyncMap
TE0,TE1,TL0,TL1,LC0,LC1,LM0,LM1,TimeSyncsReceived,EmotiBitStartTime, EmotiBitEndTime, DataParserVersion
58246.000000,150535.000000,1655243883.195380,1655243977.842433,701108.800583,701203.447635,701108.800603,701203.447646,22,39406,157506,1.5.1.lsl_1_14_0.5
sample parsed data
LslMarkerSourceTimestamp,LslLocalTimestamp,LocalTimestamp,EmotiBitTimestamp,PacketNumber,DataLength,TypeTag,ProtocolVersion,DataReliability,TH
701101.546883,701101.546862,1655243875.941659,51173.000,4818,1,TH,1,100,34.552
701101.650464,701101.650443,1655243876.045240,51274.000,4834,1,TH,1,100,34.559
701101.857625,701101.857604,1655243876.252401,51476.000,4866,1,TH,1,100,34.614
701101.961206,701101.961185,1655243876.355982,51577.000,4883,1,TH,1,100,34.614
701102.064786,701102.064765,1655243876.459563,51678.000,4899,1,TH,1,100,34.614
701102.168367,701102.168346,1655243876.563143,51779.000,4917,1,TH,1,100,34.614
701102.375528,701102.375507,1655243876.770304,51981.000,4948,1,TH,1,100,34.662
701102.479109,701102.479088,1655243876.873885,52082.000,4965,1,TH,1,100,34.662
701102.583715,701102.583694,1655243876.978491,52184.000,4983,1,TH,1,100,34.619
701102.789851,701102.789830,1655243877.184627,52385.000,5015,1,TH,1,100,34.619
701102.895482,701102.895461,1655243877.290259,52488.000,5034,1,TH,1,100,34.626
701102.999063,701102.999042,1655243877.393839,52589.000,5051,1,TH,1,100,34.634
701103.101618,701103.101597,1655243877.496394,52689.000,5067,1,TH,1,100,34.567
701103.308779,701103.308758,1655243877.703556,52891.000,5099,1,TH,1,100,34.567
701103.413385,701103.413365,1655243877.808162,52993.000,5116,1,TH,1,100,34.581
701103.552860,701103.552839,1655243877.947637,53129.000,5138,1,TH,1,100,34.581
701103.656441,701103.656420,1655243878.051217,53230.000,5156,1,TH,1,100,34.581
Timestamp type | PI | AX | TH | T1 | EA |
---|---|---|---|---|---|
Timestamp Local | |||||
LslLocal | |||||
LalMarkerSource |
TH
shows an issue with timestamps, but all other signals are generating periodic outputs with ~expected freq.
description
feature add: parser should be able to parse data using LSL markers if present in the raw file
Rough Draft
basics
If LSL stream is found by the oscilloscope, control packets containing LSL time sync information are sent from the Oscilloscope to the EmotiBit using TCP
LM
stand for LSL Markers and is followed byTSC
,TS
,LC
,LD
https://github.com/EmotiBit/ofxEmotiBit/blob/372b60a8e349e974a8a68fbe830175fbaee81320/EmotiBitOscilloscope/src/ofApp.cpp#L1427-L1437TX
stand for timestamp_cross_time and is followed by the local device time (TL
) and the LSL time (LSL time
)List of file changes
Proposed code changes
addition of a check box in DataPrser GUI
Adding parsing LSL through the command line
-p lsl
/-p timesyncs
=--protocol
Add extracting lsl_time-local_time pairs in the first pass
vector<lsl_time&local_time>
are passed in.Complete the bridge from ex - cx - lx
Notes
Proposed flow for first pass through data
outstanding questions