---- ~~~~ Everything Knobs \/\/\/\/

This page tells you everything you need to do to connect analog knobs to your EZ-Kit Lite.

last update: 2/11/2003

The Analog to Digital Converter (MAX158)

  • This is an 8 Channel, 8-bit A/D converter from Maxim which you can attach to an EZ-Kit Lite.

    The MAX158 connects to the DSP's microprocessor bus, which is available on P2 of the EZ-Kit Lite.

    Here is the Data Sheet for the MAX158 . You can also get a couple of *FREE SAMPLES* from this link!

    Maxim also makes a 4-input version, the MAX154. However, if you're going to be part of the ezkitdev scene, you should really get the MAX158, since all of my future work is going to be based on it.

    Schematic

    Use this Table to make the connections b/t the MAX158 and the EZ-Kit Lite.

    Knob Connections

    Look at these pictures to see how to "wire up" the knobs.

    Get 8 potentiometers or slider pots, etc. I recommend 100K Ohm Linear taper sliders, not audio taper. Radio Shack ones are big and clunky. You have to cut off the shaft because it's way too long. You're better off with something from digi-key or future-active. browse their catalogs.

    Once you've got the knobs, build 8 voltage dividers.

    knobs divider

    Connect Vcc and Gnd to either end of every potentiometer. Then, take the wiper from each pot and connect it to the AIN inputs on the max158.

    Congratulations, you now have 8 knobs which you can program to control any parameters in your DSP Programs!!!

    Software to read the Knobs

  • Any read to I/O memory will activate IOMS/ on the EZ-Kit Lite, which is connected to RD/ on the MAX158.

    The lowest 3 bits of the address in IO memory that you read from will select the pot to read from. E.G. read from addresses 0x0000 through 0x0007.

  • It takes the A/D converter 1/50,000 of a second to read a single knob. Therefore, if you read one knob per iteration of your codec loop, which normally runs at 44.1 KHz, you'll be reading them at an appropriate speed. You probably don't need to read them so quickly, btw...

  • For technical reasons, the a/d converter is in a special mode in which your reads, actually reflect the *last* address you read from. So, you should make a software loop that continuously reads from the next knob (modulo 8) on each codec loop. And be aware that the value you get is actually the last one the you read.

    e.g. when you read from the pots in order 0,1,2,3,4,5,6,7,0,1,2,3.. you'll actually be getting values from 7,0,1,2,3,4,5,6,7,0,1,2...

    Software Driver

    This is my first pass at a software driver for the MAX154. It works perfectly fine, but I haven't had a chance to make the MAX158 version yet. Maybe you can do it and upload it?

    Download it here.

  • Back to EZ-Kit Building

  • Back to Shifty's Homepage