Console.WriteLine("📜 Recorder");
const int VALUES_PER_RECORD = 2;
const int RECORD_PERIOD_SAMPLES = 1;
const int RECORD_TIME = 250;
const int INPUT_INDEX = 0;
try
{
Axis axis = controller.
AxisGet(Constants.AXIS_0_INDEX);
{
}
Console.WriteLine($"There are {recordsAvailable} records available");
for (int i = 0; i < recordsAvailable; i++)
{
if ((digitalInputValue & digitalInput.
MaskGet()) == digitalInput.
MaskGet())
{
Console.WriteLine($"Encoder position was: {positionRecord} when input triggered");
break;
}
}
}
finally
{
}
static void CheckErrors(RapidCodeObject rsiObject)
Checks for errors in the given RapidCodeObject and throws an exception if any non-warning errors are ...
static void PhantomAxisReset(Axis phantomAxis)
Configures a phantom axis on the controller.
Helpers class provides static methods for common tasks in RMP applications.
uint64_t AddressGet(RSIAxisAddressType addressType)
Get the an address for some location on the Axis.
Represents a single axis of motion control. This class provides an interface for commanding motion,...
uint64_t AddressGet()
Get the Host Address for the I/O point.
static IOPoint * CreateDigitalInput(Axis *axis, RSIMotorDedicatedIn motorDedicatedInNumber)
Create a Digital Input from an Axis' Dedicated Input bits.
int32_t MaskGet()
Get the bit mask for the I/O point.
Represents one specific point: Digital Output, Digital Input, Analog Output, or Analog Input....
Axis * AxisGet(int32_t axisNumber)
AxisGet returns a pointer to an Axis object and initializes its internals.
int32_t RecorderRecordCountGet()
Get the number of records that are stored and ready for reading on Recorder 0.
void RecorderStart()
Start recording data.
void RecorderCircularBufferSet(bool enable)
Configure recorder as circular buffer (or not) on Recorder 0.
void RecorderRecordDataRetrieve()
Retrieve one record of recorded data on Recorder 0.
void RecorderDataCountSet(int32_t count)
Set the number of data values to be recorded on Recorder 0.
static MotionController * Get()
Get an already running RMP EtherCAT controller.
uint64_t AddressGet(RSIControllerAddressType type)
Get the an address for some location on the MotionController.
int32_t RecorderRecordDataValueGet(int32_t index)
Get one value from a retrieved record on Recorder 0.
void RecorderStop()
Stop recording data on Recorder 0.
void Delete(void)
Delete the MotionController and all its objects.
void RecorderReset()
Reset the recorder on Recorder 0.
void RecorderDataAddressSet(int32_t index, uint64_t address)
Setup the addresses to be recorded on Recorder 0.
void RecorderPeriodSet(uint32_t samples)
Set the number of samples between records on Recorder 0.
void RecorderCountSet(int32_t recorderCount)
Set the number of processed Recorders in the controller.
bool RecorderEnabledGet()
Determine if the recorder is recording on Recorder 0.
Represents the RMP soft motion controller. This class provides an interface to general controller con...
RapidCodeOS * OS
Provides access to operating system (Windows) features.
double RecorderRecordDataDoubleGet(int32_t index)
This is an overloaded member function, provided for convenience. It differs from the above function o...
void Sleep(int32_t milliseconds)
Put the current thread to sleep.
RSIControllerAddressType
Used to get firmware address used in User Limits, Recorders, etc.
RSIAxisAddressType
Used to get firmware address used in User Limits, Recorders, etc.