NI Home
Cart Cart | Help
Hello Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI
You are here: 
NI Home > NI Developer Zone > NI Discussion Forums


Reply
Member
krasi85
Posts: 11
0 Kudos

Re: How to acquire analog input driven by digital output? (NI-6251 with Matlab)

My mistakes is up there...

should be like this in NImess.m

taskh1=uint32(1);
[a,b,taskh1] = calllib('myni','DAQmxCreateTask','master',taskh1);
------------------------------------------------------------------------


DAQmx_Val_Volts= 10348; % measure volts

why DAQmx_Val_Volts have this big number? 

taskchans1=['Dev1/ai0:' num2str(numofchans-1)];
[a,b,c,d] = calllib('myni','DAQmxCreateAIVoltageChan',uint32(taskh1),taskchans1,'',-1,-10,10,DAQmx_Val_Volts,'')

And what is the order to define the functions parameters:
for example 'DAQmxCreateAIVoltageChan' --> ,uint32(taskh1),taskchans1,'',-1,-10,10,DAQmx_Val_Volts,''   what meens? 

How to define my task? :smileysad:
Member
krasi85
Posts: 11
0 Kudos

Re: How to acquire analog input driven by digital output? (NI-6251 with Matlab)

 i get it! :smileyhappy:
 

By using this web site, you accept the Terms of Use for this web site. Please read these Terms of Use carefully before using any part of this site. Please go here for information on ni.com's copyright infringement policy.
My Profile | Privacy | Legal | Contact NI © 2011 National Instruments Corporation. All rights reserved.    |    E-Mail this Page E-Mail this Page