EmbeddedRelated.com
Forums
Memfault Beyond the Launch

MSP430 DAC example

Started by July Brownie March 1, 2013
Hi

In my project I was able to successfully calculate the Voltage and
current coming on ADC.
Now i wanted to output the voltage on DAC0 and DAC1 continuously as per my
input voltages.
I am working on 60Hz,120 V.
I am looking for some example code which i can use to get started on it.

Thanks and please help me to get this started.


Beginning Microcontrollers with the MSP430

On Fri, Mar 1, 2013 at 9:21 PM, July Brownie wrote:

> In my project I was able to successfully calculate the Voltage and
> current coming on ADC.
> Now i wanted to output the voltage on DAC0 and DAC1 continuously as per my
> input voltages.
> I am working on 60Hz,120 V.
> I am looking for some example code which i can use to get started on it.
>
> Thanks and please help me to get this started.

One of the best things about the MSP430 is that TI provides sample
code for every peripheral. Unfortunately, TI's web monkeys make it
ungodly difficult to find, and have a terrible habit of breaking
bookmarks.

All of the sample code libraries used to be accessible from the following link:

http://focus.ti.com/mcu/docs/mcuflashtools.tsp?sectionId&tabId38&familyId42

Unfortunately, as soon as this page loads, you get re-directed to an
empty page. However, if you can click on a link (any link) as soon as
the page loads but before the re-direct, you can gain access to this
page.

If that doesn't work, google for "MSP430 16-bit Microcontroller Code
Examples and Function Library"

The first hit brings up a page which appears as if it contains the
information you want, but the actual hyperlink seems to be missing.

The second link seems to work a bit better:

http://www.ti.com/lsds/ti/microcontroller/16-bit_msp430/msp430_software_landing.page

Scroll down to "MSP430 16-bit Microcontroller Code Examples" and expand the tab.

Select the family of MSP430 you are using to download the appropriate
sample code library for your part.


Good grief, TI. Every time your web monkeys touch the site they do
nothing but FUBAR it. Would you please just fire the lot of them
already? We are engineers. We don't want any f****** web eye candy
that does nothing but make things more difficult to find.

On 02.03.2013 16:05, Peter Johansson wrote:
:
> One of the best things about the MSP430 is that TI provides sample
> code for every peripheral. Unfortunately, TI's web monkeys make it
> ungodly difficult to find, and have a terrible habit of breaking
> bookmarks.
:

Although I have to admit, that TIs site is sometimes broken, finding the
code examples is relatively easy:

- go to the processor specific page, e.g.
http://www.ti.com/product/msp430f2618#technicaldocuments
- go down to software, show more
- there you can find
MSP430F241x, MSP430F261x Code Examples (Rev. E)
http://www.ti.com/litv/zip/slac151e
- http://www.ti.com/lit/zip/slac151 directs you always
to the latest version of those code examples

Unfortunately the code examples do not exist for all processors (e.g.
MSP430F5538). But I guess the examples of the MSP430F2618 should give
you the idea.

Hardy
On Sat, Mar 2, 2013 at 11:38 AM, Hardy Griech wrote:

> Unfortunately the code examples do not exist for all processors (e.g.
> MSP430F5538).

Actually, as best as I can tell, examples *are* provided for all
processors, and if you go to the page I linked to, you will see that
there is a link to MSP430F55xx code examples. Because the OP did not
specify the particular chip they were working with, I was attempting
to direct them to the page with the links to all of the code samples.

> But I guess the examples of the MSP430F2618 should give
> you the idea.

Unfortunately not, as peripherals are often a fair bit different
between processor families. OP asked for a working example, and I am
fairly certain that TI provides such an example, *IF* you can find it.
Hopefully the page I directed them to can help.

-p.

Memfault Beyond the Launch