ni-daq™mx helplabview signalexpress 2.x or later (including signalexpress le), or the labview...
TRANSCRIPT
NI-DAQ™mxHelpJanuary2008,370466L-01ThishelpfilecontainsinformationaboutusingNI-DAQmxtoprogramyourNationalInstrumentsdevice.NI-DAQmxisthesoftwareyouusetocommunicatewithandcontrolyourNIdataacquisition(DAQ)device.RefertoSupportinNI-DAQ8.7intheNI-DAQ8.7ReadmeforalistofdevicessupportedinNI-DAQmx.ThisdocumentdescribesonlyNI-DAQmx.ForinformationonTraditionalNI-DAQ(Legacy),refertotheTraditionalNI-DAQ(Legacy)UserManual.Formoreinformationaboutthishelpfile,refertothefollowingtopics:UsingHelpRelatedDocumentationImportantInformationTechnicalSupportandProfessionalServicesTocommentonNationalInstrumentsdocumentation,refertotheNationalInstrumentsWebsite.©2003–2008NationalInstrumentsCorporation.Allrightsreserved.
RelatedDocumentationManymanualsalsoareavailableasPDFs.YoumusthaveAdobeAcrobatReaderwithSearchandAccessibility5.0.5orlaterinstalledtoviewthePDFs.RefertotheAdobeSystemsIncorporatedWebsitetodownloadAcrobatReader.RefertotheNationalInstrumentsProductManualsLibraryforupdateddocumentationresources.Thefollowingdocumentscontaininformationthatyoumayfindhelpfulasyouusethishelpfile.Foradditionaldetailsonthesedocuments,alongwiththeirdefaultinstallationlocations,refertoni.com/kb.
DAQAssistantHelpDAQGettingStartedGuideGettingStartedwithLabVIEWGettingStartedwithLabVIEWSignalExpressLabVIEWHelpLabVIEWReal-TimeUserManualLabVIEWSignalExpressHelpLabWindows™/CVI™HelpMeasurement&AutomationExplorerHelpforNI-DAQmxNIMeasurementStudioHelpNI-DAQmxCReferenceHelpNI-DAQmxDataAcquisitionVIsSCXIQuickStartGuidePIDControlToolsetManualTakinganNI-DAQmxMeasurementinLabVIEWTakinganNI-DAQmxMeasurementinLabVIEWSignalExpressTakinganNI-DAQmxMeasurementinLabWindows/CVIUsingNI-DAQmxwithLabVIEWProjectDeviceDocumentation
ForadescriptionsofNI-DAQmxdocumentsalongwithdefaultinstallationlocations,refertoNI-DAQmxforWindowsDocumentationonni.com.
UsingHelpConventionsNavigatingHelpSearchingHelpPrintingHelpFileTopics
ConventionsThishelpfileusesthefollowingformattingandtypographicalconventions:
<> Anglebracketsthatcontainnumbersseparatedbyanellipsisrepresentarangeofvaluesassociatedwithabitorsignalname—forexample,AO<0..3>.
» The»symbolleadsyouthroughnestedmenuitemsanddialogboxoptionstoafinalaction.ThesequenceFile»PageSetup»OptionsdirectsyoutopulldowntheFilemenu,selectthePageSetupitem,andselectOptionsfromthelastdialogbox.Thisicondenotesatip,whichalertsyoutoadvisoryinformation.Thisicondenotesanote,whichalertsyoutoimportantinformation.
attribute/property ThistermisusedtorepresentpropertiesforLabVIEW,VisualC++,VisualBasic.NET,andVisualC#;andGetandSetAttributefunctionsforANSICandLabWindows™/CVI™.
bold Boldtextdenotesitemsthatyoumustselectorclickoninthesoftware,suchasmenuitemsanddialogboxoptions.Boldtextalsodenotesparameternames,emphasis,oranintroductiontoakeyconcept.
green Underlinedtextinthiscolordenotesalinktoahelptopic,helpfile,orWebaddress.
italic Italictextdenotesvariables,emphasis,crossreferences,oranintroductiontoakeyconcept.Italictextalsodenotestextthatisaplaceholderforawordorvaluethatyoumustsupply.
function/VI Thistermisusedtogenericallyrepresentfunctions,VIs,andmethods,dependingontheprogramminglanguageyouuse.Afunction/VImightnotexactlymatchthetermusedinyourprogramminglanguage.Consulttheappropriatereferencedocumentation,
suchastheNI-DAQmxCReferenceHelp,forthespecificterms.
monospace Textinthisfontdenotestextorcharactersthatyoushouldenterfromthekeyboard,sectionsofcode,programmingexamples,andsyntaxexamples.Thisfontisalsousedforthepropernamesofdiskdrives,paths,directories,programs,subprograms,subroutines,devicenames,functions,operations,variables,filenames,andextensions.
NavigatingHelp(WindowsOnly)Tonavigatethishelpfile,usetheContents,Index,andSearchtabstotheleftofthiswindoworusethefollowingtoolbarbuttonslocatedabovethetabs:
Hide—Hidesthenavigationpanefromview.Locate—LocatesthecurrentlydisplayedtopicintheContentstab,allowingyoutoviewrelatedtopics.Back—Displaysthepreviouslyviewedtopic.Forward—DisplaysthetopicyouviewedbeforeclickingtheBackbutton.Options—Displaysalistofcommandsandviewingoptionsforthehelpfile.
SearchingHelp(WindowsOnly)UsetheSearchtabtotheleftofthiswindowtolocatecontentinthishelpfile.Ifyouwanttosearchforwordsinacertainorder,suchas"relateddocumentation,"addquotationmarksaroundthesearchwordsasshownintheexample.SearchingfortermsontheSearchtaballowsyoutoquicklylocatespecificinformationandinformationintopicsthatarenotincludedontheContentstab.
WildcardsYoualsocansearchusingasterisk(*)orquestionmark(?)wildcards.Usetheasteriskwildcardtoreturntopicsthatcontainacertainstring.Forexample,asearchfor"prog*"liststopicsthatcontainthewords"program,""programmatically,""progress,"andsoon.Usethequestionmarkwildcardasasubstituteforasinglecharacterinasearchterm.Forexample,"?ext"liststopicsthatcontainthewords"next,""text,"andsoon.
NoteWildcardsdonotworkwhensearchingwithSimplifiedChinese,TraditionalChinese,Japanese,andKoreancharacters.
NestedExpressionsUsenestedexpressionstocombinesearchestofurtherrefineasearch.YoucanuseBooleanexpressionsandwildcardsinanestedexpression.Forexample,"exampleAND(programORVI)"liststopicsthatcontain"exampleprogram"or"exampleVI."Youcannotnestexpressionsmorethanfivelevels.
BooleanExpressionsClickthe buttontoaddBooleanexpressionstoasearch.ThefollowingBooleanoperatorsareavailable:
AND(default)—Returnstopicsthatcontainbothsearchterms.Youdonotneedtospecifythisoperatorunlessyouareusingnestedexpressions.OR—Returnstopicsthatcontaineitherthefirstorsecondterm.NOT—Returnstopicsthatcontainthefirsttermwithoutthesecondterm.NEAR—Returnstopicsthatcontainbothtermswithineightwordsofeachother.
SearchOptions
UsethefollowingcheckboxesontheSearchtabtocustomizeasearch:Searchpreviousresults—Narrowstheresultsfromasearchthatreturnedtoomanytopics.Youmustremovethecheckmarkfromthischeckboxtosearchalltopics.Matchsimilarwords—Broadensasearchtoreturntopicsthatcontainwordssimilartothesearchterms.Forexample,asearchfor"program"liststopicsthatincludethewords"programs,""programming,"andsoon.Searchtitlesonly—Searchesonlyinthetitlesoftopics.
PrintingHelpFileTopics(WindowsOnly)CompletethefollowingstepstoprintanentirebookfromtheContentstab:
1. Right-clickthebook.2. SelectPrintfromtheshortcutmenutodisplaythePrintTopics
dialogbox.3. SelectthePrinttheselectedheadingandallsubtopicsoption.
NoteSelectPrinttheselectedtopicifyouwanttoprintthesingletopicyouhaveselectedintheContentstab.
4. ClicktheOKbutton.
PrintingPDFDocumentsThishelpfilemaycontainlinkstoPDFdocuments.ToprintPDFdocuments,clicktheprintbuttonlocatedontheAdobeAcrobatViewertoolbar.
GettingStartedwithNI-DAQmxThissectionprovidesanoverviewofNI-DAQ,includingadiscussionofthedifferencesbetweenNI-DAQmxandTraditionalNI-DAQ(Legacy).ItalsoincludesinformationonconfiguringtasksandpointersonhowtocreateNI-DAQmxapplicationsindifferentADEs,suchasLabWindows/CVIandLabVIEW.
NI-DAQ8.xOverviewNationalInstrumentsmeasurementdevicesarepackagedwithNI-DAQdriversoftware,anextensivelibraryoffunctionsandVIsyoucancallfromyourapplicationsoftware,suchasLabVIEWorLabWindows/CVI,toprogramyourNImeasurementdevices.MeasurementdevicesincludeDAQdevicessuchastheMSeriesmultifunctionI/O(MIO)devices,signalconditioningmodules,andswitchmodules.Driversoftwarehasanapplicationprogramminginterface(API),whichisalibraryofVIs,functions,classes,attributes,andpropertiesforcreatingapplicationsforyourdevice.NI-DAQ8.xcomeswiththelatestversionofthesoftwaredriver,whichiscalledNI-DAQmx.NI-DAQmxreplacesTraditionalNI-DAQ(Legacy).NI-DAQmxandTraditionalNI-DAQ(Legacy)havetheirownAPIs,hardwareconfigurations,andsoftwareconfigurations.NI-DAQmxCDsalsoincludeLabVIEWSignalExpressLE,aneasy-to-useconfiguration-basedtoolspecificallydesignedfordataloggingapplications.
NI-DAQmxNI-DAQmxhasthefollowingadvantagesoverTraditionalNI-DAQ(Legacy):
DAQAssistant—agraphicalwaytoconfigurevirtualchannelsandmeasurementtasksforyourdevice,andtogenerateNI-DAQmxcodebasedonyourvirtualchannelsandtasks,foruseinLabVIEW,LabVIEWSignalExpress,LabWindows/CVI,andMeasurementStudio.Increasedperformance,includingfastersingle-pointanalogI/Oandmultithreading.NI-DAQmxsimulateddevicesfortestingandmodifyingapplicationswithoutplugginginhardware.Simpler,moreintuitiveAPIsforcreatingDAQapplicationsusingfewerfunctionsandVIsthanearlierversionsofNI-DAQ.ExpandedfunctionalityforLabVIEW,includingpropertynodesandwaveformdatatypesupport.SimilarAPIsandfunctionalityforANSIC,LabWindows/CVI,andMeasurementStudio,includingnative.NETandC++interfaces.ImprovedsupportandperformancefortheLabVIEWReal-TimeModule.
TraditionalNI-DAQ(Legacy)TraditionalNI-DAQ(Legacy)isanupgradeoftheearlierversionofNI-DAQ.TraditionalNI-DAQ(Legacy)hasthesameVIsandfunctionsandworksthesamewayasNI-DAQ6.9.3,exceptyoucanuseTraditionalNI-DAQ(Legacy)andNI-DAQmxonthesamecomputer,andsomehardwareisnolongersupported.
WhoCanUseNI-DAQmxYoushouldinstallanduseNI-DAQmxifthefollowingsituationsapply:
YouareanewNI-DAQuser.YouareusingdevicessupportedbyNI-DAQmx;refertotheNI-DAQReadmeforalistofsupporteddevices.YouareusingWindowsVista/2000/NT/XP.
IfyouareusingNIapplicationsoftwarewithNI-DAQmx,youmustuseLabVIEW,LabWindows/CVI,orMeasurementStudioversion7.xorlater,LabVIEWSignalExpress2.xorlater(includingSignalExpressLE),ortheLabVIEWReal-TimeModule7.1orlater.IfyouuseoneoftheMicrosoft.NETlanguages,VisualC#and/orVisualBasic.NET,oradevicesupportedonlybyNI-DAQmx,suchasanMSeriesdevice,youmustuseNI-DAQmx.YoualsocanuseNI-DAQmxwithasupportedcompiler,suchasanANSICcompiler.
WhoMustUseTraditionalNI-DAQ(Legacy)InstallanduseTraditionalNI-DAQ(Legacy)ifoneofthefollowingsituationsapply:
YouhaveadevicethatisnotsupportedbyNI-DAQmx,suchastheATESeriesmultifunctionDAQdevices.YouareusingaversionofLabVIEW,LabWindows/CVI,orMeasurementStudioearlierthanversion7.0.YouareupgradingfromNI-DAQ6.9.xandhaveexistingapplicationsthatyoudonotwanttoporttoNI-DAQmxnow.NoteTheearliestversionofNIapplicationsoftwaresupportedbyTraditionalNI-DAQ(Legacy)isversion6.0.LabVIEW,LabWindows/CVI,orMeasurementStudioversions6.xcanuseTraditionalNI-DAQ(Legacy)fromtheNI-DAQ8.xdistribution.
ConfiguringaTaskDAQAssistantIntroductiontoMAXCapabilitiesofMAX
DAQAssistantTheDAQAssistantisagraphicalinterfaceforconfiguringmeasurementtasks,channels,andscales.UsingtheDAQAssistant,youcaninteractivelybuildameasurementchannelortaskforuseinLabVIEW7.xorlater,LabVIEWSignalExpress2.xorlater,LabWindows/CVI7.xorlater,andMeasurementStudio7.xorlater.WiththeseNIapplicationsoftwarepackages,youalsocanusetheDAQAssistanttogeneratecodeforuseinyourapplications.RefertotheDAQAssistantHelpforadditionalinformation.SeeAlsoCreatingChannelsandTaskswiththeDAQAssistant
IntroductiontoMeasurement&AutomationExplorer(MAX)YouconfigureyourNImeasurementandsignalconditioningdeviceswithMAX.MAXinformsotherprogramswhichdevicesyouhaveinyoursystemandhowtheyareconfigured.UseMAXtoadd,configure,test,andremoveameasurementdeviceorsignalconditioningdevice.TocheckthesystemresourcesusedbyaDAQdeviceandtoselectattachedaccessories,expandDevicesandInterfacesintheconfigurationtree,andright-clickthedeviceforoptions.Formoreinformation,refertoMeasurement&AutomationExplorerHelpforNI-DAQmx.
CapabilitiesofMAXforNI-DAQmxYoucanuseMAXforthefollowingmeasurementconfigurationactions:
Configuringresourcesandotherdevice-specificsettingsforDAQdevicesinyoursystemTestingtheresourcesandthefunctionalityofDAQdevicesinyoursystemConfiguringchannels,scales,andtasksusingtheDAQAssistantCreatingandconfiguringNI-DAQmxsimulateddevices
WhenyourunanapplicationusingNI-DAQ,thesoftwarereadstheconfigurationtodeterminethedevicesyouconfigured.Therefore,youmustconfigureDAQdevicesfirstwithMAX.RefertoMeasurement&AutomationExplorerHelpforNI-DAQmxformoreinformationaboutconfiguringandtestingDAQdevices.
ExportingandImportingaConfigurationinMAXYoucansavevirtualchannels,tasks,devices,andtheirrelationshipsforreuseinothersystemsalsorunningMAX.Toreuseaconfiguration,youmustfirstexportachannel,task,ordeviceconfiguration.Exportingtheconfigurationcreatesan.nceconfigurationfilethatyoucanthenimportintoanothersystemwithMAX.UsingtheImportandExportfeaturesinMAX,youcancreateanNI-DAQmxsimulatedversionofaphysicaldeviceorimportanNI-DAQmxsimulateddeviceconfigurationontoaphysicaldevice.Fordetailedinstructionsonhowtoexportandimportconfigurationsfordeployment,refertoMeasurement&AutomationExplorerHelpforNI-DAQmx.
NoteWhenyouuseLabWindows/CVItocreateadistribution,youcanspecifytoinvoketheMAXConfigurationExportWizardtoincludethehardwareconfigurationsinyourdeployedapplication.
Youcanalsoprogrammaticallyimportandexportconfigurationfiles.Formoreinformation,refertotheMAXConfigurationVIReferenceforLabVIEWortheMAXConfigurationFunctionReferenceforLabWindows/CVI.
DistributedApplicationsYoucanusetheDAQmxI/OServertobindtoaglobalvirtualchannelcreatedinMAXortoaDAQchannelcreatedinLabVIEWProject.YoucanusethenetworkvariableinLabVIEWProjecttobindtothechannel,oryoucanuseathird-partyOPC.RefertotheNI-DAQmxtopicsintheLabVIEWdocumentationforinstructionsonbindingtoaDAQchannelusingLabVIEWProject.
GettingStartedinyourADELabVIEWLabVIEWSignalExpressLabWindows/CVIMeasurementStudio.NETwithoutMeasurementStudioANSICwithoutLabWindows/CVI
CreatinganApplicationwithLabVIEWIfyouprogramyourNI-DAQmx-supporteddeviceinLabVIEW,youcaninteractivelycreatevirtualchannels—bothglobalandlocal—andtasksbylaunchingtheDAQAssistantfromMAXorfromwithinLabVIEW.RefertotheDAQAssistantHelpforadditionalinformation.Youalsocancreatelocalvirtualchannelsandtasks,andwriteyourownapplicationsusingtheNI-DAQmxAPI.TogetstartedinLabVIEW,followthesegeneralsteps:
1. OpenanexistingornewLabVIEWVI.2. BuildyourVI,usingtheNI-DAQmxVIsandproperties.
ForhelpwithNI-DAQmxVIs,refertoLabVIEWNI-DAQmxVIReferenceHelp.ForgeneralhelpwithprogramminginLabVIEW,refertoLabVIEWHelp.
CreatinganApplicationinLabVIEWSignalExpressIfyouuseyourNI-DAQmx-supporteddeviceinLabVIEWSignalExpress,youcancreateaprojectthatincludesNI-DAQmxsteps.WithLabVIEWSignalExpress,youcanlogandanalyzedata.YoucanalsoaddglobalvirtualchannelsthatyoucreatedinMAXtoyourNI-DAQmxstepsinLabVIEWSignalExpress.RefertotheDAQAssistantHelpforadditionalinformation.TogetstartedinLabVIEWSignalExpress,followthesegeneralsteps:
1. ClickAddStepandselectAcquireSignals»AcquireDAQmx»AnalogInput»VoltagetodroptheDAQmxAcquireStep.
2. Clickthe+buttontoaddachanneltotheNI-DAQmxstep.ForhelpwithusingtheDAQAssistantwithLabVIEWSignalExpress,refertoTakinganNI-DAQmxMeasurementinLabVIEWSignalExpress.ForgeneralhelpwithprogramminginLabVIEWSignalExpress,refertoLabVIEWSignalExpressHelp.
CreatinganApplicationwithLabWindows/CVIIfyouprogramyourNI-DAQmx-supporteddeviceinLabWindows/CVI,youcaninteractivelycreateglobalorlocalvirtualchannelsandtasksbylaunchingtheDAQAssistantfromMAXorfromwithinLabWindows/CVI.YoucangeneratetheconfigurationcodebasedonyourtaskorchannelinLabWindows/CVI.RefertotheDAQAssistantHelpforadditionalinformationaboutgeneratingcode.Youalsocancreatelocalvirtualchannelsandtasks,andwriteyourownapplicationsusingtheNI-DAQmxAPI.Tocreateanapplication,followthesegeneralsteps:
1. Createanewprojectfile(.prj).2. Openanexistingornewsourcefile(.c).3. Addyoursourcefiletotheproject.4. SelectNI-DAQmxfromtheLibraryTree,andchoosethefunction
panelyouwanttouse.5. ToviewexamplesofNI-DAQmxapplicationsinLabWindows/CVI,
launchtheNIExampleFinder.6. Buildyourapplication.
ForhelpwithNI-DAQmxfunctions,refertoNI-DAQmxCFunctionReferenceHelp.ForgeneralhelpwithprogramminginLabWindows/CVI,refertoLabWindows/CVIHelp,accessiblethroughStart»AllPrograms»NationalInstruments»LabWindowsCVI»LabWindowsCVIHelp.
CreatinganApplicationinMeasurementStudiowithVisualC++,VisualC#,orVisualBasic.NETIfyouprogramyourNI-DAQmx-supporteddeviceinMeasurementStudiousingVisualC++,VisualC#,orVisualBasic.NET,youcaninteractivelycreatechannelsandtasksbylaunchingtheDAQAssistantfromMAXorfromwithinVisualStudio.NET.YoucangeneratetheconfigurationcodebasedonyourtaskorchannelinMeasurementStudio.RefertotheDAQAssistantHelpforadditionalinformationaboutgeneratingcode.Youalsocancreatechannelsandtasks,andwriteyourownapplicationsinyourADEusingtheNI-DAQmxAPI.ForhelpwithNI-DAQmxmethodsandproperties,refertotheNI-DAQmx.NETClassLibraryortheNI-DAQmxVisualC++ClassLibraryincludedintheNIMeasurementStudioHelp.ForgeneralhelpwithprogramminginMeasurementStudio,refertotheNIMeasurementStudioHelp,whichisfullyintegratedwiththeMicrosoftVisualStudio.NEThelp.ToviewthishelpfileinVisualStudio.NET,selectMeasurementStudio»NIMeasurementStudioHelp.TocreateanapplicationinVisualC++,VisualC#,orVisualBasic.NET,followthesegeneralsteps:
1. InVisualStudio.NET,selectFile»New»ProjecttolaunchtheNewProjectdialogbox.
2. FindtheMeasurementStudiofolderforthelanguageyouwanttocreateaprogramin.
3. Chooseaprojecttype.YouaddDAQtasksasapartofthisstep.
Creatinga.NETApplicationwithoutMeasurementStudioWiththeMicrosoft.NETFrameworkversion1.1orlater,youcanuseNI-DAQmxtocreateapplicationsusingVisualC#andVisualBasic.NETwithoutMeasurementStudio.YouneedMicrosoftVisualStudio.NET2003orMicrosoftVisualStudio2005fortheAPIdocumentationtobeinstalled.TheinstalleddocumentationcontainstheNI-DAQmxAPIoverview,measurementtasksandconcepts,andfunctionreference.ThishelpisfullyintegratedintotheVisualStudio.NETdocumentation.ToviewtheNI-DAQmx.NETdocumentation,gotoStart»AllPrograms»NationalInstruments»NI-DAQ»NI-DAQmx.NETReferenceHelp.ExpandNIMeasurementStudioHelp»NIMeasurementStudio.NETClassLibrary»Referencetoviewthefunctionreference.ExpandNIMeasurementStudioHelp»NIMeasurementStudio.NETClassLibrary»UsingtheMeasurementStudio.NETClassLibrariestoviewconceptualtopicsforusingNI-DAQmxwithVisualC#andVisualBasic.NET.TogettothesamehelptopicsfromwithinVisualStudio,gotoHelp»Contents.SelectMeasurementStudiofromtheFilteredBydrop-downlistandfollowthepreviousinstructions.
CreatinganANSICApplicationwithoutLabWindows/CVINI-DAQmxhasaCAPIthatyoucanusetocreateapplications.Tocreateanapplication,followthesegeneralsteps:
1. Createanewproject.2. Openexistingornewsourcefiles(.c),andaddthemtothe
project.MakesureyouincludetheNI-DAQmxheaderfile,nidaqmx.h,inyoursourcecodefiles.YoucanfindthisheaderfileatNI-DAQ\DAQmxANSICDev\include.
3. AddtheNI-DAQmximportlibrary,nidaqmx.lib,totheproject.TheimportlibraryfilesarelocatedunderNI-DAQ\DAQmxANSICDev\lib\.
4. ToviewexamplesofNI-DAQmxapplications,gototheNI-DAQ\Examples\DAQmxANSICdirectory.
5. Buildyourapplication.ForhelpwithNI-DAQmxfunctions,refertotheNI-DAQmxCReferenceHelp,whichisinstalledbydefaultatStart»AllPrograms»NationalInstruments»NI-DAQ»NI-DAQmxCReferenceHelp.
ExamplesEachAPIincludesacollectionofprogrammingexamplestohelpyougetstarteddevelopinganapplication.Youcanmodifyexamplecodeandsaveitinanapplication.Youcanuseexamplestodevelopanewapplicationoraddexamplecodetoanexistingapplication.Torunexampleswithouthardwareinstalled,youcanuseanNI-DAQmxsimulateddevice.InMAX,refertotheMeasurement&AutomationExplorerHelpforNI-DAQmxbyselectingHelp»HelpTopics»NI-DAQmxforinformationonNI-DAQmxsimulateddevices.Tofindthelocationsofexamplesforyoursoftwareapplication,refertothefollowingtable.
SoftwareApplication ExampleLocationLabVIEWorLabWindows/CVI Help»FindExamplesLabVIEWSignalExpress ProgramFiles\National
Instruments\SignalExpress\ExamplesANSIC *...NI-DAQ\Examples\DAQmxANSICMFC7.0C++ *...NI-DAQ\Examples\MStudioVC2003VisualBasic.NETandC#forVisualStudio2003
*...NI-DAQ\Examples\DotNET1.1
MFC8.0C++ *...NI-DAQ\Examples\MStudioVC2005VisualBasic.NETandC#forVisualStudio2005
*...NI-DAQ\Examples\DotNET2.0
*ForWindowsXP,thedefaultpathis<drive>:\DocumentsandSettings\AllUsers\Documents\NationalInstruments\NI-DAQ\Examples\....ForWindowsVista,thedefaultpathis<drive>:\Users\Public\Documents\NationalInstruments\NI-DAQ\Examples\....
NoteVisualStudio2003andVisualStudio2005donotrequireMeasurementStudio.
TroubleshootingInstallationandConfigurationRefertotheDAQGettingStartedGuideandtheSCXIQuickStartGuideforgeneralinstallationandconfigurationinstructions.UsethefollowingresourcesifyouhaveproblemsinstallingyourDAQhardwareand/orsoftware:
Fortroubleshootinginstructions,refertotheHardwareInstallation/ConfigurationTroubleshooteratni.com/support/install.Refertoni.com/kbfordocumentsontroubleshootingcommoninstallationandprogrammingproblemsandforansweringfrequentlyaskedquestionsaboutNIproducts.IfyouthinkyouhavedamagedyourdeviceandneedtoreturnyourNationalInstrumentshardwareforrepairorcalibration,refertoni.com/supportandsearchonSendingaBoardforRepairorCalibrationtolearnhowtobegintheReturnMerchandiseAuthorization(RMA)process.
ForLabWindows/CVIusers,iftheDataAcquisitionfunctionpanelisdisabled,youmayneedtouninstallNI-DAQandreinstallit,makingsurethatyouaddsupportforLabWindows/CVI.IfyouhaveinstalledLabWindows/CVIsupportandDataAcquisitionisstilldimmed,selectLibrary»Customize.IntheCustomizeLibraryMenudialogbox,checkDataAcquisition,andrestartLabWindows/CVI.Youmightalsoneedtoverifythatthedataacq.libisinthebindirectory.
ProgrammingTohelpyougetstartedprogramming,youcanusetheshippingexamplesforyourADE.YoucanalsovisitNI'sextensivelibraryoftechnicalsupportresourcesatni.com/support.YoucaninteractivelyconfigureglobalvirtualchannelsandtaskswiththeDAQAssistant.ForNIapplicationsoftwaresuchasLabVIEW,youcanusetheDAQAssistanttogeneratecode.Finally,theNI-DAQmxHelpcontainsprogrammingflowchartsforcommonapplicationssuchasmeasuringtemperature,current,strain,position,andacceleration.
ExternalConnectionsInadditiontotheinformationonmakingsignalconnectionsinthishelpfile,theConnectionDiagramtabintheDAQAssistantwithinMAXshowsyouhowtoconnectsignals.
CalibrationForinformationonexternallycalibratingyourdevice,includingstep-by-stepcalibrationprocedures,refertoni.com/calibration.Foranoverviewofcalibration,includingthedifferencebetweenself-calibrationandexternalcalibration,refertoCalibration.Fordevice-specificinformationrequiredforcalibrationwithNI-DAQmx,refertoDevice-SpecificCalibration.Forinformationonchannelcalibration,refertoWhatIsChannelCalibration?
CPUUsageNI-DAQmxtasksuse100%oftheCPUifnootherprocessesarerunning.However,assoonasanotherprocessrequirestheCPU,theNI-DAQmxtaskyieldstothatprocess.
TroubleshootinganSCXISystemThefollowingaresometipstohelpyoutroubleshootproblemswithanSCXIsystem:
CanMAXestablishcommunicationwiththechassis?Ifnot,tryoneorallofthefollowing:ConnecttheDAQdevicetoadifferentmoduleinthechassis.Tryadifferentcableassembly.Tryadifferentchassis.TryadifferentDAQdevice.Ifyouhavemultiplechassis,disconnectthemandreconnectthemoneatatimetoisolatetheproblem.MakesurethateachSCXIchassisconnectedtoasingleDAQdevicehasauniqueaddress.IfyouhavemultipleSCXImodules,removeallthemodulesandtesteachmoduleindividually.Ifaparticularchassisdoesnotwork,tryanotherone.Ifyouaregettingerroneousreadingsfromyoursignalsource,disconnectthesignalsourceandshorttheinputchanneltoground.Youshouldgeta0Vreading.Alternately,connectabatteryorotherknownsignalsourcetotheinputchannel.Runanexampleprogramtoseeifyoustillgeterroneousresults.
FrequentlyAskedQuestions(FAQ)Foranswerstofrequentlyaskedquestions,visittheNI-DAQmxFAQ.
GenericProgrammingFlowchartsThissectioncontainsgeneralprogrammingflowchartsthatyoucanusewhencreatinganapplication.Youalsocanfindprogrammingflowchartsfortypicalapplications—suchasmeasuringtemperature,measuringcurrent,andmeasuringstrain—intheCommonApplicationssectionofthishelpfile.Intheprogrammingflowcharts,manyapplicationsalsoincludeexplicitcontrolfunctionstostart,stop,andclearthetask.Forinstance,forapplicationsthatuseyourcounter/timer,suchasfinitecounterinput,youneedtocalltheStartfunction/VItoarmthecounter.InLabVIEW,clearingoccursautomatically.ForotherADEs,youmustincludethesefunctionsinyourapplication.FunctionsandVIsproducethecorefunctionalityoftheNI-DAQmxAPI.Forinstance,NI-DAQmxincludesfunctionsfortiming,triggering,reading,andwritingsamples.However,foradvancedfunctionality,VisualC++,VisualC#,VisualBasic.NET,andLabVIEWrequireproperties.ANSICandLabWindows/CVIemploytheGetandSetAttributefunctions.Formoreinformation,refertotheprogrammingreferencehelpforyourADE.
AnalogInputProgrammingFlowchartsSingleSampleAnalogInputFiniteAnalogInputContinuousAnalogInput
AnalogOutputProgrammingFlowchartsSingleSampleAnalogOutputFiniteAnalogOutputContinuousAnalogOutput
DigitalInputProgrammingFlowchartsSingleSampleDigitalInputFiniteDigitalInputContinuousDigitalInput
DigitalOutputProgrammingFlowchartsSingleSampleDigitalOutputFiniteDigitalOutputContinuousDigitalOutput
MeasuringCounterValues(CounterInput)ProgrammingFlowchartsSinglePointCounterInputFiniteCounterInputContinuousCounterInput
AnalogInputProgrammingFlowchartsThissectioncontainsgeneralprogrammingflowchartsthatyoucanusewhencreatinganapplication.Youalsocanfindprogrammingflowchartsfortypicalapplications—suchasmeasuringtemperature,measuringcurrent,andmeasuringstrain—intheCommonApplicationssectionofthishelpfile.FunctionsandVIsprovidethecorefunctionalityoftheNI-DAQmxAPI.Forinstance,NI-DAQmxincludesfunctionsfortiming,triggering,reading,andwritingsamples.However,foradvancedfunctionality,VisualC++,VisualC#,VisualBasic.NET,andLabVIEWrequireproperties.ANSICandLabWindows/CVIemploytheGetandSetAttributefunctions.Formoreinformation,refertotheprogrammingreferencehelpforyourADE.
AnalogInputProgrammingFlowchartsSingleSampleAnalogInputFiniteAnalogInputContinuousAnalogInputTriggeredAcquisition
SingleSampleAnalogInputProgrammingFlowchartAcquiringasinglesampleisanon-demandoperation.Inotherwords,NI-DAQmxacquiresonevaluefromaninputchannelandimmediatelyreturnsthevalue.Thisoperationdoesnotrequireanybufferingorhardwaretiming.Forexample,ifyouperiodicallyneededtomonitorthefluidlevelinatank,youacquiresingledatapoints.Youcanconnectthetransducerthatproducesavoltagerepresentingthefluidleveltoasinglechannelonyourmeasurementdeviceandinitiateasingle-channel,single-pointacquisitionwhenyouwanttoknowthefluidlevel.WithNI-DAQmx,youalsocangatherdatafrommultiplechannels.Forinstance,youmightwanttomonitorthefluidlevelinthetankaswellasthetemperature.Inthiscase,youneedtwotransducersconnectedtotwochannelsonyourdevice.Thefollowingflowchartdepictsthestepstoprogrammaticallycreateasinglesampleanaloginputapplication.Ifyouprefer,youcanconfigureataskforacquiringasinglesampleusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
FiniteAnalogInputProgrammingFlowchartOnewaytoacquiremultiplesamplesforoneormorechannelsistoacquiresinglesamplesinarepetitivemanner.However,acquiringasinglesampleononeormorechannelsoverandoverisinefficientandtimeconsuming.Moreover,youdonothaveaccuratecontroloverthetimebetweeneachsampleorchannel.Instead,youcanusehardwaretiming,whichusesabufferincomputermemorytoacquiredatamoreefficiently.Programmatically,youneedtoincludethetimingfunction,specifyingthesamplerateandthesamplemode(finite).Aswithotherfunctions,youcanacquiremultiplesamplesforasinglechannelormultiplechannels.YoucanconfigureataskforfiniteanaloginputusingtheDAQAssistant.
ContinuousAnalogInputProgrammingFlowchartIfyouwanttoview,process,orlogasubsetofthesamplesastheyarebeingacquired,youneedtocontinuallyacquiresamples.Forthesetypesofapplications,setthesamplemodetocontinuous.ThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationformeasuringvoltage.Instead,youcanconfigureataskforcontinuousanaloginputusingtheDAQAssistant.
AnalogOutputProgrammingFlowchartsThissectioncontainsgeneralprogrammingflowchartsthatyoucanusewhencreatinganapplication.Youalsocanfindprogrammingflowchartsfortypicalapplications—suchasgeneratingvoltageandgeneratingcurrent—intheCommonApplicationssectionofthishelpfile.Intheprogrammingflowcharts,manyapplicationsalsoincludeexplicitcontrolfunctionstostart,stop,andclearthetask.InLabVIEW,clearingoccursautomatically.ForotherADEs,youmustincludethesefunctionsinyourapplication.FunctionsandVIsprovidethecorefunctionalityoftheNI-DAQmxAPI.Forinstance,NI-DAQmxincludesfunctionsfortiming,triggering,reading,andwritingsamples.However,foradvancedfunctionality,VisualC++,VisualC#,VisualBasic.NET,andLabVIEWrequireproperties.ANSICandLabWindows/CVIemploytheGetandSetAttributefunctions.Formoreinformation,refertotheprogrammingreferencehelpforyourADE.
AnalogOutputProgrammingFlowchartsSingleSampleAnalogOutputFiniteAnalogOutputContinuousAnalogOutput
SingleSampleAnalogOutputProgrammingFlowchartGeneratingasinglesampleisanon-demandoperation.Inotherwords,NI-DAQmxgeneratesonevaluefromaninputchannelandimmediatelyreturnsthevalue.Thisoperationdoesnotrequireanybufferingorhardwaretiming.WithNI-DAQmx,youalsocangeneratesamplesfrommultiplechannels.Ifyouprefer,youcanconfigureataskforgeneratingasinglesampleusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesarewritten,includetheStartfunction/VIandStopfunction/VIinyourapplication.Intheprecedingflowchart,theStartfunction/VIwouldcomejustbeforeyouwritesamples,andStopwouldcomejustbeforeyouclearthetask.
FiniteAnalogOutputProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtogenerateafinitenumberofvoltagesamplesinabufferedgeneration.Ifyouprefer,youcanconfigurethistaskusingtheDAQAssistant.
ContinuousAnalogOutputProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtocontinuouslygeneratevoltagesamples.Ifyouprefer,youcanconfigurethistaskusingtheDAQAssistant.
CounterProgrammingFlowchartsThissectioncontainsgeneralprogrammingflowchartsthatyoucanusewhencreatinganapplication.Youalsocanfindprogrammingflowchartsfortypicalapplications—suchascountingedgesandgeneratingpulses—intheCommonApplicationssectionofthishelpfile.Intheprogrammingflowcharts,manyapplicationsalsoincludeexplicitcontrolfunctionstostart,stop,andclearthetask.Forinstance,forapplicationsthatuseyourcounter,suchascountingedgesormeasuringperiod,youneedtocalltheStartfunction/VItoarmthecounter.InLabVIEW,clearingoccursautomatically.ForotherADEs,youmustincludethesefunctionsinyourapplication.FunctionsandVIsprovidethecorefunctionalityoftheNI-DAQmxAPI.Forinstance,NI-DAQmxincludesfunctionsfortiming,triggering,reading,andwritingsamples.However,foradvancedfunctionality,VisualC++,VisualC#,VisualBasic.NET,andLabVIEWrequireproperties.ANSICandLabWindows/CVIemploytheGetandSetAttributefunctions.Formoreinformation,refertotheprogrammingreferencehelpforyourADE.
CounterInputProgrammingFlowchartsSinglePointCounterInputFiniteCounterInputContinuousCounterInput
SinglePointCounterInputProgrammingFlowchartThefollowingflowchartdepictsthemainstepsyoumustcompleteforanon-demandcountingapplication.Ifyouprefer,youcanconfigurethistaskusingtheDAQAssistant.
FiniteCounterInputProgrammingFlowchartThefollowingflowchartdepictsthemainstepsyoumustcompleteforfinitecounterinputinanNI-DAQmxapplication.Ifyouprefer,youcanconfigurethistaskusingtheDAQAssistant.
1Time-basedmeasurementsincludeperiod,semi-period,pulsewidth,two-edgeseparation,anddigitalfrequency.2Edgecounting-basedmeasurementsincludeedgecounting,encoder-basedpositionmeasurements,andGPStimestampmeasurements.
ContinuousCounterInputProgrammingFlowchartThefollowingflowchartdepictsthemainstepsyoumustcompleteforcontinuouscountinginanNI-DAQmxapplication.Ifyouprefer,youcanconfigurethistaskusingtheDAQAssistant.
1Time-basedmeasurementsincludeperiod,semi-period,pulsewidth,two-edgeseparation,anddigitalfrequency.2Edgecounting-basedmeasurementsincludeedgecounting,encoder-basedpositionmeasurements,andGPStimestampmeasurements.
DigitalInputProgrammingFlowchartsThissectioncontainsgeneralprogrammingflowchartsthatyoucanusewhencreatinganapplication.Youalsocanfindprogrammingflowchartsfortypicalapplications—suchasmeasuringadigitalvalue—intheCommonApplicationssectionofthishelpfile.Intheprogrammingflowcharts,manyapplicationsalsoincludeexplicitcontrolfunctionstostart,stop,andclearthetask.InLabVIEW,clearingoccursautomatically.ForotherADEs,youmustincludethesefunctionsinyourapplication.FunctionsandVIsprovidethecorefunctionalityoftheNI-DAQmxAPI.Forinstance,NI-DAQmxincludesfunctionsfortiming,triggering,reading,andwritingsamples.However,foradvancedfunctionality,VisualC++,VisualC#,VisualBasic.NET,andLabVIEWrequireproperties.ANSICandLabWindows/CVIemploytheGetandSetAttributefunctions.Formoreinformation,refertotheprogrammingreferencehelpforyourADE.
DigitalInputProgrammingFlowchartsSingleSampleDigitalInputFiniteDigitalInputContinuousDigitalInput
SingleSampleDigitalInputProgrammingFlowchartAcquiringasinglesampleisanon-demandoperation.Inotherwords,NI-DAQmxacquiresonevaluefromaninputchannelandimmediatelyreturnsthevalue.Thisoperationdoesnotrequireanybufferingorhardwaretiming.Forexample,ifyouperiodicallyneededtomonitorthefluidlevelinatank,youacquiresingledatapoints.Youcanconnectthetransducerthatproducesavoltagerepresentingthefluidleveltoasinglechannelonyourmeasurementdeviceandinitiateasingle-channel,single-pointacquisitionwhenyouwanttoknowthefluidlevel.WithNI-DAQmx,youalsocangatherdatafrommultiplechannels.Forinstance,youmightwanttomonitorthefluidlevelinthetankaswellasthetemperature.Inthiscase,youneedtwotransducersconnectedtotwochannelsonyourdevice.Thefollowingflowchartdepictsthestepstoprogrammaticallycreateanapplicationtomeasuredigitalvalues.Ifyouprefer,youcanconfigureataskforacquiringasinglesampleusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
FiniteDigitalInputProgrammingFlowchartOnewaytoacquiremultiplesamplesforoneormorechannelsistoacquiresinglesamplesinarepetitivemanner.However,acquiringasingledatasampleononeormorechannelsoverandoverisinefficientandtimeconsuming.Moreover,youdonothaveaccuratecontroloverthetimebetweeneachsampleorchannel.Instead,youcanusehardwaretiming,whichusesabufferincomputermemorytoacquiredatamoreefficiently.Programmatically,youneedtoincludethetimingfunction,specifyingthesamplerateandthesamplemode(finite).Aswithotherfunctions,youcanacquiremultiplesamplesforasinglechannelormultiplechannels.YoucanconfigureataskformeasuringdigitalvaluesusingtheDAQAssistant.
NoteTriggeringandSampleClocktimingforDigitalI/Oarenotsupportedonalldevices.
ContinuousDigitalInputProgrammingFlowchartIfyouwanttoview,process,orlogasubsetofthesamplesastheyarebeingacquired,youneedtocontinuallyacquiresamples.Forthesetypesofapplications,setthesamplemodetocontinuous.ThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationforacquiringdigitalsignals.YoucanconfigureataskforcontinuouslyacquiringdigitalvaluesusingtheDAQAssistant.
NoteSampleclocktimingforDigitalI/Oisnotsupportedonalldevices.
DigitalOutputProgrammingFlowchartsThissectioncontainsgeneralprogrammingflowchartsthatyoucanusewhencreatinganapplication.YoualsocanfindprogrammingflowchartsfortypicalapplicationsintheCommonApplicationssectionofthishelpfile.Intheprogrammingflowcharts,manyapplicationsalsoincludeexplicitcontrolfunctionstostart,stop,andclearthetask.Forinstance,forapplicationsthatuseyourcounter/timer,suchascountingedgesormeasuringperiod,youneedtocalltheStartfunction/VItoarmthecounter.InLabVIEW,clearingoccursautomatically.ForotherADEs,youmustincludethesefunctionsinyourapplication.FunctionsandVIsprovidethecorefunctionalityoftheNI-DAQmxAPI.Forinstance,NI-DAQmxincludesfunctionsfortiming,triggering,reading,andwritingsamples.However,foradvancedfunctionality,VisualC++,VisualC#,VisualBasic.NET,andLabVIEWrequireproperties.ANSICandLabWindows/CVIemploytheGetandSetAttributefunctions.Formoreinformation,refertotheprogrammingreferencehelpforyourADE.
DigitalOutputProgrammingFlowchartsSingleSampleDigitalOutputFiniteDigitalOutputContinuousDigitalOutput
SingleSampleDigitalOutputProgrammingFlowchartGeneratingasinglesampleisanon-demandoperation.Inotherwords,NI-DAQmxgeneratesonevalueonanoutputchannelimmediatelyaftertheWritefunction/VIiscalled.Thisoperationdoesnotrequireanybufferingorhardwaretiming.WithNI-DAQmx,youalsocangeneratesamplesfrommultiplechannels.Ifyouprefer,youcanconfigureataskforgeneratingasinglesampleusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesarewritten,includetheStartfunction/VIandStopfunction/VIinyourapplication.Intheprecedingflowchart,theStartfunction/VIwouldcomejustbeforeyouwritesamples,andStopwouldcomejustbeforeyouclearthetask.
FiniteDigitalOutputProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtogenerateafinitenumberofdigitalvaluesinabufferedgeneration.Ifyouprefer,youcanconfigureataskforgeneratingdigitalvaluesusingtheDAQAssistant.
NoteSampleclocktimingforDigitalI/Oisnotsupportedonalldevices.
ContinuousDigitalOutputProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtocontinuouslygeneratedigitalvalues.Ifyouprefer,youcanconfigureataskforgeneratingdigitalvaluesusingtheDAQAssistant.
NoteSampleclocktimingforDigitalI/Oisnotsupportedonalldevices.
TriggeredAcquisitionProgrammingFlowchartThefollowingflowchartdepictsthemainstepsyoufollowforaddingtriggeringtoanacquisition.Ifyouprefer,youcanconfiguretriggeringwiththeDAQAssistant.
MeasuringTemperatureNoteTemperaturemeasurementsmayrequireyoutoconditionthesignal.Theconditioningrequirementsdependonyoursensor.RefertotheOverviewofTemperatureSensorTypesforanexplanationofsensortypesandconditioningrequirements.
UsingaThermocoupletoMeasureTemperatureApopularwaytomeasuretemperaturewithaDAQdeviceistouseathermocouple,asshowninthefollowingfigure,becausethermocouplesareinexpensive,easytouse,andeasytoobtain.Thermocouplesproduceavoltagethatvariesbasedontemperature.Usingathermocouple,youcanmeasureavoltageanduseaformulatoconvertthevoltagemeasurementtotemperature.
Thetypicalwiringforathermocouple,asshowninthefollowingfigure,usesaresistor,R,onlyifthethermocoupleisnotgroundedatanyotherpoint.If,forexample,thethermocoupletipwerealreadygrounded,usingaresistorwouldcauseagroundloopandresultinerroneousreadings.
YoualsocanmeasuretemperatureusingResistanceTemperatureDetectors(RTD)andThermistors.MakingSignalConnectionsCreatingaProgramRTDThermistorThermocouple
Examples
MeasuringTemperaturewithanRTDProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasuretemperaturewithanRTD.Alternatively,youcanconfigureataskformeasuringtemperatureusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringtemperatureisanexampleofanaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringTemperaturewithaThermistorProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasuretemperaturewithathermistor.Alternatively,youcanconfigureataskformeasuringtemperatureusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringtemperatureisanexampleofanaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringTemperaturewithaThermocoupleProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasuretemperaturewithathermocouple.Alternatively,youcanconfigureataskformeasuringtemperatureusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringtemperatureisanexampleofanaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringandGeneratingCurrentManymeasurementdevicescanmeasureandgeneratecurrent.TomeasureorgeneratecurrentwithaDAQdevice,youneedaresistor.Currentthencanbemeasuredthroughananaloginputconnectororgeneratedthroughananalogoutputconnector.Theresistancemustbeplacedinparallelwiththeconnectorandthecurrentsource.Tomeasurevoltagedroppedacrosstheresistorandconvertittocurrent,useOhm'sLaw.I(A)=V(V)/R(Ω)
whereIisthecurrent,Visthevoltage,andRistheresistance.
4to20mALoops4to20milliamp(4-20mA)loopsarecommonlyusedinmeasurementsystems.4-20mAloopscoupleadynamicrangewithalivezeroof4mAforopencircuitdetectioninasystemthatdoesnotproducesparks.Otheradvantagesincludeavarietyofcompatiblehardware,alongoperatingrange,andlowcost.4-20mAloopshaveavarietyofuses,includingdigitalcommunications,controlapplications,andreadingremotesensors.Thepurposeofthe4-20mAcurrentloopisforthesensortotransmitasignalintheformofacurrent.Inthefollowingfigure,theLevelSensorandRemoteSensorElectronicsaretypicallybuiltintoasingleunit.Anexternal24VDCsupplypowersthesensor.Thesensorregulatesthecurrent,whichrepresentsthevalueofwhatthesensormeasures,inthiscase,thefluidlevelinatank.
CurrentLoopWiringTheDAQdevicereadsthevoltagedropacrossthe249ΩresistorRp,usingOhm'sLaw.Becausethecurrentis4-20mAandRpis249Ω,Vrangesfrom0.996Vto4.98V,whichiswithintherangethatDAQdevicescanread.Althoughtheequationisusefulforcalculatingthecurrent,thecurrenttypicallyrepresentsaphysicalquantityyouwanttomeasure.Inthefollowingfigure,thetanklevelmeasures0to50feet.4mArepresents0feet,and20mArepresents50feet.Listhetanklevel,andIisthecurrent.
LinearRelationshipbetweenTankLevelandCurrentUsingtheOhm'sLawequationandsubstituting0.249forthevalueofRp,youcanderiveLintermsofmeasuredvoltage:
MakingSignalConnectionsCreatingaProgramMeasuringCurrentGeneratingCurrent
ExamplesSeeAlsoTipsonMeasuringACCurrent
MeasuringCurrentProgrammingFlowchartThefollowingflowchartillustratesthemainstepsrequiredinanNI-DAQmxapplicationtomeasurecurrent.Alternatively,youcanconfigureataskformeasuringcurrentusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringcurrentisanexampleofananaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
TipsonMeasuringACCurrentTomeasureACcurrent,insertapreciselycalibrated,low-valueresistorintothesignalpathandmeasurethevoltagedropacrosstheresistor.Youmustthenperformhigh-passfilteringontheresultingsignaltoremovetheDCcomponent.Youcanperformthisfilteringusingananalogfilterordigitalsignalprocessingtechniques,suchasthefilteringtoolsintheanalysislibraryofLabVIEW.
MeasuringStrainStrain(ε)istheamountofdeformationofabodyduetoanappliedforce.Specifically,strainisthefractionalchangeinlength,asshowninthefollowingfigure.
Straincanbepositive(tensile)ornegative(compressive).Althoughdimensionless,strainissometimesexpressedinunitssuchasin./in.ormm/mm.Inpractice,themagnitudeofmeasuredstrainisverysmall.Therefore,strainisoftenexpressedasmicrostrain(µε).Whenauniaxialforcestrainsabar,asintheprecedingfigure,aphenomenonknownasPoissonStraincausesthegirthofthebar,D,tocontractinthetransversedirection,whichisperpendiculartotheforce.ThemagnitudeofthistransversecontractionisamaterialpropertyindicatedbyitsPoisson'sRatio.ThePoisson'sRatioofamaterialisthenegativeratioofthestraininthetransversedirectiontothestrainintheaxialdirection,whichisparalleltotheforce.Poisson'sRatioforsteel,forexample,rangesfrom0.25to0.3.Tomeasurestrain,youcanuseoneormorestraingagesinaWheatstonebridgeinoneofseveralbridgeconfigurations.RefertoSignalConditioningRequirementsforStrainGagesformoreinformationaboutstraingagesandbridgeconfigurations.MakingSignalConnectionsCreatingaProgramExamples
MeasuringStrainProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasurestrain.Alternatively,youcanconfigureatasktomeasurestrainwithastraingageusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringstrainisanexampleofananaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringResistanceResistanceistheoppositiontopassageofanelectriccurrent.OneOhm(Ω)istheresistancethroughwhichonevolt(V)ofelectricforcecausesoneampere(A)toflow.Twocommonmethodsformeasuringresistancearethe2-wiremethodandthe4-wiremethod.Bothmethodssendacurrentthrougharesistorwithameasurementdevicemeasuringthevoltagedropfromthesignalbeforeandafteritcrossestheresistor.The2-wiremethodiseasiertoimplement,butthismethodislessaccuratethanthe4-wiremethodforresistancesbelow100Ω.Tocalculateresistance,usethefollowingequation.R(Ω)=V(V)/I(A)
whereRistheresistance,Visthevoltage,andIisthecurrent.MakingSignalConnectionsCreatingaProgramExamples
MeasuringResistanceProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasureresistance.Alternatively,youcanconfigureataskformeasuringresistanceusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Intheprecedingflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringresistanceisanexampleofananaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringVoltageMostmeasurementdevicescanmeasure,orread,voltage.Twocommonvoltagemeasurementsaredirectcurrent(DC)andalternatingcurrent(AC).
MeasuringDCVoltageDCvoltageisusefulformeasuringphenomenathatchangeslowlywithtime,suchastemperature,pressure,orstrain.WithDCsignals,youwanttoaccuratelymeasuretheamplitudeofasignalatagivenpointintime.WindSpeedExampleThefollowingfigureshowsatypicalwiringdiagramforananemometerwithanoutputrangeof0to10V,whichcorrespondstowindspeedof0to200mph.Usethefollowingequationtoscalethedata:
Usingthisequation,ameasurementof3Vwouldcorrespondtoawindspeedof60mph(3V×20mph/V=60mph).Noticethatthewiringdiagraminthefollowingfigureusesaresistor,R,becauseananemometerisusuallynotagroundedsignalsource.Iftheanemometertransducerwerealreadygrounded,usingaresistorwouldcauseagroundloopandresultinerroneousreadings.
AveragingAveragingcanimprovemeasurementaccuracyfornoisyandrapidlychangingsignals.Thefollowingfigureshowswhatanactualwindspeedmightlooklikeovertime.Duetogustingwinds,thespeedvalueslooknoisy.Noticethatthewindspeedreadingof29mphisapeakspeedthatmightgivetheimpressionthatthewindisholdingat29mph.Abetterrepresentationmightbetotaketheaveragespeedoverashortperiodoftime.
Onecommonreasonforaveragingistoeliminate50or60Hzpowerlinenoise.Theoscillatingmagneticfieldaroundpowerlinescanintroducenoisevoltagesonunshieldedtransducerwiring.Becausepowerlinenoiseissinusoidal,orshapedlikeasinewave,theaverageoveroneperiodiszero.Ifyouuseascanratethatisanintegermultipleofthenoiseandaveragedataforanintegermultipleofperiods,youcaneliminatethelinenoise.Oneexamplethatworksforboth50and60Hzistosampleat300samplespersecondandaverage30points.Noticethat300isanintegermultipleofboth50and60.Oneperiodofthe50Hznoiseis300/50=6points.Oneperiodofthe60Hznoiseis300/60=5points.Averaging30pointsisanintegermultipleofbothperiods,soyoucanensurethatyouaveragewholeperiods.
MeasuringACVoltageACvoltageisawaveformthatconstantlyincreases,decreases,andreversespolarity.ACvoltageiscommoninhousehold,lab,andindustrialdevicesbecausemostpowerlinesdeliverACvoltage.YoucanmeasureACvoltagestodeterminethemaximum,minimum,andpeak-to-peakvaluesofasignal.Thepeak-to-peakvalueofasignalisthemaximumvoltageswing,frommaximumtominimum.ACVoltageandRootMeanSquare(RMS)Voltage,current,andpowerarenotconstantvaluesbecauseACsignalsalternate.However,youcanuseVrms(rootmeansquare)tomeasurevoltage,current,andpowersuchthataloadconnectedtoa120voltsAC(VAC)sourcedevelopsthesameamountofpowerasthatsameloadconnectedtoa120voltsDC(VDC)source.WithRMS,thepowerformulaforDCalsoworksforAC.Forsinusoidalwaveforms,Vrms=Vpeak/squarerootof2.BecausevoltmetersreadVrms,the120VACofatypicalU.S.walloutletactuallyhasapeakvalueofabout170V.MakingSignalConnectionsCreatingaProgramExamples
MeasuringVoltageProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasurevoltage.Alternatively,youcanconfigureataskformeasuringvoltageusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringvoltageisanexampleofananaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.TomeasureACvoltages,yougenerallyuseahardwaretimedacquisition,suchastheonesshowninFiniteVoltageMeasurementsandContinuousVoltageMeasurements.TomeasureDCvoltages,youoftendonotneedabufferorhardwaretiming,soyoucanuseasimpleapplicationsuchastheoneshowninAcquiringaSingleSample.
GeneratingVoltageYoucangeneratesinglesampleDCsignalsortime-varyingmultiplesamplesignals.
SingleSamples—IncludingSteadySignalsUsesinglesamplesifthesignallevelismoreimportantthanthegenerationrate.Forinstance,generateonesampleatatimeifyouneedtogenerateaconstant,orDC,signal.Youcanusesoftwareorhardwaretimingifthedevicesupportshardwaretimingtocontrolwhenthedevicegeneratesasignal.
Time-VaryingMultipleSamplesUsemultiplesamplesifthegenerationrateisjustasimportantasthesignallevel,asinanACsinewave.Functiongeneratorsareacommontypeofdevicethatyoucanprogramtoproducecertaintypesofwaveforms,suchassine,triangle,andsquarewaves.YoualsocanuseaDAQdeviceasafunctiongenerator.Youdothisbygeneratingonecycleofasinewave,suchaswiththeSineGenerationVIinLabVIEW,storingonecycleofsinewavedatainawaveform,andprogrammingthedevicetogeneratethevaluescontinuouslyfromthewaveformonepointatatimeataspecifiedrate.Alsocalledbufferedanalogoutput,generatingmultiplesamplesinvolvesthefollowingsteps:
1. Yourapplicationwritesmultiplesamplesintoabuffer.2. Allthesamplesinthebufferarethensenttoyourdevice
accordingtothetimingyouspecify.Youcanusesoftwareorhardwaretiming(ifyourdevicesupportshardwaretiming)tocontrolwhenyourdevicegeneratesasignal.
MakingSignalConnectionsCreatingaProgramGeneratingVoltageGeneralProgrammingFlowGeneratingMultipleSamplesProgrammingFlow
ExamplesSeeAlsoExternalReferenceSourcesforGeneratingVoltageWhatisaBuffer?
GeneratingVoltageProgrammingFlowchartThefollowingflowchartillustratesthemainstepsrequiredinanNI-DAQmxapplicationtogeneratevoltage.Alternatively,youcanconfigureataskforgeneratingvoltageusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Generatingvoltageisanexampleofananalogoutputmeasurement.RefertoAnalogOutputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringandGeneratingDigitalValuesSignalsthatarereadormeasuredarecalledinputsignals.Thosesignalsthataregeneratedarecalledoutput,orstandardoutput.SomespecializeddevicesalsosupportaWired-ORoutput.Refertothedevicedocumentationformoreinformationaboutthetypesofinputandoutputthedevicesupports.Thissectioncoverssoftware-timeddigitalinput/outputoperationsorunstrobedoperations.Thesesignalsarecontrolledbysoftwaretiming.Measuringandgeneratingdigitalvaluesareusedinanumberofapplications,includingcontrollingrelaysandmonitoringalarmstates.Generally,measuringandgeneratingdigitalvaluesisusedinlaboratorytesting,productiontesting,andindustrialprocessmonitoringandcontrol.MakingSignalConnectionsCreatingaProgramMeasuringaDigitalValueGeneratingaDigitalValue
Examples
GeneratingaDigitalValueProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtogeneratedigitalvalues.Ifyouprefer,youcanconfigureataskforgeneratingdigitalvaluesusingtheDAQAssistant.
MeasuringaDigitalValueProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasuredigitalvalues.Ifyouprefer,youcanconfigureataskforacquiringdigitalvaluesusingtheDAQAssistant.
EdgeCountingEdgecountingiswhenadevicecountsrisingorfallingedgesusingacounterchannel.Youcanchoosetodoeithersinglepointorbufferedsampleclockedgecounting.Thefollowingfigureshowsanexampleofedgecountinginwhichthecounterinadevicecountsfiveedgesontheinputterminal.
Withbufferededgecounting,thedevicelatchesthenumberofedgescountedontoeachactiveedgeofthesampleclockandstoresthenumberinthebuffer.Thereisnobuilt-inclockforbufferededgecounting,soyoumustsupplyanexternalsampleclock.
InNI-DAQmx,whendoingon-demandedgecounting,youfirstarmthecounterbycallingtheStartfunction/VI.Eachsubsequentreadreturnsthenumberofedgescountedsincethecounterwasstarted.Ifyouperformmultiplereadswithoutfirststartingthecounter,thecounterimplicitlystartsandstopswitheachReadfunction/VIcall,andthenumberofcountededgesisnotcumulativebetweenreadcalls.Youalsocanpausecountingwithon-demandedgecountinginNI-DAQmxbyconfiguringapausetrigger.Toconfigureapausetrigger,usethetriggerattributes/propertiestosetthesourceterminalofthedigitaltriggeraswellasthelevelonwhichtopause.MakingSignalConnectionsCreatingaProgram
Examples
EdgeCountingProgrammingFlowchartThefollowingflowchartdepictsthemainstepsyoumustcompleteforcountingedgesinanNI-DAQmxapplication.Ifyouprefer,youcanconfigureataskforcountingedgesusingtheDAQAssistant.
Edgecountingisanexampleofacountermeasurement.RefertoCounterProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
GeneratingPulsesSomemeasurementdevicescangenerateapulsefromthecounterofthedevice.Apulseisasignalwhoseamplitudedeviatesfromzeroforashortperiodoftime.Thepulseiseitherhighorlow.Ahighpulsestartslow,pulseshigh,andreturnslow,andalowpulsestartshigh,pulseslow,andreturnshigh.
NoteYoucanuseButterworthfiltersonlyintheLabVIEWFullandProfessionalDevelopmentSystems.
Apulsetrainismorethanonepulse.Youcanuseapulseorpulsetrainasaclocksignal,agate,oratriggerforameasurementorapulsegeneration.Youcanuseasinglepulseofknowndurationtodetermineanunknownsignalfrequencyortotriggerananalogacquisition.Youcanuseapulsetrainofknownfrequencytodetermineanunknownpulsewidth.Eachpulseorpulsetrainconsistsofthreeparts:
InitialDelay—Theamountoftimetheoutputremainsattheidlestatebeforegeneratingthepulse.HighTime—Theamountoftimethepulseisatahighlevel.LowTime—Theamountoftimethepulseisatalowlevel.
Theperiodofthepulseisthesumofthehightimeandthelowtime.Thefrequencyisthereciprocaloftheperiod,1/period.Thefollowingfigureshowsthepartsofapulse.
Thefollowingfigureshowsthepartsofapulsetrain.
Beforeyougenerateapulse,youneedtodetermineifyouwanttooutputthepulseorpulsetrainintermsoffrequency,time,ornumberofticksofthecountertimebase.Forfrequency,youneedtodeterminethedutycycle.Fortime,youspecifythehightimeandthelowtime.Usethenumberofticksifyouareusingacountertimebasewithanunknownrate.Whenyouconfigureapulsegeneration,theoutputappearsatthecounteroutputterminal.Theidlestatecontrolsthepulsegenerationpolarity.Whenyousettheidlestatetolow,thepulsegenerationstartslowfortheinitialdelay,transitionstohighforthehightime,andtransitionstolowforthelowtime,asshowninthefollowingfigure.Thehightimeandlowtimerepeatforeachpulse.
Whenyousettheidlestatetohigh,thepulsegenerationstartshighfortheinitialdelay,transitionstolowforthelowtime,andtransitionstohighforthehightime,asshowninthefollowingfigure.Inbothcases,theoutputrestsattheidlestateafterthepulsegenerationcompletes.
Whengeneratingpulses,youcangenerateeitherasinglepulse,afinitepulsetrain,oracontinuouspulsetrain.Youcanupdatethehightimeand
lowtimeofacontinuouspulsetraingenerationatanytime,includingwhiletheapplicationisrunning.Thisisusefulforapplicationsthatrequirepulsewidthmodulation,suchasproportionalintegralderivative(PID)loopcontrolapplications.Bydefault,singlepulsesaregeneratedunlessyouusetheTimingfunction/VIwiththeimplicittimingtype.TheSamplesPerChannelinputtotheTimingfunction/VIdeterminesthenumberofpulsestogenerateforfinitepulsetrains.Generatingasinglepulseoracontinuouspulsetrainonlyrequirestheuseofonecounter.However,generatingfinitepulsetrainsrequirestheuseofpairedcounters.Youcanconfigureavarietyoftriggerswithpulsegenerations.AllpulsegenerationssupportStartTriggers.SinglepulsegenerationandfinitepulsetraingenerationalsosupporttheRetriggerableproperty,orattribute,forStartTriggers.TodetermineifapulseiscompleteandthehardwareisreadyforanotherStartTrigger,querythePulseDoneproperty.Continuouspulsetraingenerationsalsosupportpausetriggers.However,youcannotuseboththestartandthepausetriggeratthesametime.Youcanusethesamepropertiesthatcreatethechanneltoupdatetherateofthepulsetraingeneration.Becauseyouneedtwopropertiestospecifytherateofthepulsetrain,therateonlyupdateswhenyousetoneofthetwoproperties.Forexample,ifyouspecifythepulsegenerationintermsoffrequency,thefrequencyanddutycyclepropertiescontroltherateofthegeneration.However,therateonlyupdateswhenyousetthefrequencyproperty.Thesameistruewhenyouspecifypulsegenerationintermsoftimeorticks;thelowtimeandlowtickspropertiescontrolwhentherateupdates.Whenupdatingtherateofthepulsegeneration,acompleteperiodofthecurrentrategeneratesbeforethenewratetakeseffect.MakingSignalConnectionsCreatingaProgramGeneratingaPulseGeneratingaFinitePulseTrainGeneratingaContinuousPulseTrain
Examples
GeneratingaPulseProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtogenerateapulse.Ifyouprefer,youcanconfigureatasktogenerateapulseusingtheDAQAssistant.
GeneratingaFinitePulseTrainProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationforgeneratingafinitepulsetrain.Alternatively,youcanconfigureataskforgeneratingthepulsetrainusingtheDAQAssistant.
GeneratingaContinuousPulseTrainProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationforgeneratingacontinuouspulsetrain.Alternatively,youcanconfigureataskforgeneratingthepulsetrainusingtheDAQAssistant.
MeasuringAccelerationAccelerationisachangeinvelocitywithrespecttotime.Anaccelerometerisatransducerthatrepresentsaccelerationasavoltage.Accelerometersalsocanmeasurevibrationandshock.Accelerometerstypicallyconvertaccelerationmeasureding'stovoltage.Forexample,asensorwitharatedoutputof10mV/gshouldproduce50mVwhensubjectedto5gofacceleration.MakingSignalConnectionsCreatingaProgramExamples
MeasuringAccelerationProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasureacceleration.Alternatively,youcanconfigureataskformeasuringaccelerationusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringaccelerationisanexampleofananaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringAngularDisplacementAngulardisplacementismovementaroundanaxis,suchastheangularmotionoftheshaftofamotor.Anangulardisplacementsensorisadevicewhoseoutputsignalrepresentstherotationoftheshaft;itcannotmeasurethephysicaldisplacementofthewholeshaft.Onetypeofsensorusedtomeasureangulardisplacementisarotaryvariabledifferentialtransformer(RVDT).Anothertypeofsensorusedtomeasureangulardisplacementisaresolver,whichisarotatingtransformerthatcanmeasure360°ofrotation.OnMSeriesdevices,CSeriesdevices,andNI-TIO-baseddevices,youcanusethecounterstoperformdisplacementmeasurementswithquadratureencoders,orangularencoders.YoucanmeasureangularpositionwithX1,X2,andX4angularencoders.Youcanchoosetodoeitherasingle-pointorabufferedsampleclockdisplacementmeasurement.Youalsocanmeasurevelocitywithangularencoders,butyouneedtouseasampleclockwithafixedfrequency.Tomeasurevelocity,usethefollowingformula:V=D/T
whereVistheaveragevelocity,Disthedistance,andTistime.ThecountermeasuresthepositionoftheencoderusingtheAandBsignals,whichareoffsetby90°.ThecounteralsosupportstheZindex,whichprovidesaprecisereferencepointandisavailableonsomeencoders.MakingSignalConnectionsCreatingaProgramRVDTProgrammingFlowchartEncoderProgrammingFlowchart
Examples
MeasuringPositionwithEncodersProgrammingFlowchartThefollowingflowchartdepictsthemainstepsyoumustcompleteformeasuringpositionwithanencoderinanNI-DAQmxapplication.Ifyouprefer,youcanconfigureataskusingtheDAQAssistant.
Measuringpositionwithanencoderisanexampleofacountermeasurement.RefertoCounterProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringPositionwithanRVDTorLVDTProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasurepositionwithanRVDTorLVDT.Alternatively,youcanconfigureataskformeasuringpositionusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringpositionisanexampleofananaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringLinearDisplacementLineardisplacementismovementanddirectionalongasingleaxis.Apositionorlineardisplacementsensorisadevicewhoseoutputsignalrepresentsthedistanceanobjecthastraveledfromareferencepoint.Thelinearvariabledifferentialtransformer(LVDT)isasensorthatmeasureslineardisplacement.OnMSeriesdevices,CSeriesdevices,andNI-TIO-baseddevices,youcanusethecounterstoperformdisplacementmeasurementswithtwo-pulseencoders.Linearpositioncanbemeasuredwithtwo-pulseencoders.Youcanchoosetodoeitherasinglepointorabufferedsampleclockdisplacementmeasurement.Youalsocanmeasurevelocitywithtwo-pulseencoders,butyouneedtouseasampleclockwithafixedfrequency.Tomeasurevelocity,usethefollowingformula:V=D/T
whereVistheaveragevelocity,Disthedistance,andTistime.ThecountermeasuresthepositionoftheencoderusingtheAandBsignals,whichareoffsetby90°.ThecounteralsosupportstheZindex,whichprovidesaprecisereferencepointandisavailableonsomeencoders.MakingSignalConnectionsCreatingaProgramLVDTProgrammingFlowchartEncoderProgrammingFlowchart
Examples
MeasuringAnalogFrequencySomedevicescanmeasureanalogfrequencydirectlyusingfrequency-to-voltagecircuitry.Manydevices,however,onlymeasurevoltage,andyoumustusesoftwarealgorithmstoconvertthosemeasurementstofrequency.Devicesthatmeasureanalogfrequency,suchasDSAdevicesandtheSCXI-1126,havecircuitrythatproducestriggersofthesamefrequencyasthemeasuredsignal.Everytimethesignalpassesfromthresholdlevelminushysteresistothresholdlevel,atriggeroccurs.Apulsegeneratorusesthesetriggersandproducesapulseonceeveryfrequencycycle.Theinputfrequencyrangesetsthewidthofthispulse.Astheinputfrequencyrangeincreases,thepulsewidthgrowssmaller.ThispulsetrainisthenconvertedtoaDCsignalthathasalevelproportionaltothedutycycleofthepulsetrain.Thedutycycleisthefractionofaperiodofthepulsetrainwhenthepulseisoccurring.TheDCsignalhasavoltagethatisproportionaltotheinputfrequencyandcanthereforebescaledtothatfrequencyvalue.Fordevicesthatcannotmeasurefrequencydirectly,youneedtousesoftwarealgorithms,suchastheFastFourierTransform(FFT),toconvertvoltagetofrequency.LabVIEWFullandProfessionalDevelopmentSystemscontainsadvancedanalysisVIsthathandlethesetransformations.TheLabWindows™/CVI™fulldevelopmentsystemalsocontainsadvancedanalysisfunctionstohelpyoumeasureanalogfrequency.RegardlessofwhetheryouuseexistingVIsorfunctionsorcreateyourown,youneedtosampleatleasttwiceasfastasthehighestfrequencycomponentinthesignalyouareacquiring.
AnalogFrequency,SampleRate,andtheNyquistTheoremTheNyquistTheoremstatesthatthehighestfrequencyyoucanaccuratelyrepresentishalfthesamplingrate.Forinstance,tomeasurethefrequencyofa100Hzsignal,youneedasamplingrateofatleast200S/s.Inpractice,youshouldusesamplingratesof5to10timestheexpectedfrequenciestoimproveaccuracyofmeasurements.Inadditiontosamplerate,youneedtodeterminethenumberofsamplestoacquire.Youmustsampleaminimumofthreecyclesoftheanalogsignal.Forexample,youneedtocollectatleast15samples,orpoints,ifyouuseasamplingrateof500S/stomeasurethefrequencyofa100Hzsignal.Becauseyousampleaboutfivetimesfasterthanthesignalfrequency,yousampleaboutfivepointspercycleofthesignal.Youneeddatafromthreecycles,so5pointsx3cycles=15points.Inpractice,however,youshouldacquire10ormorecyclestoimproveaccuracyofmeasurements,soyoushouldacquire50ormoresamples.Thenumberofpointsyoucollectdeterminesthenumberoffrequencybinsthatthesamplesfallinto.Thesizeofeachbinisthesamplingratedividedbythenumberofpointsyoucollect.Forexample,ifyousampleat500S/sandcollect100points,youhavebinsat5Hzintervals.TheNyquistfrequencyisthebandwidthofthesampledsignalandisequaltohalfthesamplingfrequency.FrequencycomponentsbelowtheNyquistfrequencyappearnormally.FrequencycomponentsabovetheNyquistfrequencyappearaliasedbetween0andtheNyquistfrequency.Thealiasedcomponentistheabsolutevalueofthedifferencebetweentheactualcomponentandtheclosestintegermultipleofthesamplingrate.Forexample,ifyouhaveasignalwithacomponentat800Hzandyousampleat500S/s,thatcomponentappearsaliasedat200Hzbecause|800–(2x500)|=200(Hz).Onewaytoeliminatealiasedcomponentsistouseananaloghardwarefilterbeforeyoudigitizeandanalyzethefrequencyinformation.Ifyouwanttoperformallthefilteringinsoftware,youmustfirstsampleataratefastenoughtocorrectlyrepresentthehighestfrequencycomponentthesignalcontains.Forexample,withthehighestcomponentat800Hz,theminimumsamplingrateis1,600Hz,butyoushouldsample5to10timesfasterthan800Hz.Ifthefrequencyyouwanttomeasureisaround100Hz,youcanusealowpassButterworthfilterwithacutofffrequency(fc)of
250Hztofilteroutfrequenciesabove250Hzandpassfrequenciesbelow250Hz.
NoteLabVIEWincludesButterworthfilterswiththeLabVIEWFullandProfessionalDevelopmentSystems.
MeasuringFrequencywithFilteringThefollowingfigureshowsalowpassfilter.
LowpassFilterTheIdealFilterinthefigureisoptimal.AllfrequenciesabovetheNyquistfrequencyarerejected.TheRealFilterinthefigureiswhatyoumightactuallybeabletoaccomplishwithaButterworthfilter.ThepassbandiswhereVout/Viniscloseto1.ThestopbandoccurswhereVout/Viniscloseto0.Thefrequenciesgraduallyattenuateonthetransitionregionbetween1and0.MakingSignalConnectionsCreatingaProgramExamples
MeasuringAnalogFrequencyProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasureanalogfrequency.Alternatively,youcanconfigureataskformeasuringanalogfrequencyusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringfrequencyisanexampleofanaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
HysteresiswithAnalogFrequencyMeasurementsForwaveformrepetitions,hysteresisaddsawindowbelowthethresholdlevel.Hysteresisistypicallyusedtoavoiderroneousmeasurementsduetonoiseorjitterinthesignal.ThesignalmustdropbelowthethresholdlevelminusthehysteresisbeforeNI-DAQmxrecognizesawaveformrepetitionatthethresholdlevel.
GeneratingCurrentProgrammingFlowchartThefollowingflowchartillustratesthemainstepsrequiredinanNI-DAQmxapplicationtogeneratecurrent.Alternatively,youcanconfigureataskforgeneratingcurrentusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Generatingcurrentisanexampleofananalogoutputmeasurement.RefertoAnalogOutputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
ControlYoucancreateaneventresponseorcontrolloopapplicationinanyoperatingsystemsupportedbyNI-DAQmx,suchasWindows2000.However,yourapplicationcanonlybedeterministicifyouhavetheLabVIEWReal-Timemoduleanduseyourapplicationonareal-timecontroller.ThissectionassumesthatyouareusingLabVIEWwithNI-DAQmxtocreateacontrolapplication.ItdoesnotassumethatyouhavetheLabVIEWReal-Timemoduleorthereal-timecontroller.
EventResponseInacontrolapplication,aneventisthesameasanoccurrence.Thisoccurrenceleadstoanaction,oraresponse.Anexampleismonitoringthetemperatureofanengine.Whenthetemperaturerisestoohigh,theengineslowsdown.Theevent,inthiscase,wouldbethetemperaturerisingaboveapredeterminedlevel,andtheresponsewouldbetheengineslowingdown.Anotherexamplecomesfrommanufacturing.Inamanufacturingline,asystemsenseswhenapartisinfrontofastation(theevent)andtakesareadingormanipulatesthepart(theresponse).Ifthesystemdoesnotsenseandrespondtothepresenceofthatpartinasetamountoftime,themanufacturinglinecreatesdefectiveparts.Whencreatinganeventresponseapplication,makesureyouconsidertheamountoftimeneededtorespondtotheevent.Forexample,ifthedevicecontrolsthetemperatureofyourhome,thetimetoreacttoevents(changesintemperature)islesscriticalthanifthedevicecontrolsanuclearreactor.Iftheapplicationisnottimecritical,theapplicationdoesnotneedtobedeterministic,meaningthatyoudonotneedtheLabVIEWReal-TimeModuleorareal-timecontroller.Therelativepriorityofthetaskisimportantaswell.BecauseLabVIEWismulti-threaded,youcanseparatetheapplicationintotasks,eachwithitsownpriority.Bysettingpriorities,time-criticaltaskscantakeprecedenceovernon-time-criticaltasks.Thetime-criticaltaskmustperiodicallyyieldprocessorresourcestothelower-prioritytaskssotheycanexecute.Byproperlyseparatingthetime-criticaltaskfromlowerprioritytasks,youcanreduceapplicationjitter.RefertotheLabVIEWReal-TimeModuleConceptsbookintheLabVIEWHelpformoreinformationaboutassigningprioritiestotasks.CreatingaProgramExamplesSeeAlsoKeyControlConceptsSettingPrioritiesforControlApplications
ControlLoopsAcontrolapplicationmonitorsandcontrolsasystem.Theapplicationcontinuouslyloopsbyreadingsamples,processingdata,andadjustingtheoutput.YoucanuseNI-DAQmxandDAQdevicestocreateacontrolapplication.WiththeLabVIEWReal-TimeModule,youcancreatedeterministiccontrolapplications.
CreatingaControlLoopApplicationwithNI-DAQmxThefollowingblockdiagramshowsatypicaldeterministiccontrolloopapplication.First,ananalogvalueisread.Thisvaluecorrespondstotheprocessvariable.Thisvalueiscomparedtothesetpoint,whichisspecifiedintheCtrlAlgrthmVIinthediagram,andadjustedasnecessarywithinthewhileloop,possiblyusingaPIDalgorithm.Theadjustedvalueisthenwritten.Thisvaluecorrespondstotheactuatoroutput.Intheblockdiagram,thesamplingratesarethesameforanaloginputandoutput.BecausetheexampleshownassumesasingleDAQdevice,theStartTriggersynchronizestheanaloginputandanalogoutputtasks.Formultipledevices,synchronizationworksdifferently.RefertoSynchronizationformoreinformation.Noticealsothattheslavetasktheanalogoutputtaskstartsbeforetheanaloginputtask.Finally,withintheloop,theWaitforNextSampleClockVIcheckstomakesurethattheloopexecuteswithinthespecifiedsamplingrate.Ifitdoesnot,thisVIreturnsanerror.
ExamplesSeeAlsoTimingControlLoopsKeyControlConceptsSettingPrioritiesforControlApplications
MeasuringSoundPressureSoundpressureisthedynamicvariationofthestaticpressureofairandismeasuredinforceperunitarea(Pa).Theinstantaneoussoundpressureistypicallyaveragedoveracertaindurationtogivesoundpressurelevel.Soundpressurelevelisusuallyrepresentedonalogarithmicamplitudescale,whichissimilartothehumanperceptionofhearing.Typicalvaluesonthislogarithmicscaleareasoundlevelof0dB,whichistheaveragethresholdofhumanhearing,60to70dBfornormalconversation,110dBatanextremelyloudconcert,and150dBforthenoiseofarockettakeofforajetengineatcloserange.TheSoundPressureLevel(SPLorLP)indecibelsisdefinedbythefollowingequation.SPL=20log10(p/pref)wherepistheinstantaneoussoundpressureinPaandprefis20µPa,theinternationallyacceptedreferenceforsoundpressuremeasurements,whichroughlycorrespondstothethresholdofhumanhearing.Youuseamicrophonetomeasuresoundpressure.Themicrophoneactsasatransducer,creatingavoltagesignalthatisproportionaltotheinstantaneoussoundpressure.MakingSignalConnectionsCreatingaProgramExamples
MeasuringSoundPressureProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasuresoundpressure.Alternatively,youcanconfigureataskformeasuringsoundpressureusingtheDAQAssistant.
TipToincreaseperformance,especiallywhenmultiplesamplesareread,includetheStartfunction/VIandStopfunction/VIinyourapplication.Inthepreviousflowchart,theStartfunction/VIwouldcomejustbeforeyoureadsamples,andStopwouldcomejustbeforeyouclearthetask.
Measuringsoundpressureisanexampleofananaloginputmeasurement.RefertoAnalogInputProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringTime—Period,Semi-Period,PulseWidth,Two-EdgeSeparation,andDigitalFrequencyYoucanusethecountersonaDAQdevicetomeasuretime.Timemeasurementsareperiod,pulsewidth,semi-period,frequency,andtwo-edgeseparationmeasurements.
MeasuringDigitalFrequencyThedigitalfrequencyofasignalistheinverseoftheperiodofasignal.Togetthefrequencyofthesignal,taketheinverseoftheperiod.TheformulaforfrequencyisFrequency(inHz)=CounterTimebaseRate(inHz)/Count.TheCounterTimebaseRateisaknownfrequencyandisusuallyabuilt-intimesource.Ifthecountertimebaserateisunknown,youonlycanmakemeasurementsonlyintermsofticksofthecountertimebase.Thismaybethecaseifyouareusinganexternalsignalforthecountertimebase,andthefrequencyoftheexternalsignalisunknownoraperiodic.Digitalfrequencyisanexampleofatimemeasurement.RefertoConfiguringaTimeMeasurementinNI-DAQmxandTwoCounterMeasurementMethodformoreinformationaboutmeasuringtime.MakingSignalConnectionsCreatingaProgramExamples
MeasuringDigitalFrequencyandPeriodProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtomeasuredigitalfrequencyorperiod.Alternatively,youcanconfigureataskformeasuringdigitalfrequencyusingtheDAQAssistant.
Digitalfrequencyandperiodareexamplesofcountermeasurements.RefertoCounterProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringPeriod,Semi-Period,PulseWidth,andTwo-EdgeSeparationYoucanmeasureperiod,semi-period,pulsewidth,andtwo-edgeseparationusingcounters,suchasonaDAQdevice,todeterminethedurationofaneventortodeterminetheintervaltimebetweentwoevents.Periodmeasurementsmeasurethetimebetweenconsecutiverisingorfallingedgesofapulse.Semi-periodmeasurementsmeasurethetimebetweenconsecutiveedges.Pulsewidthmeasurementsmeasurethetimebetweeneitherarisingandfallingedge,orafallingandrisingedge.Two-edgeseparationmeasurementsmeasurethetimebetweentherisingorfallingedgeofonedigitalsignalandtherisingorfallingedgeofanotherdigitalsignal.
Theformulaforperiod,semi-period,pulsewidth,andtwo-edgeseparationisasfollows:Period,Semi-Period,PulseWidth,orTwo-EdgeSeparation(inseconds)=Count/CounterTimebaseRate(inHz).whereCountisthenumberofcountertimebaseticksthatelapseduringoneperiod,semi-period,pulsewidth,ortwo-edgeseparationofthemeasuredinputsignalorsignals.TheCounterTimebaseRateisaknownfrequencyandisusuallyabuilt-intimesource.Ifthecountertimebaserateisunknown,youonlycanmakemeasurementsonlyintermsofticksofthecountertimebase.Thismaybethecaseifyouareusinganexternalsignalforthecountertimebase,andthefrequencyoftheexternalsignalisunknownoraperiodic.Period,semi-period,pulsewidth,andtwo-edgeseparationareexamples
oftimemeasurements.RefertoConfiguringaTimeMeasurementinNI-DAQmxandTwoCounterMeasurementMethodformoreinformationaboutmeasuringtime.MakingSignalConnectionsCreatingaProgramMeasuringSemi-Period,Two-EdgeSeparation,andPulseWidthProgrammingFlowchartMeasuringDigitalFrequencyandPeriodProgrammingFlowchart
Examples
MeasuringSemi-Period,Two-EdgeSeparation,andPulseWidthProgrammingFlowchartThefollowingflowchartdemonstratesthemainstepsrequiredinanNI-DAQmxapplicationtomeasuresemi-periodandpulsewidth.Alternatively,youcanconfigureataskformeasuringsemi-periodandpulsewidthusingtheDAQAssistant.
Period,semi-period,two-edgeseparation,andpulsewidthisanexampleofacountermeasurement.RefertoCounterProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
MeasuringGPSTimestampYoucantakeaGPStimestampmeasurementwiththeNIPXI-6608.InaGPStimestampmeasurement,theNIPXI-6608determinestheprecisetimeofyearusingaspecializedonboardcounter.Youcanselectasinglepoint(on-demand)timestamporabuffered(sampleclock)timestamp.YoucansynchronizetheGPStimestampcountertoaGPSreceiversignalbyusingapulsepersecond(PPS)oranIRIG-B(timecodeTTL)synchronizationsignalfromtheGPSreceiver.PPSdoesnotincludeanytiminginformation;rather,thePPSaccuratelyreportswhenthebeginningofasecondoccurs.IRIG-B,ontheotherhand,hasthetimeencodedinthesignalfromthebeginningofthecurrentyear.TheGPScountercanlatchonthecurrenttimeuponreceivingahardwaregatesignal.GPSdoesnotprovideyearinformation;however,thetimeisstoredina64-bitfloating-pointnumberthatcanbeconvertedtosecondssinceJanuary1ofthecurrentyear.Whendoinganon-demandGPStimestampmeasurement,youmustfirstarmthecounterbycallingtheStartfunction/VI.Eachsubsequentreadreturnsthenumberofsecondscounted.WhendoingabufferedGPStimestampmeasurement,thecurrenttimeislatchedoneachactiveedgeofthesampleclockandstoredinthebuffer.Thereisnobuilt-inclockforbufferedGPStimestampmeasurements,soyoumustsupplyanexternalsampleclock.MakingSignalConnectionsCreatingaProgramExamples
GPSTimestampProgrammingFlowchartThefollowingflowchartdepictsthemainstepsrequiredinanNI-DAQmxapplicationtotakeaGPStimestampmeasurementwithanNIPXI-6608.Alternatively,youcanconfigurethistaskusingtheDAQAssistant.
GPStimestampisanexampleofacountermeasurement.RefertoCounterProgrammingFlowchartsforadditionalflowchartsthatcanhelpyoucreateanapplication.
GlossaryPrefixes Numbers/Symbols A B C D E F G H I J
L M N O P R S T U V W
Symbol Prefix Valuen nano 10-9
µ micro 10-6
m milli 10-3
k kilo 103
M mega 106
Symbol Meaning% percent+ positiveof,orplus– negativeof,orminusΩ ohmº degree
Aacceleration Achangeinvelocitywithrespecttotime.accelerometer Asensorthatrepresentsaccelerationasavoltage.ADC Analog-to-digitalconverter—anelectronicdevice,often
anintegratedcircuit,thatconvertsananalogsignaltoadigitalvalue.
address Acharactercodethatidentifiesaspecificlocation(orseriesoflocations)inmemory.
ADE Applicationdevelopmentenvironment—someexamplesincludeLabVIEWandLabWindows/CVI.
advancedterminal
AterminalnotaccessiblefromtheI/Oconnectororaterminalnotcommonlyusedinmeasurementapplications.
AI Analoginput—acquisitionofdata.amplification Atypeofsignalconditioningthatimprovesaccuracyin
theresultingdigitizedsignalbyincreasingsignalamplituderelativetonoise.
analog Datarepresentedbycontinuouslyvariablephysicalquantities.
AO Analogoutput—generationofdata.angulardisplacement
Movementaboutanaxis,suchastheangularmotionoftheshaftofamotor.
angulardisplacementsensor
Adevicewhoseoutputsignalrepresentstherotationoftheshaft,suchasarotaryvariabledifferentialtransformer(RVDT).
API Applicationprogramminginterface—Alibraryoffunctions,classesorVIs,attributes,andpropertiesforcreatingapplicationsforyourdevice.
asynchronous 1. Hardware—asignalthatoccursorisacteduponatanarbitrarytime,withoutsynchronizationtoanothersignal,suchasareferenceclock.
2. Software—aVIorfunctionthatbeginsan
operationandreturnspriortothecompletionorterminationoftheoperation.
attenuation Thereductionofavoltageoracousticalpressure.Measuredreferencedtotheoriginalvoltage.
Bbandwidth Therangeoffrequenciespresentinasignal,ortherangeof
frequenciestowhichameasuringdevicecanrespond.baseaddress
Amemoryaddressthatservesasthestartingaddressforprogrammableregisters.Allotheraddressesarelocatedbyaddingtothebaseaddress.
bipolar Asignalrangethatincludesbothpositiveandnegativevalues(forexample,5Vto+5V).
BIOS BasicInput/OutputSystem—BIOSfunctionsarethefundamentallevelofanyPCorcompatiblecomputer.BIOSfunctionsembodythebasicoperationsneededforsuccessfuluseofthecomputerhardwareresources.
bit Thesmallestunitofdatausedinadigitaloperation.Bitsarebinary,sotheycanbeeithera1ora0.
buffer Insoftware,temporarystorageforacquiredorto-be-generatedsamples.
bus Thegroupofconductorsthatinterconnectindividualcircuitryinacomputer.Typically,abusistheexpansionvehicletowhichI/Oorotherdevicesareconnected.ExamplesofPCbusesaretheISAbusandPCIbus.
CCSeries Afamilyofdevicesormodulesusedforanaloginput,
analogoutput,digitalinput/output,andcounter/timerapplications.CSeriesdevicesworkwithchassisbasedontheCompactDAQ,CompactRIO,andotherarchitectures,andarecomponentsoftheNIUSB-9XXXdevices.
cDAQ TheprefixoftheproductmodelnameofaCompactDAQdevice,suchasNIcDAQ-9172.
CH Channel.channel 1. Physical—aterminalorpinatwhichyoucan
measureorgenerateananalogordigitalsignal.Asinglephysicalchannelcanincludemorethanoneterminal,asinthecaseofadifferentialanaloginputchanneloradigitalportofeightlines.Thenameusedforacounterphysicalchannelisanexceptionbecausethatphysicalchannelnameisnotthenameoftheterminalwherethecountermeasuresorgeneratesthedigitalsignal.
2. Virtual—acollectionofpropertysettingsthatcanincludeaname,aphysicalchannel,inputterminalconnections,thetypeofmeasurementorgeneration,andscalinginformation.YoucandefineNI-DAQmxvirtualchannelsoutsideatask(global)orinsideatask(local).ConfiguringvirtualchannelsisoptionalinTraditionalNI-DAQ(Legacy)andearlierversions,butisintegraltoeverymeasurementyoutakeinNI-DAQmx.InTraditionalNI-DAQ(Legacy),youconfigurevirtualchannelsinMAX.InNI-DAQmx,youcanconfigurevirtualchannelseitherinMAXorinaprogram,andyoucanconfigurechannelsaspartofataskorseparately.
3. Switch—aswitchchannelrepresentsanyconnectionpointonaswitch.Itmaybemadeup
ofoneormoresignalwires(commonlyone,two,orfour),dependingontheswitchtopology.Avirtualchannelcannotbecreatedwithaswitchchannel.SwitchchannelsmaybeusedonlyintheNI-DAQmxSwitchfunctionsandVIs.
clock Aperiodicdigitalsignal.CMRR Common-moderejectionratio—ameasureoftheability
ofaninstrumenttorejectinterferencefromacommon-modesignal,usuallyexpressedindecibels(dB).
codewidth ThesmallestdetectablechangeinaninputvoltageofaDAQdevice.
cold-junctioncompensation
Amethodofcompensatingforinaccuraciesinthermocouplecircuits.
CompactDAQ AnarchitectureorchassisforCSeriesdevices.configurationtree
ReferstotheleftwindowinMAX,whichcontainsitemssuchasDataNeighborhoodandDevicesandInterfaces.
counter/timer Acircuitthatcountsdigitaledges.Countersandtimersusuallyhavefrom16bitsto48bits(sometimesmore)countingcapability.Thetotalnumberofcountspossibleequals2N,whereNisthenumberofbitsinthecounter.Whentheedgescountedareproducedbyaclock,elapsedtimecanbecomputedfromthenumberofedgescountediftheclockfrequencyisknown.
convertclock TheclockonamultiplexeddevicethatdirectlycausesADCconversions.
customscale AmethodofinstructingNI-DAQmxtoapplyadditionalscalingtoyourdata.RefertotheCreateScalefunction/VIinyourreferencehelp.
DDAC Digital-to-analogconverter—anelectronicdevice,oftenan
integratedcircuit,thatconvertsadigitalvalueintoacorrespondinganalogvoltageorcurrent.
DAQ Refertodataacquisition.DAQAssistant
Agraphicalinterfaceforconfiguringmeasurementtasks,virtualchannels,andscales.
DAQdevice Adevicethatacquiresorgeneratesdataandcancontainmultiplechannelsandconversiondevices.DAQdevicesincludeplug-indevices,PCMCIAcards,andDAQPaddevices,whichconnecttoacomputerUSBor1394(FireWire)port.SCXImodulesareconsideredDAQdevices.
data Samples.dataacquisition(DAQ)
1. Acquiringandmeasuringanalogordigitalelectricalsignalsfromsensors,transducers,andtestprobesorfixtures.
2. Generatinganalogordigitalelectricalsignals.
dB Decibel—theunitforexpressingalogarithmicmeasureoftheratiooftwosignallevels:dB=20log10V1/V2,forsignalsinvolts.
DC directcurrentdelayfromsample
Theamountoftimetowaitafterreceivingasampleclockedgebeforebeginningtheacquisitionofasample.
delayfromstart
TheamountoftimetowaitafterreceivingaStartTriggerbeforebeginningtheoperation.
determinism Characteristicofasystemthatdescribeshowconsistentlyitcanrespondtoexternaleventsorperformoperationswithinagiventimelimit.
device 1. Aninstrumentorcontrolleryoucanaccessasasingleentitythatcontrolsormonitorsreal-worldI/Opoints.Adeviceoftenisconnectedtoahostcomputerthroughsometypeofcommunication
network.2. SeealsoDAQdeviceandmeasurementdevice.
digital ATTLsignal.Refertoedge.DIO digitalinput/outputDMA directmemoryaccess—Amethodoftransferringdata
betweenabufferandadevicethatisusedmostoftenforhigh-speedoperations.
driver Softwareuniquetothedeviceortypeofdevice,andincludesthesetofcommandsthedeviceaccepts.
drop-downlistbox
Agraphicalboxwithadownarrowbuttonthatletsyouselectvaluesoroptionsfromalist.Toselectavalueoroptionintheselectionbox,clickthedownarrowforacompletelistofvaluesoroptions,thenuseyourarrowkeysormousetoselectavalueoroptionfromthelist.
DSUB D-subminiatureconnectorDUT deviceundertest—adeviceusedfortestingpurposes.
EESeries Astandardarchitectureforinstrumentation-class,
multichanneldataacquisitiondevices.edge AdigitaledgeisasinglerisingorfallingTTLtransition.An
analogedgeisdefinedbytheslope,level,andhysteresissettings.
event Adigitalsignalproducedfromadeviceorcircuit.Foranadvanceddiscussionofevents,refertoEvents.
excitation Supplyingavoltageorcurrentsourcetoenergizeasensororcircuit.
Ffalltime Thetimeforasignaltotransitionfrom90%to10%ofthe
maximumsignalamplitude.filtering Atypeofsignalconditioningthatyoucanusetoremove
unwantedfrequencycomponentsfromthesignalyouaremeasuring.
FIFO AtypeofmemorythatimplementsaFirstInFirstOutstrategyinwhichsamplesareremovedintheordertheywerewritten.FIFOsaretypicallyusedasintermediatebuffersbetweenanADCorDACandthememorybuffer.
floatingsignalsources
Signalsourceswithvoltagesignalsthatarenotconnectedtoanabsolutereferenceorsystemground.
Ggain Thefactorbywhichasignalisamplified,oftenexpressedin
decibels(dB).Gainasafunctionoffrequencyiscommonlyreferredtoasthemagnitudeofthefrequencyresponsefunction.
groundedsignalsources
Signalsourceswithvoltagesignalsthatarereferencedtoasystemground,suchastheearthorabuildingground.Groundedsignalsourcesarealsocalledreferencedsignalsources.
Hhardware Thephysicalcomponentsofacomputersystem,suchasthe
circuitboards,plug-inboards,chassis,enclosures,peripherals,andcables.
hardwaretiming
Ameansofcontrollingsignalgeneration.Adigitalsignal,suchasaclockonaDAQdevice,controlstherateofgeneration.
hardwaretriggering
Aformoftriggeringinwhichthesourceofthetriggerisananalogordigitalsignal.RefertoSoftwareTrigger.
hex Hexadecimal—abase-16numberingsystem.hysteresis Awindowaroundatriggerlevelthatisoftenusedtoreduce
falsetriggeringduetonoiseorjitterinthesignal.Hz Hertz—cyclespersecondofaperiodicsignal.
IIEEEP1451
FamilyofIEEEstandardsdefiningavarietyofsmarttransducerinterfaces.AllofthestandardswithinthisfamilysupporttheconceptofaTEDSthatprovidesself-identificationandplugandplayoperationtotransducers.
IEEEP1451.4
AnIEEEstandardthatdefinestheconceptofplugandplaysensorswithanalogsignals.ThisisaccomplishedwiththeadditionofaTEDSinmemory,typicallyanEEPROM,embeddedwithinthesensorandcommunicatedthroughasimple,low-costserialconnection.
instrumentdriver
Refertodriver.
internalchannel
AphysicalchannelnotaccessiblefromanI/Oconnector.Internalchannelsareoftenusedforcalibrationandareintendedforadvancedapplications.
interrupt Amethodwherebyadevicenotifiesthecomputerofsomeconditiononthedevicethatrequiresthecomputer'sattention.Whenthisconditionisarequestfordataoranotificationofavailabledata,interruptsareusedasadatatransfermechanism.
interruptlevel
Therelativepriorityatwhichadevicecaninterrupt.
I/O Input/Output—thetransferofdatato/fromacomputersysteminvolvingcommunicationschannels,operatorinterfacedevices,and/ordataacquisitionandcontrolinterfaces.
IRQ InterruptReQuest.ISA IndustryStandardArchitecture—Alsoreferstoacommon
PCexpansionbus.isolation Atypeofsignalconditioninginwhichyouisolatethe
transducersignalsfromthecomputer.Isolationmakessurethemeasurementsfromthemeasurementdevicearenotaffectedbydifferencesingroundpotentials.
Jjitter Theamountoftimethattheloopcycletimevariesfromthedesired
time.
LLED light-emittingdiode—asemiconductorlightsource.line Anindividualsignalinadigitalport.Thedifference
betweenabitandalineisthatthebitreferstotheactualdatatransferred,andthelinereferstothehardwarethebitistransferredon.However,thetermslineandbitarefairlyinterchangeable.Forexample,an8-bitportisthesameasaportwitheightlines.
lineardisplacement
Movementinonedirectionalongasingleaxis.
lineardisplacementsensor
Adevicethatmeasureslineardisplacement.
linearization Atypeofsignalconditioninginwhichsoftwarelinearizesthevoltagelevelsfromtransducers,sothevoltagescanbescaledtomeasurephysicalphenomena.
LSB leastsignificantbit—oftenusedtorefertothesmallestvoltagechangedetectablebyanA/DconverterorthesmallestvoltagechangethatcanbegeneratedbyaD/Aconverter.
LVDT Linear-voltagedifferentialtransformer—Asensorusedtomeasurelineardisplacement.AnLVDTconsistsofapassivetransformwithoneprimaryandtwosecondarywindings.TheprimarywindingisexcitedbyanaudiofrequencyrangeACvoltage,whoseimbalancebetweenthesecondarywindings,isproportionaltothedisplacement.Thesecondarywindingsareidentical,butarenormallyconnectedwithoppositepolarity,sothetransduceratrestingpositionwillhavezerooutputvoltage.
MMSeries Astandardarchitectureforinstrumentation-class,
multichanneldataacquisitiondevices.MAX Measurement&AutomationExplorer—Acentralized
configurationenvironmentthatallowsyoutoconfigureallofyourNationalInstrumentsdevices.
measurementdevice
DAQdevicessuchastheMSeriesmultifunctionI/O(MIO)devices,SCXIsignalconditioningmodules,andswitchmodules.
memorybuffer
Refertobuffer.
memorymapping
Atechniqueforreadingandwritingtoadevicedirectlyfromyourprogram,whichavoidstheoverheadofdelegatingthereadsandwritestokernel-levelsoftware.Delegationtothekernelissafer,butslower.Memorymappingislesssafebecauseanentire4KBpageofmemorymustbeexposedtoyourprogramforthistowork,butitisfaster.
microphone Atransducerthatconvertsacousticalwavesintoelectricalsignals.
MIO multifunctionI/O—Designatesacategoryofdataacquisitiondevicesthathavemultipleanaloginputchannels,digitalI/Ochannels,timing,andoptionally,analogoutputchannels.AnMIOproductcanbeconsideredaminiaturemixedsignaltester,duetoitsbroadrangeofsignaltypesandflexibility.ItisalsoknownasmultifunctionDAQ.AnESeriesdeviceisanexampleofanMIOdevice.
module Aboardassemblyanditsassociatedmechanicalparts,frontpanel,optionalshields,andsoon.Amodulecontainseverythingrequiredtooccupyoneormoreslotsinamainframe.SCXIandPXIdevicesaremodules.
multiplexedmode
AnSCXIoperatingmodeinwhichanaloginputchannelsaremultiplexedintoonemoduleoutputsothatthe
cabledDAQdevicehasaccesstothemultiplexedoutputaswellastheoutputsonallothermultiplexedmodulesinthechassisthroughtheSCXIbus.Alsocalledserialmode.
multiplexer Aswitchingdevicewithmultipleterminalsthatsequentiallyconnectseachofitsterminalstoasingleterminal,typicallyathighspeeds.Oftenusedtomeasureseveralsignalswithasingleanaloginputchannel.
multithreading Runningtasksofanapplicationforashortamountoftimetogivetheimpressionofmultipletasksrunningsimultaneously.
NNI-DAQ DriversoftwareincludedwithallNImeasurementdevices.
NI-DAQisanextensivelibraryofVIsandfunctionsyoucancallfromanapplicationdevelopmentenvironment(ADE),suchasLabVIEW,toprogramallthefeaturesofanNImeasurementdevice,suchasconfiguring,acquiringandgeneratingdatafrom,andsendingdatatothedevice.
NI-DAQ7.x IncludestwoNI-DAQdrivers—NI-DAQmxandTraditionalNI-DAQ(Legacy)—eachwithitsownAPI,hardwareconfiguration,andsoftwareconfiguration.
NI-DAQmx ThelatestNI-DAQdriverwithnewVIs,functions,anddevelopmenttoolsforcontrollingmeasurementdevices.TheadvantagesofNI-DAQmxoverearlierversionsofNI-DAQincludetheDAQAssistantforconfiguringchannelsandmeasurementtasksforyourdeviceforuseinLabVIEW,LabWindows/CVI,andMeasurementStudio;increasedperformancesuchasfastersingle-pointanalogI/O;andasimplerAPIforcreatingDAQapplicationsusingfewerfunctionsandVIsthanearlierversionsofNI-DAQ.
NI-DAQmxSimulatedDevice
AreplicaofadevicecreatedusingtheNI-DAQmxSimulatedDeviceoptionintheCreateNewmenuofMAXforthepurposeofoperatingafunctionorprogramwithouthardware.AnNI-DAQmxsimulateddevicebehavessimilarlytoaphysicaldevice.Itsdriverisloaded,andprogramsusingitarefullyverified.
nonlinearity Ameasureinpercentageoffull-scalerange(FSR)oftheworst-casedeviationfromtheidealtransferfunction—astraightline.
ThisspecificationisincludedonlyforDAQproducts,suchassignalconditioningproducts,thatdonothaveanADC.BecauseaproductwiththisspecificationcanalsobeusedwithaDAQproductwithanADC,thisnonlinearityspecificationmustbeaddedtotherelativeaccuracyspecificationoftheDAQproductwiththeADC.
NRSE Nonreferencedsingle-endedmode—allmeasurementsaremadewithrespecttoacommon(NRSE)measurementsystemreference,butthevoltageatthisreferencecanvarywithrespecttothemeasurementsystemground.
Oonboard Providedbythedataacquisitiondevice.onboardchannels
Channelsprovidedbytheplug-indataacquisitiondevice.
onboardclock
Thedefaultsourceforaparticularclock.Usually,thedevicehasdedicatedacircuitforproducingthissignalanditsonlypurposeistoactasthesourceforacertainclock.
onboardmemory
Memoryprovidedbyadevicefortemporarystorageofinputoroutputdata.Typically,onboardmemoryisaFIFO,whichisdistinctfromcomputermemory.
operatingsystem
Base-levelsoftwarethatcontrolsacomputer,runsprograms,interactswithusers,andcommunicateswithinstalledhardwareorperipheraldevices.AlsoreferredtoasOS.
Pparallelmode
AtypeofSCXIoperatingmodeinwhichthemodulesendseachofitsinputchannelsdirectlytoaseparateanaloginputchannelofthedeviceconnectedtothemodule.
patternI/O patterninputandoutput—adigitalI/Ooperationonwhichaclocksignalinitiatesadigitaltransfer.Becausetheclocksignalisaconstantfrequency,youcangenerateandreceivepatternsataconstantrate.
PCI peripheralcomponentinterconnect—ahigh-performanceexpansionbusarchitectureoriginallydevelopedbyInteltoreplaceISAandEISA.PCIhasachievedwidespreadacceptanceasastandardforPCsandworkstations,anditoffersatheoreticalmaximumtransferrateof132Mbytes/s.
PCMCIA Anexpansionbusarchitecturethathasfoundwidespreadacceptanceasadefactostandardinnotebook-sizecomputers.PCMCIAoriginatedasaspecificationforadd-onmemorycardswrittenbythePersonalComputerMemoryCardInternationalAssociation.
PFI programmablefunctioninterface—generalpurposeinputterminals,fixedpurposeoutputterminals.ThenameofthefixedoutputsignalisoftenplacedontheI/Oconnectornexttotheterminalasahint.
physicalchannel
Refertochannel.
PID proportionalintegralderivative—Combinationofproportional,integral,andderivativecontrolactions.Referstoacontrolmethodinwhichthecontrolleroutputisproportionaltotheerror,itstimehistory,andtherateatwhichitischanging.Theerroristhedifferencebetweentheobservedanddesiredvaluesofavariablethatisundercontrolaction.
pin Refertoterminal.Poisson's Thenegativeratioofthestraininthetransversedirection
Ratio (perpendiculartotheforce)tothestrainintheaxialdirection(paralleltotheforce).
port Acollectionofdigitallines.Usuallythelinesaregroupedintoeithera8-bitor32-bitport.MostESeriesdeviceshaveone8-bitport.
portwidth Thenumberoflinesinaport.Forexample,mostESeriesdeviceshaveoneportwitheightlines;therefore,theportwidthiseight.
positionsensor
Refertolineardisplacementsensor.
posttriggersamples
IfthereisnoReferenceTrigger,posttriggersamplesarethedataacquiredafterthetaskisstarted.IfthereisaReferenceTrigger,thisisthedataacquiredaftertheReferenceTrigger.
plugandplaydevices
DevicesthatdonotrequireDIPswitchesorjumperstoconfigureresourcesonthedevices.Alsocalledswitchlessdevices.
plugandplaysensors
AtransducerwithanassociatedTEDS—includesbothVirtualTEDSandsmartTEDSsensors.
pretriggersamples
DataacquiredbeforetheoccurrenceoftheReferenceTrigger.
pretriggering Thetechniqueusedonameasurementdevicetokeepacircularbufferfilledwithsamples,sothatwhentheReferenceTriggerconditionsaremet,thebufferincludessamplesleadinguptothetriggerconditionaswellassamplesacquiredimmediatelyafterthetrigger.
programmedI/O
Adatatransfermechanisminwhichabufferisnotusedandinstead,thecomputerreadsandwritesdirectlytothedevice.
propagationdelay
Theamountoftimerequiredforasignaltopassthroughacircuit.
pulsedoutput
Aformofcountersignalgenerationbywhichapulseisgeneratedwhenacounterreachesacertainvalue.
PWM pulse-widthmodulation
PXI PCIeXtensionsforInstrumentation—arugged,opensystemformodularinstrumentationbasedonCompactPCI,withspecialmechanical,electrical,andsoftwarefeatures.ThePXIstandardwasoriginallydevelopedbyNationalInstrumentsin1997andisnowmanagedbythePXISystemsAlliance.
PXItriggerbus
ThetimingbusthatconnectsPXIDAQdevicesdirectly,bymeansofconnectorsbuiltintothebackplaneofthePXIchassis,forprecisesynchronizationoffunctions.ThisbusisfunctionallyequivalenttotheRTSIbusforPCIDAQdevices.
Rrange Theminimumandmaximumanalogsignallevelsthatthe
ADCcandigitize.raw Datathathasnotbeenchangedinanyway.Forinput,data
isreturnedexactlyasreceivedfromthedevice.Foroutput,dataiswrittenasistothedevice.Refertounscaledandscaled.
realtime Apropertyofaneventorsysteminwhichsamplesareprocessedastheyareacquiredinsteadofbeingaccumulatedandprocessedatalatertime.
referencedsignalsource
Signalsourceswithvoltagesignalsthatarereferencedtoasystemground,suchastheearthorabuildingground.Alsocalledgroundedsignalsources.
resolution Thesmallestamountofinputsignalchangethatadeviceorsensorcandetect.Thetermdiscriminationisalsousedforresolution.
risetime Thetimeforasignaltotransitionfrom10%to90%ofthemaximumsignalamplitude.
route Aconnectionbetweenapairofterminals.Anytimethesourceordestinationterminalofasignalisspecified,arouteiscreated.
RSE Referencedsingle-endedmode—allmeasurementsaremadewithrespecttoacommonreferencemeasurementsystemoraground.Alsocalledagroundedmeasurementsystem.
RTD Resistancetemperaturedetector—ametallicprobethatmeasurestemperaturebasedonitscoefficientofresistivity.
RTSIbus Real-timesystemintegrationbus—theNItimingbusthatconnectsDAQdevicesdirectly,bymeansofconnectorsontopofthedevices,forprecisesynchronizationoffunctions.ThisbusisfunctionallyequivalenttothePXITriggerbusforPXIDAQdevices.
RVDT rotaryvariabledifferentialtransformer—asensorwhoseoutputsignalrepresentstherotationoftheshaft.
Ss secondsS samples.Refertosample.S/s samplespersecond—usedtoexpresstherateatwhicha
measurementdevicesamplesananalogsignal.sample Asinglemeasurementfromasinglechannelor,foroutput,
asinglegenerationtoasinglechannel.sampleclock
Theclockthatinitiatesanacquisitionofonesamplefromeachchannelinthescanlist.Forexample,witheachsampleclockpulse,MSeriesdevicesacquireasampleoneachanaloginputchannelinataskbymultiplexingeachchannelthroughasingleADC.Onsimultaneoussamplingdevices,thesampleclockinitiatesthesimultaneousacquisitionofonesamplefromeachchannelinthetaskthroughadedicated,per-channelADC.Nomultiplexing(andthereforenoconvertclock)isnecessaryforSSeriesdevices.
sampleclockrate
Refertosamplerate.
samplerate Thenumberofsamplesperchannelpersecond.Forexample,asamplerateof10S/smeanssamplingeachchannel10timespersecond.
scale Datathathasbeenmathematicallytransformedintoengineeringunits.Othermanipulationsalsocanbedonesuchasreorderingtomatchthechannelorder.
scanning Methodofsequentiallyconnectingchannels.SCC Signalconditioningcomponent—lowchannelcountanalog
ordigitalI/OmodulesforconditioningDAQsystems.SCXI SignalConditioningeXtensionsforInstrumentation—the
NIproductlineforconditioninglow-levelsignalswithinanexternalchassisnearsensorssothatonlyhigh-levelsignalsaresenttomeasurementdevicesinthenoisyPCenvironment.SCXIisanopenstandardavailableforallvendors.
sensor Adevicethatrespondstoaphysicalstimulus(heat,light,sound,pressure,motion,flow,andsoon)andproducesacorrespondingelectricalsignal.
signal Ameansofconveyinginformation.Ananalogwaveform,aclock,andasingledigital(TTL)edgeareallexamplesofsignals.
signalconditioning
Themanipulationofsignalstopreparethemfordigitizing.
smartTEDSsensor
Atransducerwithabuilt-inself-identificationEEPROMthatprovidestheTEDS.
softwaretiming
Ameansofcontrollingsignalgeneration.Thesoftware,suchasNI-DAQmx,andtheoperatingsystemcontroltherateofgeneration.
softwaretrigger
AVIorfunctionthat,whenitexecutes,triggersanactionsuchasstartinganacquisition.
sourceimpedance
Aparameterofsignalsourcesthatreflectscurrent-drivingabilityofvoltagesources(lowerisbetter)andthevoltage-drivingabilityofcurrentsources(higherisbetter).
staticAO Analogoutputoperationsthatusesoftwaretiming.staticdigitalI/O
Software-timeddigitalI/Ooperationsthatdonotinvolvetheuseofcontrolsignalsindatatransfers.Alsoknownassoftware-timedI/OorunstrobedI/O.
strain Theamountofdeformationofabodyduetoanappliedforce.
strobedI/O Anyoperationinwhicheverydatatransferistimedbyhardwaresignals.Inthecaseofsampleclocktiming,thishardwaresignalisaclockedge.InthecaseofhandshakingI/O,hardwaresignalsinvolvetwoorthreehandshakinglines.
STC systemtimingcontrollersynchronous 1. Hardware—asignalthatoccursorisacteduponin
synchronywithanothersignal,suchasareferenceclock.
2. Software—aVIorfunctionthatbeginsanoperation
andreturnsonlywhentheoperationiscomplete.
Ttask InNI-DAQmx,acollectionofoneormorechannels,
timing,andtriggeringandotherpropertiesthatapplytothetaskitself.Conceptually,ataskrepresentsameasurementorgenerationyouwanttoperform.
taskbuffer Refertobuffer.TCR temperaturecoefficientofresistance—theaverage
resistancechangeperonedegreeattemperaturesbetween0°Cand100°C.
TEDS transducerelectronicdatasheet—standardizeddatastructure,definedbyIEEE1451.4,fordescribingsensors,typicallystoredinnonvolatilememorywithinasensor.Themanufacturerofthesensorstores,intothismemory,initialinformationsuchasmanufacturername,sensortype,modelnumber,serialnumber,andcalibrationdata.TheTEDSdatastructurealsoincludesspaceforcustominformationsuchaschannelID,location,position,direction,tagnumber,etc.Alternatively,theTEDSdatamaybestoredinafileordatabaserecordasaVirtualTEDS.ForinformationonIEEE1451.4-compliantTEDSsensors,refertowww.ni.com/pnp.
TEDSClassISensor
AsmartTEDSsensorwithaconstant-currentpoweredtransducerwithatwo-wireinterface,suchasanaccelerometer.ClassItransducersalsoincludediodesoranalogswitcheswithwhichthemultiplexingoftheanalogsignalwiththedigitalTEDSinformationonthesinglepairofwiresispossible.Thedigitalportionofthemixed-modeinterface(Class1orClass2)isbasedonthe1-WireprotocolfromMaxim/DallasSemiconductor.
TEDSClassIISensor
AsmartTEDSsensorwithseparatewiresfortheanaloganddigitalportionsoftheTEDSmixed-modeinterface.Theanaloginput/outputofthetransducerisleftunmodified,andthedigitalTEDScircuitisaddedinparallel,suchasthermocouples,RTDs,andbridge-basedsensors.Thedigitalportionofthemixed-modeinterface
(Class1orClass2)isbasedonthe1-WireprotocolfromMaxim/DallasSemiconductor.
terminal AnamedlocationonaDAQdevicewhereasignaliseithergenerated(outputorproduced)oracquired(inputorconsumed).
terminalcount
Whencountingup,anNbitcounterreachesitsterminalcountat2N-1.AnNbitcountercountingdownreachesitsterminalcountat0.
thermistor Asemiconductorsensorthatproducesarepeatablechangeinelectricalresistanceasafunctionoftemperature.Mostthermistorshaveanegativetemperaturecoefficient.
thermocouple Atemperaturesensorcreatedbyjoiningtwodissimilarmetals.Thejunctionproducesasmallvoltageasafunctionofthetemperature.
threshold Thevoltagelevelasignalmustreachforatriggertooccur.
tick Adigitaledgeofaclock.timebase Aclockthatisdivideddowntoproduceanotherclockora
clockprovidedtoacounterformeasuringelapsedtime.TraditionalNI-DAQ(Legacy)
AnupgradeoftheearlierversionofNI-DAQ.TraditionalNI-DAQ(Legacy)hasthesameVIsandfunctionsandworksthesamewayasNI-DAQ6.9.x,exceptyoucanusebothTraditionalNI-DAQ(Legacy)andNI-DAQmxonthesamecomputer,andsomehardwareisnolongersupported.
transducer Refertosensor.transducerexcitation
Atypeofsignalconditioningthatusesexternalvoltagesandcurrentstoexcitethecircuitryofasignalconditioningsystemintomeasuringphysicalphenomena.
trigger Anysignalthatcausesadevicetoperformanaction,suchasstartinganacquisition.
TTL Transistor-transistorlogic—asignalhavingtwodiscretelevels,ahighandalowlevel.
Uunipolar Asignalrangethatisalwayspositive(forexample,0to+10
V).unscaled Samplesintheintegerformthatthehardwareproducesor
requires.Althoughnomathematicaltransformationsareappliedtounscaleddata,othermanipulationsmaybedonesuchasreorderingtomatchthechannelorder.
unstrobedI/O
RefertostaticdigitalI/O.
USBDAQ
AUSB-basedfamilyofdevicesusedforanaloginput,analogoutput,digitalinput/output,andcounter/timerapplications.SomeexampledevicesincludetheNIUSB-9201,NIUSB-9211,NIUSB-9215,NIUSB-9221,NIUSB-9233,andNIUSB-9237devices.ThesedevicesarealsoreferredtoasUSBDAQwithIntegratedSignalConditioning.
VV voltsVI Refertovirtualinstrument.virtualchannel
Refertochannel.
virtualinstrument
AprograminLabVIEWthatmodelstheappearanceandfunctionofaphysicalinstrument.
VISA VirtualInstrumentationSoftwareArchitecture.
Wwaveformdatatype
ALabVIEWdatatypethatbundlestiminginformationalongwiththedata.
WDT Refertowaveformdatatype.
ImportantInformationWarrantyCopyrightTrademarksPatentsWarningRegardingUseofNIProducts
WarrantyThemediaonwhichyoureceiveNationalInstrumentssoftwarearewarrantednottofailtoexecuteprogramminginstructions,duetodefectsinmaterialsandworkmanship,foraperiodof90daysfromdateofshipment,asevidencedbyreceiptsorotherdocumentation.NationalInstrumentswill,atitsoption,repairorreplacesoftwaremediathatdonotexecuteprogramminginstructionsifNationalInstrumentsreceivesnoticeofsuchdefectsduringthewarrantyperiod.NationalInstrumentsdoesnotwarrantthattheoperationofthesoftwareshallbeuninterruptedorerrorfree.AReturnMaterialAuthorization(RMA)numbermustbeobtainedfromthefactoryandclearlymarkedontheoutsideofthepackagebeforeanyequipmentwillbeacceptedforwarrantywork.NationalInstrumentswillpaytheshippingcostsofreturningtotheownerpartswhicharecoveredbywarranty.NationalInstrumentsbelievesthattheinformationinthisdocumentisaccurate.Thedocumenthasbeencarefullyreviewedfortechnicalaccuracy.Intheeventthattechnicalortypographicalerrorsexist,NationalInstrumentsreservestherighttomakechangestosubsequenteditionsofthisdocumentwithoutpriornoticetoholdersofthisedition.ThereadershouldconsultNationalInstrumentsiferrorsaresuspected.InnoeventshallNationalInstrumentsbeliableforanydamagesarisingoutoforrelatedtothisdocumentortheinformationcontainedinit.EXCEPTASSPECIFIEDHEREIN,NATIONALINSTRUMENTSMAKESNOWARRANTIES,EXPRESSORIMPLIED,ANDSPECIFICALLYDISCLAIMSANYWARRANTYOFMERCHANTABILITYORFITNESSFORAPARTICULARPURPOSE.CUSTOMER'SRIGHTTORECOVERDAMAGESCAUSEDBYFAULTORNEGLIGENCEONTHEPARTOFNATIONALINSTRUMENTSSHALLBELIMITEDTOTHEAMOUNTTHERETOFOREPAIDBYTHECUSTOMER.NATIONALINSTRUMENTSWILLNOTBELIABLEFORDAMAGESRESULTINGFROMLOSSOFDATA,PROFITS,USEOFPRODUCTS,ORINCIDENTALORCONSEQUENTIALDAMAGES,EVENIFADVISEDOFTHEPOSSIBILITYTHEREOF.ThislimitationoftheliabilityofNationalInstrumentswillapplyregardlessoftheformofaction,whetherincontractortort,includingnegligence.AnyactionagainstNationalInstrumentsmustbebroughtwithinoneyearafterthecauseofaction
accrues.NationalInstrumentsshallnotbeliableforanydelayinperformanceduetocausesbeyonditsreasonablecontrol.Thewarrantyprovidedhereindoesnotcoverdamages,defects,malfunctions,orservicefailurescausedbyowner'sfailuretofollowtheNationalInstrumentsinstallation,operation,ormaintenanceinstructions;owner'smodificationoftheproduct;owner'sabuse,misuse,ornegligentacts;andpowerfailureorsurges,fire,flood,accident,actionsofthirdparties,orothereventsoutsidereasonablecontrol.
CopyrightUnderthecopyrightlaws,thispublicationmaynotbereproducedortransmittedinanyform,electronicormechanical,includingphotocopying,recording,storinginaninformationretrievalsystem,ortranslating,inwholeorinpart,withoutthepriorwrittenconsentofNationalInstrumentsCorporation.NationalInstrumentsrespectstheintellectualpropertyofothers,andweaskouruserstodothesame.NIsoftwareisprotectedbycopyrightandotherintellectualpropertylaws.WhereNIsoftwaremaybeusedtoreproducesoftwareorothermaterialsbelongingtoothers,youmayuseNIsoftwareonlytoreproducematerialsthatyoumayreproduceinaccordancewiththetermsofanyapplicablelicenseorotherlegalrestriction.
TrademarksNationalInstruments,NI,ni.com,andLabVIEWaretrademarksofNationalInstrumentsCorporation.RefertotheTermsofUsesectiononni.com/legalformoreinformationaboutNationalInstrumentstrademarks.FireWire®istheregisteredtrademarkofAppleComputer,Inc.HandleGraphics®,MATLAB®,Real-TimeWorkshop®,Simulink®,Stateflow®,andxPCTargetBox®areregisteredtrademarks,andTargetBox™andTargetLanguageCompiler™aretrademarksofTheMathWorks,Inc.Tektronix®andTekareregisteredtrademarksofTektronix,Inc.Otherproductandcompanynamesmentionedhereinaretrademarksortradenamesoftheirrespectivecompanies.MembersoftheNationalInstrumentsAlliancePartnerProgramarebusinessentitiesindependentfromNationalInstrumentsandhavenoagency,partnership,orjoint-venturerelationshipwithNationalInstruments.
PatentsForpatentscoveringNationalInstrumentsproducts,refertotheappropriatelocation:Help»Patentsinyoursoftware,thepatents.txtfileonyourCD,orni.com/patents.
WARNINGREGARDINGUSEOFNATIONALINSTRUMENTSPRODUCTS(1)NATIONALINSTRUMENTSPRODUCTSARENOTDESIGNEDWITHCOMPONENTSANDTESTINGFORALEVELOFRELIABILITYSUITABLEFORUSEINORINCONNECTIONWITHSURGICALIMPLANTSORASCRITICALCOMPONENTSINANYLIFESUPPORTSYSTEMSWHOSEFAILURETOPERFORMCANREASONABLYBEEXPECTEDTOCAUSESIGNIFICANTINJURYTOAHUMAN.(2)INANYAPPLICATION,INCLUDINGTHEABOVE,RELIABILITYOFOPERATIONOFTHESOFTWAREPRODUCTSCANBEIMPAIREDBYADVERSEFACTORS,INCLUDINGBUTNOTLIMITEDTOFLUCTUATIONSINELECTRICALPOWERSUPPLY,COMPUTERHARDWAREMALFUNCTIONS,COMPUTEROPERATINGSYSTEMSOFTWAREFITNESS,FITNESSOFCOMPILERSANDDEVELOPMENTSOFTWAREUSEDTODEVELOPANAPPLICATION,INSTALLATIONERRORS,SOFTWAREANDHARDWARECOMPATIBILITYPROBLEMS,MALFUNCTIONSORFAILURESOFELECTRONICMONITORINGORCONTROLDEVICES,TRANSIENTFAILURESOFELECTRONICSYSTEMS(HARDWAREAND/ORSOFTWARE),UNANTICIPATEDUSESORMISUSES,ORERRORSONTHEPARTOFTHEUSERORAPPLICATIONSDESIGNER(ADVERSEFACTORSSUCHASTHESEAREHEREAFTERCOLLECTIVELYTERMED"SYSTEMFAILURES").ANYAPPLICATIONWHEREASYSTEMFAILUREWOULDCREATEARISKOFHARMTOPROPERTYORPERSONS(INCLUDINGTHERISKOFBODILYINJURYANDDEATH)SHOULDNOTBERELIANTSOLELYUPONONEFORMOFELECTRONICSYSTEMDUETOTHERISKOFSYSTEMFAILURE.TOAVOIDDAMAGE,INJURY,ORDEATH,THEUSERORAPPLICATIONDESIGNERMUSTTAKEREASONABLYPRUDENTSTEPSTOPROTECTAGAINSTSYSTEMFAILURES,INCLUDINGBUTNOTLIMITEDTOBACK-UPORSHUTDOWNMECHANISMS.BECAUSEEACHEND-USERSYSTEMISCUSTOMIZEDANDDIFFERSFROMNATIONALINSTRUMENTS'TESTINGPLATFORMSANDBECAUSEAUSERORAPPLICATIONDESIGNERMAYUSENATIONALINSTRUMENTSPRODUCTSINCOMBINATIONWITHOTHERPRODUCTSINAMANNERNOTEVALUATEDORCONTEMPLATEDBYNATIONALINSTRUMENTS,THEUSEROR
APPLICATIONDESIGNERISULTIMATELYRESPONSIBLEFORVERIFYINGANDVALIDATINGTHESUITABILITYOFNATIONALINSTRUMENTSPRODUCTSWHENEVERNATIONALINSTRUMENTSPRODUCTSAREINCORPORATEDINASYSTEMORAPPLICATION,INCLUDING,WITHOUTLIMITATION,THEAPPROPRIATEDESIGN,PROCESSANDSAFETYLEVELOFSUCHSYSTEMORAPPLICATION.
TechnicalSupportandProfessionalServicesVisitthefollowingsectionsoftheNationalInstrumentsWebsiteatni.comfortechnicalsupportandprofessionalservices:
Support—Onlinetechnicalsupportresourcesatni.com/supportincludethefollowing:
Self-HelpResources—Foranswersandsolutions,visittheaward-winningNationalInstrumentsWebsiteforsoftwaredriversandupdates,asearchableKnowledgeBase,productmanuals,step-by-steptroubleshootingwizards,thousandsofexampleprograms,tutorials,applicationnotes,instrumentdrivers,andsoon.FreeTechnicalSupport—AllregisteredusersreceivefreeBasicService,whichincludesaccesstohundredsofApplicationsEngineersworldwideintheNIDeveloperExchangeatni.com/exchange.NationalInstrumentsApplicationsEngineersmakesureeveryquestionreceivesananswer.Forinformationaboutothertechnicalsupportoptionsinyourarea,visitni.com/servicesorcontactyourlocalofficeatni.com/contact.
TrainingandCertification—Visitni.com/trainingforself-pacedtraining,eLearningvirtualclassrooms,interactiveCDs,andCertificationprograminformation.Youalsocanregisterforinstructor-led,hands-oncoursesatlocationsaroundtheworld.SystemIntegration—Ifyouhavetimeconstraints,limitedin-housetechnicalresources,orotherprojectchallenges,NationalInstrumentsAlliancePartnermemberscanhelp.Tolearnmore,callyourlocalNIofficeorvisitni.com/alliance.DeclarationofConformity(DoC)—ADoCisourclaimofcompliancewiththeCounciloftheEuropeanCommunitiesusingthemanufacturersdeclarationofconformity.Thissystemaffordstheuserprotectionforelectroniccompatibility(EMC)andproductsafety.YoucanobtaintheDoCforyourproductbyvisitingni.com/certification.CalibrationCertificate—Ifyourproductsupportscalibration,youcanobtainthecalibrationcertificateforyourproductat
ni.com/calibration.Ifyousearchedni.comandcouldnotfindtheanswersyouneed,contactyourlocalofficeorNIcorporateheadquarters.YoualsocanvisittheWorldwideOfficessectionofni.com/niglobaltoaccessthebranchofficeWebsites,whichprovideup-to-datecontactinformation,supportphonenumbers,emailaddresses,andcurrentevents.
BranchOfficesOffice TelephoneNumberAustralia 1800300800Austria 43662457990-0Belgium 32(0)27570020Brazil 551132623599Canada 8004333488China 862150509800CzechRepublic 420224235774Denmark 4545762600Finland 358(0)972572511France 33(0)157662424Germany 49897413130India 918041190000Israel 972036393737Italy 390241309277Japan 0120-527196/81354722970Korea 820234513400Lebanon 961(0)1332828Malaysia 1800887710Mexico 018000100793Netherlands 31(0)348433466NewZealand 0800553322Norway 47(0)66907660Poland 48223390150Portugal 351210311210Russia 74957836851Singapore 18002265886Slovenia 38634254200
SouthAfrica 270118058197Spain 34916400085Sweden 46(0)858789500Switzerland 41562005151Taiwan 8860223772222Thailand 6622786777Turkey 902122793031UnitedKingdom 44(0)1635523545UnitedStates(Corporate) 5126830100