John Scherer came across an interesting, i2c addressable rotary encoder board that allows you to connect encoders in just about any configuration.
The board has pins for digital or ADC I/O, has 256 bytes of eeprom, pads for setting each encoders i2c address, and works from 3.3 – 5V DC. For something like the µBitx, this could be an easy way to add additional physical I/O (i.e. knobs).
There is also a video that gives a pretty good overview of how they work.
John VK2ETA suggests that on a read of the manual it appears the 256 registers are at one I2C address, and are divided between control registers and EEPROM addresses (two banks of 128 bytes).
The current implementation has the current modes for the encoder:
A. Relative, where the counter keeps the number of steps since last read. Reading it resets the counter to zero. Useful for frequency tuning in our case.
B. Absolute
B1. Without limits.
B2. With user defined limits
B2.1. No wrap around, like a potentiometer, hard stops at the limits.
B2.2 With wrap around, goes back to low limit if high limit is exceeded and vice-versa.
The encoder push button events are:
– button down
– button up
– double-press with user selectable double-press interval.
Current consumption is listed at less than 2mA plus LED current if used.
The board mounted PIC controller’s program is open source so it can be customized as well.
Tom, WB6B believes they keep a counter in the PIC chip that is on each board, so each time you check the status of an encoder board it will tell you how many encoder pulses took place since the last time you polled the data. This should greatly relax any timing issues.