diff --git a/Packages/MIES/MIES_AnalysisFunctions_PatchSeq.ipf b/Packages/MIES/MIES_AnalysisFunctions_PatchSeq.ipf index c7bbd70061..6d21c5f04e 100644 --- a/Packages/MIES/MIES_AnalysisFunctions_PatchSeq.ipf +++ b/Packages/MIES/MIES_AnalysisFunctions_PatchSeq.ipf @@ -3031,7 +3031,7 @@ static Function [WAVE data, variable emptySCI] PSQ_DS_GetLabnotebookData(WAVE nu WAVE/Z dataCurrentSCI = GetLastSettingIndepEachSCI(numericalValues, sweepNo, key, headstage, UNKNOWN_MODE) break default: - FATAL_ERROR("Unsupported headstageContigencyMode") + FATAL_ERROR("Unsupported headstageContingencyMode") endswitch break endswitch @@ -3056,7 +3056,7 @@ static Function [WAVE data, variable emptySCI] PSQ_DS_GetLabnotebookData(WAVE nu idx = INDEP_HEADSTAGE break default: - FATAL_ERROR("Unsupported headstageContigencyMode") + FATAL_ERROR("Unsupported headstageContingencyMode") endswitch WAVE dataRhSuAd = ListToNumericWave(dataRhSuAdLBN[idx], ";") diff --git a/Packages/MIES/MIES_Cache.ipf b/Packages/MIES/MIES_Cache.ipf index e2f36623bb..4a40d49bfd 100644 --- a/Packages/MIES/MIES_Cache.ipf +++ b/Packages/MIES/MIES_Cache.ipf @@ -175,6 +175,24 @@ threadsafe Function/S CA_GenKeyGetActiveChannels(WAVE numericalValues, WAVE text return num2istr(crc) + version End +/// @brief Cache key generator for LBN index cache +threadsafe Function/S CA_CreateLBIndexCacheKey(WAVE values) + + string name = GetWavesDataFolder(values, 2) + ASSERT_TS(!isEmpty(name), "Invalid path to wave, free waves won't work.") + + return name + "_IndexCache" +End + +/// @brief Cache key generator for LBN row cache +threadsafe Function/S CA_CreateLBRowCacheKey(WAVE values) + + string name = GetWavesDataFolder(values, 2) + ASSERT_TS(!isEmpty(name), "Invalid path to wave, free waves won't work.") + + return name + "_RowCache" +End + /// @brief Cache key generator for Logbook sortedKeyWave threadsafe Function/S CA_GenKeyLogbookSortedKeys(WAVE keys) diff --git a/Packages/MIES/MIES_Constants.ipf b/Packages/MIES/MIES_Constants.ipf index f87568c445..b270f7a147 100644 --- a/Packages/MIES/MIES_Constants.ipf +++ b/Packages/MIES/MIES_Constants.ipf @@ -979,22 +979,23 @@ Constant DA_EPHYS_PANEL_PRESSURE_AUTO = 0 Constant DA_EPHYS_PANEL_PRESSURE_MANUAL = 1 Constant DA_EPHYS_PANEL_PRESSURE_USER = 2 -StrConstant PULSE_START_TIMES_KEY = "Pulse Train Pulses" -StrConstant PULSE_TO_PULSE_LENGTH_KEY = "Pulse To Pulse Length" -StrConstant HIGH_PREC_SWEEP_START_KEY = "High precision sweep start" -StrConstant STIMSET_SCALE_FACTOR_KEY = "Stim Scale Factor" -StrConstant STIMSET_WAVE_NOTE_KEY = "Stim Wave Note" -StrConstant EPOCHS_ENTRY_KEY = "Epochs" -StrConstant CLAMPMODE_ENTRY_KEY = "Clamp Mode" -StrConstant TP_AMPLITUDE_VC_ENTRY_KEY = "TP Amplitude VC" -StrConstant TP_AMPLITUDE_IC_ENTRY_KEY = "TP Amplitude IC" -StrConstant PULSE_START_INDICES_KEY = "Pulse Train Pulse Start Indices" -StrConstant PULSE_END_INDICES_KEY = "Pulse Train Pulse End Indices" -StrConstant INFLECTION_POINTS_INDEX_KEY = "Inflection Points Indices" -StrConstant EPOCH_LENGTH_INDEX_KEY = "Epoch Length Indices" -StrConstant STIMSET_SIZE_KEY = "Stimset Size" -StrConstant STIMSET_ERROR_KEY = "Wavebuilder Error" -StrConstant AUTOBIAS_PERC_KEY = "Autobias %" +StrConstant PULSE_START_TIMES_KEY = "Pulse Train Pulses" +StrConstant PULSE_TO_PULSE_LENGTH_KEY = "Pulse To Pulse Length" +StrConstant HIGH_PREC_SWEEP_START_KEY = "High precision sweep start" +StrConstant STIMSET_SCALE_FACTOR_KEY = "Stim Scale Factor" +StrConstant STIMSET_WAVE_NOTE_KEY = "Stim Wave Note" +StrConstant EPOCHS_ENTRY_KEY = "Epochs" +StrConstant CLAMPMODE_ENTRY_KEY = "Clamp Mode" +StrConstant TP_AMPLITUDE_VC_ENTRY_KEY = "TP Amplitude VC" +StrConstant TP_AMPLITUDE_IC_ENTRY_KEY = "TP Amplitude IC" +StrConstant PULSE_START_INDICES_KEY = "Pulse Train Pulse Start Indices" +StrConstant PULSE_END_INDICES_KEY = "Pulse Train Pulse End Indices" +StrConstant INFLECTION_POINTS_INDEX_KEY = "Inflection Points Indices" +StrConstant EPOCH_LENGTH_INDEX_KEY = "Epoch Length Indices" +StrConstant STIMSET_SIZE_KEY = "Stimset Size" +StrConstant STIMSET_ERROR_KEY = "Wavebuilder Error" +StrConstant AUTOBIAS_PERC_KEY = "Autobias %" +StrConstant SWEEP_EPOCH_VERSION_ENTRY_KEY = "Epochs Version" Constant WAVEBUILDER_STATUS_ERROR = 1 diff --git a/Packages/MIES/MIES_DAEphys.ipf b/Packages/MIES/MIES_DAEphys.ipf index 2365a391fe..62db4cd771 100644 --- a/Packages/MIES/MIES_DAEphys.ipf +++ b/Packages/MIES/MIES_DAEphys.ipf @@ -4025,7 +4025,7 @@ static Function DAP_AddUserComment(string device) return NaN endif - comment = DAG_GetTextualValue(device, "SetVar_DataAcq_Comment") + comment = GetSetVariableString(device, "SetVar_DataAcq_Comment") if(isEmpty(comment)) return NaN diff --git a/Packages/MIES/MIES_Epochs.ipf b/Packages/MIES/MIES_Epochs.ipf index a97b6b56a9..f319d954e2 100644 --- a/Packages/MIES/MIES_Epochs.ipf +++ b/Packages/MIES/MIES_Epochs.ipf @@ -1268,7 +1268,7 @@ Function EP_WriteEpochInfoIntoSweepSettings(string device, variable sweepNo, var endif endfor - DC_DocumentChannelProperty(device, "Epochs Version", INDEP_HEADSTAGE, NaN, NaN, var = SWEEP_EPOCH_VERSION) + DC_DocumentChannelProperty(device, SWEEP_EPOCH_VERSION_ENTRY_KEY, INDEP_HEADSTAGE, NaN, NaN, var = SWEEP_EPOCH_VERSION) End /// @brief Convert the epochs wave layer given by `channel` and `channelType` to a string suitable for storing the labnotebook diff --git a/Packages/MIES/MIES_ExperimentDocumentation.ipf b/Packages/MIES/MIES_ExperimentDocumentation.ipf index f787304655..7e6b243eae 100644 --- a/Packages/MIES/MIES_ExperimentDocumentation.ipf +++ b/Packages/MIES/MIES_ExperimentDocumentation.ipf @@ -11,6 +11,56 @@ /// @brief Add numerical/textual entries to the labnotebook /// +/// This function adds one or more new entries to the LBN. +/// The new entries are given through a vals, keys combination. Depending on the type of +/// vals the textual or numerical LBN is targeted. The function determines the correct +/// target LBN automatically through sweepNo and device. +/// +/// The entrySourceType specifies to which logical block of the LBN the entries get added +/// +/// Specification of vals and keys: +/// Multiple entries can be written with one call. +/// vals: text or numerical WAVE of size (1, numberOfNewEntries, LABNOTEBOOK_LAYER_COUNT) +/// The layers index the target headstage or INDEP_HEADSTAGE. +/// The elements of the wave must be filled with the values that should be written. +/// Based on the column number key/value pairs are defined from vals/keys. +/// numeric vals waves must be initialized with NaN +/// keys: text WAVE in one of three possible layouts: +/// - size (1, numberOfNewEntries) +/// one key is specified per column +/// - size (3, numberOfNewEntries) +/// row 0: key +/// row 1: LBN unit +/// row 2: LNB tolerance +/// - size (6, numberOfNewEntries) +/// row 0: key +/// row 1: unit +/// row 2: tolerance +/// row 3: description +/// row 4: Headstage Contingency +/// row 5: ClampMode +/// optionally the keys wave may have a layer size of 1. +/// +/// Key specification: +/// Duplicated keys are not allowed and will give an error. +/// +/// Correct filling of entry keys and corresponding values: +/// for associated DA/AD channels use the regular key and the headstage as layer for vals +/// for unassociated DA/AD channels create the correct key with CreateLBNUnassocKey with +/// layer INDEP_HEADSTAGE in vals +/// for some TTL channels the correct key is created through CreateTTLChannelLBNKey with layer INDEP_HEADSTAGE in vals +/// +/// In the LBN one new row is added at the end where all entries that should be written are placed. +/// (As no keys are duplicated, all data can be written to one row) +/// LBN columns for new keys are created automatically. +/// +/// If insertAsPostProc is set to 1: +/// Instead of the above: In the LBN a new row is inserted after the block specified by sweepNo/entrySourceType. +/// The new entries are placed in this row and implicitly an entry with key "PostProcessed" +/// and value "1" or 1 respectively is set in the same row. +/// +/// It is recommended to gather all entries to be written in keys/values and call ED_AddEntriesToLabnotebook then once. +/// /// @see ED_createTextNotes, ED_createWaveNote Function ED_AddEntriesToLabnotebook(WAVE vals, WAVE/T keys, variable sweepNo, string device, variable entrySourceType) @@ -37,12 +87,59 @@ End static Function ED_CheckValuesAndKeys(WAVE vals, WAVE keys) + string msg + ASSERT(DimSize(vals, ROWS) == 1, "Mismatched row count") ASSERT(DimSize(vals, COLS) == DimSize(keys, COLS), "Mismatched column count") ASSERT(DimSize(vals, LAYERS) <= LABNOTEBOOK_LAYER_COUNT, "Mismatched layer count") ASSERT(DimSize(keys, ROWS) == 1 || DimSize(keys, ROWS) == 3 || DimSize(keys, ROWS) == 6, "Mismatched row count") ASSERT(DimSize(keys, LAYERS) <= 1, "Mismatched layer count") + + if(DimSize(keys, COLS) == 1) + return NaN + endif + Duplicate/FREE/RMD=[0][][0][0] keys, checkKeysForDupes + Redimension/N=(DimSize(checkKeysForDupes, COLS))/E=1 checkKeysForDupes + if(SearchForDuplicates(checkKeysForDupes)) + FindDuplicates/Z/FREE/DT=dups checkKeysForDupes + wfprintf msg, "%s", dups + sprintf msg, "Keywave contains duplicate keys: %s", msg + FATAL_ERROR(msg) + endif +End + +static Function ED_InitNewRow(WAVE values, variable rowIndex, variable sweepNo, variable entrySourceType, variable acqState) + + variable timestamp + string timestampStr + + if(IsTextWave(values)) + WAVE/T valuesT = values + valuesT[rowIndex][0][] = num2istr(sweepNo) + valuesT[rowIndex][3][] = num2istr(entrySourceType) + + valuesT[rowIndex][4][] = num2istr(acqState) + + // store the current time in a variable first + // so that all layers have the same timestamp + timestampStr = num2strHighPrec(DateTime, precision = 3) + valuesT[rowIndex][1][] = timestampStr + timestampStr = num2strHighPrec(DateTimeInUTC(), precision = 3) + valuesT[rowIndex][2][] = timestampStr + else + values[rowIndex][0][] = sweepNo + values[rowIndex][3][] = entrySourceType + + values[rowIndex][4][] = acqState + + // store the current time in a variable first + // so that all layers have the same timestamp + timestamp = DateTime + values[rowIndex][1][] = timestamp + timestamp = DateTimeInUTC() + values[rowIndex][2][] = timestamp + endif End /// @brief Add textual entries to the logbook @@ -62,7 +159,6 @@ End static Function ED_createTextNotes(WAVE/T incomingTextualValues, WAVE/T incomingTextualKeys, variable sweepNo, variable entrySourceType, variable logbookType, [string device]) variable rowIndex, numCols, i, lastValidIncomingLayer, state - string timestamp if(ParamIsDefault(device)) ASSERT(logbookType == LBT_RESULTS, "Invalid logbook type") @@ -80,17 +176,7 @@ static Function ED_createTextNotes(WAVE/T incomingTextualValues, WAVE/T incoming [WAVE indizes, rowIndex] = ED_FindIndizesAndRedimension(incomingTextualKeys, incomingTextualValues, keys, values, logbookType) ASSERT(WaveExists(indizes), "Missing indizes") - values[rowIndex][0][] = num2istr(sweepNo) - values[rowIndex][3][] = num2istr(entrySourceType) - - values[rowIndex][4][] = num2istr(state) - - // store the current time in a variable first - // so that all layers have the same timestamp - timestamp = num2strHighPrec(DateTime, precision = 3) - values[rowIndex][1][] = timestamp - timestamp = num2strHighPrec(DateTimeInUTC(), precision = 3) - values[rowIndex][2][] = timestamp + ED_InitNewRow(values, rowIndex, sweepNo, entrySourceType, state) WAVE valuesDat = ExtractLogbookSliceTimeStamp(values) EnsureLargeEnoughWave(valuesDat, indexShouldExist = rowIndex, dimension = ROWS) @@ -113,7 +199,7 @@ static Function ED_createTextNotes(WAVE/T incomingTextualValues, WAVE/T incoming SetNumberInWaveNote(values, NOTE_INDEX, rowIndex + 1) End -static Function ED_ParseHeadstageContigencyMode(string str) +static Function ED_ParseHeadstageContingencyMode(string str) if(!cmpstr(str, "ALL")) return (HCM_DEPEND | HCM_INDEP) @@ -126,7 +212,7 @@ static Function ED_ParseHeadstageContigencyMode(string str) return HCM_EMPTY End -static Function/S ED_HeadstageContigencyModeToString(variable mode) +static Function/S ED_HeadstageContingencyModeToString(variable mode) switch(mode) case HCM_INDEP: @@ -142,7 +228,7 @@ static Function/S ED_HeadstageContigencyModeToString(variable mode) endswitch End -/// @brief Return the headstage contigency mode for values +/// @brief Return the headstage contingency mode for values static Function ED_GetHeadstageContingency(WAVE values) if(IsTextWave(values)) @@ -182,7 +268,7 @@ End /// @param logbookType one of @ref LogbookTypes static Function ED_createWaveNotes(WAVE incomingNumericalValues, WAVE/T incomingNumericalKeys, variable sweepNo, variable entrySourceType, variable logbookType, [string device]) - variable rowIndex, numCols, lastValidIncomingLayer, i, timestamp, state + variable rowIndex, numCols, lastValidIncomingLayer, i, state if(ParamIsDefault(device)) ASSERT(logbookType == LBT_RESULTS, "Invalid logbook type") @@ -201,17 +287,7 @@ static Function ED_createWaveNotes(WAVE incomingNumericalValues, WAVE/T incoming [WAVE indizes, rowIndex] = ED_FindIndizesAndRedimension(incomingNumericalKeys, incomingNumericalValues, keys, values, logbookType) ASSERT(WaveExists(indizes), "Missing indizes") - values[rowIndex][0][] = sweepNo - values[rowIndex][3][] = entrySourceType - - values[rowIndex][4][] = state - - // store the current time in a variable first - // so that all layers have the same timestamp - timestamp = DateTime - values[rowIndex][1][] = timestamp - timestamp = DateTimeInUTC() - values[rowIndex][2][] = timestamp + ED_InitNewRow(values, rowIndex, sweepNo, entrySourceType, state) WAVE valuesDat = ExtractLogbookSliceTimeStamp(values) EnsureLargeEnoughWave(valuesDat, indexShouldExist = rowIndex, dimension = ROWS, initialValue = NaN) @@ -493,11 +569,10 @@ End /// @retval rowIndex returns the row index into values at which the new values should be written static Function [WAVE colIndizes, variable rowIndex] ED_FindIndizesAndRedimension(WAVE/T incomingKey, WAVE incomingValues, WAVE/T key, WAVE values, variable logbookType) - variable numCols, numKeyRows, numKeyCols, i, j, numAdditions, idx + variable numCols, numKeyCols, i, j, numAdditions, idx variable lastValidIncomingKeyRow, descIndex, isUserEntry, headstageCont, headstageContDesc, isUnAssoc string msg, searchStr - numKeyRows = DimSize(key, ROWS) numKeyCols = DimSize(key, COLS) lastValidIncomingKeyRow = DimSize(incomingKey, ROWS) - 1 @@ -596,14 +671,14 @@ static Function [WAVE colIndizes, variable rowIndex] ED_FindIndizesAndRedimensio // check for correct headstage contingency Duplicate/FREE/RMD=[0][i][*] incomingValues, valuesSlice headstageCont = ED_GetHeadstageContingency(valuesSlice) - headstageContDesc = ED_ParseHeadstageContigencyMode(desc[%HeadstageContingency][descIndex]) + headstageContDesc = ED_ParseHeadstageContingencyMode(desc[%HeadstageContingency][descIndex]) if(isUnAssoc) headstageContDesc = HCM_INDEP endif if(headstageCont != HCM_EMPTY && !(headstageCont & headstageContDesc)) - sprintf msg, "Headstage contingency for entry \"%s\": stock: \"%s\", incoming: \"%s\"", searchStr, desc[%HeadstageContingency][descIndex], ED_HeadstageContigencyModeToString(headstageCont) + sprintf msg, "Headstage contingency for entry \"%s\": stock: \"%s\", incoming: \"%s\"", searchStr, desc[%HeadstageContingency][descIndex], ED_HeadstageContingencyModeToString(headstageCont) BUG(msg) endif diff --git a/Packages/MIES/MIES_LogbookViewer.ipf b/Packages/MIES/MIES_LogbookViewer.ipf index 74692b2552..623189fe82 100644 --- a/Packages/MIES/MIES_LogbookViewer.ipf +++ b/Packages/MIES/MIES_LogbookViewer.ipf @@ -100,15 +100,16 @@ Function/WAVE LBV_GetAllLogbookParamNames(WAVE/Z/T textualValues, WAVE/Z/T numer key = CA_GetLabnotebookNamesKey(textualValues, numericalValues) - WAVE/Z result = CA_TryFetchingEntryFromCache(key) + WAVE/Z/WAVE resultEncap = CA_TryFetchingEntryFromCache(key) - if(!WaveExists(result)) - WAVE result = LBV_GetAllLogbookParamNames_NoCache(textualValues, numericalValues) + if(!WaveExists(resultEncap)) + WAVE/Z result = LBV_GetAllLogbookParamNames_NoCache(textualValues, numericalValues) + Make/FREE/WAVE resultEncap = {result} - CA_StoreEntryIntoCache(key, result) + CA_StoreEntryIntoCache(key, resultEncap) endif - return result + return resultEncap[0] End static Function/WAVE LBV_GetAllLogbookParamNames_NoCache(WAVE/Z/T textualValues, WAVE/Z/T numericalValues) diff --git a/Packages/MIES/MIES_MiesUtilities_Logbook.ipf b/Packages/MIES/MIES_MiesUtilities_Logbook.ipf index e805b1cdd1..5b722be6d1 100644 --- a/Packages/MIES/MIES_MiesUtilities_Logbook.ipf +++ b/Packages/MIES/MIES_MiesUtilities_Logbook.ipf @@ -1819,15 +1819,13 @@ Function GetHeadstageForChannel(WAVE numericalValues, variable sweep, variable c variable index [WAVE settings, index] = GetLastSettingChannel(numericalValues, $"", sweep, "Headstage Active", channelNumber, channelType, entrySourceType) - if(!WaveExists(settings)) - return NaN + if(WaveExists(settings) && settings[index] == 1) + return index endif - if(!settings[index]) - return NaN - endif - - return index + // fallback for LBN before + // 602debb9 (Record the active headstage in the settingsHistory, 2014-11-04) + return GetHeadstageFromOldLBN(numericalValues, sweep, channelType, channelNumber, entrySourceType) End /// @brief Return a list of TTL stimsets which are indexed by DAEphys TTL channels @@ -1922,6 +1920,41 @@ Function [variable type, variable waMode, variable headstage] GetAnalysisFunctio return [type, waMode, headstage] End +// fallback for headstage retrievel for LBN before +// 602debb9 (Record the active headstage in the settingsHistory, 2014-11-04) +// The headstage is retrieved by evaluating the DAC/ADC entries of the LBN +static Function GetHeadstageFromOldLBN(WAVE numericalValues, variable sweepNo, variable channelType, variable channelNumber, variable dataAcqOrTP) + + string lbnEntry + + switch(channelType) + case XOP_CHANNEL_TYPE_DAC: + lbnEntry = "DAC" + break + case XOP_CHANNEL_TYPE_ADC: + lbnEntry = "ADC" + break + case XOP_CHANNEL_TYPE_TTL: + return NaN + default: + FATAL_ERROR("Unknown channel type") + endswitch + + WAVE/Z settings = GetLastSetting(numericalValues, sweepNo, lbnEntry, dataAcqOrTP) + if(!WaveExists(settings)) + return NaN + endif + FindValue/V=(channelNumber) settings + if(V_value == -1) + return NaN + endif + if(V_row < NUM_HEADSTAGES) + return V_row + endif + + return NaN +End + Function ParseLogbookMode(string modeText) strswitch(modeText) diff --git a/Packages/MIES/MIES_WaveDataFolderGetters.ipf b/Packages/MIES/MIES_WaveDataFolderGetters.ipf index 64b70f545a..de7306f0dc 100644 --- a/Packages/MIES/MIES_WaveDataFolderGetters.ipf +++ b/Packages/MIES/MIES_WaveDataFolderGetters.ipf @@ -32,6 +32,8 @@ static StrConstant TP_SETTINGS_LABELS = "bufferSize;resistanceTol;sendToAllHS;ba static StrConstant LOGBOOK_SUFFIX_SORTEDKEYS = "_sorted" static StrConstant LOGBOOK_SUFFIX_SORTEDKEYSINDICES = "_indices" +static Constant SWEEP_SETTINGS_WAVE_VERSION = 41 + /// @brief Return a wave reference to the corresponding Logbook keys wave from an values wave input threadsafe Function/WAVE GetLogbookValuesFromKeys(WAVE keyWave) @@ -2190,15 +2192,12 @@ End threadsafe Function/WAVE GetLBRowCache(WAVE values) variable actual, sweepNo, first, last - string key, name + string key variable versionOfNewWave = 6 actual = WaveModCountWrapper(values) - name = GetWavesDataFolder(values, 2) - ASSERT_TS(!isEmpty(name), "Invalid path to wave, free waves won't work.") - - key = name + "_RowCache" + key = CA_CreateLBRowCacheKey(values) WAVE/Z/D wv = CA_TryFetchingEntryFromCache(key, options = CA_OPTS_NO_DUPLICATE) @@ -2268,15 +2267,12 @@ End threadsafe Function/WAVE GetLBIndexCache(WAVE values) variable actual, sweepNo, first, last - string key, name + string key variable versionOfNewWave = 5 actual = WaveModCountWrapper(values) - name = GetWavesDataFolder(values, 2) - ASSERT_TS(!isEmpty(name), "Invalid path to wave, free waves won't work.") - - key = name + "_IndexCache" + key = CA_CreateLBIndexCacheKey(values) WAVE/Z/D wv = CA_TryFetchingEntryFromCache(key, options = CA_OPTS_NO_DUPLICATE) @@ -2377,8 +2373,6 @@ threadsafe Function/WAVE GetLBNidCache(WAVE numericalValues) return wv End -static Constant SWEEP_SETTINGS_WAVE_VERSION = 40 - /// @brief Uses the parameter names from the `sourceKey` columns and /// write them as dimension into the columns of dest. static Function SetSweepSettingsDimLabels(WAVE dest, WAVE/T sourceKey) @@ -2499,31 +2493,30 @@ End /// - 35: Multi Device mode /// - 36: Background Testpulse /// - 37: Background DAQ -/// - 38: Sampling interval multiplier -/// - 39: TP during ITI -/// - 40: Amplifier change via I=0 -/// - 41: Skip analysis functions -/// - 42: Repeat sweep on async alarm -/// - 43: Set Cycle Count -/// - 44: Stimset cycle ID -/// - 45: Digitizer Hardware Type, one of @ref HardwareDACTypeConstants -/// - 46: Fixed frequency acquisition -/// - 47: Headstage Active, binary flag that indicates the enabled headstage(s), the index is the headstage number -/// - 48: Clamp Mode -/// - 49: Igor Pro bitness -/// - 50: DA ChannelType, one of @ref DaqChannelTypeConstants -/// - 51: AD ChannelType, one of @ref DaqChannelTypeConstants -/// - 52: oodDAQ member, true if headstage takes part in oodDAQ mode, false otherwise -/// - 53: Autobias % (DAEphys->Settings->Amplifier) -/// - 54: Autobias Interval (DAEphys->Settings->Amplifier) -/// - 55: TP after DAQ -/// - 56: Epochs version -/// - 57: Get/Set Inter-trial interval -/// - 58: Double precision data -/// - 59: Save amplifier settings -/// - 60: Require amplifier -/// - 61: Skip Ahead -/// - 62: TP power spectrum +/// - 38: TP during ITI +/// - 39: Amplifier change via I=0 +/// - 40: Skip analysis functions +/// - 41: Repeat sweep on async alarm +/// - 42: Set Cycle Count +/// - 43: Stimset cycle ID +/// - 44: Digitizer Hardware Type, one of @ref HardwareDACTypeConstants +/// - 45: Fixed frequency acquisition +/// - 46: Headstage Active, binary flag that indicates the enabled headstage(s), the index is the headstage number +/// - 47: Clamp Mode +/// - 48: Igor Pro bitness +/// - 49: DA ChannelType, one of @ref DaqChannelTypeConstants +/// - 50: AD ChannelType, one of @ref DaqChannelTypeConstants +/// - 51: oodDAQ member, true if headstage takes part in oodDAQ mode, false otherwise +/// - 52: Autobias % (DAEphys->Settings->Amplifier) +/// - 53: Autobias Interval (DAEphys->Settings->Amplifier) +/// - 54: TP after DAQ +/// - 55: Epochs version +/// - 56: Get/Set Inter-trial interval +/// - 57: Double precision data +/// - 58: Save amplifier settings +/// - 59: Require amplifier +/// - 60: Skip Ahead +/// - 61: TP power spectrum Function/WAVE GetSweepSettingsKeyWave(string device) variable versionOfNewWave = SWEEP_SETTINGS_WAVE_VERSION @@ -2545,7 +2538,7 @@ Function/WAVE GetSweepSettingsKeyWave(string device) if(WaveExists(wv)) Redimension/N=(-1, 63) wv else - Make/T/N=(3, 63) newDFR:$newName/WAVE=wv + Make/T/N=(3, 62) newDFR:$newName/WAVE=wv endif wv = "" @@ -2706,105 +2699,101 @@ Function/WAVE GetSweepSettingsKeyWave(string device) wv[%Units][37] = LABNOTEBOOK_BINARY_UNIT wv[%Tolerance][37] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][38] = "Sampling interval multiplier" - wv[%Units][38] = "" - wv[%Tolerance][38] = "1" + wv[%Parameter][38] = "TP during ITI" + wv[%Units][38] = LABNOTEBOOK_BINARY_UNIT + wv[%Tolerance][38] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][39] = "TP during ITI" + wv[%Parameter][39] = "Amplifier change via I=0" wv[%Units][39] = LABNOTEBOOK_BINARY_UNIT wv[%Tolerance][39] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][40] = "Amplifier change via I=0" + wv[%Parameter][40] = "Skip analysis functions" wv[%Units][40] = LABNOTEBOOK_BINARY_UNIT wv[%Tolerance][40] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][41] = "Skip analysis functions" + wv[%Parameter][41] = "Repeat sweep on async alarm" wv[%Units][41] = LABNOTEBOOK_BINARY_UNIT wv[%Tolerance][41] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][42] = "Repeat sweep on async alarm" - wv[%Units][42] = LABNOTEBOOK_BINARY_UNIT - wv[%Tolerance][42] = LABNOTEBOOK_NO_TOLERANCE + wv[%Parameter][42] = "Set Cycle Count" + wv[%Units][42] = "" + wv[%Tolerance][42] = "1" - wv[%Parameter][43] = "Set Cycle Count" + wv[%Parameter][43] = STIMSET_ACQ_CYCLE_ID_KEY wv[%Units][43] = "" wv[%Tolerance][43] = "1" - wv[%Parameter][44] = STIMSET_ACQ_CYCLE_ID_KEY + wv[%Parameter][44] = "Digitizer Hardware Type" wv[%Units][44] = "" wv[%Tolerance][44] = "1" - wv[%Parameter][45] = "Digitizer Hardware Type" - wv[%Units][45] = "" + wv[%Parameter][45] = "Fixed frequency acquisition" + wv[%Units][45] = "kHz" wv[%Tolerance][45] = "1" - wv[%Parameter][46] = "Fixed frequency acquisition" - wv[%Units][46] = "kHz" - wv[%Tolerance][46] = "1" + wv[%Parameter][46] = "Headstage Active" + wv[%Units][46] = LABNOTEBOOK_BINARY_UNIT + wv[%Tolerance][46] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][47] = "Headstage Active" - wv[%Units][47] = LABNOTEBOOK_BINARY_UNIT + wv[%Parameter][47] = CLAMPMODE_ENTRY_KEY + wv[%Units][47] = "" wv[%Tolerance][47] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][48] = CLAMPMODE_ENTRY_KEY + wv[%Parameter][48] = "Igor Pro bitness" wv[%Units][48] = "" wv[%Tolerance][48] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][49] = "Igor Pro bitness" + wv[%Parameter][49] = "DA ChannelType" wv[%Units][49] = "" - wv[%Tolerance][49] = LABNOTEBOOK_NO_TOLERANCE + wv[%Tolerance][49] = "1" - wv[%Parameter][50] = "DA ChannelType" + wv[%Parameter][50] = "AD ChannelType" wv[%Units][50] = "" wv[%Tolerance][50] = "1" - wv[%Parameter][51] = "AD ChannelType" - wv[%Units][51] = "" - wv[%Tolerance][51] = "1" + wv[%Parameter][51] = "oodDAQ member" + wv[%Units][51] = LABNOTEBOOK_BINARY_UNIT + wv[%Tolerance][51] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][52] = "oodDAQ member" - wv[%Units][52] = LABNOTEBOOK_BINARY_UNIT - wv[%Tolerance][52] = LABNOTEBOOK_NO_TOLERANCE + wv[%Parameter][52] = AUTOBIAS_PERC_KEY + wv[%Units][52] = "" + wv[%Tolerance][52] = "0.1" - wv[%Parameter][53] = AUTOBIAS_PERC_KEY - wv[%Units][53] = "" + wv[%Parameter][53] = "Autobias Interval" + wv[%Units][53] = "s" wv[%Tolerance][53] = "0.1" - wv[%Parameter][54] = "Autobias Interval" - wv[%Units][54] = "s" - wv[%Tolerance][54] = "0.1" + wv[%Parameter][54] = "TP after DAQ" + wv[%Units][54] = LABNOTEBOOK_BINARY_UNIT + wv[%Tolerance][54] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][55] = "TP after DAQ" - wv[%Units][55] = LABNOTEBOOK_BINARY_UNIT - wv[%Tolerance][55] = LABNOTEBOOK_NO_TOLERANCE + wv[%Parameter][55] = SWEEP_EPOCH_VERSION_ENTRY_KEY + wv[%Units][55] = "" + wv[%Tolerance][55] = "1" - wv[%Parameter][56] = "Epochs version" - wv[%Units][56] = "" - wv[%Tolerance][56] = "1" + wv[%Parameter][56] = "Get/Set Inter-trial interval" + wv[%Units][56] = LABNOTEBOOK_BINARY_UNIT + wv[%Tolerance][56] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][57] = "Get/Set Inter-trial interval" + wv[%Parameter][57] = "Double precision data" wv[%Units][57] = LABNOTEBOOK_BINARY_UNIT wv[%Tolerance][57] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][58] = "Double precision data" + wv[%Parameter][58] = "Save amplifier settings" wv[%Units][58] = LABNOTEBOOK_BINARY_UNIT wv[%Tolerance][58] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][59] = "Save amplifier settings" + wv[%Parameter][59] = "Require amplifier" wv[%Units][59] = LABNOTEBOOK_BINARY_UNIT wv[%Tolerance][59] = LABNOTEBOOK_NO_TOLERANCE - wv[%Parameter][60] = "Require amplifier" - wv[%Units][60] = LABNOTEBOOK_BINARY_UNIT - wv[%Tolerance][60] = LABNOTEBOOK_NO_TOLERANCE - - wv[%Parameter][61] = "Skip Ahead" - wv[%Units][61] = "" - wv[%Tolerance][61] = "1" + wv[%Parameter][60] = "Skip Ahead" + wv[%Units][60] = "" + wv[%Tolerance][60] = "1" - wv[%Parameter][62] = "TP power spectrum" - wv[%Units][62] = LABNOTEBOOK_BINARY_UNIT - wv[%Tolerance][62] = LABNOTEBOOK_NO_TOLERANCE + wv[%Parameter][61] = "TP power spectrum" + wv[%Units][61] = LABNOTEBOOK_BINARY_UNIT + wv[%Tolerance][61] = LABNOTEBOOK_NO_TOLERANCE SetSweepSettingsDimLabels(wv, wv) SetWaveVersion(wv, versionOfNewWave) diff --git a/Packages/MIES/labnotebook_numerical_description.itx b/Packages/MIES/labnotebook_numerical_description.itx index 339329c091..ce017fdca3 100644 --- a/Packages/MIES/labnotebook_numerical_description.itx +++ b/Packages/MIES/labnotebook_numerical_description.itx @@ -6,16 +6,16 @@ BEGIN "TimeStamp" "s" "-" "Time Stamp: Seconds since Igor epoch (1/1/1904) in local time zone with millisecond precision. Written at time of labnotebook entry." "ALL" "" "TimeStampSinceIgorEpochUTC" "s" "-" "Time Stamp: Seconds since Igor epoch (1/1/1904) in coordinated universal time zone (UTC) with millisecond precision. Written at time of labnotebook entry." "ALL" "" "EntrySourceType" "" "-" "Entry source type: type of the labnotebook entry, 0 for data acquisition, 1 for test pulse, NaN for all other types including user entries.\r" "ALL" "" - "AcquisitionState" "" "-" "Stores the current numbered state of data acquistion." "ALL" "" + "AcquisitionState" "" "-" "Stores the current numbered state of data acquisition." "ALL" "" "TP Baseline Vm" "mV" "1" "Testpulse Baseline: Average membrane potential, see https://alleninstitute.github.io/MIES/CalculateTPLikePropsFromSweep.html" "DEPEND" "IC;I=0" "TP Baseline pA" "pA" "50" "Testpulse Baseline: Average holding current, see https://alleninstitute.github.io/MIES/CalculateTPLikePropsFromSweep.html" "DEPEND" "VC" - "TP Peak Resistance" "MΩ" "runtime" "Testpulse Peak Resistance: Instantaneous resistance measurement calculated from testpulse profil, https://alleninstitute.github.io/MIES/CalculateTPLikePropsFromSweep.html" "DEPEND" "" + "TP Peak Resistance" "MΩ" "runtime" "Testpulse Peak Resistance: Instantaneous resistance measurement calculated from testpulse profile, https://alleninstitute.github.io/MIES/CalculateTPLikePropsFromSweep.html" "DEPEND" "" "TP Steady State Resistance" "MΩ" "runtime" "Testpulse Steady State Resistance: Resistance measurement obtained from the end of the applied testpulse profile, see https://alleninstitute.github.io/MIES/CalculateTPLikePropsFromSweep.html" "DEPEND" "" - "Fast compensation capacitance" "F" "1e-12" "Fast capacitance compensation: Cp Fast sets the parameters of current injected into the headstage atvoltage steps to charge (and discharge) the fast component of electrodecapacitance. The adjustable fields display estimates of the magnitudeand time constant for this capacitance.\r\rFor theoretical details see the MultiClamp700B Manual." "DEPEND" "" - "Slow compensation capacitance" "F" "1e-12" "Slow capacitance compensation: Settings for Cp Slow determine the parameters of current injected intothe headstage at voltage steps to charge and discharge the slow componentof electrode capacitance. The adjustable fields display estimates of themagnitude and time constant for this capacitance.\r\rFor theoretical details see the MultiClamp700B Manual." "DEPEND" "" + "Fast compensation capacitance" "F" "1e-12" "Fast capacitance compensation: Cp Fast sets the parameters of current injected into the headstage at voltage steps to charge (and discharge) the fast component of electrode capacitance. The adjustable fields display estimates of the magnitudeand time constant for this capacitance.\r\rFor theoretical details see the MultiClamp700B Manual." "DEPEND" "" + "Slow compensation capacitance" "F" "1e-12" "Slow capacitance compensation: Settings for Cp Slow determine the parameters of current injected into the headstage at voltage steps to charge and discharge the slow component of electrode capacitance. The adjustable fields display estimates of themagnitude and time constant for this capacitance.\r\rFor theoretical details see the MultiClamp700B Manual." "DEPEND" "" "Fast compensation time" "s" "1e-6" "Fast compensation time: Time constant for Fast compensation\r\rFor theoretical details see the MultiClamp700B Manual." "DEPEND" "" "Slow compensation time" "s" "1e-6" "Slow compensation time: Time constant for slow compensation\r\rFor theoretical details see the MultiClamp700B Manual." "DEPEND" "" - "Headstage Active" "On/Off" "-" "Headtage Active State: Specifies if the hardware associated with the headstage is in use." "DEPEND" "" + "Headstage Active" "On/Off" "-" "Headstage Active State: Specifies if the hardware associated with the headstage is in use." "DEPEND" "" "DAC" "" "0.1" "Digital Analog Channel used for testpulse or data acquisition" "ALL" "" "ADC" "" "0.1" "Analog digital channel used for testpulse or data acquisition" "ALL" "" "Clamp Mode" "" "-" "Amplifier clamp state: One of 0 (VC aka Voltage Clamp), 1 (IC aka Current Clamp), 2 (I=0 aka I Equal Zero)" "ALL" "" @@ -29,32 +29,32 @@ BEGIN "Set Sweep Count" "" "0.1" "Non-negative sweep (timeseries) index for the stimulus set." "ALL" "" "TP Insert Checkbox" "On/Off" "-" "Inserted Testpulse:" "INDEP" "" "Inter-trial interval" "s" "0.01" "Target interval for consecutive sweeps, start to start, in seconds" "INDEP" "" - "Inter-trial interval (effective)" "s" "-" "Realised interval for consecutive sweeps, start to start, in seconds including repurposed time" "INDEP" "" + "Inter-trial interval (effective)" "s" "-" "Realized interval for consecutive sweeps, start to start, in seconds including repurposed time" "INDEP" "" "TTL rack zero bits" "bit mask" "-" "ITC hardware specific: Bit mask for active DAEphys TTL channels of rack zero.\r\rSee also https://alleninstitute.github.io/MIES/file/_m_i_e_s___mies_utilities_8ipf.html?highlight=getttlbits#_CPPv310GetTTLBits4wave8variable8variable and https://alleninstitute.github.io/MIES/file/_m_i_e_s___mies_utilities_8ipf.html?highlight=getttlstimsets#_CPPv314GetTTLStimSets4wave4wave8variable." "INDEP" "" "TTL rack one bits" "bit mask" "-" "ITC hardware specific: Bit mask for active DAEphys TTL channels of rack one.\r\rSee also https://alleninstitute.github.io/MIES/file/_m_i_e_s___mies_utilities_8ipf.html?highlight=getttlbits#_CPPv310GetTTLBits4wave8variable8variable and https://alleninstitute.github.io/MIES/file/_m_i_e_s___mies_utilities_8ipf.html?highlight=getttlstimsets#_CPPv314GetTTLStimSets4wave4wave8variable." "INDEP" "" "TTL rack zero channel" "" "-" "ITC hardware specific: ITC XOP TTL hardware channel for rack zero, e.g., ITC 1600 = 0, ITC 18USB = 1" "INDEP" "" "TTL rack one channel" "" "-" "ITC hardware specific: ITC XOP TTL hardware channel for rack one, e.g., ITC 1600 = 3. Of the ITC devices, only the ITC1600 can have up to two racks." "INDEP" "" - "Delay onset user" "ms" "1" "User defined delay of stimset onset in milliseconds across all active channels. Occurs immediately after an optionally inserted Testpulse. Output is constant zero during the delay.\r\rSee https://alleninstitute.github.io/MIES/#id2 for a visualization of the sweep delays during data acquisition." "INDEP" "" - "Delay onset auto" "ms" "1" "Automatically defined delay in milliseconds due to the Testpulse (optionally) inserted at sweep onset.\r\rSee https://alleninstitute.github.io/MIES/#id2 for a visualization of the sweep delays during data acquisition." "INDEP" "" + "Delay onset user" "ms" "1" "User defined delay of stimset onset in milliseconds across all active channels. Occurs immediately after an optionally inserted testpulse. Output is constant zero during the delay.\r\rSee https://alleninstitute.github.io/MIES/#id2 for a visualization of the sweep delays during data acquisition." "INDEP" "" + "Delay onset auto" "ms" "1" "Automatically defined delay in milliseconds due to the testpulse (optionally) inserted at sweep onset.\r\rSee https://alleninstitute.github.io/MIES/#id2 for a visualization of the sweep delays during data acquisition." "INDEP" "" "Delay termination" "ms" "1" "User defined delay of sweep termination in milliseconds across all active channels. Occurs immediately after stimulus set termination. Output is constant zero during the delay.\r\rSee https://alleninstitute.github.io/MIES/#id2 for a visualization of the sweep delays during data acquisition." "INDEP" "" "Delay distributed DAQ" "ms" "1" "Distributed data acquisition distributes in time the selected stimsets across all active channels in a single sweep. The delay is the time in milliseconds between stimsets on each active channel.\r\rSee https://alleninstitute.github.io/MIES/index.html#id3 for visualization of the delay." "INDEP" "" "Distributed DAQ" "On/Off" "-" "Distributed data acquisition distributes in time the selected stimsets across all active channels in a single sweep.\r\rSee https://alleninstitute.github.io/MIES/index.html#id3 for visualization of the delay." "INDEP" "" - "Repeat Sets" "" "1" "User defined value that sets the minimum number of times a stimulus set is acquired within a repeated acquisition cycle.\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualisation of set repetition and indexing." "INDEP" "" - "Scaling zero" "On/Off" "-" "The DA scaling for active channels is set to zero after the stimulus set has cycled once. Only applies with locked indexing.\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualisation of scaling to zero." "INDEP" "" - "Indexing" "On/Off" "-" "Enables the acquistion of multiple stimulus sets, for an active channel, on a single repeated acquisition cycle.\r\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualisation of indexing." "INDEP" "" - "Locked indexing" "On/Off" "-" "Enables the acquistion of multiple stimulus sets, for an active channel, on a single repeated acquisition cycle.\rA special form of indexing where the transition to the next stimulus set happens on the same sweep for all active channels.\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualisation of indexing." "INDEP" "" - "Repeated Acquisition" "On/Off" "-" "Automated acquisition of more than one sweep.\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualisation of repeated acquisition." "INDEP" "" - "Random Repeated Acquisition" "On/Off" "-" "Randomizes the sweep acquisition order within a stimulus set.\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualisation of indexing." "INDEP" "" + "Repeat Sets" "" "1" "User defined value that sets the minimum number of times a stimulus set is acquired within a repeated acquisition cycle.\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualization of set repetition and indexing." "INDEP" "" + "Scaling zero" "On/Off" "-" "The DA scaling for active channels is set to zero after the stimulus set has cycled once. Only applies with locked indexing.\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualization of scaling to zero." "INDEP" "" + "Indexing" "On/Off" "-" "Enables the acquisition of multiple stimulus sets, for an active channel, on a single repeated acquisition cycle.\r\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualization of indexing." "INDEP" "" + "Locked indexing" "On/Off" "-" "Enables the acquisition of multiple stimulus sets, for an active channel, on a single repeated acquisition cycle.\rA special form of indexing where the transition to the next stimulus set happens on the same sweep for all active channels.\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualisation of indexing." "INDEP" "" + "Repeated Acquisition" "On/Off" "-" "Automated acquisition of more than one sweep.\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualization of repeated acquisition." "INDEP" "" + "Random Repeated Acquisition" "On/Off" "-" "Randomizes the sweep acquisition order within a stimulus set.\r\rSee https://alleninstitute.github.io/MIES/index.html#id1 for a visualization of indexing." "INDEP" "" "Sampling interval DA" "ms" "1" "Time interval between consecutive DA data points." "INDEP" "" "Sampling interval AD" "ms" "1" "Time interval between consecutive AD data points." "INDEP" "" "Sampling interval TTL" "ms" "1" "Time interval between consecutive TTL data points." "INDEP" "" "Sampling interval multiplier" "" "0.1" "The hardware limited minimum interval between consecutive data points is called the minimum sampling interval.\rThis interval can be prolonged by the user configured sampling interval multiplier." "INDEP" "" "Stim set length" "" "0.1" "Number of points in each sweep of the stimulus set. This is determined by the acquisition sampling interval." "ALL" "" - "oodDAQ Pre Feature" "ms" "1" "oodDAQ pre delay is the leading time envelope for non-zero parts of the stimulus set sweeps.\r\rSee https://alleninstitute.github.io/MIES/#id4 for a visualisation of oodDAQ." "INDEP" "" - "oodDAQ Post Feature" "ms" "1" "oodDAQ post delay is the trailing time envelope for non-zero parts of the stimulus set sweeps.\r\rSee https://alleninstitute.github.io/MIES/#id4 for a visualisation of oodDAQ." "INDEP" "" - "oodDAQ Resolution" "ms" "1" "The minimum search step for the oodDAQ time offset calculation.\r\rSee https://alleninstitute.github.io/MIES/#id4 for a visualisation of oodDAQ." "INDEP" "" + "oodDAQ Pre Feature" "ms" "1" "oodDAQ pre delay is the leading time envelope for non-zero parts of the stimulus set sweeps.\r\rSee https://alleninstitute.github.io/MIES/#id4 for a visualization of oodDAQ." "INDEP" "" + "oodDAQ Post Feature" "ms" "1" "oodDAQ post delay is the trailing time envelope for non-zero parts of the stimulus set sweeps.\r\rSee https://alleninstitute.github.io/MIES/#id4 for a visualization of oodDAQ." "INDEP" "" + "oodDAQ Resolution" "ms" "1" "The minimum search step for the oodDAQ time offset calculation.\r\rSee https://alleninstitute.github.io/MIES/#id4 for a visualization of oodDAQ." "INDEP" "" "Optimized Overlap dDAQ" "On/Off" "-" "Optimized overlap distributed data acquisition (oodDAQ) offsets in time stimulus set sweeps across headstages. The offset is determined such that the non-zero parts, plus user defined envelope (pre and post delay), of the stimset sweeps don't overlap on different headstages.\r\rSee https://alleninstitute.github.io/MIES/#id4 for a visualisation of oodDAQ." "INDEP" "" - "Delay onset oodDAQ" "ms" "1" "Calculated total oodDAQ offset used for acquisition.\r\rSee https://alleninstitute.github.io/MIES/#id4 for a visualisation of oodDAQ." "DEPEND" "" + "Delay onset oodDAQ" "ms" "1" "Calculated total oodDAQ offset used for acquisition.\r\rSee https://alleninstitute.github.io/MIES/#id4 for a visualization of oodDAQ." "DEPEND" "" "Pulse To Pulse Length" "ms" "1" "Not used in newer MIES versions." "ALL" "" "Repeated Acq Cycle ID" "" "1" "The \"Repeated Acq Cycle ID\" labels each repeated acquisition with a unique integer number.\rSweeps belonging to the same repeated acquisition cycle have the same ID.\rFor yoked devices the follower and lead devices will have the same ID,\rwhich also helps in that case to group sweeps together." "INDEP" "" "Stim Wave Checksum" "" "1" "The \"Stim Wave Checksum\" is a unique identifier for the stimulus set contents.\r\rChanges in this ID catches cases where the stimset has the same name but different contents." "DEPEND" "" @@ -64,11 +64,11 @@ BEGIN "TP buffer size" "" "0.1" "Size of the running average window for the testpulse results." "INDEP" "" "TP during ITI" "On/Off" "-" "When checked the testpulse runs during the inter-trial-interval." "INDEP" "" "Amplifier change via I=0" "On/Off" "-" "Switching between voltage and current clamp passes through I=0 mode if enabled.\r\rFor theoretical details see the MultiClamp700B Manual." "INDEP" "" - "Skip analysis functions" "On/Off" "-" "Analysis functions attached to simulus sets are not called when enabled." "INDEP" "" - "Repeat sweep on async alarm" "On/Off" "-" "When an asynchronous' channel alarm is triggered (user configurable) the last sweep is continously reacquired until the alarm state is cleared." "INDEP" "" + "Skip analysis functions" "On/Off" "-" "Analysis functions attached to stimulus sets are not called when enabled." "INDEP" "" + "Repeat sweep on async alarm" "On/Off" "-" "When an asynchronous' channel alarm is triggered (user configurable) the last sweep is continuously reacquired until the alarm state is cleared." "INDEP" "" "TP after DAQ" "On/Off" "-" "Run the testpulse immediately after data acquisition finished or was stopped prematurely." "INDEP" "" "Set Cycle Count" "" "1" "The number of stimulus set repetitions in one repeated acquisition cycle." "DEPEND" "" - "Stimset Acq Cycle ID" "" "1" " This identifier changes if one of the folllowing properties change:\r - Repeated acquisition cycle ID\r - Stimulus set\r - Stimulus set checksum\r - Stimulus set cycle count\r\rThe primary use case is for querying all labnotebook entries of all sweeps from the current set.\rIn analysis function terms all sweeps which are acquired between pre set event and post set event, see\ralso https://alleninstitute.github.io/MIES/file/_m_i_e_s___analysis_functions_8ipf.html.\r\rA visualisation is available at https://alleninstitute.github.io/MIES/#id1." "DEPEND" "" + "Stimset Acq Cycle ID" "" "1" " This identifier changes if one of the following properties change:\r - Repeated acquisition cycle ID\r - Stimulus set\r - Stimulus set checksum\r - Stimulus set cycle count\r\rThe primary use case is for querying all labnotebook entries of all sweeps from the current set.\rIn analysis function terms all sweeps which are acquired between pre set event and post set event, see\ralso https://alleninstitute.github.io/MIES/file/_m_i_e_s___analysis_functions_8ipf.html.\r\rA visualisation is available at https://alleninstitute.github.io/MIES/#id1." "DEPEND" "" "DAQ stop reason" "" "-" "Documents why data acquisition was stopped." "INDEP" "" "Digitizer Hardware Type" "" "1" "Hardware type (integer) of the DAEphys panel digitizer." "INDEP" "" "Fixed frequency acquisition" "kHz" "1" "The sampling frequency of the digitizer in kHz when fixed frequency acquisition is enabled." "INDEP" "" diff --git a/Packages/MIES/labnotebook_textual_description.itx b/Packages/MIES/labnotebook_textual_description.itx index 6ef9342f27..2f5b5eb0e2 100644 --- a/Packages/MIES/labnotebook_textual_description.itx +++ b/Packages/MIES/labnotebook_textual_description.itx @@ -5,7 +5,7 @@ BEGIN "TimeStamp" "s" "-" "Time Stamp: Seconds since Igor epoch (1/1/1904) in local time zone with millisecond precision. Written at time of labnotebook entry." "ALL" "" "TimeStampSinceIgorEpochUTC" "s" "-" "Time Stamp: Seconds since Igor epoch (1/1/1904) in coordinated universal time zone (UTC) with millisecond precision. Written at time of labnotebook entry." "ALL" "" "EntrySourceType" "" "-" "Entry source type: type of the labnotebook entry, 0 for data acquisition, 1 for test pulse, NaN for all other types including user entries.\r" "ALL" "" - "AcquisitionState" "" "-" "Stores the current numbered state of data acquistion." "ALL" "" + "AcquisitionState" "" "-" "Stores the current numbered state of data acquisition." "ALL" "" "Stim Wave Name" "" "-" "Stimulus set name" "DEPEND" "" "DA unit" "" "-" "User-defined analog output unit. Depends on the clamp mode. Typically pA or mV." "DEPEND" "" "AD unit" "" "-" "User-defined analog input unit. Depends on the clamp mode. Typically pA or mV." "DEPEND" "" @@ -54,7 +54,7 @@ BEGIN "RawOutSignalString" "" "-" "User-configured signal type of secondary output encoded as a string.\r\rFor more details, see the MultiClamp700B Manual." "DEPEND" "" "RawScaleFactorUnitsString" "" "-" "String denoting the unit of the Raw Scale Factor.\r\rFor more details see the MultiClamp700B Manual." "DEPEND" "" "User comment" "" "-" "Free-form user comment without a timestamp. Duplicate of entries in the user-comment notebook." "INDEP" "" - "HardwareTypeString" "" "-" "Amplifer hardware type string. e.g., MultiClamp 700B" "DEPEND" "" + "HardwareTypeString" "" "-" "Amplifier hardware type string. e.g., MultiClamp 700B" "DEPEND" "" "Async AD0 Title" "" "-" "User name of indicated asynchronous channel." "INDEP" "" "Async AD1 Title" "" "-" "User name of indicated asynchronous channel." "INDEP" "" "Async AD2 Title" "" "-" "User name of indicated asynchronous channel." "INDEP" "" diff --git a/Packages/tests/Basic/UTF_Labnotebook.ipf b/Packages/tests/Basic/UTF_Labnotebook.ipf index 3977ded68a..2337da1095 100644 --- a/Packages/tests/Basic/UTF_Labnotebook.ipf +++ b/Packages/tests/Basic/UTF_Labnotebook.ipf @@ -825,7 +825,7 @@ static Function Test_GetHeadstageForChannel() channel = 6 hs = GetHeadstageForChannel(numericalValues, sweepNo, XOP_CHANNEL_TYPE_TTL, channel, DATA_ACQUISITION_MODE) - CHECK_EQUAL_VAR(hs, INDEP_HEADSTAGE) + CHECK_EQUAL_VAR(hs, NaN) hs = GetHeadstageForChannel(numericalValues, sweepNo, XOP_CHANNEL_TYPE_DAC, channel, TEST_PULSE_MODE) CHECK_EQUAL_VAR(hs, NaN) hs = GetHeadstageForChannel(numericalValues, sweepNo, XOP_CHANNEL_TYPE_ADC, channel, UNKNOWN_MODE) diff --git a/Packages/tests/UTF_HelperFunctions.ipf b/Packages/tests/UTF_HelperFunctions.ipf index 3e33405f9b..ba70b33823 100644 --- a/Packages/tests/UTF_HelperFunctions.ipf +++ b/Packages/tests/UTF_HelperFunctions.ipf @@ -382,7 +382,7 @@ Function [string key, string keyTxt] PrepareLBN_IGNORE(string device) keys[0][0][0] = "Headstage Active" keys[1][0][0] = LABNOTEBOOK_BINARY_UNIT keys[2][0][0] = LABNOTEBOOK_NO_TOLERANCE - ED_AddEntriesToLabnotebook(valuesDAC, keys, sweepNo, device, DATA_ACQUISITION_MODE) + ED_AddEntriesToLabnotebook(values, keys, sweepNo, device, DATA_ACQUISITION_MODE) keys = "" @@ -505,7 +505,7 @@ Function [string key, string keyTxt] PrepareLBN_IGNORE(string device) values[0][0][0] = 1 values[0][0][1] = 1 keys[0][0][0] = "Headstage Active" - ED_AddEntriesToLabnotebook(valuesDAC, keys, sweepNo, device, DATA_ACQUISITION_MODE) + ED_AddEntriesToLabnotebook(values, keys, sweepNo, device, DATA_ACQUISITION_MODE) // numerical entries @@ -609,7 +609,7 @@ Function [string key, string keyTxt] PrepareLBN_IGNORE(string device) values[0][0][0] = 1 values[0][0][1] = 1 keys[0][0][0] = "Headstage Active" - ED_AddEntriesToLabnotebook(valuesDAC, keys, sweepNo, device, DATA_ACQUISITION_MODE) + ED_AddEntriesToLabnotebook(values, keys, sweepNo, device, DATA_ACQUISITION_MODE) values[] = NaN values[0][0][0] = I_EQUAL_ZERO_MODE @@ -670,7 +670,7 @@ Function [string key, string keyTxt] PrepareLBN_IGNORE(string device) values[] = 0 values[0][0][0] = 1 keys[0][0][0] = "Headstage Active" - ED_AddEntriesToLabnotebook(valuesDAC, keys, sweepNo, device, DATA_ACQUISITION_MODE) + ED_AddEntriesToLabnotebook(values, keys, sweepNo, device, DATA_ACQUISITION_MODE) values[] = NaN values[0][0][0] = V_CLAMP_MODE