Patent ID: 7548306

Claim:
An optical encoder for detecting a speed of a moving member, comprising: a sensor module including: a light emitting member configured to emit light, a light receiving member opposed to the light emitting member in a first direction to receive the light emitted from the light emitting member, and at least one boss; a shade member having a shading pattern, which has a light shielding portion and a light transmitting portion and which is located between the light emitting member and the light receiving member to block the light, wherein one of the sensor module and the shade member moves together with the moving member so that the sensor module detects the speed of the moving member; and a first support configured to support the sensor module, including: at least one recessed portion, which is engaged with the at least one boss to support the sensor module, and a guide groove, which is connected with the at least one recessed portion and which extends in a second direction, wherein the sensor module is attached to the first support by being moved in the second direction while the at least one boss is guided by the guide groove, and wherein the at least one recessed portion has a depth in the first direction greater than a height of the at least one boss, and at least a portion of the guide groove adjacent to the recessed portion has a depth in the first direction less than the height of the at least one boss.