Enable Auto Start

NI-Motion VI

Enable Auto Start

Allows you to automatically run a program when the controller powers up.

Details

Device Compatibility

DeviceCompatibility
7330
N
7340
Y
7344
Y
7350
Y
7390
N
NI SoftMotion Controller for CANopen—Accelnet
N
NI SoftMotion Controller for CANopen—Xenus
N
Program To Execute (1) is the onboard program the controller executes if the auto start feature is enabled. This must be a valid program number (1-255), that is stored to FLASH using the Object Memory Management VI.
Enable Auto Start enables or disables the auto start feature. Set this to Enable (true) to enable auto start and Disable (false) to disable auto start.
Board ID is a unique number assigned by Measurement & Automation Explorer (MAX) used to send and receive commands and data to or from a specific NI motion controller.
error in (no error) describes error conditions that occur before this VI runs. The default input of this cluster is no error. If an error already occurred, this VI returns the value of error in in error out. The VI runs normally only if no incoming error exists. Otherwise, the VI passes the error in value to error out. The error in cluster contains the following parameters:
status is TRUE if an error occurred before this VI was called, or FALSE if not. If status is TRUE, code is a nonzero error code. If status is FALSE, code is zero or a warning code.
code is a number identifying an error or warning. If status is TRUE, code is a nonzero error code. If status is FALSE, code is zero or a warning code. Use the error handler VIs to look up the meaning of this code and display the corresponding error message.
source is a string that indicates the origin of the error, if any. Typically, source is the name of the VI in which the error occurred.
Bd ID Out is provided for flow control. You can string together NI-Motion VIs by wiring the Bd ID Out terminal of one VI to the Board ID terminal of the next VI.
error out contains error information. If error in indicates an error, error out contains the same error information. Otherwise, it describes the error status that this VI produces.
status is TRUE if an error occurred, or FALSE if not. If status is TRUE, code is a nonzero error code. If status is FALSE, code is zero or a warning code.
code is a number identifying an error or warning. If status is TRUE, code is a nonzero error code. If status is FALSE, code is zero or a warning code. Use the error handler VIs to look up the meaning of this code and display the corresponding error message.
source is a string that indicates the origin of the error, if any. Typically, source is the name of the VI in which the error occurred.

Using This VI

The Enable Auto Start VI configures the controller to automatically start an onboard program on power up. After auto start is enabled, the controller automatically executes the onboard program specified when the controller is powered on. The onboard program to execute must be saved to FLASH using the Object Memory Management VI before the controller is powered down. If the controller does not find a valid program that it can load, NIMC_autoStartFailedError is generated. If the onboard program is removed from FLASH memory, the auto start functionality is disabled.

Note  This VI writes to onboard FLASH memory and hence it is not safe to execute when motors are in motion. Doing so generates a NIMC_wrongModeError.

This VI may take longer than 62 ms to process, so it is not guaranteed to be compatible with real-time execution.