EmbeddedRelated.com
Forums

IO expander

Started by Kushan Hind March 14, 2004
Hi folks
I am a newbie who has a great oppurtunity(relatively speaking) to make
his first embedded design.

I want to make an attenuator controller to control 32 digitaly
programmable attenuators. I need 256 bit TTL compatible digital output
(8/attenuator) .

I am considering MCP23016 IC from microchip and pic microcontroller
for this task.

8 MCP23016 ICs can be put on 1 IIC bus and i plan to use a pic w/ 2
IIC bus(HW/ or bit bang)

Does this approach seem reasonable?
I do not want to reinvent the wheel if other devices exists.
What do you people think?
Any advice will be appreciated.

TIA
-Kushan
Kushan Hind wrote:

>Hi folks >I am a newbie who has a great oppurtunity(relatively speaking) to make >his first embedded design. > >I want to make an attenuator controller to control 32 digitaly >programmable attenuators. I need 256 bit TTL compatible digital output >(8/attenuator) . > >I am considering MCP23016 IC from microchip and pic microcontroller >for this task. > >8 MCP23016 ICs can be put on 1 IIC bus and i plan to use a pic w/ 2 >IIC bus(HW/ or bit bang) > >Does this approach seem reasonable?
256 bits of output seems excessive. A better solution may be offered if if you tell more about the attenuators and their role in the system you are designing.
>I do not want to reinvent the wheel if other devices exists. >What do you people think? >Any advice will be appreciated. > >TIA >-Kushan
-- ======================================================================== Michael Kesti | "And like, one and one don't make | two, one and one make one." mkesti@gv.net | - The Who, Bargain
Kushan Hind schrieb:

> I want to make an attenuator controller to control 32 digitaly > programmable attenuators. I need 256 bit TTL compatible digital output > (8/attenuator) . > > I am considering MCP23016 IC from microchip and pic microcontroller > for this task. > > 8 MCP23016 ICs can be put on 1 IIC bus and i plan to use a pic w/ 2 > IIC bus(HW/ or bit bang) > > Does this approach seem reasonable? > I do not want to reinvent the wheel if other devices exists. > What do you people think? > Any advice will be appreciated.
You might consider using simple shift registers (74xx595) and cascade them to the number of outputs you need. Faster and probably much cheaper than those I2C output chips, however you can't address the outputs individually. Depending on how these attenuators are controlled, there might be better solutions, as Michael already mentioned. -- Dipl.-Ing. Tilmann Reh Autometer GmbH Siegen - Elektronik nach Ma�. http://www.autometer.de ================================================================== In a world without walls and fences, who needs Windows and Gates ? (Sun Microsystems)
"Michael R. Kesti" <mkesti@gv.net> wrote in message news:<40550C4D.85FE64B8@gv.net>...
> Kushan Hind wrote: > > >Hi folks > >I am a newbie who has a great oppurtunity(relatively speaking) to make > >his first embedded design. > > > >I want to make an attenuator controller to control 32 digitaly > >programmable attenuators. I need 256 bit TTL compatible digital output > >(8/attenuator) . > > > >I am considering MCP23016 IC from microchip and pic microcontroller > >for this task. > > > >8 MCP23016 ICs can be put on 1 IIC bus and i plan to use a pic w/ 2 > >IIC bus(HW/ or bit bang) > > > >Does this approach seem reasonable? > > 256 bits of output seems excessive. A better solution may be offered if > if you tell more about the attenuators and their role in the system you > are designing.
This is supposed to be a test bed for a wireless device. A simplified block diagram is below [1server]->[RF channel sim]->[attenuator1]->[client#1]. |->[attenuator2]->[client#2] . . . |->[attenuator32]->[client#32] All attenutors would be in different settings for a multitude of tests. Each attenuator has a 8 bit digital interface to control attenuation.
> > >I do not want to reinvent the wheel if other devices exists. > >What do you people think? > >Any advice will be appreciated. > > > >TIA > >-Kushan
Kushan Hind wrote:

>"Michael R. Kesti" <mkesti@gv.net> wrote in message news:<40550C4D.85FE64B8@gv.net>... >> Kushan Hind wrote: >> >> >Hi folks >> >I am a newbie who has a great oppurtunity(relatively speaking) to make >> >his first embedded design. >> > >> >I want to make an attenuator controller to control 32 digitaly >> >programmable attenuators. I need 256 bit TTL compatible digital output >> >(8/attenuator) . >> > >> >I am considering MCP23016 IC from microchip and pic microcontroller >> >for this task. >> > >> >8 MCP23016 ICs can be put on 1 IIC bus and i plan to use a pic w/ 2 >> >IIC bus(HW/ or bit bang) >> > >> >Does this approach seem reasonable? >> >> 256 bits of output seems excessive. A better solution may be offered if >> if you tell more about the attenuators and their role in the system you >> are designing. > >This is supposed to be a test bed for a wireless device. >A simplified block diagram is below > >[1server]->[RF channel sim]->[attenuator1]->[client#1]. > |->[attenuator2]->[client#2] > . > . > . > |->[attenuator32]->[client#32] > >All attenutors would be in different settings for a multitude of tests. >Each attenuator has a 8 bit digital interface to control attenuation. > >> >> >I do not want to reinvent the wheel if other devices exists. >> >What do you people think? >> >Any advice will be appreciated. >> > >> >TIA >> >-Kushan
I see. As a test bed that you're going to build a small number of, as opposed to a product that you might build 1000's of, then your approach is probably acceptable. If it was a volume product, I'd probably be looking for another attenuator implementation with a more economically suitable control scheme. -- ======================================================================== Michael Kesti | "And like, one and one don't make | two, one and one make one." mkesti@gv.net | - The Who, Bargain
Michael R. Kesti wrote:
<snip>
> I see. As a test bed that you're going to build a small number of, as > opposed to a product that you might build 1000's of, then your approach > is probably acceptable. If it was a volume product, I'd probably be > looking for another attenuator implementation with a more economically > suitable control scheme.
Main difference between i2c slaves, and the cascade shift registers others have suggested, is the i2c is slower, and cannot update all nodes at once. That may matter - with Serial cascade, you send ALL data bits, and then a single LOAD pulse updates ALL pins at the same instant.