long meiSqNodeDriveMonitor(MEISqNode             node,
                           long                  driveIndex, /* relative to 
                                                             the node */
                           MEISqNodeMonitorValue *value);
  Required Header: stdmei.h


meiSqNodeDriveMonitor reads the monitor fields from the drive and writes them into the structure pointed to by value.

node a handle to a SynqNet node object.
driveIndex an index to the drive (0, 1, 2, etc), relative to the node.
*value pointer to a structure of monitor values
Return Values

Sample Code

/* This function configure monitorA to look at index 10 on the drive
and display the monitorA value after. For Kollmorgen CD drive, index 10
shows the actual torque on the drive */

void driveCurrentMonitor(MEISqNode sqNode)
   MEISqNodeDriveMonitorConfig  monitorConfig; 
   MEISqNodeMonitorValue        value;
   long                         returnValue;

   /* Always do a ConfigGet before a ConfigSet */
   returnValue = meiSqNodeDriveMonitorConfigGet(sqNode,
                                                0, /* driveIndex */

   /* Configure monitorA to look at index 10 */
   monitorConfig.monitorA.data.index = 10;
   monitorConfig.monitorA.type       = MEISqNodeDriveMonitorDataTypeINDEX;

   returnValue = meiSqNodeDriveMonitorConfigSet(sqNode, 
                                                0, /* driveIndex */

   /* Get all monitor (A, B and C) values */
   returnValue = meiSqNodeDriveMonitor(sqNode, 
                                       0, /* driveIndex */

   /* Print monitorA value */
   printf("MonitorValueA: %ld\n", value.monitor[MEISqNodeMonitorValueIndexA]);

See Also



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