.

mpiMotionConfigGet

Declaration

 
long mpiMotionConfigGet(MPIMotion        motion,
                        MPIMotionConfig  *config,
                        void             *external) 
 

Required Header: stdmpi.h

Description

mpiMotionConfigGet gets the configuration of a Motion object (motion) and puts (writes) it in the structure pointed to by config, and also writes it into the implementation-specific structure pointed to by external (if external is not NULL).

The configuration information in external is in addition to the configuration information in config, i.e, the configuration information in config and in external is not the same information. Note that config or external can be NULL (but not both NULL).

Remarks

external either points to a structure of type MEIMotionConfig{} or is NULL.

 
Return Values
MPIMessageOK  

Sample Code

 

void modifyFeedrate(MPIMotion motion,
float normalFeedrate,
float pauseFeedrate)
{
MPIMotionConfig motionConfig;
long returnValue;

returnValue = mpiMotionConfigGet(motion,
&motionConfig,
NULL);
msgCHECK(returnValue);

printf("Before: normalFeedrate %lf, pauseFeedrate %lf\n",motionConfig.normalFeedrate,motionConfig.pauseFeedrate);

motionConfig.normalFeedrate = normalFeedrate;
motionConfig.pauseFeedrate = pauseFeedrate;

returnValue = mpiMotionConfigSet(motion,
&motionConfig,
NULL);
msgCHECK(returnValue);

printf("After: normalFeedrate %lf, pauseFeedrate %lf\n",motionConfig.normalFeedrate,motionConfig.pauseFeedrate);
}

 

See Also

mpiMotionConfigSet | MEIMotionConfig

 

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