LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

convert digital data into analog signal

hi

i have acquired digital data using DAQ assistant. now i need to get digital waveform from that data.

when i connect "data" from DAQ input to digital waveform, it gives me error saying they are two different data types.

basically, i need to convert the digital signal i am acquiring into analog signal.

does anybody know how to convert the "data" in DAQ input to digital signal so that i can later convert it to analog signal?

any help will be greatly appreciated.

please help me. 

thank you.

 

0 Kudos
Message 1 of 9
(9,255 Views)

If I am understand correctly you need to index the array that is produced by the DAQ Assitant.  The DAQ Assistant produces an array of digital waveforms and each element is a channel in the task that was set up by the DAQ Assistant.

 

daq_assistant_di.PNG

Message 2 of 9
(9,246 Views)

hi arvont,

thanks. it worked, but not completely as i thought it would.

i have attached my vi here.

i can see the digital signal in digital waveform. but after i change it into analog and try to plot it, i dont get any signal.

by the way, i am using NI ELVIS data acquisition prototype board to acquire my digital signal.

do you have any suggestions or idea?

thank you so much for your help.

 

0 Kudos
Message 3 of 9
(9,240 Views)

When I run your VI with a simulated DAQ device (PXI-6225) I see the digital data.  The analog data doesn't appear to be there because the DAQ Assistant is only returning one digital sample every time it runs.  An inspection of the analog waveform wire shows this.  The data are there.  The graph indicator isn't very good at showing only one sample.  See the attached modified VI.  I have added a waveform indicator that allows inspection of the waveform such as sample rate and individual sample values.  I've never used ELVIS so I can't help too much there.

 

Do you have to graph the data or do you simply need to scale them to analog values?  In any event you should study the Waveform Palette especially the "Get Wfm Components" VI.

 

 

0 Kudos
Message 4 of 9
(9,231 Views)

hi

thanks for your approach again.

actually, I have to change the acquired digital signal to analog signal, filter it for some cutoff frequency, and record the voltage values.

the digital signal i acquire comes from ADC0831 chip, which gets analog signal from skin sensor.

i ran the vi you sent me, it is showing from Y values in analog waveform, but it showing extremely small value (only 0 or -1 or 1 i think).

i was thinking that i would get (atleast) some sort of analog signal finally so that i can get the voltage value.

i hope this makes it clear for you.

do you still think this is a right procedure?

 

 

0 Kudos
Message 5 of 9
(9,227 Views)

Ok, mentioning the ADC0831 helps a lot.  I looked at the ADC0831 data sheet and it produces 8 bit serial data that must be decoded into into an analog value by a host microcontroller or similar device.  Your approach will not work.  Your approach will only sample the serial data. 

 

You will have to shift in the samples from the ADC0831 into a binary array and then convert that array to an integer, scale that integer to a floating point value.  Then you can do your filtering.

 

Do you have to use the ADC0831?  Why not connect the skin sensor to an ELVIS analog input?  Can you further describe the goal of your project?

Message Edited by Arvont on 04-04-2010 07:41 PM
0 Kudos
Message 6 of 9
(9,217 Views)

hi

i can try without using ADC0831.

the main goal of my project is to read emg signals from body (or to build the system).

the sensor part will have various components to amplify the signals, and use some cutoff frequency (set upper and lower limit of frequency).

then, we have to feed that signal to the computer in online fashion continuously and record its voltage values.

as i am new to this field, im not sure if i can directly extract analog signals before i use ADC0831, and then use filter to cut off 60Hz frequency.

if i can, i can probably use the analog inputs of ELVIS to do that.

 

i hope i made it little more clear for you.

thanks. 

0 Kudos
Message 7 of 9
(9,212 Views)
I think your best option is to use an analog input on the NI_ELVIS if you can.
0 Kudos
Message 8 of 9
(9,201 Views)

ok. i will try it.

if there's any problem, i will write you again later.

i really really appreciate your help.

even if i get it working using analog signal, i will let you know. thanks a lot again.

 

Message 9 of 9
(9,199 Views)