The ADuCM3029_demo_ad5770rpmdz project provides a solution to control the EVAL-AD5770R-PMDZ PMOD using a minimal CLI and the no-OS drivers for the EVAL-ADICUP3029 platform.
The AD5770R is a 6-channel, 14-bit, multi-range, current output DAC designed for use in communications systems, instrumentation and industrial applications; specifically for photonics control and current mode biasing. It has 6 programmable output channels with 1 channel capable of sinking up to 60 mA of current. The EVAL-AD5770R-PMDZ is a board designed to be a compact and low cost solution to evaluate the part.
The application builds upon the no-OS device and platform drivers and a minimal CLI module to provide a robust command set to set the range and output value of the channels.
The program first initializes the hardware system as well as the driver handlers, then goes into the main process that just implements the CLI process and waits for user commands. If a command is received, it is executed and the program returns to the main loop.
The following is a list of items needed in order to replicate this demo.
A serial terminal is an application that runs on a PC or laptop that is used to display data and interact with a connected device (including many of the Circuits from the Lab reference designs). The device's UART peripheral is most often connected to a UART to USB interface IC, which appears as a traditional COM port on the host PC/ laptop. (Traditionally, the device's UART port would have been connected to an RS-232 line driver / receiver and connected to the PC via a 9-pin or 25-pin serial port.) There are many open-source applications, and while there are many choices, typically we use one of the following:
Before continuing, please make sure you download and install one of the above programs.
There are several parameters on all serial terminal programs that must be setup properly in order for the PC and the connected device to communicate. Below are the common settings that must match on both the PC side and the connected UART device.
In many instances there are other options that each of the different serial terminal applications provide, such as local line echo or local line editing, and features like this can be turned on or off depending on your preferences. This setup guide will not go over all the options of each tool, but just the minor features that will make it easier to read back data from the connected devices.
Example setup using Putty
Typing help or h after initial calibration sequence will display the list of commands and their short versions. Bellow is the short command list:
Function | Command | Description | Example |
---|---|---|---|
General commands | |||
h | Display available commands. | ||
t | Set channels at production test levels. | ||
DAC commands | |||
sir | Set the input register of the chosen DAC channel. <chan> = channel to update; values are: c0, c1, c2, c3, c4, c5. <value> = update value in decimal; between 0 and 16383. | sir c0 8192 | |
uo | Update the DAC output with the channel input registers value. This is done with the nLDAC GPIO if it's available and with the SW register otherwise. | ||
sc | Set the value of the chosen DAC channel. <chan> = channel to update; values are: c0, c1, c2, c3, c4, c5; <value> = update value in decimal; between 0 and 16383. | sc c0 8192 | |
sr | Set the range of the DAC output channels. <chan> = channel to update; values are: c0, c1, c2, c3, c4, c5; <opt> = option chosen for the channel. values are: opt1 - only for channels 0 and 1, opt2, opt3. Those correspond to the options in the datasheet. | sr c0 opt1 |
We recommend not opening the project directly, but rather import it into CrossCore Embedded Studios and make a local copy in your workspace.
The source code and include files of the ADuCM3029_demo_ad5770rpmdz can be found here:
The official tool we promote for use with the EVAL-ADICUP3029 is CrossCore Embedded Studio. For more information on downloading the tools and a quick start guide on how to use the tool basics, please check out the Tools Overview page.
For more detailed instructions on importing this application/demo example into the CrossCore Embedded Studios tools, please view our How to import existing projects into your workspace section.
For more detailed instructions on importing this application/demo example into the CrossCore Embedded Studios tools, please view our How to configure the debug session section.
Beside the IDE generated sources the project structure is divided into high level software modules and low level software modules.
The high level modules are in the src folder and are:
The low level modules are the platform drivers and are included in the platform_source and platform_include folders.
End of Document
声明:本文内容及配图由入驻作者撰写或者入驻合作网站授权转载。文章观点仅代表作者本人,不代表电子发烧友网立场。文章及其配图仅供工程师学习之用,如有内容侵权或者其他违规问题,请联系本站处理。 举报投诉
全部0条评论
快来发表一下你的评论吧 !