USB 6008 DAQ Read switch wiring

Hi i am looking to wire a magnetic read switch into the 6008 DAQ. The switch has just two wires and im just using it to count events.
If anyone could help that would be great.
Attached is the lab view progrem i have written for this task.
regards Gerry
Attachments:
read switch.vi ‏56 KB

Gerry,
Because you are using the 6008 and want to determine the duration that the switch is closed then I would use a digital line and just poll it in software. Look at the Example Finder in LabVIEW (Help » Find Examples) and find either Digital - SW - Timed Input or Read Digital Channel. This will show you how to read a digital line in LabVIEW. You can use the Express VI, but I just looked for examples that would be similar to what you need.
From there you will use a loop to continuously measure the digital line. You will need to keep track of times that the digital line goes high (closed switch - I'm assuming you are probably just hooking one side of the switch to +5V) and then you can also count how long the digital line stay high. You probably don't need it overly accurate for your application. You can query the time when the line goes high, and then again when the line goes low and then subtract the two to get your time duration.
Aaron W.
National Instruments
CLA, CTA and CPI

Similar Messages

  • Laser operation with a USB 6008 DAQ

    I'm wondering how I go about using the USB 6008 DAQ in conjuction with labView to turn on and off ths laser: 
    http://www.maplin.co.uk/p/1mw-3v-red-laser-module-le07h
    The laser must be turned on using 3V which isn't possible with this DAQ. I was thinking of usinga BC 109 transistor, then have the laser connected to an external power supply which is supplying 3V to the laser. then have the laser connected to the collector of the transistor.
    I set this up and it didn't exactly work out as the laser was drawing to high a current and not working correctly.
    Can anyone help me?

    OK. The problem is that you need to supply about 30 mA to the laser to get it to work. The digital outputs of the USB-9008 are limited to 8.5 mA or less. Furthermore, a laser diode is a current operated device. If you apply a fixed voltage the current will vary depending on the exact doping used when the device was manufactured and on it instantaneous temperature. The curretn rises exponentially with voltage as in any diode. The link you posted does not have any real data about the electrical characteristics of that diode.
    Typically a current regulating circuit is used to drive laser diodes.  The simplest circuit is a resistor in series with the diode connected to a power supply with a voltage higher than 3 V. The value of the resistor depends on the power supply voltage, the voltage drop across thes witching transistor, and how much current you want to run through the diode. If you have applied 12 V to that laser from a source which can provide substantial current (>50 mA), you have probably destroyed it.
    Lynn

  • Will USB-6008 DAQ be able to power and record voltage for UMS T5 tensiometer at the same time?

    I would like to use my NI USB-6008 to provide power to my UMS T5 tensiometer  (http://www.ums-muc.de/en/products/tensiometer/t5.html) as well as take readings from it, but I don't know if this is possible to do properly. The supply voltage for the instrument can be as low as 5V, which I can easily get from the dedicated +5V channel. I am able to power the instrument and connect it to an analog input on the 6008 and measure a voltage in differential mode. However, while reading the support literature for the instrument, I find the following:
    "Potential data acquisition pitfalls: Because the pressure transducer is configured in a Wheatstone full bridge, the input voltage and signal mV output cannot be connected to the same reference (ground). Hence, the signal mV output can only be measured using a differential voltage measurement. Therefore, do not attempt to make a single-ended measurement of the pressure transducer mV output."  (http://www.decagon.com/assets/Uploads/MeasuringUMSTensiometerswithnon-UMSControlandDataAcquisitionSystems.pdf)
    My understanding is that the 6008 can take a differential measurement if I attach the signal "+" and signal "-" to the positive and negative analog input terminals. However, it seems that all of the Ground ports on the 6008 are grounded to the same reference, which would make my voltage measurement invalid according to the paragraph above. So my real questions is: if I attempt to record the voltage using one of the analog inputs on the 6008 in this way, is the measurement valid? Or do I need to find a separate power supply with a different reference ground to ensure that the measurement is accurate?

    The specification sheet for that device is very poor. The manual is not much better. Companies which want to sell scientific equipment should publish decent data sheets or get out of business.
    In section 3.4.3 General requirements the device is described as a "non-amplified bridge circuit."  This information along with the bridge impedance should be in the specifications because it is essential to applying the device under any circumstances other than the nominal behavior at 10.6 V.
    The answer to your question is this:
    You can use it with the USB-6008.  The 5 V power supply will result in output voltages slightly less than half (5/10.6) the voltages specified under nominal conditions. You can use the differential input mode on the USB-6008.  The absolute input voltages will be about 2.5 V with the 5 V supply. That voltage is within the working range of the device. The differences will probably be less than 100 mV. The resolution of the USB-6008 on the +/-1 V range is about 0.5 mV so your pressure resolution will be around 1 % of full scale. The input impedance and termination voltage of the USB-6008 will introduce some errors.  These may be on the order of 5-10%. I cannot predict much better without the missing bridge impedance specification.  Those errors should be systematic and relatively constant. A calibration of the whole system - sensor and DAQ device together should allow you to compensate for much of that error.
    Lynn

  • Usb 6008 daq spi lcd server client

    Hi.
    I'm new to the labview.ich have a project and comes to data acquisition and remote monitoring
    detaille:
    2 computer are labview installed on both and connected to wifi / internet.
    the server computer connected with ni usb 6008 and it pt100 temperature sensor
    it should also include the measurement data display on an LCD
    it should be the client computer also read out the measured values
    has anyone an idea how could you start?., I will be very grateful

    This sounds like a pretty big task for someone new to LabVIEW.
    First get the DAQ working on the server PC.  There are tons of examples that ship with LabVIEW for taking DAQ, go to Help >> Find Examples.
    Getting the information to your other PC can be done many different ways, but maybe the easiest is to just use a Web Server to control the front panel.
    http://zone.ni.com/reference/en-XX/help/371361H-01/lvconcepts/viewing_fp_remote/
    Also you could remote into this PC using remote contol software and remote desktop.
    As for displaying data on an LCD.  A relativly simple solution is to use an Arduino UNO, the LIFA toolkit and an LCD connected to it.  It is a little bit if a round about solution but the LIFA toolkit comes with code to output to LCDs connected and it is relatively easy to use.
    EDIT:  LIFA https://decibel.ni.com/content/groups/labview-interface-for-arduino
    Unofficial Forum Rules and Guidelines - Hooovahh - LabVIEW Overlord
    If 10 out of 10 experts in any field say something is bad, you should probably take their opinion seriously.

  • Has anyone any experience with a USB-6008 and reading a thermistor value

    Labview 8.0 connected to a USB-6008
    I am using 'BC Components' NTC Thermistor. I used the express VI to create a Vex input and entered the A,B,& C values from the datasheet. The thermistor is the 10K version and I placed a 10K resistor in series with it. I wired it as is shown in the connection diagram, and applied 2.5 volts to it.
    I get completly the wrong temperature readings out of it! I called the NI help line in the UK and the engineer confirmed that I had done everything correctly but couldn't understand why it didn't work.
    Any thoughts?
    Steve Lawson

    I had a similar problem, had it working at one point then screwed it up.
    try this:
    Attachments:
    Temp Pressure EXpress.vi ‏92 KB

  • Controling heating/cooling element with labview and usb 6008 DAQ card

    Greetings All
    I'm looking for a heating/cooling type of element that I can control with labview and my usb-6008 card. Heating/Cooling will just be for clean water and the temperture range will be from 0 C to 100 degree C.
    Thanks
    The heating and cooling elements can be seperate products. Any recommendations

    A simple kettle element will of course be sufficient for upto 100°C
    To get the temperature down you need a cooling system, what springs readily to mind of course is a refrigerator.
    Just a note of warning, water and electricity are dangerous bed fellows.
    On that note perhaps one of those vortex air units would be safer - they blow hot in one direction and cold in the other, nominally to 100°C
    see: -
    http://www.airtxinternational.com/how_vortex_tubes_work.php

  • Reading an encoder with a USB 6008

    Hello DAQmx users,
    I have a USB 6008 and it doesn't work the way I want it to.  I have done no troubleshooting or research and I refuse to give you any more information.  You have 30 seconds to answer my question.   i kid, i kid...
    So here is my real question:
    I have a USB 6008 that we use to do simple analog output.  I'm looking for a way to use the USB 6008 to also get encoder information.  I know that the USB 6008 cannot read an encoder directly, but I was wondering if anyone knew of or had any ideas of external hardware that could be used inbetween the 6008 and the encoder.  I think it would be something like 1) the encoder generates pulses 2) external hardware takes encoder pulses, translates them into a digital value representing the angle and outputs this digital value 3) use the digital lines on the 6008 to read in the digital angle value from the external hardware 4) I don't lose my job.
    I realize that this isn't an easy, optimal, or preferred solution, but I want to look into it before being forced to replace the USB 6008 with another piece of hardware.
    Eric
    DE For Life!

    Oops..  Just realized that this got posted in the Motion Control Forums... Meant for it to go in the MIO forums.  Sorry!
    New thread is here, feel free to respond!
    Message Edited by e-Cash-Money on 03-17-2006 04:30 PM
    Eric
    DE For Life!

  • Relay and DAQ for switching a DC Motor

    Hello..we wish to use SPDT relay with NI USB-6008 DAQ card for switching on/off a DC motor. The DC motor has a voltage rating of 122V and current rating of 10A and it is used to pump water. The SPDT relay we have has voltage and current ratings of 12V and 6A respectively. Can this relay be used to directly control the motor, if the relay is energized from the DAQ? Do we need to connect any other component in order to use this relay?

    You'll need a couple of relays.  You'll need a motor contactor that has a voltage and current rating on the contacts that work for the motor.  Many of these contactors have a 24V coil that.
    You will need a 24V power supply.  Now you need something between the USB-6008 and the 24V contactor.  This might be another relay.  Or perhaps a transistor driver that can take the 5V DC output from the USB=6008 that will control the 24 V DC coil.  A USB-6008 doesn't have enough current capacity (or the voltage) to drive a motor contactor coil directly.
    I'd recommend talking to someone familiar with electrical control circuits about your specific requirements.

  • Error -10401 occurred at AI Group Config - in relation to USB-6008

    I'm attempting to run a simple vi that uses AI Aquire Waveforms.vi to input voltage data that I have coming in from the USB-6008 DAQ.  However, when I try running the program, I receive the error:
    Error -10401 occurred at AI Group Config
    Possible reason(s):
    NI-DAQ LV:  The specified device is not a National Instruments product, the driver does not support the device (for example, the driver was released before the device was supported), or the device has not been configured using the Measurement & Automation Explorer.
    And I'm not sure how to fix it.  In MAX, the device seems to be working properly and everyhting seems to work fine in the test panel, so I'm slightly at a loss.  I'm running Labview 7.1, and installed NI-DAQmx 7.5 which came with the USB-6008.

    Never mind.  I'm new to Labview, and didn't realize that I could not use the traditonal Data Aquisition components with the USB-5008 (I didn't even realize that NI-Daqmx was different).

  • Rpm sensor diagram using usb-6008

    Hi All,
    Attached is my block diagram for the RPM sensor that I wan to create. What I'm trying to do is to get the analog input and do a pulse calculation within 60 seconds, and my RPM would be how many pulse * 60. I don't know whether I'm doing it right or not, but I have a feeling that I need to use the digital input rather than analog input. Any comment?
    Thanks
    Attachments:
    rpm sensor design.vi ‏70 KB

    Hello Dadsf,
    Welcome to the NI Discussion Forums!  From your post, you would like to be able to count the number of pulses from your sensor that occur during a period of time and convert this to RPM.  Let me know if I have interpreted this incorrectly.  Your USB-6008 manual indicates that the device has a built in counter that can be used to count falling edge signals.  If your sensor outputs digital signal this would be a good way to go.  You can take the number of pulses that occur over a certain period of time (perhaps between two loop iterations) to find the number of pulses per second.  The longer the period of time you acquire pulses for, the more accurate your average RPM will be.  This will be at an expense of how often the user is updated with a new RPM value.  Check out the links in my signature for some great information on how to get started with DAQmx and what all of the different terms in the DAQ Assistant mean. 
    I noticed that your DAQ Assistant was set to 1 sample on demand.  What this does is causes the USB-6008 to read a single sample from the analog input during each iteration of the loop.  I am not sure if that is the behavior you are looking for.  Another option would be to setup the task as continuous hardware timed analog input (change the Acquisition mode to Continuous Samples with you desired sample rate and the desired number of samples you would like to read at a time).  This will give you a waveform of data that should show the pulses over a period of time.  You could then count the number of pulses that occur over the length of the waveform.  This would be the equivalent of the number of pulses per second that could be converted to RPM.  This method requires a little more processing than the first method, but could give you a little better accuracy.  Post back if you need more info. 
    Regards,
    Browning G
    FlexRIO R&D

  • Cannot use USB 6008 in Lab VIEW... is in Devices on Comp however

    I was in class the other night, and was running a VI.  We went to lab, and without shutting down labView, my partner plugged in my USB-6008 DAQ.  SInce that time, the 6008 will not show up.  I have a message about having no supported devices.  I am using DAQmx 8.0 that came with my student version, and have reinstalled the LabVIEW 8.0 and the DAQmx 8.0  I still cannot get LabVIEW to recognize the DAQ.  When I plug it in my hardware profiles recognize that it is hooked up, but LabVIEW will not.  Also I have uninstalled it, and plugged it in, reinstalled it using the auto hardware install wizard, and still nothing on LabVIEW.  The DAQ has the flickering green LED, and works on other laptops.  Also my flash drive works correctly in all of the USBs, so I do not think that could be the problem.  I just really would like to get this to work again, but as I said the DAQ is not recognized by MAX or DAQmx inside of LabVIEW.  Any help would be greatly appreciated...
    Thanks

    Hi,
    You might want to try MSI-Blast.
    Have a look at this thread.
    http://forums.ni.com/ni/board/message?board.id=170&message.id=108288&query.id=113978#M108288
    Patrick Allen

  • Switching pneumatic solenoid valves using USB 6008

    Hi, 
    I am a student working on a project in which I need to built a program to control/switch  pneumatic solenoid valves to oporate on a pneumatic cylinder using the USB 6008 I am very new to LabView and DAQ.
    The solenoid has two ports, one for extending the stroke arm of the pneumatic cylinder and the other for collapsing the stroke arm.as the solenoids works off of a 12V supply I have bulilt a darlington pair as a firing circuit for it.
    I have had built different programs but I'm only able to  send a signal to extend the stroke arm  and then manually switch the wiring to collaps the stroke arm. So I have problem building a program that sends a signal to my circuit in such a way that ports of the solenoids go ON and OFF after a certain time.
    I really appreciate your help
    Elmira
    Elmira

    Dear Lynn,
    Thanks for the replay.
    I'm gonna try to best describe my system this time;
    I'm trying to creat pitch motion  using a pneumatic system including an air compressor, a solenoid valve and a cylinder.
    The compressor is made by PowerFist and is capable of storing 5 gallons of air under a rated pressure of 125psi and can deliver 2.5cfm (cubic foot per meter) at 90 psi. The compressed air is sent directly to the solenoid valve. It operates using an electrical motor operating from a standard 110V power outlet.The cylinder has a stoke length of 19.7” and a bore size of 1.6” capable of operating under 130psi.
    The solenoid valve used is  5-way 3-position. This means that there are five different ways the air flows inside the solenoid and the solenoid can set in three positions depending on the movement of the mechanical core inside. When air is transferred into the valve the mechanical core moves directing the air to the appropriate ports of the solenoid. The two outputs of the solenoid are sent directly to the pneumatic cylinder where extension and collapsing movements can be performed. the solenoid works off of a 12V supply so I'm using darlington pair transistor as the firing circuit .
    Please see the attach for the pneumatic diagram.
    Thank you
    Elmira
    Attachments:
    pneumatic diagram.jpg ‏33 KB

  • How can I make LabView 6.1to detect DAQ NI-USB 6008

    I have a LabView version 6.1, recently I bought a new DAQ model NI-USB 6008, I could not use it with my Labview version. Please, how can I adapt my DAQ for version 6.1 or update my LabView to detect my DAQ? Please advise me to a free applicable solutions. Thanks very much

    The USB 6008 requires DAQmx which requires LabVIEW 7.0 or greater. The upgrade to 7.x (or the just released 8.0) is not free. The only other solution I've heard of is to use the Call Library Function Node to make your own calls to the DAQmx dll. This would not be for the faint of heart or anyone wishing to come up with a quick solution.

  • Thermocoup​le DAQ USB 6008

    Hello
    I am novice of LABVIEW and DAQ system. If now i am going to use thermocouple, will it be suitable for me to use USB 6008 to acquire and analyze signal. USB 6008 has no filters inside. Using labview, will the noise be filtered out by LABVIEW itself using FILTER vi?
    if signals are going to be analyzed continuously( it will measure ambient temperature with sudden hot air is blown against thermocouple intermittently), how would u recommend me? how can i take only signals with hot air and disregard the ambient temperature( as differentiate the hot air from ambient air).

    Hi to all,
    I don't understand very well whats mean this that says johnsold:
    "The USB-6008 has 12 bit resolution (differential) and the most sensitive range is +/-1 V. This means that the resolution is about 0.5 mV."
    could someone explain to me please?
    I am trying to read sensor Lm 35, through the USB6008 and get a signal with noise near .005 V. In fact when I read any signal I have this noise level, can you advise me?
    Thanks, greetings.

  • NI-DAQ for USB-6008, LV 2012

    Hello, I have a NI USB-6008 for which I want to create a VI with Labview 2012 for logging one channel at 0-2V from a current shunt. In the our previous version of Labview 2011 I was experimenting with DAQ Assistant which made the job easy, but in LV 2012 this doesn't seem to exist.
    I was reading help files and I should be able to use NI-DAQmx but I can't seem to be able to find it. In NI Max I can see NI-DAQmx is there and can run  NI-DAQmx test panels on the USB-6008, but in LV 2012 I go to blank VI, block diagram, and I'm stuck. Any help will be greatly appreciated.
    LV 2012
    Windows XP
    NI USB-6008

    Hi there,
    Can you check if you have DAQmx functions in Measurement I/O > NI-DAQmx in the function palette?
    If no, did you re-install the DAQmx device driver together with LabVIEW 2012?
    And what is your DAQmx version you're currently using?
    - Ee Lim -
    See that button on the left side of this post...
    If you feel my post is helpful, all you need is just (at most) 2 seconds to click that button, to show your appreciation. Thank you~~

Maybe you are looking for