Which micro controller suits this project?

This is the place for any magazine-related discussions that don't fit in any of the column discussion boards below.
Post Reply
Trepan
Posts: 10
Joined: Wed May 30, 2007 8:40 am
Contact:

Which micro controller suits this project?

Post by Trepan »

I'd like to design a project where I would have a micro controller that would take as input a few switches/potentiometers, say 3 or 4 of each max. The output would be to an optional LCD screen (3 line etc), and it would control the analog switching of a bunch of coils that I have. This will be my first shot at using micro controllers (I'm already a software engineer though).

Basically, I'd like to digitally control if the coils are in phase, out of phase, in series, in parallel etc.. I would say there'd be up to 12 maximum connections that would need to be manipulated in this fashion, with the micro controller providing the switching.

The thing here is that it's an audio application as well, and audio signal travels along the coils, so this has to absolutely not taint the signal whatsoever.

Can the majority of this work be done in a micro controller, with only a few controls? Or would I also need a bunch of transistors etc. If at all possible I'd like to do it all in the micro controller if possible.

Thank you all very much!
Bigglez
Posts: 1282
Joined: Mon Oct 15, 2007 7:39 pm
Contact:

Re: Which micro controller suits this project?

Post by Bigglez »

Greetings (No Name Supplied),
Trepan wrote: Basically, I'd like to digitally control if the coils are in phase, out of phase, in series, in parallel etc.. I would say there'd be up to 12 maximum connections that would need to be manipulated in this fashion, with the micro controller providing the switching.
By far the easiest way to get started with a uC
(microcontroller) is to buy an experimenter's board.
It has the power supply, input switches, output LEDs,
an optional LCD, and additional IO lines for your
dedicated hardware. It allows the uC to be
programmed with the help of a PC (where you can
also do software development and debugging).

There are two dominant uC brands in use; AVR
by Atmel,and PIC by Microchip. There are a few
others for more powerful or specialized applications.

The native uC chip needs to be programmed, and
some hobby vendors provide chips with Bootloaders

Here's a few candidates:
MeLabs
Basic Stamp - Parallax
AVR - Atmel
PIC - Microchip
PICAXE

Pololu's Orangutan boardmight be good place to start.
Trepan wrote:The thing here is that it's an audio application as well, and audio signal travels along the coils, so this has to absolutely not taint the signal whatsoever.
Well, before anyone can help you with that request you'll
need to define the analogue signals, levels, circuit
impedances, and what taint means.

Comments Welcome!
User avatar
philba
Posts: 2050
Joined: Tue Nov 30, 2004 1:01 am
Location: Seattle
Contact:

Post by philba »

that's a decent intro to uCs.

I think you should tell us what your application is and what the coils are used for.

Also, I suspect taint means to add undesirable noise to the signal.
Trepan
Posts: 10
Joined: Wed May 30, 2007 8:40 am
Contact:

Post by Trepan »

Thanks for the links, I'll have to check them out :)

The coils are electric guitar pickups. Basically, humbuckers, which are two single coils connected together. Basically there are several ways to connect them, and wiring two of them up to provide all possible configurations using regular switches would be a real pain, and probably require many more switches.

Basically I just want the microcontroller to control which of the four wires from each pickup will be connected to each other at a given time, without adding anything into the signal path.

Also, I think if it could do variable resistance and capacitance, I could have less controls and still be able to do the volume/tone controls for each individual pickup.

I think what you're saying is this type of functionality is pretty much standard in all microcontroller kits? If so, basically I'd just want to choose based on the language and features.. probably wouldn't need a pile of memory or processing power in something like this, something fairly low powered and running on low voltage requirements, a single 9 volt battery should be enough power and will need to last a reasonable amount of time.
Bigglez
Posts: 1282
Joined: Mon Oct 15, 2007 7:39 pm
Contact:

Post by Bigglez »

Greetings (Still No Name Supplied),
Trepan wrote: The coils are electric guitar pickups. Basically, humbuckers, which are two single coils connected together. Basically there are several ways to connect them, and wiring two of them up to provide all possible configurations using regular switches would be a real pain, and probably require many more switches.
This is low level audio. you could use relays or electronic
analog switches to route the signals from inputs to outputs.
Trepan wrote:Also, I think if it could do variable resistance and capacitance, I could have less controls and still be able to do the volume/tone controls for each individual pickup.
To replace the "tone" controls on the guitar? I think these
are always resistance, not adjustable capacitance.

You could use the relays or analog switches to insert
fixed values, as many as you need. Or, you could use a
digital pot to convert from digital data to variable resistance
in the signal circuit. Better yet, you could digitize the
raw signal and manipulate it in a DSP or dedicated logic.
I would think many standard guitar pedal effects use this
technique.
Trepan wrote:I think what you're saying is this type of functionality is pretty much standard in all microcontroller kits?
Perhaps you should follow the links already provided before
jumping to any conclusions?
Trepan wrote:If so, basically I'd just want to choose based on the language and features.. probably wouldn't need a pile of memory or processing power in something like this, something fairly low powered and running on low voltage requirements, a single 9 volt battery should be enough power and will need to last a reasonable amount of time.
That said, where is this to end up? In the guitar body or
outboard somewhere? Why do you need an LCD display
if the function is to select from a limited number of input
sources, and feed to only one output destination (your PA
or a mixing board)?

Comments Welcome!
dyarker
Posts: 1917
Joined: Fri Aug 22, 2003 1:01 am
Location: Izmir, Turkiye; from Rochester, NY
Contact:

Post by dyarker »

Some of the probing is interest, mostly more info is needed to make a better suggestion.

One bit I did catch in your first post ... The coils can't be switched by the uController itself; the uController can control relays, or better yet bilateral switches (updated cousins of CD4066).

Also, which language would you prefer to program the uController? C, BASIC, or assembly? Not all are available for all the uControllers; how can someone suggest a particular chip without knowing?

Your project is not a "simple question". Not tainting the audio is going to be a major challenge with high speed logic in the same box with low level audio.

Cheers,
Dale Y
User avatar
haklesup
Posts: 3136
Joined: Thu Aug 01, 2002 1:01 am
Location: San Jose CA
Contact:

Post by haklesup »

Sounds like you are trying to make a NxM switch matrix. If you could sketch out the coil and switch part of your concept (design) then selecting switches and a switch controller is all that is left. In other words, how would you do it with mechanical switches?

I like the maxim analog switches and Muxes because they have a very wide selection of switch contact types (NO, NC, SPDT etc.) from 1 to 8 switches per package, come in DIP and SMT and operate in single or dual supplies (up to 40V) and have a range of series ON resistance (down to 1.25 ohms). In general these switches activate one switch per I/O line but you can use glue logic to mux signals if you want too (for example use 8 I/O lines to control 128 switch nodes).

http://para.maxim-ic.com/cache/en/results/35452.html

Relays may result in an audible click when switching and if amplified, this could be very loud. By using discrete FETs and RC components on the gates, you can make a soft switch that smoothly switches from one input to the other like a fader. If that sounds interesting I can post a snippet.

Dosen't sound like your uController needs to be too complicated. Needs to support maybe 12-40 I/O lines for the switch matrix and user interface buttons and have more I/O lines to support a display (LCD or some arrangement of LEDs). THere are uControllers with lots of I/O lines but generally in QFP packages you will need to design a board to use. Try to stick to DIP and PLCC (with have cheap production thru hole sockets) for easy assembly on a breadboard.

Choose some analog switches, design the switch matrix and user interface requirements. Once you reach that point, it will be clear how many I/O lines you need to support and if any external combinational logic (for decoding I/O lines) and what power supply is required. With that, you can then rationally select a uController with the right amount of resources. Resources being I/O lines and any RAM or Flash you need to store firmware.

I think if you do away with the LCD display, you could do the whole switch selection thing with combinational logic or just a PAL. The design process is different though. You will need to make state diagrams and translate to boolean logic statements to design that. The uController/PIC will give you more options with the user interface and the ability to run macros or change the program by reflashing the firmware. A PIC and a PAL would give you the lowest parts count. A simple PIC with 8 i/o lines and a PAL containing the glue logic to drive the switches and LEDs.

If you want to start adding variable anything (output volume, tone, input level) now you need to look at devices with built in A/D and or D/A converters of appropriate resolution for the analog functions you want. Just switching the coils is a 100% digital thing and only needs I/O lines. If you want to start varying impedance like capacitance or inductance, you need a lot more than just a uController, these are not easily variabe parameters. At that point, you might as well just get into DSP.

You will find products with very similar specs from different manufacturers. It may be that you like the development software better from one vendor over another.
Post Reply

Who is online

Users browsing this forum: No registered users and 42 guests