Unless you have some other way of knowing which way it's going, I don't think you can.

If it needs to keep track of absolute position in both directions, you'll probably need a "Quadrature Encoder".
<br>