¿ªÔÆÌåÓý

ctrl + shift + ? for shortcuts
© 2025 Groups.io

Odd PCB design [1 Attachment]


Jim Hughen
 

¿ªÔÆÌåÓý

Note:? This encoder appears to be binary which is not a "unit distance code".? May have trouble reading.? Try a gray code maybe.
?
...Jim
?

----- Original Message -----
Sent: Monday, January 17, 2011 8:04 PM
Subject: [kicad-users] Odd PCB design [1 Attachment]

?

Hi

I¡¯m making a PCB design with PCBNew and I have the need to design the electrical part of a rotary encoder in the PCB (see the attached drawing).

I¡¯m new to Kicad, and I¡¯ve been trying with the PCB designer and even tried the module (footprint) editor, but wasn¡¯t able to do it.

Even considered editing a ¡°.mod¡± file by hand (took a look at one and it seems possible).

Do you have any suggestions on how to do it, or any documentation on the ¡°.mod¡± file so I can try editing it by hand?

TIA

Best regards

Jorge Ferreira


 

Off topic reply (about rotary encoder design):

Jorge, if you are designing a conventional 24-position rotary switch, your design should work OK. However, if you are trying to determine a shaft position in a _continuous_ range to the nearest 15 degrees, your rotary encoder design will not work reliably because it will give incorrect codes when the encoder sensors are lined up exactly on a boundary between the 15 degree sectors. For example, at the boundary between 10111 and 00000, the sensors might report 10111, 00000, 10000, 00110, etc.

To make a rotary encoder that works over a continuous range, you can use Gray code. See You can use a 32-entry lookup table to quickly convert the Gray code to binary.

Cheers,
- Jan