Skip to content

Commit 6f302e2

Browse files
committed
Merge branch 'master' of github.com:Miodec/deej
2 parents 11501e3 + 0525071 commit 6f302e2

File tree

4 files changed

+12
-212
lines changed

4 files changed

+12
-212
lines changed

README.md

Lines changed: 8 additions & 208 deletions
Original file line numberDiff line numberDiff line change
@@ -1,216 +1,16 @@
11
# In this fork
22

3-
This fork of deej adds remappable button support. Buttons must be defined in config with int values. The int values can be found https://github.com/micmonay/keybd_event/blob/master/keybd_windows.go (make sure to convert hex values to int)
3+
This fork of deej adds remappable button support. Buttons must be defined in config with int values. The key values can be found here: https://github.com/micmonay/keybd_event/blob/master/keybd_windows.go (make sure to convert hex values to int)
44

5-
# deej
5+
Be sure to visit the [original repository](https://github.com/omriharel/deej)
66

7-
deej is an **open-source hardware volume mixer** for Windows and Linux PCs. It lets you use real-life sliders (like a DJ!) to **seamlessly control the volumes of different apps** (such as your music player, the game you're playing and your voice chat session) without having to stop what you're doing.
7+
# Build
88

9-
**Join the [deej Discord server](https://discord.gg/nf88NJu) if you need help or have any questions!**
9+
![Finished build](https://i.imgur.com/neM2xle.jpg)
10+
![Finished build2](https://i.imgur.com/moRmNFJ.jpg)
1011

11-
[![Discord](https://img.shields.io/discord/702940502038937667?logo=discord)](https://discord.gg/nf88NJu)
12+
Mini build log: https://imgur.com/a/baIDppz
1213

13-
> **_New:_** [work-in-progress deej FAQ](./docs/faq/faq.md)!
14+
# Case files
1415

15-
deej consists of a [lightweight desktop client](#features) written in Go, and an Arduino-based hardware setup that's simple and cheap to build. [**Check out some versions built by members of our community!**](./community.md)
16-
17-
**[Download the latest release](https://github.com/omriharel/deej/releases/latest) | [Video demonstration](https://youtu.be/VoByJ4USMr8) | [Build video by Tech Always](https://youtu.be/x2yXbFiiAeI)**
18-
19-
![deej](assets/build-3d-annotated.png)
20-
21-
> _**Psst!** [No 3D printer? No problem!](./assets/build-shoebox.jpg)_ You can build deej on some cardboard, a shoebox or even a breadboard :)
22-
23-
## Table of contents
24-
25-
- [Features](#features)
26-
- [How it works](#how-it-works)
27-
- [Hardware](#hardware)
28-
- [Schematic](#schematic)
29-
- [Software](#software)
30-
- [Slider mapping (configuration)](#slider-mapping-configuration)
31-
- [Build your own!](#build-your-own)
32-
- [FAQ](#faq)
33-
- [Build video](#build-video)
34-
- [Bill of Materials](#bill-of-materials)
35-
- [Thingiverse collection](#thingiverse-collection)
36-
- [Build procedure](#build-procedure)
37-
- [How to run](#how-to-run)
38-
- [Requirements](#requirements)
39-
- [Download and installation](#download-and-installation)
40-
- [Building from source](#building-from-source)
41-
- [Community](#community)
42-
- [License](#license)
43-
44-
## Features
45-
46-
deej is written in Go and [distributed](https://github.com/omriharel/deej/releases/latest) as a portable (no installer needed) executable.
47-
48-
- Bind apps to different sliders
49-
- Bind multiple apps per slider (i.e. one slider for all your games)
50-
- Bind the master channel
51-
- Bind "system sounds" (on Windows)
52-
- Bind specific audio devices by name (on Windows)
53-
- Bind currently active app (on Windows)
54-
- Bind all other unassigned apps
55-
- Control your microphone's input level
56-
- Lightweight desktop client, consuming around 10MB of memory
57-
- Runs from your system tray
58-
- Helpful notifications to let you know if something isn't working
59-
60-
> **Looking for the older Python version?** It's no longer maintained, but you can always find it in the [`legacy-python` branch](https://github.com/omriharel/deej/tree/legacy-python).
61-
62-
## How it works
63-
64-
### Hardware
65-
66-
- The sliders are connected to 5 (or as many as you like) analog pins on an Arduino Nano/Uno board. They're powered from the board's 5V output (see schematic)
67-
- The board connects via a USB cable to the PC
68-
69-
#### Schematic
70-
71-
![Hardware schematic](assets/schematic.png)
72-
73-
### Software
74-
75-
- The code running on the Arduino board is a [C program](./arduino/deej-5-sliders-vanilla/deej-5-sliders-vanilla.ino) constantly writing current slider values over its serial interface
76-
- The PC runs a lightweight [Go client](./pkg/deej/cmd/main.go) in the background. This client reads the serial stream and adjusts app volumes according to the given configuration file
77-
78-
## Slider mapping (configuration)
79-
80-
deej uses a simple YAML-formatted configuration file named [`config.yaml`](./config.yaml), placed alongside the deej executable.
81-
82-
The config file determines which applications (and devices) are mapped to which sliders, and which parameters to use for the connection to the Arduino board, as well as other user preferences.
83-
84-
**This file auto-reloads when its contents are changed, so you can change application mappings on-the-fly without restarting deej.**
85-
86-
It looks like this:
87-
88-
```yaml
89-
slider_mapping:
90-
0: master
91-
1: chrome.exe
92-
2: spotify.exe
93-
3:
94-
- pathofexile_x64.exe
95-
- rocketleague.exe
96-
4: discord.exe
97-
98-
# set this to true if you want the controls inverted (i.e. top is 0%, bottom is 100%)
99-
invert_sliders: false
100-
101-
# settings for connecting to the arduino board
102-
com_port: COM4
103-
baud_rate: 9600
104-
105-
# adjust the amount of signal noise reduction depending on your hardware quality
106-
# supported values are "low" (excellent hardware), "default" (regular hardware) or "high" (bad, noisy hardware)
107-
noise_reduction: default
108-
```
109-
110-
- `master` is a special option to control the master volume of the system _(uses the default playback device)_
111-
- `mic` is a special option to control your microphone's input level _(uses the default recording device)_
112-
- `deej.unmapped` is a special option to control all apps that aren't bound to any slider ("everything else")
113-
- On Windows, `deej.current` is a special option to control whichever app is currently in focus
114-
- On Windows, you can specify a device's full name, i.e. `Speakers (Realtek High Definition Audio)`, to bind that device's level to a slider. This doesn't conflict with the default `master` and `mic` options, and works for both input and output devices.
115-
- Be sure to use the full device name, as seen in the menu that comes up when left-clicking the speaker icon in the tray menu
116-
- `system` is a special option on Windows to control the "System sounds" volume in the Windows mixer
117-
- All names are case-**in**sensitive, meaning both `chrome.exe` and `CHROME.exe` will work
118-
- You can create groups of process names (using a list) to either:
119-
- control more than one app with a single slider
120-
- choose whichever process in the group that's currently running (i.e. to have one slider control any game you're playing)
121-
122-
## Build your own!
123-
124-
Building deej is very simple. You only need a few relatively cheap parts - it's an excellent starter project (and my first Arduino project, personally). Remember that if you need any help or have a question that's not answered here, you can always [join the deej Discord server](https://discord.gg/nf88NJu).
125-
126-
Build deej for yourself, or as an awesome gift for your gaming buddies!
127-
128-
### FAQ
129-
130-
I've started a highly focused effort of writing a proper FAQ page for deej, covering many basic and advanced topics.
131-
132-
It is still _very much a work-in-progress_, but I'm happy to [share it in its current state](./docs/faq/faq.md) in hopes that it at least covers some questions you might have.
133-
134-
FAQ feedback in our [community Discord](https://discord.gg/nf88NJu) is strongly encouraged :)
135-
136-
### Build video
137-
138-
In case you prefer watching to reading, Charles from the [**Tech Always**](https://www.youtube.com/c/TechAlways) YouTube channel has made [**a fantastic video**](https://youtu.be/x2yXbFiiAeI) that covers the basics of building deej for yourself, including parts, costs, assembly and software. I highly recommend checking it out!
139-
140-
### Bill of Materials
141-
142-
- An Arduino Nano, Pro Micro or Uno board
143-
- I officially recommend using a Nano or a Pro Micro for their smaller form-factor, friendlier USB connectors and more analog pins. Plus they're cheaper
144-
- You can also use any other development board that has a Serial over USB interface
145-
- A few slider potentiometers, up to your number of free analog pins (the cheaper ones cost around 1-2 USD each, and come with a standard 10K Ohm variable resistor. These _should_ work just fine for this project)
146-
- **Important:** make sure to get **linear** sliders, not logarithmic ones! Check the product description
147-
- You can also use circular knobs if you like
148-
- Some wires
149-
- Any kind of box to hold everything together. **You don't need a 3D printer for this project!** It works fantastically with just a piece of cardboard or a shoebox. That being said, if you do have one, read on...
150-
151-
### Thingiverse collection
152-
153-
With many different 3D-printed designs being added to our [community showcase](./community.md), it felt right to gather all of them in a Thingiverse collection for you to browse. If you have access to a 3D printer, feel free to use one of the designs in your build.
154-
155-
**[Visit our community-created design collection on Thingiverse!](https://thingiverse.com/omriharel/collections/deej)**
156-
157-
> You can also [submit your own](https://discord.gg/nf88NJu) design to be added to the collection. Regardless, if you do upload your design to Thingiverse, _please add a `deej` tag to it so that others can find it more easily_.
158-
159-
160-
### Build procedure
161-
162-
- Connect everything according to the [schematic](#schematic)
163-
- Test with a multimeter to be sure your sliders are hooked up correctly
164-
- Flash the Arduino chip with the sketch in [`arduino\deej-5-sliders-vanilla`](./arduino/deej-5-sliders-vanilla/deej-5-sliders-vanilla.ino)
165-
- _Important:_ If you have more or less than 5 sliders, you must edit the sketch to match what you have
166-
- After flashing, check the serial monitor. You should see a constant stream of values separated by a pipe (`|`) character, e.g. `0|240|1023|0|483`
167-
- When you move a slider, its corresponding value should move between 0 and 1023
168-
- Congratulations, you're now ready to run the deej executable!
169-
170-
## How to run
171-
172-
### Requirements
173-
174-
#### Windows
175-
176-
- Windows. That's it
177-
178-
#### Linux
179-
180-
- Install `libgtk-3-dev`, `libappindicator3-dev` and `libwebkit2gtk-4.0-dev` for system tray support. Pre-built Linux binaries aren't currently released, so you'll need to [build from source](#building-from-source). If there's demand for pre-built binaries, please [let me know](https://discord.gg/nf88NJu)!
181-
182-
### Download and installation
183-
184-
- Head over to the [releases page](https://github.com/omriharel/deej/releases) and download the [latest version](https://github.com/omriharel/deej/releases/latest)'s executable and configuration file (`deej.exe` and `config.yaml`)
185-
- Place them in the same directory anywhere on your machine
186-
- (Optional, on Windows) Create a shortcut to `deej.exe` and copy it to `%APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup` to have deej run on boot
187-
188-
### Building from source
189-
190-
If you'd rather not download a compiled executable, or want to extend deej or modify it to your needs, feel free to clone the repository and build it yourself. All you need is a Go 1.14 (or above) environment on your machine. If you go this route, make sure to check out the [developer scripts](./pkg/deej/scripts).
191-
192-
Like other Go packages, you can also use the `go get` tool: `go get -u github.com/omriharel/deej`. Please note that the package code now resides in the `pkg/deej` directory, and needs to be imported from there if used inside another project.
193-
194-
If you need any help with this, please [join our Discord server](https://discord.gg/nf88NJu).
195-
196-
## Community
197-
198-
[![Discord](https://img.shields.io/discord/702940502038937667?logo=discord)](https://discord.gg/nf88NJu)
199-
200-
deej is a relatively new project, but a vibrant and awesome community is rapidly growing around it. Come hang out with us in the [deej Discord server](https://discord.gg/nf88NJu), or check out a whole bunch of cool and creative builds made by our members in the [community showcase](./community.md).
201-
202-
The server is also a great place to ask questions, suggest features or report bugs (but of course, feel free to use GitHub if you prefer).
203-
204-
### Donations
205-
206-
If you love deej and want to show your support for this project, you can do so using the link below. Please don't feel obligated to donate - building the project and telling your friends about it goes a very long way! Thank you very much.
207-
208-
[![ko-fi](https://www.ko-fi.com/img/githubbutton_sm.svg)](https://ko-fi.com/omriharel)
209-
210-
### Contributing
211-
212-
Please see [`docs/CONTRIBUTING.md`](./docs/CONTRIBUTING.md).
213-
214-
## License
215-
216-
deej is released under the [MIT license](./LICENSE).
16+
Case files available in the [/models](https://github.com/Miodec/deej/tree/master/models) directory

arduino/deej-5-sliders-vanilla/deej-5-sliders-vanilla.ino

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,20 +42,20 @@ void sendSliderValues() {
4242
builtString += String((int)analogSliderValues[i]);
4343

4444
if (i < NUM_SLIDERS - 1) {
45-
builtString += String("\t");
45+
builtString += String("|");
4646
}
4747
}
4848

4949
if(NUM_BUTTONS > 0){
50-
builtString += String("\t");
50+
builtString += String("|");
5151
}
5252

5353
for (int i = 0; i < NUM_BUTTONS; i++) {
5454
builtString += "b";
5555
builtString += String((int)buttonValues[i]);
5656

5757
if (i < NUM_BUTTONS - 1) {
58-
builtString += String("\t");
58+
builtString += String("|");
5959
}
6060
}
6161

@@ -73,4 +73,4 @@ void printSliderValues() {
7373
Serial.write("\n");
7474
}
7575
}
76-
}
76+
}

models/deej2body.stl

79.8 KB
Binary file not shown.

models/deej2top.stl

119 KB
Binary file not shown.

0 commit comments

Comments
 (0)