Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

How to simulate ADC by using the dip switch??

Status
Not open for further replies.

ru

Junior Member level 1
Joined
Sep 30, 2004
Messages
17
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
168
ADC simulator

may i know how to simulate ADC by using the dip switch??

anyone got similar program??

can post here??

thanks.. :)
 

Re: ADC simulator

Hi, this is how it should work:

First choose a Vref (5V for example)

Now, to get the digital equivalent from the analog voltage you do the following math:


Vref = 255 (for 8 bits ADC; 4095 for 12 bits and so on)
Vanalog = x

x = Vanalog(255) / Vref

So you put in your dip switch the bynary number "x". Keep in mind that ADC rounds numbers, if you got 128.5 or more it wil be 129 on the ADC output; in the other hand if you got 128.4 or less it will be 128 on the ADC output.

An example to clarify things:

Vref = 5
Vanalog = 2

5 = 255
2 = x

x = 102;

So you put in your dip switch 01100110 = 102

Hope i could help.
mcoster
 

Re: ADC simulator

it will depend on whether ur ADC uses natural binary , offset binary or 2's complement binary
 

Re: ADC simulator

salam :
try simulation program like proteus , it can help you
regards
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top