Console.WriteLine("📜 IO: IOPoint Objects");
int exitCode = 0;
try
{
Helpers.VerifyHardwareUsage(controller);
Helpers.VerifyAxisCount(controller);
const int NODE_INDEX = 0;
const int OUTPUT_INDEX = 0;
Console.WriteLine($"Output {OUTPUT_INDEX} set to: false");
controller.SampleWait(1);
bool outputValue = output0.
Get();
Console.WriteLine($"Output {OUTPUT_INDEX} value: {outputValue}");
Console.WriteLine($"Output {OUTPUT_INDEX} set to: true");
controller.SampleWait(1);
outputValue = output0.
Get();
Console.WriteLine($"Output {OUTPUT_INDEX} value: {outputValue}");
}
catch (Exception e)
{
Console.WriteLine($"❌ Error: {e.Message}");
}
finally
{
controller.Delete();
}
return exitCode;
Constants used in the C# sample apps.
const int EXIT_FAILURE
Exit code for failed execution.
const int EXIT_SUCCESS
Exit code for successful execution.
void Set(bool state)
Set the state of a Digital Output.
static IOPoint * CreateDigitalOutput(Axis *axis, RSIMotorDedicatedOut motorDedicatedOutNumber)
Create a Digital Output from an Axis' Dedicated Output bits.
bool Get()
Get the state of Digital Input or Output.
Represents one specific point: Digital Output, Digital Input, Analog Output, or Analog Input....
static MotionController * Get()
Get an already running RMP EtherCAT controller.
Represents the RMP soft motion controller. This class provides an interface to general controller con...
Helpers namespace provides utility functions for common tasks in RMP applications.