1 / 38

Course contents

Course contents. Labview basics virtual instruments, data flow, palettes Structures for, while, case, ... editing techniques Controls&Indicators arrays, clusters, charts, graphs Additional lecture State machines, SubVIs, MainCluster Modular programming + recording SubVIs File I/O

gryta
Download Presentation

Course contents

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Course contents • Labview basics • virtual instruments, data flow, palettes • Structures • for, while, case, ... • editing techniques • Controls&Indicators • arrays, clusters, charts, graphs • Additional lecture • State machines, SubVIs, MainCluster • Modular programming + recording • SubVIs • File I/O • Analysis • Signal processing • Communication between loops • Instrument control • DAQ , Data collection, GPIB, Serial • Additional lecture • Data Acquisition, Instrument control

  2. Measurement & Automation Explorer (MAX) • View and control your devices and software

  3. Create simulated device • You can test your code without the hardware

  4. Create simulated device • Real devices are green • Simulated devices are yellow • simulated devices work just like real devices

  5. Test panel

  6. MAX • Check pinouts

  7. MAX • Self Test

  8. DAQ Assistant

  9. DAQ Assistant • Create new task • put express VI to block diagram

  10. DAQ Assistant

  11. DAQ Assistant • Define Task • 1 sample

  12. Acquire 1 sample with DAQ assistant

  13. Acquire multiple samples from multiple channels

  14. Acquire multiple samples from multiple channels • N Samples

  15. Acquire multiple samples from multiple channels • You can sample within a loop

  16. Acquire continuosly

  17. Acquire continuosly

  18. Create NI-DAQmx tasks from MAX

  19. Define Task

  20. Define Task • Tasks are visible in all LabVIEW applications

  21. Task settings • Input range • Timing • Terminal configuration • Add channels

  22. Run task • Simulated device will produce sine wave • Press Save to save the task settings

  23. Test simulated device on LabVIEW • Hardware Input and Output»DAQmx»AnalogMeasurements»Voltage»ContAcq&Graph Voltage-Int Clk.VI

  24. Test simulated device on LabVIEW

  25. Create task from express VI

  26. Generate code from express VI • Express VI set to Continuos mode

  27. Generate code from Task name constant

  28. Generate code from Task name constant

  29. Output voltages

  30. Output Voltages • N samples • Generate >> Example

  31. Digital input • 1 Sample

  32. Digital input • 1 Sample • Generate >> Example

  33. Digital output • 1 Sample

  34. Triggered acquisition

  35. Counter

  36. NI DAQmx Help • Start»Programs»NationalInstruments»NI-DAQ

  37. Terms • Physical channel - A terminal or pin at which you can measure or generate an analog or digital signal. • Virtual channel - A collection of settings that can include a name, a physical channel, input terminal connections, the type of measurement or generation, and scaling information. In NI-DAQmx, virtual channels are integral to every measurement. You can configure virtual channels with the DAQ Assistant, which you can open from Measurement & Automation Explorer (MAX) or your application software. You also can configure virtual channels with the NI-DAQmx API in your application program. • Task - A collection of one or more virtual channels with timing, triggering, and other properties. Conceptually, a task represents a measurement or generation you want to perform. You can set up and save all of the configuration information in a task and use the task in an application. In NI-DAQmx, you can configure virtual channels as part of a task or separate from a task. • Local channels - Virtual channels created inside a task. • Global channels - Virtual channels defined outside a task. You can create global channels in MAX or in your application software. You can use global channels in any application or add them to a number of different tasks. If you modify a global channel, the change affects all tasks in which you reference that global channel. In most cases, it is simpler to use local channels.

  38. Links • DAQmx Simulated Devices • http://zone.ni.com/devzone/cda/tut/p/id/3698 • DAQ Assistant and automatic code generation • http://zone.ni.com/devzone/cda/tut/p/id/4656 • Useful DAQmx functions • http://zone.ni.com/devzone/cda/tut/p/id/2835 • Continuous vs. Finite Sampling • http://digital.ni.com/public.nsf/allkb/B86AA2D2FDE9A16086256FFC00604202 • Read multiple channels sequentially (advanced) • https://decibel.ni.com/content/docs/DOC-6901

More Related