.

Controller Initialization

The Controller properties Location, Number, Port, and Type specify what SynqNet controller each MPX Controller object addresses. The default controller is controller zero on the local machine.

Where there are multiple motion controller cards in a system, multiple MPX Controller objects can be created to address each of the motion controller cards individually.

It is possible to modify these Controller properties using the properties list window when you are designing your program. When an application starts, it uses the Location, Number, Port, and Type properties specified in the properties page to communicate with the controller.

When an application is executing, it is possible change the SynqNet controller the MPX Controller object addresses. Controller.Disconnect must be called before the Type, Number, Address and Port properties are changed. After the new address properties are set, Controller.Connect must be called to connect to the new controller. The following MPX code shows how you would switch to using the controller number 1 on the local machine.

Visual Basic

Controller.Disconnect() 
Controller.Type = Mpx.ControllerType.Local
Controller.Number = 1
Controller.Connect()

C#

Controller.Disconnect();
Controller.Type = Mpx.ControllerType.Local;
Controller.Number = 1;
Controller.Connect();

 

See Also

Controller Object
Connect
Disconnect
Location
Number
Port
Type

       Legal Notice  |  Tech Email  |  Feedback
      
Copyright ©
2001-2021 Motion Engineering