loading

Ever wished for a giant volume knob? I have! So I thought I'd have a go at making one and share it in my first Instructables project.

I had 2 goals:

  • Adjust volume (Up/Down/Mute)
  • Switch playback devices

The Solution: A giant volume knob!

To make things easy I went with using an Arduino ATmega32u4 board. Which can be recognised as a USB HID keyboard (using the NicoHood HID Library).

SoundSwitch is a great lightweight software for playback device switching. It provides a simple UI for set up and has the perfect functionality - shortcut macro keys to switch device, which can easily be emulated by the Arduino.

Step 1: What You Will Need

Software

Materials - Electronics

Materials - Case

  • Giant volume knob
  • Aluminium U-Channel (15mm square)
  • Aluminium sheet (2mm thick)
  • Screws & Rivets

Step 2: Getting the Electronics Ready

Testing the circuit

As always I would suggest testing the circuit on a breadboard before moving on to soldering. The last thing you'd want to have to do is desolder everything!

Pin layout reference:

  • Encoder Pin A -> Pin 2
  • Encoder Pin B -> Pin 3
  • Switch -> Pin 5
  • SoundSwitch Button -> Pin 4
  • HID Switch/Jumper -> Pin 6

*If you find your encoder is reversed, just swap pins A&B on the board or the pinout in line 22 of of the sketch :

Encoder knobVol(2, 3);  // VOLUME KNOB 


Making the circuit

Depending on the encoder and enclosure you are building, it might be a good idea to have a daughter board for the encoder. The encoder in this build is a very common 12-step encoder. It does not have a mounting thread around the shaft. So I built a little daughter board with a pull down resistor for the switch and some standoffs for mounting.

The Arduino board I used is a cheap version of the Arduino Pro Micro 3.3V/8MHz, I managed to get a bunch of them from aliexpress.com for <$10. Instead of a switch, I opted to use a bent wire jumper as this pin won't need to be toggled very often.

Step 3: Setting Up Software

Programming the Arduino

Before uploading the sketch, there are some dependencies you'll have to take care of.

  • HID-Project by NicoHood
  • Encoder by Paul Stoffregen

These libraries can be installed directly through the Arduino IDE: Sketch > Include Library > Manage Libraries. Once that is set it should compile and upload without a hitch. If you need to re-upload a sketch, setting the main HID switch to off will make it easier for the Arduino to be recognized.

Installing/Setup of SoundSwitch

Setup is very simple, download and install the latest release of SoundSwitch.

Choose your playback devices and other settings by right clicking on the SoundSwitch icon and going into settings. Make sure to check the "Run on Startup" checkbox, then you're ready to go!

Step 4: Make the Case

*This enclosure was made to match the aesthetic of my PC.

I decided to build a very basic enclosure using bits of aluminium I had lying around.

It is made up of 15mm Square U-Channel pieces cut into rabbet joints then sandwiched between two sheets of 2mm aluminium.

A great way to cut sheet materials is to use a paper template, just print out a 1:1 of your design and stick it to your sheet. This provides a nice guide for your lines and drill holes to help keep things accurate. I've attached the template I used, it was made using cadstd.

I do not recommend making the enclosure as short as I did. The tolerances were very tight. Also it could be wise to remove some of the unnecessary overhang from the U-Channel to give yourself more room.

JB Weld epoxy and rivets were used to fasten the bottom plate to the U-Channel. The same epoxy was used to fill in gaps at the joints. The top plate is held down with screws that have been tapped in to the base, this way it can be taken apart as needed.

Painting

I was aiming for a durable matte finish.

  • 2 coats epoxy primer
  • 2 coats enamel
  • 1 coat clear coat

When spray painting it is best to do light passes and let paint build up slowly. A light sanding with high grit sandpaper after the first enamel coat could yield a cleaner result.

Feet

To stop your enclosure from sliding you will need to add some form of grip to the bottom. I got very lucky and found these black rubber screw covers that I am using as feet. They fit perfectly over the rivets on the underside of my enclosure. Grip tape, thin foam/rubber were some of the other possibilities.

Step 5: Put It All Together!

Mush it all in there!

Having a semi modular design really helps at this point. Makes taking apart and putting together a lot easier. Be sure to insulate anything that could short! Hot glue and tape are your friends here.

Thoughts / Suggestions

    • Having a heavy base is great! Especially if you have buttons mounted on the side like I have done.
    • Using an Arduino is a bit overkill for this build. Another possible way to go would be to use a Micro USB Digispark, or other micro controller that can run the HID profile. This would help to miniaturize the enclosure.
    • The key combination currently set for SoundSwitch is Crtl+Alt+f11 (default). This can be changed in code line 80-84. Adding a button for switching default recording device can be achieved through the same structure used for play back device.
    • There is a lot of extra IO. This leaves space for additions like LEDs (fade with PWM?) or other buttons and controls.
    • If you are adding buttons I would recommend using a debounce library instead of boolean states like I have.

    Hope this instructable was helpful! Please do let me know if you make your own Giant Volume Knob or have any questions/suggestions :)

    <p>Cool Thing!</p><p>Can you say how can i read out the actual volume?</p><p>And can i control the Mic Mute?</p><p>It woult be helpfully...</p>
    <p>Looks cooool.I had not built it yet. But will begin buit it soon. First let me collect the electronic &amp; other hardware. I think www.aliexpress.com is excellent e-commerce website to buy all stuff required to built a electronic project with low cost.I had just searched for &quot;volume knob&quot; &amp; there was great cool small and large knobs. Aliexpress provide international shipping. Only thing is that you have to wait a bit long for delivery. Just search for &quot;Encoder&quot; &amp; you will find many cheap one&gt;</p>
    <p>After all I decided to use the Leonardo Micro and was excellent! Thank you for the tutorial!</p>
    <p>Well done! What does the LED indicate?</p>
    <p>Currently it flashes to indicate that the arduino not crashed. I'm thinking of putting more LEDs and buttons to aid in application development (repetitive tasks like compilation).</p>
    <p>Hello! Congrats for this amazing project!</p><p>I'm trying to make my version, but somehow I'm in trouble with ino code:</p><p><strong>#error &quot;Encoder requires interrupt pins, but this board does not have any :(&quot;</strong></p><p>That's my first time using HoodLoader2, so ANY tips would help a LOT!</p><p>Thanks in advance!</p>
    <p>I figured out that my mistake was using Arduino Uno.</p><p>I will try a solution proposed in this link: http://forum.arduino.cc/index.php?topic=274386.0</p>
    <p>Does changing the firmware remove the interrupt pin access? Hope your project works out! Easiest solution would be to switch boards to something that is compatibable without modification</p>
    <p>I did it and was infinitely easier. Thank you!</p>
    <p>Where do I get that knob!??!?</p>
    <p>I found mine on eBay, large aluminium volume knob. Not sure if I can link to products here</p>
    Thanks! I just bought some!
    <p>http://www.ebay.com/itm/1PC-30-17mm-Black-Anodized-Machined-Solid-Aluminum-DVD-Potentiometer-Volume-Knob-/321441068287?hash=item4ad76174ff:g:lZQAAOSwZ8ZW6VsR</p>
    <p>If you can find the item again, just copy/paste the URL, like above.. some of the other instructables have links to their items too, as well as others pointing to optional sources the same way. I imagine you can also add the IR library, and add additional control with a IR remote, as well as the local volume control. Simply add the key-code to the same controls as the encoder (up/down) and mute button. Nice job!!!</p>
    <p>Updated the first step with links to some of the items :)</p>
    <p>You can copy and paste url's no problem.</p>
    <p>I love it! Definitely on my to do list now. I really miss the manual knob.<br>A while back I made this as a homage to the missing volume knob:<br>https://www.instructables.com/id/Turn-Up-the-Bracelet/</p>
    <p>Great job looks awesome!</p>
    <p>how do you download soundswitch for mac?</p>
    <p>Currently I don't have an answer to this :( Although a commentor below did mention there being a few soudswitch type applications for mac out there</p>
    <p>So I was thinking you could add some flair (lol, 10 pieces of flair minimum*quote from a certain movie*) by cutting the sides of the enclosure out of some clear acrylic and adding a few LED's of your choice of color inside. Since the connection is going to be USB, 3.3 volts should be no problem to power a few LED's. Not to mention the clear acrylic sides would allow everyone to see your excellent handiwork inside the enclosure. </p>
    <p>If you could just get around to reading the Instructable about adding LED's, that'd be greeeeaaaat...</p>
    <p>Sorry, didn't make it to the end of your Instructable about adding LED's. </p>
    <p>Would this work on a Mac?</p>
    <p>The Volume control part will work as it is a HID, but SoundSwitch application won't run on OSX. You could find an alternative and use the same macros?</p>
    OK, thanks, that's what I wanted to know. Looks like there are several SounSwitch type applications for the Mac.
    <p>For Macs check out the Powermate - https://griffintechnology.com/us/powermate</p>
    <p>Wow I do like the design. Not sure if I will make one right off, however I think I have most of the parts in my box. Not quite that large of button but a fairly big one that would do I believe. I can see other uses for this, so I am going to put it in my favorites for future use. Thanks a million for your hard work and imagination. Without witch, this would be a very boring world indeed.</p>
    <p>Thanks for reading!</p>
    <p>Hey I was thinking about making one of these and realized that I only have a potentiometer as opposed to the rotary encoder that you used. </p><p>Do you think that it would still work?<br></p>
    <p>Will not work at all. Potentiometer and Rotary encoder are quite different components. Encoders are fairly common components, the one I used was pruchased through sparkfun :)</p>
    <p>Nice project.</p><p>How do you add the libraries to make IDE recognize them?</p>
    <p>Thanks! As in step 3, you can download them through the IDE by going to the menus Sketch &gt; Include Library &gt; Manage Libraries and searching for the two libraries mentioned</p>
    <p>Got this error &quot;Error compiling for board Arduino/Genuino Uno&quot; Is my board not compatible? Its a genuine Uno board..</p>
    <p>Yes. Uno can't do the HID profile, unfortunately you'll need one with the ATmega32u4 chip. Such as Arduino Leonardo or Micro</p>
    <p>This is pretty cool. Not as nice and polished as the Powermate (the Powermate (https://griffintechnology.com/us/powermate) but it could be a good substitute for Windows since Powermate doenst support Windows any more. (They used to, but now seem either unable or unwilling to do so, very strange for such large market)</p>
    <p>I have a powermate running on windows 7 with the same old controler with no problems.</p>
    <p>Hey, its /u/-Tilde here, from reddit. Just wondering if you had to use a primer or any special paints?</p>
    Hi Mr_Bablae,<br>I just noticed your comment and remembered that the indestructible maker did mention painting:<br><br>&quot;Painting<br><br>I was aiming for a durable matte finish.<br><br> 2 coats epoxy primer<br> 2 coats enamel<br> 1 coat clear coat<br><br>When spray painting it is best to do light passes and let paint build up slowly. A light sanding with high grit sandpaper after the first enamel coat could yield a cleaner result.&quot;<br><br>Hope this helps :)
    OK, thanks!
    You're welcome to my aid :)
    looks great ?
    <p>You're not sure?</p>
    Isn't that VHB tape bit of an overkill? :D
    <p>Haha yes! The board is not going anywhere...</p>
    That's awesome man, great instructions too! My only question, do you think there's a way to carry out audio device switching using something more native like PowerShell or vb? This would save on having an extra program running all the time (also the audio switcher software I used to use wasn't 100% reliable).
    <p>Thats a great idea! I actually did have a quick look before I started and couldn't really figure out simply how I'd trigger it silently from the Arduino as a HID device.</p>
    Ahh yeah good point. Last I checked for PowerShell commands (mid 2015) I couldn't find anything but the w10 anniversary update added much easier audio device switching on the interface, here's hoping there's a PowerShell api or wmi object for us to use!
    With regards to the resistors, are they 2k or 20k? The &quot;Materials- Electronics&quot; portion has it as &quot;2k0&quot;.
    <p>Oh whoops! I was using European notation, so 2k0 = 2.0k&Omega;. </p>

    About This Instructable

    49,244views

    499favorites

    License:

    More by alizaliz:Giant USB Volume Knob 
    Add instructable to: