In the past, we've assumed that the number of TDM rows is the number of subframe divisions in the places where they are relevant:
In the LJH per-pulse timing info, there's a "row count" value. It's equal to frame counts times the number of rows, plus this channel's row number. That makes sense for TDM data! But for other data, not so much.
In the external trigger information, there's a similar assumption that our counts correspond to a frame divided into Nrows subdivisions. Again, that's only strictly required for TDM data. For µMUX data, the subdivision is nearly arbitrary! I chose 64 last week.
Proposal:
Explicitly track the number of subframe divisions. This might not equal the number of rows in a µMUX data source (because "rows" there is an artificial construct).
Even better, we might be able to restrict the language of "rows" only to TDM data sources (Lancero).
Explicitly track the number of subframe steps by which this channel is offset from the exact frame start. For Lancero sources, this will be the row number; for others, it will be zero.
Put new info into the LJH2 and OFF file headers to indicate the "Number of subframe divisions" and "Subframe delay for this channel". If not found, MASS can assume these values default to the number of rows and the row number.
In the past, we've assumed that the number of TDM rows is the number of subframe divisions in the places where they are relevant:
Proposal: