Loading...
Searching...
No Matches
AisInstrumentHandler Class Referencefinal

this class provides control of the device including starting, pausing, resuming and stopping an experiment on a channel as well as reading the data and other controls of the device. More...

#include <AisInstrumentHandler.h>

#include <AisInstrumentHandler.h>

Inheritance diagram for AisInstrumentHandler:

Signals

void deviceDisconnected ()
 a signal that is emitted if the device associated with this handler has been disconnected.
 
void groundFloatStateChanged (bool grounded)
 a signal that is emitted when the floating ground connection state has changed.
 
void experimentNewElementStarting (uint8_t channel, const AisExperimentNode &stepInfo)
 a signal that is emitted whenever a new elemental experiment has started.
 
void activeDCDataReady (uint8_t channel, const AisDCData &DCData)
 a signal that is emitted whenever new DC data for an active experiment are ready.
 
void idleDCDataReady (uint8_t channel, const AisDCData &DCData)
 a signal that is emitted whenever new DC data are ready when the device is in an idle state.
 
void recoveryDCDataReady (uint8_t channel, const AisDCData &DCData)
 a signal that is emitted whenever new DC recovery data are ready.
 
void activeACDataReady (uint8_t channel, const AisACData &ACData)
 a signal that is emitted whenever new AC data for an active experiment are ready.
 
void recoveryACDataReady (uint8_t channel, const AisACData &ACData)
 a signal that is emitted whenever new AC recovery data are ready.
 
void experimentStopped (uint8_t channel, const QString &reason)
 a signal that is emitted whenever an experiment was stopped manually or has completed.
 
void experimentPaused (uint8_t channel)
 a signal that is emitted whenever an experiment was paused.
 
void experimentResumed (uint8_t channel)
 a signal that is emitted whenever an experiment was resumed.
 
void recoverDataErased (bool successful)
 a signal that is emitted whenever data erase process is completed.
 
void deviceError (uint8_t channel, const QString &error)
 a signal that is emitted whenever device send any critical error.
 

Public Member Functions

AisErrorCode uploadExperimentToChannel (uint8_t channel, std::shared_ptr< AisExperiment > experiment) const
 upload an already created custom experiment to a specific channel on the device.
 
AisErrorCode uploadExperimentToChannel (uint8_t channel, const AisExperiment &experiment) const
 upload an already created custom experiment to a specific channel on the device.
 
AisErrorCode startUploadedExperiment (uint8_t channel) const
 start the previously uploaded experiment on the specific channel.
 
AisErrorCode startIdleSampling (uint8_t channel) const
 start idle sampling when an experiment is neither uploaded nor running on the specified channel.
 
AisErrorCode skipExperimentStep (uint8_t channel) const
 skip the current experiment step and proceed to the next.
 
AisErrorCode pauseExperiment (uint8_t channel) const
 pause a running experiment on the channel.
 
AisErrorCode resumeExperiment (uint8_t channel) const
 resume a paused experiment on the channel.
 
AisErrorCode stopExperiment (uint8_t channel) const
 stop a running or a paused experiment on the channel.
 
double getExperimentUTCStartTime (uint8_t channel) const
 get UTC time for the start of the experiment in seconds.
 
AisErrorCode setIRComp (uint8_t channel, double uncompensatedResistance, double compensationLevel) const
 set IR compensation.
 
AisErrorCode setCompRange (uint8_t channel, const AisCompRange &compRange) const
 set a compensation range with stability factor and bandwidth index.
 
int8_t setLinkedChannels (std::vector< uint8_t > channels) const
 connect several channels together in parallel mode.
 
int8_t setBipolarLinkedChannels (std::vector< uint8_t > channels) const
 connect two channels together in bipolar mode.
 
bool hasBipolarMode (uint8_t channel) const
 tells whether the given channel is bipolar mode
 
std::vector< uint8_t > getLinkedChannels (uint8_t channel) const
 get a list of channels linked to the given channel.
 
AisErrorCode setFanSpeedMaximum () const
 Set the fan speed to maximum when an experiment is active. Only available on some devices.
 
AisErrorCode setFanSpeedVariable () const
 Set the fan speed to always adjust automatically based on the internal temperature of the instrument. Only available on some devices.
 
bool isChannelBusy (uint8_t channel) const
 tells whether the given channel is busy or not.
 
bool isChannelPaused (uint8_t channel) const
 tells whether the given channel has a paused experiment or not.
 
std::vector< uint8_t > getFreeChannels () const
 get a list of the currently free channels.
 
int getNumberOfChannels () const
 get the number of all the channels on this device.
 
AisErrorCode eraseRecoverData () const
 delete the recover data from device.
 
AisErrorCode startManualExperiment (uint8_t channel) const
 start a manual experiment.
 
AisErrorCode setManualModeSamplingInterval (uint8_t channel, double value) const
 set an interval for sampling the data.
 
AisErrorCode setManualModeOCP (uint8_t channel) const
 set open-circuit potential mode.
 
AisErrorCode setManualModeConstantVoltage (uint8_t channel, double value) const
 set constant voltage for the manual experiment.
 
AisErrorCode setManualModeConstantVoltage (uint8_t channel, double value, int currentRangeIndex) const
 set constant voltage for the manual experiment and also set a manual current range.
 
AisErrorCode setManualModeCurrentRange (uint8_t channel, int currentRangeIndex) const
 set the current range for the manual experiment. Once a range is set, autoranging capability is turned off. That means that during potentiostatic control, the current range may range up if necessary, but it will not drop below the user-set range. During galvanostatic control, the lowest current range that contains the designated setpoint will be chosen, provided it is not lower than the user-set range.
 
AisErrorCode setManualModeCurrentAutorange (uint8_t channel) const
 enable current autoranging for the manual experiment.
 
AisErrorCode setManualModeVoltageRange (uint8_t channel, int voltageRangeIndex) const
 set the voltage range for the manual experiment. Once a range is set, autoranging capability is turned off. That means that during galvanostatic control, the voltage range may range up if necessary, but it will not drop below the user-set range. During potentiostatic control, the lowest voltage range that contains the designated setpoint will be chosen, provided it is not lower than the user-set range.
 
AisErrorCode setManualModeVoltageAutorange (uint8_t channel) const
 enable voltage autoranging for the manual experiment.
 
AisErrorCode setManualModeConstantCurrent (uint8_t channel, double value) const
 set constant current for the manual experiment.
 
std::vector< std::pair< double, double > > getManualModeCurrentRangeList (uint8_t channel) const
 get a list of the applicable current ranges to the given channel specific to your device.
 
std::vector< std::pair< double, double > > getManualModeVoltageRangeList (uint8_t channel) const
 get a list of the applicable voltage ranges to the given channel specific to your device.
 
AisErrorCode setChannelMaximumVoltage (uint8_t channel, double Vmax) const
 Sets the maximum allowable voltage for a channel. The experiment will stop if the measured voltage exceeds this limit.
 
AisErrorCode setChannelMinimumVoltage (uint8_t channel, double Vmin) const
 Sets the minimum allowable voltage for a channel. The experiment will stop if the measured voltage falls below this limit.
 
AisErrorCode setChannelMaximumCurrent (uint8_t channel, double Imax) const
 Sets the maximum allowable current for a channel. The experiment will stop if the measured current exceeds this limit.
 
AisErrorCode setChannelMinimumCurrent (uint8_t channel, double Imin) const
 Sets the minimum allowable current for a channel. The experiment will stop if the measured current falls below this limit.
 
AisErrorCode setChannelMaximumTemperature (uint8_t channel, double MaxTemperature) const
 Sets the maximum allowable temperature for a channel. The experiment will stop if the measured temperature exceeds this limit.
 
AisErrorCode resetChannelLimits (uint8_t channel) const
 Resets all limits for the specified channel.
 

Member Function Documentation

◆ activeACDataReady

void AisInstrumentHandler::activeACDataReady ( uint8_t channel,
const AisACData & ACData )
signal
Parameters
channelthe channel number from which the AC data arrived.
ACDatathe AC data that just arrived.
Examples
basicExperiment.cpp, dataOutput.cpp, nonblockingExperiment.cpp, and pulseData.cpp.

◆ activeDCDataReady

void AisInstrumentHandler::activeDCDataReady ( uint8_t channel,
const AisDCData & DCData )
signal
Parameters
channelthe channel number from which the DC data arrived.
DCDatathe DC data that just arrived.
Examples
advancedExperiment.cpp, basicExperiment.cpp, dataOutput.cpp, linkedChannels.cpp, manualExperiment.cpp, nonblockingExperiment.cpp, and pulseData.cpp.

◆ deviceError

void AisInstrumentHandler::deviceError ( uint8_t channel,
const QString & error )
signal
Parameters
channelthe channel number at which error rise.
errorinformation about error message.
Note
stop experiment command will automatilcally send on channel.
Examples
advancedExperiment.cpp, basicExperiment.cpp, linkedChannels.cpp, and manualExperiment.cpp.

◆ eraseRecoverData()

AisErrorCode AisInstrumentHandler::eraseRecoverData ( ) const
Returns
AisErrorCode::Success if request is sucessfully send for delete the data. If not successful, possible returned errors are:

◆ experimentNewElementStarting

void AisInstrumentHandler::experimentNewElementStarting ( uint8_t channel,
const AisExperimentNode & stepInfo )
signal
Parameters
channelthe channel number on which the experiment was started.
stepInfoinformation regarding the current step.
See also
AisExperimentNode
Examples
advancedExperiment.cpp, basicExperiment.cpp, dataOutput.cpp, nonblockingExperiment.cpp, and pulseData.cpp.

◆ experimentPaused

void AisInstrumentHandler::experimentPaused ( uint8_t channel)
signal
Parameters
channelthe channel on which the experiment was paused.
Examples
pulseData.cpp.

◆ experimentResumed

void AisInstrumentHandler::experimentResumed ( uint8_t channel)
signal
Parameters
channelthe channel on which the experiment was resumed.
Examples
pulseData.cpp.

◆ experimentStopped

void AisInstrumentHandler::experimentStopped ( uint8_t channel,
const QString & reason )
signal
Parameters
channelthe channel on which the experiment has stopped.
reasonthe reason why the experiment has stopped.
Examples
advancedControlFlow.cpp, advancedExperiment.cpp, basicExperiment.cpp, dataOutput.cpp, manualExperiment.cpp, nonblockingExperiment.cpp, and pulseData.cpp.

◆ getExperimentUTCStartTime()

double AisInstrumentHandler::getExperimentUTCStartTime ( uint8_t channel) const

This will give the time in seconds between the origin of UTC time and the start of the experiment aka Unix Epoch.

Parameters
channelthe channel for which to get the start time of the experiment.
Returns
the Unix Epoch up to the start of the experiment in seconds.

◆ getFreeChannels()

std::vector< uint8_t > AisInstrumentHandler::getFreeChannels ( ) const
Returns
a list of the currently free channels. If all channels are busy, an empty list is returned.

◆ getLinkedChannels()

std::vector< uint8_t > AisInstrumentHandler::getLinkedChannels ( uint8_t channel) const
Parameters
channela valid channel number to find which other channels are linked to it.
Returns
a list of channels linked to the channel parameter.

◆ getManualModeCurrentRangeList()

std::vector< std::pair< double, double > > AisInstrumentHandler::getManualModeCurrentRangeList ( uint8_t channel) const

The list is indexed, with each index containing a range with minimum and maximum current for the range. You can pass the index of the desired current range to setManualModeConstantVoltage or setManualModeConstantCurrent.

Parameters
channela valid channel number for which to check the current range.
Returns
a list of the of the applicable current ranges to the given channel specific to your device.

◆ getManualModeVoltageRangeList()

std::vector< std::pair< double, double > > AisInstrumentHandler::getManualModeVoltageRangeList ( uint8_t channel) const

The list is indexed, with each index containing a range with minimum and maximum voltage for the range. You can pass the index of the desired current range to setManualModeConstantVoltage or setManualModeConstantCurrent.

Parameters
channela valid channel number for which to check the current range.
Returns
a list of the of the applicable current ranges to the given channel specific to your device.

◆ getNumberOfChannels()

int AisInstrumentHandler::getNumberOfChannels ( ) const
Returns
the number of channels on the connected device. If no device found, -1 will be returned.

◆ groundFloatStateChanged

void AisInstrumentHandler::groundFloatStateChanged ( bool grounded)
signal
Parameters
groundedtrue if there is a connection to ground and false if the ground has disconnected.

◆ hasBipolarMode()

bool AisInstrumentHandler::hasBipolarMode ( uint8_t channel) const
Parameters
channelthe channel number to check if it is bipolar mode
Returns
true only if given a valid channel number that has bipolar mode.

◆ idleDCDataReady

void AisInstrumentHandler::idleDCDataReady ( uint8_t channel,
const AisDCData & DCData )
signal

A manual experiment displays real time values. These values are displayed even if the channel does not have an experiment running on it.

Parameters
channelthe channel number from which the DC data arrived.
DCDatathe DC data that just arrived.

◆ isChannelBusy()

bool AisInstrumentHandler::isChannelBusy ( uint8_t channel) const
Parameters
channelthe channel number to check if it is busy or not.
Returns
true only if given a valid channel number that has either a running or a paused experiment.

◆ isChannelPaused()

bool AisInstrumentHandler::isChannelPaused ( uint8_t channel) const
Parameters
channelthe channel number to check if it has a paused experiment.
Returns
true only if given a valid channel number that has an experiment that has been paused.

◆ pauseExperiment()

AisErrorCode AisInstrumentHandler::pauseExperiment ( uint8_t channel) const
Parameters
channelthe channel number to pause the experiment on.
Returns
true if an experiment was successfully paused on the channel and false otherwise. If not successful, possible returned errors are:

This will return AisErrorCode::Success only if there is currently a running experiment on a valid channel on a connected device.

◆ recoverDataErased

void AisInstrumentHandler::recoverDataErased ( bool successful)
signal
Parameters
successfulis true on erased correctly, and false on data is not erased.

◆ recoveryACDataReady

void AisInstrumentHandler::recoveryACDataReady ( uint8_t channel,
const AisACData & ACData )
signal
Parameters
channelthe channel number from which the AC data are recovered from.
ACDatathe AC data that just arrived.

◆ recoveryDCDataReady

void AisInstrumentHandler::recoveryDCDataReady ( uint8_t channel,
const AisDCData & DCData )
signal
Parameters
channelthe channel number from which the DC data are recovered from.
DCDatathe DC data that just arrived.

◆ resetChannelLimits()

AisErrorCode AisInstrumentHandler::resetChannelLimits ( uint8_t channel) const

This function removes all configured voltage, current, and temperature limits for a specific channel, restoring it to its default state.

Parameters
channelThe channel number for which the limits are to be reset.
Returns
AisErrorCode indicating success or failure of the operation.

◆ resumeExperiment()

AisErrorCode AisInstrumentHandler::resumeExperiment ( uint8_t channel) const
Parameters
channelthe channel number to resume the experiment on.
Returns
AisErrorCode::Success if an experiment was successfully resumed on the channel. If not successful, possible returned errors are:

This will return AisErrorCode::Success only if there is currently a paused experiment on a valid channel on a connected device.

◆ setBipolarLinkedChannels()

int8_t AisInstrumentHandler::setBipolarLinkedChannels ( std::vector< uint8_t > channels) const

You may combine two channels to expand the voltage range to include negative voltages. Note that this is only applicable to the cycler model. For 4 channel Cycler models, you can combine channels 1 and 2 or channels 3 and 4. You cannot use any other channel combinations.

Parameters
channelsa list of two channels to be oprate in bipolar mode.
Returns
the master channel out of the given list of two channels. The master channel is your interface to upload an experiment to and then control it. If not successful set in bipolar mode, possible returned errors as -1.
Note
this functionality is only applicable to the cycler model.

◆ setChannelMaximumCurrent()

AisErrorCode AisInstrumentHandler::setChannelMaximumCurrent ( uint8_t channel,
double Imax ) const

Sets the maximum allowable current for a channel. The experiment will stop if the measured current exceeds this limit.

Parameters
channelThe channel number for which the current limit is to be set.
ImaxThe maximum allowable current in amperes.
Returns
AisErrorCode indicating success or failure of the operation.
Note
  • For Squidstat Cyclers, this limit will not apply to AC elements.
  • For all other devices, it is not recommended to use this for AC elements.

◆ setChannelMaximumTemperature()

AisErrorCode AisInstrumentHandler::setChannelMaximumTemperature ( uint8_t channel,
double MaxTemperature ) const

Sets the maximum allowable temperature for a channel. The experiment will stop if the measured temperature exceeds this limit.

Parameters
channelThe channel number for which the temperature limit is to be set.
MaxTemperatureThe maximum allowable temperature in degrees Celsius.
Returns
AisErrorCode indicating success or failure of the operation.
Note
  • For Squidstat Cyclers, this limit will not apply to AC elements.

◆ setChannelMaximumVoltage()

AisErrorCode AisInstrumentHandler::setChannelMaximumVoltage ( uint8_t channel,
double Vmax ) const

Sets the maximum allowable voltage for a channel. The experiment will stop if the measured voltage exceeds this limit.

Parameters
channelThe channel number for which the voltage limit is to be set.
VmaxThe maximum allowable voltage in volts.
Returns
AisErrorCode indicating success or failure of the operation.
Note
  • For Squidstat Cyclers, this limit will not apply to AC elements.
  • For all other devices, it is not recommended to use this for AC elements.

◆ setChannelMinimumCurrent()

AisErrorCode AisInstrumentHandler::setChannelMinimumCurrent ( uint8_t channel,
double Imin ) const

Sets the minimum allowable current for a channel. The experiment will stop if the measured current falls below this limit.

Parameters
channelThe channel number for which the current limit is to be set.
IminThe minimum allowable current in amperes.
Returns
AisErrorCode indicating success or failure of the operation.
Note
  • For Squidstat Cyclers, this limit will not apply to AC elements.
  • For all other devices, it is not recommended to use this for AC elements.

◆ setChannelMinimumVoltage()

AisErrorCode AisInstrumentHandler::setChannelMinimumVoltage ( uint8_t channel,
double Vmin ) const

Sets the minimum allowable voltage for a channel. The experiment will stop if the measured voltage falls below this limit.

Parameters
channelThe channel number for which the voltage limit is to be set.
VminThe minimum allowable voltage in volts.
Returns
AisErrorCode indicating success or failure of the operation.
Note
  • For Squidstat Cyclers, this limit will not apply to AC elements.
  • For all other devices, it is not recommended to use this for AC elements.

◆ setCompRange()

AisErrorCode AisInstrumentHandler::setCompRange ( uint8_t channel,
const AisCompRange & compRange ) const
Parameters
channelthe channel for which to set the compensation range.
compRangean object of type compRange that is initialized with a stability factor (0-10) and a bandwidth index (0-10).
Returns
AisErrorCode::Success if setting the IR compensation was successful. If not successful, possible returned errors are:
See also
AisCompRange

◆ setFanSpeedMaximum()

AisErrorCode AisInstrumentHandler::setFanSpeedMaximum ( ) const
Note
Setting this mode may remove small variations in data caused by fan cycling in some electrochemical systems.

Set the fan speed to maximum when an experiment is active. Only available on some devices.
Model-specific fan behavior:

◆ setFanSpeedVariable()

AisErrorCode AisInstrumentHandler::setFanSpeedVariable ( ) const

Set the fan speed to always adjust automatically based on the internal temperature of the instrument. Only available on some devices.
Model-specific fan behavior:

◆ setIRComp()

AisErrorCode AisInstrumentHandler::setIRComp ( uint8_t channel,
double uncompensatedResistance,
double compensationLevel ) const
Parameters
channelthe channel for which to set the IR compensation.
uncompensatedResistancethe value of the uncompensated resistance in Ohms.
compensationLevelthe compensation percentage (0%-100%). This is unit-less.
Returns
AisErrorCode::Success if setting the IR compensation was successful. If not successful, possible returned errors are:

◆ setLinkedChannels()

int8_t AisInstrumentHandler::setLinkedChannels ( std::vector< uint8_t > channels) const

You may connect a list of channels so you can get a higher combined output current of all channels. Note that this is only applicable to the cycler model.

Parameters
channelsa list of channels to be linked.
Returns
the master channel out of the given list of channels. The master channel is your interface to upload an experiment to and then control it.
Note
this functionality is only applicable to the cycler model.

◆ setManualModeConstantCurrent()

AisErrorCode AisInstrumentHandler::setManualModeConstantCurrent ( uint8_t channel,
double value ) const
Parameters
channela valid channel number to set a constant voltage for.
valuethe value to set the constant current in Amps.
Returns
AisErrorCode::Success if setting the constant current was successful. If not successful, possible returned errors are:

◆ setManualModeConstantVoltage() [1/2]

AisErrorCode AisInstrumentHandler::setManualModeConstantVoltage ( uint8_t channel,
double value ) const
Parameters
channela valid channel number to set a constant voltage for.
valuethe value to set the constant voltage in volts.
Returns
AisErrorCode::Success if setting the constant voltage was successful. If not successful, possible returned errors are:

◆ setManualModeConstantVoltage() [2/2]

AisErrorCode AisInstrumentHandler::setManualModeConstantVoltage ( uint8_t channel,
double value,
int currentRangeIndex ) const
Parameters
channela valid channel number to set a constant voltage for.
valuethe value to set the constant voltage in volts.
currentRangeIndexthe index of the desired current range.
Returns
AisErrorCode::Success if setting the constant voltage was successful. You can get a list of the available ranges for your model by calling getManualModeCurrentRangeList. If not successful, possible returned errors are:

◆ setManualModeCurrentAutorange()

AisErrorCode AisInstrumentHandler::setManualModeCurrentAutorange ( uint8_t channel) const
Parameters
channela valid channel number to enable current autoranging for.
Returns
AisErrorCode::Success if enabling current autoranging successful. If not successful, possible returned errors are:

◆ setManualModeCurrentRange()

AisErrorCode AisInstrumentHandler::setManualModeCurrentRange ( uint8_t channel,
int currentRangeIndex ) const
Parameters
channela valid channel number to set the current range for.
currentRangeIndexthe index of the desired current range.
Returns
AisErrorCode::Success if setting the current range was successful. You can get a list of the available ranges for your model by calling getManualModeCurrentRangeList. If not successful, possible returned errors are:

◆ setManualModeOCP()

AisErrorCode AisInstrumentHandler::setManualModeOCP ( uint8_t channel) const

To apply the set potential or current, leave the open circuit potential mode off. This operation is reversed automatically when calling either setManualModeConstantVoltage() or setManualModeConstantCurrent()

Parameters
channela valid channel number to set open circuit mode on.
Returns
AisErrorCode::Success if turning on the open circuit mode was successful. If not successful, possible returned errors are:

◆ setManualModeSamplingInterval()

AisErrorCode AisInstrumentHandler::setManualModeSamplingInterval ( uint8_t channel,
double value ) const
Parameters
channelthe channel to set the sampling interval for.
valuethe value for the sampling interval in seconds.
Returns
AisErrorCode::Success if the operation was set successfully. If not successful, possible returned errors are:

◆ setManualModeVoltageAutorange()

AisErrorCode AisInstrumentHandler::setManualModeVoltageAutorange ( uint8_t channel) const
Parameters
channela valid channel number to enable voltage autoranging for.
Returns
AisErrorCode::Success if enabling voltage autoranging successful. If not successful, possible returned errors are:

◆ setManualModeVoltageRange()

AisErrorCode AisInstrumentHandler::setManualModeVoltageRange ( uint8_t channel,
int voltageRangeIndex ) const
Parameters
channela valid channel number to set the voltage range for.
voltageRangeIndexthe index of the desired voltage range.
Returns
AisErrorCode::Success if setting the voltage rnage was successful. You can get a list of the available ranges for your model by calling getManualModeVoltageRangeList. If not successful, possible returned errors are:

◆ skipExperimentStep()

AisErrorCode AisInstrumentHandler::skipExperimentStep ( uint8_t channel) const

When running an element that has several steps like going from CC to CV, then skipping the step goes to the next step within the element. When having several elements in the custom experiment and the current element has one step or we are at the last step within the element, then skipping the step results in going to the next element. If this is the final step of the final element, the experiment will stop.

Parameters
channela valid channel number with an experiment to skip the step.
Returns
AisErrorCode::Success the experiment step was successfully skipped If not successful, possible returned errors are:

◆ startIdleSampling()

AisErrorCode AisInstrumentHandler::startIdleSampling ( uint8_t channel) const
Parameters
channelthe channel number to start collecting idle data on.
Returns
AisErrorCode::Success if the request to start idle data was sent. If not successful, possible returned errors are:
See also
isChannelBusy

◆ startManualExperiment()

AisErrorCode AisInstrumentHandler::startManualExperiment ( uint8_t channel) const

With manual experiments, users can turn on any connected channel and toggle between open circuit mode and voltage or current setpoints that can be changed in real-time and run for indefinite periods.

Parameters
channela valid channel number to run the manual experiment on.
Returns
AisErrorCode::Success if the manual experiment was successfully started. If not successful, possible returned errors are:

◆ startUploadedExperiment()

AisErrorCode AisInstrumentHandler::startUploadedExperiment ( uint8_t channel) const
Parameters
channelthe channel number to start the experiment on.
Returns
AisErrorCode::Success if the experiment was successfully started on the channel. If not successful, possible returned errors are:
See also
uploadExperimentToChannel
isChannelBusy

◆ stopExperiment()

AisErrorCode AisInstrumentHandler::stopExperiment ( uint8_t channel) const
Parameters
channelthe channel number to stop the experiment on.
Returns
AisErrorCode::Success if an experiment was successfully stopped on the channel. If not successful, possible returned errors are:

This will only return AisErrorCode::Success if there is currently a running or a paused experiment on a valid channel on a connected device.

◆ uploadExperimentToChannel() [1/2]

AisErrorCode AisInstrumentHandler::uploadExperimentToChannel ( uint8_t channel,
const AisExperiment & experiment ) const

Any running experiment is run on a specific device on a specific channel. This function uploads an experiment to a channel so that you may start, pause, resume and stop the experiment. All of these four control functionalities and others require a channel number to control the experiment. Therefore, if we have several channels, we need to keep track of which experiment is on which channel.

Parameters
channelthe channel number to upload the experiment to.
experimentthe custom experiment to be uploaded to the channel.
Returns
AisErrorCode::Success if the experiment was successfully uploaded to the channel. If not successful, possible returned errors are:

This returns AisErrorCode::Success only when given a valid channel number that is not busy on a connected device.

See also
isChannelBusy

◆ uploadExperimentToChannel() [2/2]

AisErrorCode AisInstrumentHandler::uploadExperimentToChannel ( uint8_t channel,
std::shared_ptr< AisExperiment > experiment ) const

Any running experiment is run on a specific device on a specific channel. This function uploads an experiment to a channel so that you may start, pause, resume and stop the experiment. All of these four control functionalities and others require a channel number to control the experiment. Therefore, if we have several channels, we need to keep track of which experiment is on which channel.

Parameters
channelthe channel number to upload the experiment to.
experimentthe custom experiment to be uploaded to the channel.
Returns
AisErrorCode::Success if the experiment was successfully uploaded to the channel. If not successful, possible returned errors are:

This returns AisErrorCode::Success only when given a valid channel number that is not busy on a connected device.

See also
isChannelBusy

The documentation for this class was generated from the following file: