Page 2 of 4 FirstFirst 1234 LastLast
Results 11 to 20 of 33

Thread: DACs and analog inputs

  1. #11
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Nice! Thanks for the lesson. That should help things out a lot.

  2. #12
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Quote Originally Posted by 2k1Toaster View Post
    Well if you get an 8bit DAC, then you are limiting your steps to be 1/(2^8) even if you only use 32 buttons. if you scaled this up, you are scaling error with it too.

    If you want an 8bit dac, I like this one as I have used it before on a single 5v supply: http://focus.ti.com/lit/ds/symlink/tlc7528.pdf
    Looking at the datasheet it looks to me like it needs 10V reference for the output... I know I can't get full 5V out with a 5V reference, but close is ok with me. but it would be nice to not have to supply this thing externally (12V), but I suppose it's not a big problem. Here's what I have so far, it's mostly cut and paste from the datasheets, I haven't put some values up yet either. If I do need higher voltages, then I suppose I can go back to the DAC0800 setup.

    If you see anything feel free to point it out, I'm learning here.


  3. #13
    Fusion Brain Creator 2k1Toaster's Avatar
    Join Date
    Mar 2006
    Location
    Colorado, but Canadian!
    Posts
    10,045
    For the dac use it in the mode like on page 14. Tie "Out" to 5v, AGND to 0v, and then just read out REF.

    Single 5v. It will never go all the way to 5v, but pretty close.
    Fusion Brain Version 6 Released!
    1.9in x 2.9in -- 47mm x 73mm
    30 Digital Outputs -- Directly drive a relay
    15 Analogue Inputs -- Read sensors like temperature, light, distance, acceleration, and more
    Buy now in the MP3Car.com Store

  4. #14
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Thanks, so I guess that saves me an opamp circuit. So, so far I'm getting about 7mA;
    DAC-4mA
    Encoder-1.1mA
    NAND-0.1mA
    NOT-1.6mA
    Resistors-0.2mA.

    I think...

    give or take... Can the analog input supply that? What's the limit?

  5. #15
    Fusion Brain Creator 2k1Toaster's Avatar
    Join Date
    Mar 2006
    Location
    Colorado, but Canadian!
    Posts
    10,045
    Yeah that is no problem. You can get 1A out of the regulator the way it is before it gets heatsink-needed hot. And that supplies everything on the board and all the sensors. The board as a whole takes almost nothing, so you have lots of room left over.
    Fusion Brain Version 6 Released!
    1.9in x 2.9in -- 47mm x 73mm
    30 Digital Outputs -- Directly drive a relay
    15 Analogue Inputs -- Read sensors like temperature, light, distance, acceleration, and more
    Buy now in the MP3Car.com Store

  6. #16
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Quote Originally Posted by 2k1Toaster View Post
    Yeah that is no problem...
    Good news.

    Well I'm going to start to build it on a breadboard to try it out this week, (or whenever the parts get here) let me know if there are any things I might want to consider, if you don't mind. I have a couple of concerns.
    -what would be the problem with tying OE to ground always? I suppose the data on the outputs of the encoder would never go to TRI-STATE, but being that this isn't really a data bus, would that matter? It would save 1 component. I also wondered if there would be a delay with doing it that way (not that it would matter really). The asynchronous example has it, but the 32 input example left that pin out entirely.

    The switches I'm using are those standard PCB SPST switches (from the OEM stereo) in one case and who knows for the other things, do you think .1 sec. debounce period will be enough?


  7. #17
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Also, in relation to the software and control, what is the downside to pulling discrete inputs out of an analog input. Obviously there is some overhead, in terms of processing the SWC loop needed to pull out the values. And since you've pulled a lot of the properties you once reserved for only inputs and buttons, and made them available for variables, I shouldn't not be able to do anything with variables extracted from the loop the I couldn't do with DI's right?

  8. #18
    Fusion Brain Creator 2k1Toaster's Avatar
    Join Date
    Mar 2006
    Location
    Colorado, but Canadian!
    Posts
    10,045
    Well looking at Figure 2 in the datasheet it only shows transition clock pulses, and it is vague as to how it works. It mentions "The output latches feed TRI-STATE, which is enabled when the Output Enable (OE) input is taken low." But you dont need/want tristate, so it shouldnt matter. But it could be tied to other things too, I am not sure. Only way to know is to try I suppose.


    Other suggestion is to buffer the output. That DAC I havent looked at too much, I used it it worked, but was too expensive for the long haul so a simple resistor ladder works fine. It shouldnt be a big deal if you dont buffer it, but it would be a good idea if you had room.
    Fusion Brain Version 6 Released!
    1.9in x 2.9in -- 47mm x 73mm
    30 Digital Outputs -- Directly drive a relay
    15 Analogue Inputs -- Read sensors like temperature, light, distance, acceleration, and more
    Buy now in the MP3Car.com Store

  9. #19
    Fusion Brain Creator 2k1Toaster's Avatar
    Join Date
    Mar 2006
    Location
    Colorado, but Canadian!
    Posts
    10,045
    Quote Originally Posted by h3rk View Post
    Also, in relation to the software and control, what is the downside to pulling discrete inputs out of an analog input. Obviously there is some overhead, in terms of processing the SWC loop needed to pull out the values. And since you've pulled a lot of the properties you once reserved for only inputs and buttons, and made them available for variables, I shouldn't not be able to do anything with variables extracted from the loop the I couldn't do with DI's right?
    double negatives!

    but yes you can do anything in the program with anything available in the program.

    The "do this" part of the program is shared throughout everything. You push a button, or a logic statement evaluates to true, both send their votes to be processed in the same function.
    Fusion Brain Version 6 Released!
    1.9in x 2.9in -- 47mm x 73mm
    30 Digital Outputs -- Directly drive a relay
    15 Analogue Inputs -- Read sensors like temperature, light, distance, acceleration, and more
    Buy now in the MP3Car.com Store

  10. #20
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Too expensive? I thought it was a bargain, but then, I was comparing it to AD558 (wtf?).

    A R/2R ladder would be cheaper... I'm dumming down these DACs to make them work in this application as it is. And if you say it works fine, maybe I'll give that a deeper look too. But this one isn't really being built with the long haul in mind.

Page 2 of 4 FirstFirst 1234 LastLast

Similar Threads

  1. Alpine PXA-H701 Questions
    By unixxx in forum Car Audio FAQ
    Replies: 461
    Last Post: 02-14-2012, 04:58 AM
  2. Ultimate USB, Firewire, External Soundcard List
    By durwood in forum Car Audio FAQ
    Replies: 121
    Last Post: 12-30-2009, 05:15 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •