Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
use of Sys.pushm
As I understand it Sys.pushm can be used as a convenient method of disabling inputs and outputs, ie:


Am I correct that this is OK? My worry is that an output such as Motor[2].pDac will put data into this address which will then be read by "unused" inputs also pointing to Sys.pushm.
At re-initialization, motors that do not have hardware channels auto-assigned to them have input and output pointers assigned to the register at the Sys.pushm address. These motors are not activated, so the register is not actually addressed.

If you have an active motor, and want to assign an output to a do-nothing, harmless register, Sys.pushm is a good choice.

As for inputs, you do want to be a little more careful, I think. Safety flag inputs like pLimits, pAmpFault, pEncLoss, and pAuxFault are better just set to 0 to disable the function altogether. I'm not sure why you would want to redirect position input pointers.

Forum Jump:

Users browsing this thread: 1 Guest(s)