SignalExpress

cancel
Showing results for 
Search instead for 
Did you mean: 

how to generate pulse train at USB-6501 output port using signal express

Im trying to send a pulse train from PC to USB-6501 using labview signal express 2.5.0. I am doing the following,

 

1) generate signal -> DAQmx generate signal -> digital ouput

          : write a "High" to the line selected

2) generate signal -> DAQmx generate signal -> digital ouput

          : write a "low" to the line selected

3) do a conditional repeat around the above until iteration reaches 100

 

it gives the following error while execution on both 1 and 2 tasks

Error -201003 occurred at DAQ Assistant

 

Also, is there a way to control the period of the pulses I intend to generate

 

         

0 Kudos
Message 1 of 9
(10,477 Views)

Hi there

 

Have you made sure you have configured the DIO ports on the USB-6501 correctly?

 

Please see here; USB-6501 Manual to configure the ports correctly. The NI USB-6501 has 24 single-ended digital lines, P0.<0..7>, P1.<0..7>, and P2.<0..7>, which comprise the three DIO ports. P2.7/PFI 0 can also function as a 32-bit counter.

 

The error you are receiving is due to the USB device not being recognised. Have you used MAX (Measurement & Automation Explorer) to make sure this is performing correctly? Please make sure you clear the task before restarting it.

 

Error 201003 is generally caused due to the following reasons:

  • DAQmx is not installed properly or has not been updated.
  • The slot location of the DAQ card has been changed.
  • The card is damaged.

To resolve this error, carry out the following steps:

  • Check that the card is powered and is detected by your operating system. To do so go to Control Panel»System»Hardware»Device Manager and expand Data Acquisition Devices. If your card is visible in this section it indicates that it is properly installed and has been detected by your operating system. If not, then turn your computer off and on again.
  • After the card shows up in Device Manager go to Measurement and Automation Explorer and check if the card is visible under Devices and Interfaces»DAQmx Devices. If it shows up and gives the same error or does not show up, uninstall NI-DAQmx and reinstall it. Make sure you get the right version and if necessary, update it by downloading the driver from the Updates and Drivers page on ni.com.
  • Lastly, if the card shows up in Measurement and Automation Explorer but still gives error 201003 at the test panel, it indicates that the card is interacting with the driver but is giving the error as DAQ Assistant still has the previous configuration information from Measurement and Automation. To update the card configuration for DAQ Assistant, do the following for every instant of DAQ Assistant in your VI that uses the same card. Double-click on DAQ Assistant and go to Configuration»Details»Physical Channel. Right click on the entry there and choose Change Physical Channel. From the menu window that opens up select the current device configuration and confirm that it is the right one by checking in Measurement and Automation Explorer to see that the device number matches. This will update the DAQ Assistant.

If  the card is not visible in Device Manager or never appears in Measurement and Automation Explorer, it could indicate that the card is damaged. In this case please contact National Instruments Support.

Many thanks for using the NI forums and I look forward to your reply.

Kind regards

David

Applications Engineer
National Instruments UK
Message 2 of 9
(10,452 Views)

Hi David

 

Thanks for the reply

 

I tried another task on USB-6501 and it seems to work fine. The error, mentioned above, said there is probably a clash in using the same line ouput for two tasks at the same time.

 

I have changed the task and now use DQAmx generate and sweep (value to write) to generate this pulse train. But the signal I see on the scope has a period of 2.3s. And I cannot see the complete pulse train as the scope goes into "slow acquisition"

 

Is there an better way to generate pulse train on USB-6501 outputs and see it on the scope without slowing it down

 

Thames

 

0 Kudos
Message 3 of 9
(10,440 Views)

Dear Thames

 

You are correct in using different lines for acquistion. Please see Page 10 of the USB-6501 manual I referenced in my earlier post. You will see that there are 24 single-ended digital lines, P0.<0..7>, P1.<0..7>,and P2.<0..7>, which comprise the three DIO ports. You should use P0.1 and P1.0 for exampel to seperate the ports.

 

With regards to generating a pulse train using one of the output ports, the USB-6501 does not support pulse generation; please see the specifications description at the below link; The board's timer can only count edges, it doesn't have output modes. The DIO lines are software timed, so the output is as fast as the software can run. This is usually around 1kHz, which was more than adequate for his application.

 

USB-6501 Specifications

 

I recommend using USB-6211 which supports Digital Pulse Generation and also uses 32bit counters and 4 DIO ports.

Many thanks for using the NI forums and I look forward to your reply.

Kind regards

David

Applications Engineer
National Instruments UK
Message 4 of 9
(10,438 Views)

Hi David

 

I will debug whether the period '2.3s' is due to actual software timing or incorrect task sample period setup:since from what you said it is possible to get upto 1KHz even with software timing

 

Thanks for your promt reply

 

Thames

 

 

0 Kudos
Message 5 of 9
(10,371 Views)

Hi David

 

I can read back a waveform of 10Hz freq (from waveform generator) using USB-6501 and signal express sampling every 5ms. But I am not able to generate a pulse train at USB output (by toggling its value using "sweep") at a period better than ~2.3s. The sample period for this "DAQmx Generate" is also 5ms.

 

Can I improve the write rate some other way

 

Thames 

0 Kudos
Message 6 of 9
(10,360 Views)

Dear Thames

 

As I mentioned previously, the USB-6501 does not have the hardware capability to generate a hardware timed pulse train. However, a pulse train could be produced with a digital line and some software timing. It would entail toggling a digital line in a loop structure. In this situation, the pulse train would of course be software timed as mentioned and at the mercy of the operating system.

 

Take a look at the KB I ve linked below; this will enable you to use the counter on the USB-6501 and a pause drigger to enable a pulse train; before you would need 2 counters, but this method, although not as accurate will enable you to accomplish a pulse train

 

Using One Counter to Generate a Retriggerable Finite Digital Pulse Train with a PCI-6602 and DAQmx

 

As I mentioned this isn't the most optimum approach and is not as accurate as using one of our Pulse Generation Modules I referenced earlier; and hence why your timings are slightly out. I hope this is of help.

 

 

Many thanks for using the NI forums and I look forward to your reply.

Kind regards

David

Applications Engineer
National Instruments UK
0 Kudos
Message 7 of 9
(10,358 Views)

Excuse me:

I have the opposite problem; I have a pulse train coming from a pulse generator (square wave) and as a technician some times I need to check how is the pulse train; so I must use the oscilloscope that is mounted on a oscilloscope cart and after the readings I must go back to the maintenance shop pulling the oscilloscope again, my question is if can be possible to use an Ipad or an blackberry or a galaxy tab or an Alcatel one touch tribe and read the data from the usb port of the mobile gadget maybe with a java program; somebody knows about that???;( the mobile gadgets list is because every technician here uses a different gadget, I use a big screen Alcatel One touch tribe (and I am pretty sure can use Java) but the second shif technician uses blackberry and so); if somebody knows about this please send an email to ofsalcido@gmail.com

 

Thanks in advance

Octavio Salcido

0 Kudos
Message 8 of 9
(8,889 Views)

Hi Octavio Salcido

 

Please start a new thread for new questions!

This thread is three years old and posting here will likely not get you an answer at all.

 

Kind Regards

Chris | Applications Engineer NIUK
Message 9 of 9
(8,875 Views)