Does anybody know of a ready made six channel PGA2311 kit for control by Pi, ESP32 or Arduino?

I need a way to control independent volume to the active subs and the two power amps on my boat. Main volume will still be the headunit. I have seen lots of prebuilt PGA2311 kits on Aliexpress and eBay with IR remote controls, but IR control is slow and imprecise, when the IR signal has to come from an ESP. The volume control will be in a sealed IP67/68 box under the dashboard. The main thing is that I must be able to reduce volume on the subs almost instantly, when running playlists and something with too much bass comes on that makes them distort and can damage them. So does anybody know of such a kit where I can program the controlling unit to "jump x dB down" and then fine tune it after that?

Here's an example on the IR remote type:
https://www.aliexpress.com/item/1005005548879854.html
I assume that it's not possible to hook up a Pi, ESP32 or Arduino to that. I would prefer Pi or ESP32 control, since I have never worked with Arduino, but if Arduino is the only option I will try to find out how I do it with that.

Also I am not good enough to solder to use a kit, I manage to replace keys on my Matias Ergo Pro keyboard (they are quite regularly worn out), but that's as far as I can go with my tools and hands.

This is one of the two possibilities I have, I am also going to see if I can use USB sound cards, Pi's and CamillaDSP for this, but I want to test the two solutions against each other and see what works best.
 
Last edited:
There are so many things on the diyAudio board that I had no idea excisted! I'm wondering if the easiest thing, at least for now, would be to use a two channel motorized ALPS potmeter for each amp and control the motor on that with an ESP32 relay. I wonder if that's possible. Note: I'm running two parallel threads here for the two different approaches I'm considering, CamillaDSP and simple volume control. The other one is here:

https://www.diyaudio.com/community/...rossovers-room-correction-etc.349818/page-202
 
1 - usual way would be a H bridge rather than relay.
2 - consider a fixed attenuator for the subs which could be switched by a single pole relay (dp relay could switch 2 subs) as it would be either in or out of circuit.
This would give you the fixed dB reduction: normal level operation / reduced level operation.
3 - AFAIK motorized pots do not have positional feedback so Arduino would not know how far to move.
 
Thank you for answering! I want adjustable volume for the subs not just a failsafe, I like to keep them just below distortion level (I'm a big bass man for my progmetal). But no, you're right, the pots do not have positional feedback. But would they work for adjusting the level? I can simply send tree seconds down volume with one button and then have another button that increases for one second. That way I can go down quickly and adjust more carefully up. It's not a directly "jump to", but it seems like a simple way.

As for the H Bridge (had to google that one, never heard about that before...) do you mean that driving potmeters would need that, or was that for the PGA2311?
 
First observation: Building something as specific as you want it to be from ready-made HW components is going to be quite difficult, so maybe the best solution would be to starting to improve your soldering skills and/or finding someone to help you with that part?

Second observation: When I read what your "real" need is, you want to attenuate the volume at the press of a button. For that you fundamentally only need to be able to "add" a button to an interrupt-capable pin on the controller and then modify the control code so that the interrupt triggers a reduction of volume by a fixed amount? The board you link to has an onboard microcontroller to drive the PGA chip, but if you do a real DIY-solution you can substitute an ESP/RPi/Arduino controller of your own choosing - and include your own IR receiver, button control etc. The interface to the PGA-ICs is SPI and there are quite a few code examples online to show how it works.

Last observation: The H-bridge is to control the motor on the Alps pots, because you can then get the motor to run in both directions to change volume up/down. Positional feedback on a rotary pot is possible if you have a spare potentiometer deck (i.e. you need a 4-channel pot for stereo) and an analog input port on your controller (ESP/RPi).
 
I assume that it's not possible to hook up a Pi, ESP32 or Arduino to that. I would prefer Pi or ESP32 control, since I have never worked with Arduino, but if Arduino is the only option I will try to find out how I do it with that.

Also I am not good enough to solder to use a kit, I manage to replace keys on my Matias Ergo Pro keyboard (they are quite regularly worn out), but that's as far as I can go with my tools and hands.

This is one of the two possibilities I have, I am also going to see if I can use USB sound cards, Pi's and CamillaDSP for this, but I want to test the two solutions against each other and see what works best.

It is very much possible to hookup a PI or ESP32 with the mentioned KIT, all you have to do is pull out the micro controller, and hook up the PI/ESP32 with the KIT. If I remember right PGA231x have an SPI interface and cascaded.

So if you could hook up the PI/ESP32 and write up the code it is very much possible to do what you want to. Although IR is comparatively slow but if you program well instead of linear increase/decease in volume/bass etc you can program it in the form of jumps -16 db, 0db, etc.

The other option is that you already have a bass/tone control then you could replace the pots with either motorized ALPS pots or design one around AD8402/8403, this way you can control 6 channels in total all independently, but that will require designing the circuit, programming PI/ESP32, making a PCB lot of SMD type solder and then replacing the original pots.

Lots of options are available but they all depend how much time you are willing to invest and how much effort you want to put in.
 
@Nisbeth Thanks for answering! For the first observation, I would have to find somebody, I have tried on more advanced soldering before and made a total pigs breakfast of it, after spending 2000 kroner on soldering equipment. That went out on Finn (Norway's version of DBA) pretty soon! But I figure if I buy one of those ALPS I could just "jump" into the connection that powers it, with power from relays on the ESP, one relay for up and one for down.

The second: No, not really. I am looking for something that lets me control the volume whenever I want to. The "downjump" is for emergencies, but normally, I would fine tune the volume of the subs to get the sound I like. I will be using these manette knobs for the adjustment, one in the front, where I fish, and one in the back, where I drive the boat back and forth:

1687176260067.png


But if I can use code laying around the web for that Aliexpress board, that seems like a very tidy, ready made solution, by adding an ESP! The only thing is do I have to get the ESP soldered to the board to make it work? Or are there boards that are easy to add an ESP to?

Last observation: Sneaky! Very sneaky! So I use an ampmeter like the I2C to measure the second channel's resistance to see where the potmeter is, right? That would mean six stereo potmeters (one for each subs and two each for the other channels). With this solution will it matter what electrical noise the boat motor creates? Will the potmeter only use power to drive it up and down, not in the signal chain? Also, this is a solution where I can start with just the subs and then build it out if I like the way it functions. If it works that way I think I will try the ALPS way first, by getting one of the stereo controllers with as little extra stuff as possible and see if I can make it behave the way I want to.

@rehanabid Thanks to you too! I'm afraid I didn't understand much, except for "it is very much possible", which probably tells you something about how much I know about this field... But I guess that's something of the same as the previous answer, right?

Edit: I found this one on eBay: https://www.ebay.co.uk/itm/113521392539 There's a connector named "relay", but not explained in the page. Could it be that it is to send in power there and turn the volume up and down?
 
Last edited: