Instructables

Creating a Bluetooth wireless scrollwheel

I find it difficult to use those builtin mousewheel scrollers, and even the two-finger scroll gesture can be inconvenient at times.  After discovering the Bluefruit EZ-Key and seeing the USB Volume knob project, I knew what I had to do.

After liberating a rotary encoder and weighted knob from an old USB sound board that no longer worked, I started soldering.  

Edit: The code and Fritzing diagrams are available at https://github.com/rmd6502/BluetoothEncoder .  Note that the Fritzing sketch shows a Trinket 5v, this is incorrect - it needs to be a Trinket 3.3v
 
Remove these adsRemove these ads by Signing Up

Step 2: Programming

Picture of Programming
Leave the battery pack off for now - you only want to power the board from one source.

Plug a USB cable into your computer and plug it into the Trinket.  You should see the red LED pulse - if it just comes on then the board wasn't detected by the computer.  Try with a different cable, that seems to matter.  You can also try plugging it in through a hub, people have had better luck with that.

You will need to download and install the special version of Arduino for the Trinket, or perform the steps listed in the tutorial to add Trinket support to you existing installation.  You'll also need the SoftwareSerial and Rotary Encoder libraries.  These should be placed in the appropriate libraries directory for your OS and installation.

Next, uncompress the attached zip file to your Arduino sketch directory, open it, and program the Trinket.  If this succeeds, you are ready for the next step.

Step 3: Pairing to your computer

This step will vary depending on your OS and installation.  Thus I refer you to the instructions for the EZ-Key, where they are thoroughly covered with walkthroughs.

Once you're paired, you should be able to scroll with the rotary encoder, and click the mouse by pressing the button.
Pro

Get More Out of Instructables

Already have an Account?

close

PDF Downloads
As a Pro member, you will gain access to download any Instructable in the PDF format. You also have the ability to customize your PDF download.

Upgrade to Pro today!