Arduino controled HIFI Preamp

Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.
Hello everyone

I am new to the world of microcontrolers. I am working on a HIFI Pre AMP to run a power Amp I built few years ago. I got an Arduino Mega off ebay that came with a ks0108 128*64 GLCD screen. I want to create a menu to select different sources (CD DVD Radio etc) and use a rotary encoder to select items from the menu. I have found lots of sample code for doing this with a standard 20x2 LCD, but nothing for using my big GLCD. Can someone please point me in the right direction. Also I would like to create a volume level display and remote control. This is a sample of what I would like to do, only on bigger screen. http://www.youtube.com/watch?v=EZigza0sSOc

I have been thinking it would also be fun to create a spectrum analyzer on this display.

Thanks in advance for all your help
 
diyaudio is not the best place to discuss Arduino, since you questions have nothing to do with audio. Go to Arduino: Forum, you should be able to find help there.

I could not disagree with you more!

Diyaudio needs to start a section to incorporate digital control of audio systems.

I just finished helping a friend to control his home theater system by using a logictec $250 controller. The Dennon Rec/controller switch was a pain, ALL digital controls and running everything from the TV to the cable box to the DVD blue ray etc. etc.

Digital is the future. Trust me.:p

I am currently working on a Arduino system to control power, track voltages and monitor temperature around the power amp system.:D
 
You are not out of place at all & there is a member here who uses Arduino uCs all the time & has advanced his control of his DAC & preamp with them. Just ignore the people who have nothing better to do than crap on somebody's genuine inquiry - there seems to be a lot of these sorts haunting this forum.

The member you want to make contact with is glt & his forum is H I F I D U I N O . he has posted his code & I would bet that it does exactly what you want with maybe a tweak or two. Good luck with it & all we (most of us) would ask you to do is feed back your progress & findings to the DIYA community as this is how knowledge is advanced (for those that are interested in such)!
 
Member
Joined 2009
Paid Member
Whoa, don't get emotional, guys, and please don't crap on my genuine attempt to help by providing relevant links.

ialpha wants to connect a graphic LCD to an Arduino. This task is not audio-specific, so I pointed to a direction where someone has already accomplished that. I agree with ialpha that members of Arduino Forum are less responsive then we are here at diyaudio, but they do have a lot of solutions and code posted. Specifically, my first search of "KS0108" gave me this announcement: Graphic LCD (KS0108) library now available, which led me to KS0108 Graphics LCD library. Reading the original post, it looks like it solves the problem. There are also some discussions about connecting GLCD specifically to Arduino Mega.

The HIFIDUINO has nothing about GLCDs, although there is a lot of audio-specific stuff like controlling Wolfson DACs, which I personally am very interested in. Thank you jkeny for sharing the link!
 
Last edited:
Sorry Alexcp, if I over-reacted to your directing ialpha away to the Arduino forum but I thought glt's code was relevant to him & he use a rotary encoder in his code & a screen. I also get a bit fed up with the stock response in this forum to notions/ideas that are in any way out of the mainstream/accepted norms (whatever they are) & it has maybe sensitised my antennae. In this case I was wrong, sorry!
 
Last edited:
ialpha, the arduino forums are not too helpful with vague descriptions of projects but if you have a very specific problem, like interfacing with particular hardware or coding they are excellent.

I'm definitely interested in your project so keep us updated as to how it goes! I'm working on something similar:
http://www.diyaudio.com/forums/anal...i2c-relay-selector-attenuator-tube-stage.html
Just waiting to finish some case work at the moment.
 
I'm glad to see more interest in Arduino. The diyaudio people have been slow in adopting software in this mainly hardware oriented hobby. But all modern chips (DACs, receivers, sample rate converters) have a software interface just waiting to be tapped. Some of the chips like the Sabre 9018 almost always require a software setup.

If you look at my bog (thanks jkenny :) ) you will find a lot of Arduino related resources and full source code for Wofson wm8741, ESS Sabre 9018, rotary encoders, LCD displays, sony remote and my favorite the apple aluminum remote.

Regarding the use of a graphical interface, my recommendation is not to do this for a first timer as you will spend most of your time trying to make the display work whereas the effort should be spend trying to communicate with the chips. I would say get the code working first with a character LCD and then port to code to a graphical LCD. If you are just using text. The real nice thing to have is to use a touch sensitive graphical LCD.

Regarding asking questions in the Arduino forum, as another poster indicated, you have to frame the question from a software point of view. If the question is too basic or too general, then you will probably get no response. They are very helpful and share everything. That is one place where copying is encouraged :)

I also agree with another poster proposing a section in diyaudio for microcontrollers and code.

BTW, I have two blogs because I wanted to try both blogger and wordpress :) blogspot is the old stuff, wordpress is the new stuff
 
Thanks for all your help and advice. As always its very much appreciated :D I have taken your advice glt and just ordered a couple of different size LCD from a local supplier. will start off with that. I have been looking through your blog and looks very interesting

alexcp Thanks for the info on the spectrum analyzer, will attempt this once I have rest of system up and running.

Sorry if my original post was bit vague, I have the library for the KS0108 but couldn't figure out how to do the menu. I now realise this is bit tricky for a first timer. I got some pga 2310 volume controls and am going to try interfacing with them. Later if im feeling bit more conferment with coding Ill try a LDR Light speed attenuator controlled by arduino.

jkeny I agree with you completely about learning from each other. I will be starting a new thread soon outlining my project in detail.

Thanks again for all your help..

;):cheers:
 
Do you take any special precautions with grounding and / or shielding when using a micro processor in a preamp? I have two nearly identical tube preamps, one with a micro one without. I get just touch of hum (60hz) and some other noise with the micro controlled version.

Thanks

john
 
Do you take any special precautions with grounding and / or shielding when using a micro processor in a preamp? I have two nearly identical tube preamps, one with a micro one without. I get just touch of hum (60hz) and some other noise with the micro controlled version.

Thanks

john
The microcontroller wouldn't cause 60Hz hum, but could be causing the "some other noise." There could be a wiring issue or something indirectly related to the controller being there that causes the hum.
use a dedicated controller which goes to sleep when there is nothing to do instead of those generic boards which don't....

But if there's an lcd around, it still has a dedicated controller running...
There are microcontrollers with direct interfacing to LCD displays (such as the AVR Butterfly), but regardless, if there's an LCD displaying something, there are active digital lines driving it and it must be well shielded from low-level audio.

If you use a non-multiplexed LED display you can have the processor go to sleep while the display stays lit. I'm all in favor of putting the controller and its oscillator to sleep while not adjusting volume or "changing channels" (thus it's all DC idle current, no moving lines to make noise) though this can be tricky if remote control is needed.
 
Thanks for the input. I am actually using a BP40 Basic Stamp. I started out with Basic stamps as a first step in learning to program and stuck with it. I use a VFD which does not contribute to the noise since it is off most of the time. I am wondering if the controller is putting garbage into the ground lines. Is there any way to isolate the controller from the rest of the ground, beyond the usual things like star grounding?
 
optocouplers. I actually have used them in i2c lines:

i added volume control with relays later and used one of the power supplies for the tubes (filament). As the powersupply was designed for an additional phono stage which i don't use, the supplies were designed for three tubes / channel. As i only have the line stage i put both tubes on the supply of one channel (doesn't harm).

So i had one supply left to power the relays. But i did not want to connect the audio gnd to the controller gnd. So i used some opto's in the i2c lines and powered the relays, i2c i/o expander and uln chip with the audio supply.

I do have to say this is one way only, gets bit more complicated when there is an electronic volume where you would need to read the registers or so. Obviously i did not care about the acknowledge bit (which is the other way around). With one busmaster you don't get failures unless you really screwed up the design.

An externally hosted image should be here but it was not working when we last tested it.

The yellow ones in the middle for the relays on the left. i/o expander and uln chip are just beneith. top blue connector is for the power of that part.

Can obviously also be applied to an arduino or basic stamp.

Edit: guess you need both way communication also if you use a controller with build in hardware i2c. The hardware then expects the acknowledge and i don't know if you can disable this. I'm using an old pic with the i2c protocol programmed in software. Well part of it, as i don't do collision detection etc etc. Just the basics to get it working. You need opto's with a transistor and not those ttl to ttl thingies. It's easy to do bothway with them, you just need four then.
 
Last edited:
Thanks for the input. I am actually using a BP40 Basic Stamp. I started out with Basic stamps as a first step in learning to program and stuck with it. I use a VFD which does not contribute to the noise since it is off most of the time. I am wondering if the controller is putting garbage into the ground lines. Is there any way to isolate the controller from the rest of the ground, beyond the usual things like star grounding?

There is a line of ADUM devices specially for i2c isolation...Digital Isolators | Interface | Analog Devices

After setup/adjustment, turn off the microcontroller and see if the hum goes away
 
Last edited:
Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.