VolCon

Updated 31 March 2022

This project began as an experiment when I inexplicably decided to learn how an optical rotary encoder worked (FYI, 2-bit gray code). It transformed into a learning experience around USB - specifically the HID protocol. Ultimately I ended up with a simple gadget that now sits on my desk and allows me to control the PC volume. A salvaged optical encoder was used to detect rotation along with a reclaimed head drum of a VCR which was repurposed as a control knob.

Key concepts for the project were:

    • The optical encoder parts (sensors and disk) were salvaged from an old track-ball.
    • The "knob" was made from the head drum of a VCR (remember those?). I liked it because of the smooth bearings - it spins forever. This is the part that spins and is used to adjust volume on my PC.
    • The optical disk was fixed to the shaft and optical sensors mounted off some strip-board and attached to the base of the vcr head.
    • This assembly is mounted to a custom PCB with some nylon stand-offs. The PCB became the base of the whole unit.
    • Some wooden rings were cut to enclose the electronics and the base of the vcr drum.
    • The custom PCB was designed in eagle and etched at home from some single-sided copper-clad board. The circuit was designed around an AVR at90usb162. The code is written in C and implements the LUFA library developed by Dean Cameron.
    • The whole unit plugs into a PC via USB and is automatically identified as a HID - no drivers required (tested in Debian Linux and Windows). It's a very simple device - rotate clockwise to increase volume, counter-clockwise to decrease.
    • Code and PCB design are available via github. Here are some reference links:

Here's the completed device. You can just make out the USB port on the lower right:

An inside view; note the rotary encoder:

This is the underside of the PCB - DIY designed and etched. Just the SMD Atmel chip is soldered on this side:

Attachment - Project Files

Have a question? Ask the Author of this guide today!

Please enter minimum 20 characters

Your comment will be posted (automatically) on our Support Forum which is publicly accessible. Don't enter private information, such as your phone number.

Expect a quick reply during business hours, many of us check-in over the weekend as well.

Comments


Loading...
Feedback

Please continue if you would like to leave feedback for any of these topics:

  • Website features/issues
  • Content errors/improvements
  • Missing products/categories
  • Product assignments to categories
  • Search results relevance

For all other inquiries (orders status, stock levels, etc), please contact our support team for quick assistance.

Note: click continue and a draft email will be opened to edit. If you don't have an email client on your device, then send a message via the chat icon on the bottom left of our website.

Makers love reviews as much as you do, please follow this link to review the products you have purchased.