flex_enable_home_inputs

NI-Motion Functions

flex_enable_home_inputs

Device Compatibility

Device Compatibility
7330
Y
7340
Y
7344
Y
7350
Y
7390
Y
NI SoftMotion Controller for CANopen—Xenus
Y
NI SoftMotion Controller for CANopen—Accelnet
Y

Enable Home Inputs

Usage

status = flex_enable_home_inputs(u8 boardID, u16 homeMap);

Purpose

Enables/disables the home inputs.

Tip  Refer to the Remarks section for information about how the behavior of this function differs between controllers.

Parameters

Name Type Description
boardID u8 assigned by Measurement & Automation Explorer (MAX)
homeMap u16 bitmap of home inputs to enable

Parameter Discussion

homeMap is the bitmap of home inputs to enable.

D15 ... D10 D9 D8 D7 D6 D5 D4 D3 D2 D1 D0
Home 15 ...  Home 10 Home 9 Home 8 Home 7 Home 6 Home 5 Home 4 Home 3 Home 2 Home 1 0

For D1 through D8:
   1 = Home input enabled
   0 = Home input disabled (default)

Using This Function

This function enables/disables any combination of axis home inputs. An enabled home input causes a halt stop on the axis when the input becomes active. You can configure each home input to active low or active high with the Set Home Input Polarity function. You also can use a home input as a general-purpose input and read its status with the Read Home Input Status function.

Home inputs are an enhancement on the NI motion controller and are not required for basic motion control. You can operate all motion control functions without enabling or using the home inputs except the Find Reference function, which requires enabled limit and home inputs for operation when the find reference type is "home."

To configure the property of Find Reference Home, such as Initial search direction or Home edge to stop on, use the Load Reference Parameter function.

Note  An active (and enabled) home input transition on an axis that is part of a vector space move causes that axis to halt stop and the other axes in the vector space to decelerate to a stop.

Example

To enable the home inputs for axes 2 and 4, call the Enable Home Inputs function with homeMap = 0x0014, which corresponds to the following bitmap:

D15 ... D10 D9 D8 D7 D6 D5 D4 D3 D2 D1 D0
Home 15 ... Home 10 Home 9 Home 8 Home 7 Home 6 Home 5 Home 4 Home 3 Home 2 Home 1 0
0 0 0 0 0 0 0 1 0 1 0 0

Remarks

This section includes information about how the behavior of this function differs among the controllers that support it.

NI SoftMotion Controller Considerations

The following list includes considerations you must make when you are using this function with the NI SoftMotion Controller:

To enable home inputs on axes sixteen through thirty, use the Write Motion I/O Data function.