element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Raspberry Pi
  • Products
  • More
Raspberry Pi
Blog Raspberry PI 2.0, Windows 10 and how to drive the DAC8734 from TI (AKA the DAC8734EVM Road test Board)
  • Blog
  • Forum
  • Documents
  • Quiz
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Raspberry Pi to participate - click to join for free!
Featured Articles
Announcing Pi
Technical Specifications
Raspberry Pi FAQs
Win a Pi
GPIO Pinout
Raspberry Pi Wishlist
Comparison Chart
Quiz
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: Robert Peter Oakes
  • Date Created: 26 Jul 2015 6:26 AM Date Created
  • Views 2012 views
  • Likes 5 likes
  • Comments 6 comments
Related
Recommended
  • pi2_launchart
  • texas-instruments
  • keysight
  • dac8734evm
  • 34470a
  • rpi2
  • dac8734
  • raspberry_pi_2
  • raspberrypi

Raspberry PI 2.0, Windows 10 and how to drive the DAC8734 from TI (AKA the DAC8734EVM Road test Board)

Robert Peter Oakes
Robert Peter Oakes
26 Jul 2015

You know your an Engineer when this combination of ICONS means something exciting image

\imageimageimageimage

 

Here is a link to the Second video in this short series Raspberry PI 2.0, Windows 10 and Diagnosing issues with the SPI bus when writing software for the DAC8734.

And here is the third Raspberry PI 2.0, Windows 10 and how to drive the DAC8734 from TI - Software review

 

OK, so its been a busy week learning, researching and creating sample content for the Raspberry PI using windows 10 to drive the DAC8734 Quad 16bit DAc from Texas Instruments

 

This was made more difficult becaue of the seeming lack of information outside of the actual datasheet for the chip wich can be found here;http://www.ti.com/lit/ds/symlink/dac8734.pdf

 

I also want to be clear, I dont have the DAC8734EVM to hand but I did get some DAC8734 Chips and mounted one on a breakout board and created my circuit on a bread board but there is nothing I am aware of that will prevent any of my software attached from working on the EVM

This is the EVM followed by my circuit

image

imageimage

The objective of this post is to share my findings and experiance with the DAC8734, my initial intention was to evaluate it with regard to using it on my Power Supply Series and it just so happened to come up as a road test item also... Bonus.!!

 

I have created test programs for the Raspberry PI with Windows 10 for IOT (Detailed here), the Arduino UNO using the Arduino IDE and the TI LaunchPads (well several of them have been tested and there is very little difference between each one so only one sketch will be shown) and it was created using Enegia so anyone can use it with ease. even if there used to using only an Arduino.

 

So the featurs of the DAC8734 are many and most are integrated into my test program to evaluate their use

image

Right of the bat, the biggest two things I saw as a plus with this chip  were the fact it was 16 bit, Quad channel and most of all can output upto 20V in unipolar mode or +10 to -10V in bipolar mode, Ideal for my power supply control or related projects.

 

This is the internal block diagram of the DAC and a bit more detail of one channel (There all the same)

imageimage

One of the more interestng features are the calibration registers that allow the programmer to adjust the DAC for 0V and full scale by setting values into two registers that allow the scale of the dac to be changed up or down, even above the normal DAC max output volts (Software typically only allows adjustment up to the MAX of a DAC by tweeking hte binary value prior to writing to the DAC)

 

The DAC is also broken int to two halves, Group A and Group B, each group has seperate VREF and controls for Bipolar/Unipolar and Power Down.

 

This is the view of the application I am sharing, it follows the same basic design of the DAC, I have not gotton too cleaver with it, for instance you still can only input 0 - 65535 rather than an actual voltage, irrespective of the mode of operation, but this would be an easy thing for anyone to add if they wish (I may even do it later)

image

on the Windows 10 side of things, I will show (In the post related to the software review) how a splash screen can be added as well as setting the program to automatically start. I will attach the complete project for you to get to grips with on this post though, so you wont have to wait.

 

Here is a crude but informative wiring diagram showing how I connected up my version of the chip, A total of 6 wires from the PI, 3V3 and 0V power, then MOSI, MISO, CLK and CS for the SPI bus, I used CS1 on the PI for this sample.

image

So I have shown in the past using the PI with Windows 10 for IOT and driving SPI devices, and in those examples I was using Mode 0 of the SPI bus for clocking etc. I initially assumed as I was also using TI chips that this mode would also work with the DAC8734... Wrong, It took me a while to figure out what was wrong but eventually I did, thanks to my trusty MDO3054 scope and the SPI decode module to make life a little easier. The chip requires Mode 1 of operation

Here are two captured traces, one MODE 0 and one MODE 1, see if you can tell the difference without looking up the SPI standard image. I will be posting a complete video and write up on this issue after this post and am keeping it seperate in order to keep the videos under an hour each (Yes I did hear you all from my previous posts). For now here is the teaser waveforms

imageimage

 

I dont have the ability to measure the full acuracy, the low power mode consumption or the low noise claims for the DAC but im hoping one of the lucky road testers can do that and share their findings as I for sure am interested in so real world observations.

 

The DAC has the ability to work upto a 50Mhz SPI closk, this is not viable on a bread board but I was able to clock reliably upto 20Mhz, im sure if I shortened leads and improved termination this could go all the way and I am also sure that given the EVM board it will easily be achieved with the PI and any other able device.

 

One of the big issues I did observe while running under windows 10 for IOT was a very poor response to outputting a sine wave from an array of 256 16bit integers, I was able to get upto 250Hz on the arduino/Launchpads bit with the 1Ghz PI it was only able to complete a cycle of 256 points in 44mS resulting in a frequency of only 22Hz, so pretty bad really. I will be opening a ticket with MS regarding this and will keep you posted

 

Here are the timeing diagrams for one period (2 sample outputs), the three diagrams show the complete cycle, the first 24bit output and then a subsiquent one. As you can see, there is a significant delay between the end of the data being output and the chip select releasing.

imageimageimage

So if being able to output 256 samples in 44mS seems reasonable, if I simply comment out the lowest level write to the SPI bus I can, it will complete 255 loops of 256 values in only about 33mS equating to about 7.7Khz so if this had efficient lower level drivers perhaps the PI would still be able to output a 256 sample waveform at about 5Khz, that would not be too bad. Lets see what MS has to say and also what the release builds due out in a week or two will show.

 

As best as I could measure, the DAC was pretty stable and accurate but I only have 4.5digit hand held DMMs to perform measurement and a 16bit dac with a better than 1LSB accuracy equates to about 152uV on a 10V scale which is about

10.000xxx 0.0015%and I could only check to 0.05% ish, which is still way good enough for power supplies and most other systems, unless your building metrology grade instruments or other systems demanding precision outputs. Again I look to the road testers to prove the capabilities down there.I do show my testing on the posts using the Arduino and Launchpads, I did not repeat it here as the cycle between compiling and testing was much longer and I have not built in calibration routines to the PI UI applicaton yet. so please refer to the pther posts (Up In the next few days) to see those findings. It was pretty impressive for sure.

 

So in summary for this post, I am most impressed with the DAC, it was relativly easy to integrate to the PI and windows 10 for IOT once I figured out the datasheet and the right mode to run the SPI bus in (And of course the time to write the code) and now it is done I have a base to extend on to more rich applications.

 

Please feel free to use this code as you wish, Visual Studio Community edition is all I used but untill the end of the month (July 2015) you will need to stick with the RC version and the current production version just release does not maintain compatability with the current version of the PI IOT firmware (Go Figure) but the MS docs state this will be rectified at the end of july along with the official release of Windows 10.

 

There may be a few minor bugs in the code but I have not done with it yet and if you try it and find some, please let me know and i will correct it. I will also be posting it up onto GITHUB for those that like that way of managing their code

 

You will also see other libraries I have written in the solution attached for ADC1115, DAC8574, MCP3208 that were the subject of previous posts as well as the DAC8734, feel free to play and use them as you wish.

 

Here is the video on Youtube, this contains much more commentry and a demo of the working program. I hope you enjoy

You don't have permission to edit metadata of this video.
Edit media
x
image
Upload Preview
image

Attachments:
DAC8734 RPI Tester.zip
  • Sign in to reply

Top Comments

  • DAB
    DAB over 10 years ago +1
    Good update Peter. I am still trying to think of an application where I would need 16-bits, but you never know. DAB
  • michaelkellett
    michaelkellett over 10 years ago in reply to DAB

    Linear technology have published some interesting papers discussing how to measure the performance of very high performance DACs.

     

    MK

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • DAB
    DAB over 10 years ago in reply to Robert Peter Oakes

    That does sound like a problem.

    I would set up two 16 Bit DAC's in a vernier configuration so that you can setup gross levels with one and then fine tune the output with the other to check if the ADC can see the change.

    I suspect that you will have a lot of issues in trying to get the circuit stable and isolated from EM interference.

     

    I will check some of my measurement manuals to see if they have an easy to build circuit to use with something that sensitive.

     

    DAB

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • Robert Peter Oakes
    Robert Peter Oakes over 10 years ago in reply to DAB

    He,He,He, I just got some samples of 32Bit ADC's from TI, I don't think I have anything even remotely able to validate their accuracy, Even a 8.5 Digit DMM would not be sufficient, but they will be educational and fun to figure out and have a lot of possibilities so stay tuned

     

    one benefit btw, is you can have the resolution even if you don't have the absolute accuracy for instance, looking at drift or noise (Providing the ADC / DAC it self is stable of course)

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • DAB
    DAB over 10 years ago

    Good update Peter.

     

    I am still trying to think of an application where I would need 16-bits, but you never know.

     

    DAB

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • Robert Peter Oakes
    Robert Peter Oakes over 10 years ago in reply to michaelkellett

    new software will be out in a week or two coinciding with the release of Windows 10 so with luck it may be fixed, we will have to wait and see. Yes, that was something I mentioned in the video, off loading the PI / controller to a low level Microcontroller or FPDA will make a massive difference, I'm going to play with some lower level code on the Launchpad and Arduinos to see how fast I can get it.

     

    It has the potential to be an interesting ARB project.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
>
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube