nMotorEncoder write clarification
It was my understanding that the nMotorEncoder could be written to in order to pre-set the value of the encoder. This is important because I built a circuit to swap between two different motors that share the same port. I would like to be able to read the value of the motor encoder right before the swap, store it in an array, then track the second motor's progress using the encoder. When it is about to swap back, it stores the latest encoder position to a second array element and RE-Initializes the nMotorEncoder with the first motors last position prior to the first swap. (This way neither motor looses the last known position of it's encoder.) I have all of the code written and the circuit built, but I can't seem to get the nMotorEncoder to re-Initialize to the stored value.
Should this be able to function with this code? Is there another way to assign the Encoder a value from a variable?
Any help would be much appreciated.