Each magnetic encoder contains a magnetic ring and Hall detection circuit, and outputs two square waves. Encoder wiring instructions Encoder power: DC5V. Green line : encoder power negative GND. Blue line : The encoder power is positive VCC(5V cannot be mistaken, otherwise it will burn out).
eBay