Count only when a external TTL signal is high

Hallo,
I'm using LabView 6.1 on WinXP with a NI6014 DAQ Board...
I have to count a some TTL pulses only when another TTL signal is high (start the count when the signal goes high and stop it when the signal goes low). Can I program the DAQ to do this (like a gate function) so that in the meanwhile my program can do other things, and only at the end I read the result of the count?
Thank you,
Pixo

Hello Pixo,
Thank you for your inquiry regarding counters on the PCI-6014. It sounds like you would like a gate function for the counter that you are using. There is a gate for each counter that enables the counter when the gate line is high and disables the counter when this line is low. The I/O connector pin assignment and signal descriptions can be found here . To use the counter you must first configure it and then use a Counter Start VI. Then when the gate is high the counter will increment and the value can be read at the end of the program like you had stated. I have attached a great example VI to get you started with counters. Other examples like this can be found in LabVIEW 6.1 under �Find Examp
les from the LabVIEW startup screen.
I hope these resources help. Let me know if I can further assist you.
Shea C.
Applications Engineering
Attachments:
Getting_Started_Counters.vi ‏64 KB

Similar Messages

  • Forwarding calls only when I have no signal?

    Hey folks,
    I just moved and have really poor reception in my house. I tried a signal booster and that didn't work. I also thought I could maybe forward calls to a skype phone, but I don't want to have to turn call forwarding on and off every time I come and go.
    So does anyone have any tips? Can I have calls forwarded only when my phone has no signal or is turned off?
    Thanks,
    Joe

    I have a new iPhone 3G and I have the exact same question and challenge, poor reception at home and at my office. I used to have a Palm 750 (Mobile 6), and it had that feature, but on my new 3G, I have to reenter the call forward number every time, unless I am missing sometime. Seems ridiculous. It should maintain a list of at least 3-5 recently call forwarded numbers, as most persons would only have a select few numbers that they would ever call forward. Also, my Palm 750 had a special icon on the face page showing that I had the call forwarding feature turned on. That was a nice reminder, if I left that building and forgot to un-forward my calls.

  • Add counter only when duplicate segments are present in mapping

    Hi Gurus,
    I have a FILE to FILE scenario, and the source file is as this:
    aaa aaa aaa
    bbb bbb bbb
    ccc ccc ccc
    ccc ccc ccc
    ddd ddd ddd
    and the structure will be as:
    <Row>
    field1> aaa
    field2> aaa
    field3> aaa
    </Row>
    <Row>
    field1> bbb
    field2> bbb
    field3> bbb
    </Row>
    etc
    In the target structure, I need to have the same elements, but there is one more field which is a counter field that need to be increased for each repetitive line and then reset back to 1 for a non-unique one.
    So regarding the source structure, the target one should be as this:
    <Row>
    field1> aaa
    field2> aaa
    field3> aaa
    counter> 1
    </Row>
    <Row>
    field1> bbb
    field2> bbb
    field3> bbb
    counter> 1
    </Row>
    <Row>
    field1> ccc
    field2> ccc
    field3> ccc
    counter> 1
    </Row>
    <Row>
    field1> ccc
    field2> ccc
    field3> ccc
    counter> 2
    </Row>
    <Row>
    field1> ddd
    field2> ddd
    field3> ddd
    counter> 1
    </Row>
    etc
    I am asumming that I need to do this using UDF and local variables, but what I don't know is how can I compare the actual Row data with the previous one so I can increase the counter (or reset it).
    Any idea on what can I do here?

    Hi,
      You can try the below logic to get the counter incremented according to the row. For all fields its simple one to one mapping except counter.
       Row----Row
       field1---field1
       field2---field2 etc
    for counter concat field1,field2,field3 with empty delimiter ...
    concatinationof3fields--removecontext-sort-splitbyvaluechange-UDF-splitbyeachValue--counter
    **execution type of UDF is Allvalues of a context.
    public void UDF(String[] var1, ResultList result, Container container) throws StreamTransformationException{
              ArrayList aList =  new ArrayList();
         int counter = 1;
         int cnt = 1;
         for(int i=0; i<var1.length; i++){
                  if(aList.contains(var1<i>)){
              cnt++;
              result.addValue(cnt);
                                 else{
              aList.add(var1<i>);
              result.addValue(counter);
    Regards
    Priyanka

  • Slow boot time Mac Osx when USB external hard drive is connected

    I have bought some days ago an external hard drive, the Western Digital 500 GB Elements.
    It goes very well by now but I have a problem.
    When I turn on my MBP, after the "bong", I have to wait 60 second more than the normal boot time.
    The screen stay grey and after 60 second it appears the apple.
    It appens only when the external hdd is connected.
    Someone has a solution?

    Some time ago, I read that the OS has a problem waking from sleep or booting if an external was attached (USB or Firewire), something about it being confused about the startup order. Anyway, since then, I have religiously followed this procedure when I'm done using the external: unmount, unplug, and then turn it off (if necessary). I have never experienced a problem with my Mac not recognizing or not being able to boot because of an external. It certainly doesn't involve more than a second or two to unplug a USB drive.

  • GiGe camera waits till there is a TTL signal takes a picture and then waits again for another TTL signal (IMAQdx)

    Hello , I have a problem with a GIgE AVT camera.
    All I want to do is make the camera wait and each time there is a TTL signal snap a picture and save it to the disk.
    I have spent hours and hours trying to make this work but I had no luck !
    Could someone with knowledge of the IMAQdx drivers help me please !?
    I really can't find a solution to this problem!

    Hello LaThoS, 
    thanks for your reply .
    What i am trying to do is use an AVT GS660 which actually has a hardware trigger input and all i am trying to do is put it in a while loop and make it wait untill there is an external ttl signal, then take a picture , save it and then wait for another ttl signal !
    I 've seen the examples but i cannot see how they are going to be usefull to me since there is no hardaware ttl signal on the cam( https://decibel.ni.com/content/docs/DOC-15346)
    I am attaching my sample code.
    Could you please help me figure it out ?
    Thanks in advance,
    yannis.
    ps:the problems that i am facing is that on ttl the camera starts saving the same image continisously till i stop the loop !
    Attachments:
    AVT_v5_NI.vi ‏75 KB
    enum.ctl ‏4 KB

  • TTL signal count problem: mistaken counting

    Hello,
    I use a 0.2Hz TTL signal to synchronize two devices. I use a Usb 6210 card to count the TTL pulse. The counter is triggered when it detects rising edges. In my case, the counter was sometimes triggered at low level, which causes a false result (see the attached images, the TTL signal is sampled at 20Hz and the dots represent an increment of counter). How can I resolve this problem?
    In addition, the cable which connects the TTL output was welded by myself, could it be a problem of poor contact?
    Thanks a lot,
    KX
    Solved!
    Go to Solution.
    Attachments:
    pb_ttl1.jpg ‏80 KB
    pb_ttl2.jpg ‏223 KB

    What is the nature of the device producing the TTL trigger signal?  Is it possible, for example, that it could produce a 1-microsecond pulse (that might not be visible on your plot of the signal) that would trigger the counter?  Are you really producing a digital pulse (i.e. is your circuit something that is either "on" or "off", as opposed to "produces an analog voltage in the range 0 to 5 volts")?  Are there other devices around that could be producing pulses that are being "picked up" by your counter?  Is the cable connecting the TTL pulses to the counter shielded?  Is the shield grounded at only one end?
    These questions (and the previous one) suggest that the problem may be "electronics" rather than "LabVIEW" ...

  • How I can measure frequency of TTL signal without external clock?

    Hello,
    I want to measure frequency of TTL signal using PXI-6254 or PXI-6713, without using external clock.
    Frequency will be up to 100kHz. How I can use internal counter of 20MHz or 80MHz?

    Hi Yuta K,
    You have not stated what software you want to use for this measurement, but in case you're using LabVIEW, please go to the Example Finder (in LabVIEW go to "Help >> Find Examples"). 
    In the Example Finder, you make sure the "Browse" tab is stil selected, and than you go to:
    Hardware Input and Output >> DAQmx >> Counter Measurements >> Digital Frequency
    Here you will find some good examples of measuring a digital frequency with 1 or 2 onboard counters.
    If you need additional information, please let us know!
    Best regards,
    Peter S

  • Battery , time , signal strength bar is not getting displayed in home screen , these will be displayed only when i click on any app. Can u let me know the setting change ?

    Battery , time , signal strength bar is not getting displayed in home screen , these will be displayed only when i click on any app. Can u let me know the setting change ?

    Did you check the Zoom setting?
    Have you tried a reset (reboot)? Hold HOME and SLEEP until an Apple logo appears.
    If it isn't Zoom and a reboot doesn't help try Settings/General/Reset - Reset all settings

  • When I backed up files on my external drive, I inadvertently dragged my itunes library there. Now I can only play songs on my laptop when my external drive is plugged in. How do I get the library back to my computer

    When I was backing up files from my computer to my external drive, I inadvertently dragged my itunes library to the external drive. Now I can only play my library when my external drive is plugged into my computer. How do I get the library location changed back to my computer?

    Your drive was used with a PC and formatted NTFS which is proprietary Microsoft format.
    You need to install a third party program that will read the NTFS format.
    There is various software from PARAGON, Tuxera and NTFS-3G
    When you get the data off and have verified it to be good, reformat the drive either HFS+ for Mac use only, or for Mac and PC use then MSDOS (FAT32) for under 4GB files (best) or exFAT (for larger than 4GB files) is proprietary and Microsoft is appling for a patent, which would likely mean OS X won't be allowed to read it anymore without a licensing fee and you'l have to pay another third party software company to read the format, just like NTFS is.
    The less you have to rely upon third party sources to read your drives the better, this way if you have a issue and need to read the drive on another machine you don't need the software, and a internet connection and a credit card and...and...and...

  • I can turn my phone on only when connected to power. however it cant pick up signal it says connect to apple/support but I cant plug in to computer as it needs power I think the battery aerial is stuffed can I still backup phone if i put into get repaired

    can turn my phone on  only when plugged into the power. everything is still accessable on the when when this is done. but it cant pick up a signal its just serching.
    a message says i need to connect to apple/support but i can plug into the computer as its not getting any power and i cant turn on.
    I need pictures and stuff baked up on it as i dont want to loose them.
    I think the battery/aerial in stuffed as it go some water on it.
    will it be possible to save the data when getting repaired???

    Hello there stidhambr15,
    I was researching the issue you are having and recommend a couple of things. First it might be a good idea to reset the device following iPhone, iPad, iPod touch: Turning off and on (restarting) and resetting found here http://support.apple.com/kb/ht1430
    Resetting your device
    Press and hold the Sleep/Wake button and the Home button together for at least ten seconds, until the Apple logo appears.
    If that doesn't quite get the device going again, I recommend restoring the device.
    iTunes: Restoring iOS software
    http://support.apple.com/kb/ht1414
    Might even be a good idea to turn off the phone, reseat the SIM card, and turn it back on.
    iPhone and iPad: How to remove the SIM card
    http://support.apple.com/kb/ht5163
    iPhone 4 (GSM model)
    iPhone 4S
    Cheers,
    Sterling

  • I downloaded several cds to my external hard drive in .mp3 format. Later, I copied them to iTunes. The songs only play when the external hard drive is plugged in. I tried to load the songs from iTunes to my iPhone and the songs don't play.

    I downloaded several cds to my external hard drive in .mp3 format. Later, I copied them to iTunes. The songs only play when the external hard drive is plugged in. I tried to load the songs from iTunes to my iPhone and the songs don't play. I thought iTunes allowed me to transfer music to my iPhone and play it. What am I doing wrong?

    Hi skoorb1,
    When adding music to iTunes, you can set it to either make a local copy of the file, or simply point to the original location of the file (for example, on an external hard drive). If it is set to do the latter, it will not be able to play or transfer those files when the external hard drive is not plugged in. You may find the following article helpful:
    iTunes: About the Add to Library, Import, and Convert functions
    http://support.apple.com/kb/ht1347
    Regards,
    - Brenden

  • Mountain Lion bug:  Switching between virtual desktops not possible when using external screen only.

    I think I have found a bug.  I upgraded to Mountain Lion last week, 2 days after ML became available.  My laptop is a Macbook Pro from November 2011.  I ran Lion before and I did an upgrade on my laptop (not reinstall, but upgrade).
    I have an external HP screen (24 inch) connected using DVI (standard connection). I also have an external Apple keyboard (bluetooth) and the external trackpad (bluetooth). I concider myself as a power user with long experience.  I started using multiple desktops in Snow Leopard, and really liked the "4 finger swipe up" that came in Lion.  By swiping 4 fingers up on the trackpad, I can see all "virtual desktops" on the top of the screen and select or more applications to the different screens.
    This function does still work, but when I put the Macbook pro in "clamshell mode" (meaning the lid is locked and I am ONLY using the external screen), then this does not work.  When I do the gesture (4 finger swipe up), the virtual desktops on top of the screen are not shown. 
    But if I open the Mac and then having 2 active screens, both the internal LCD on the Macbook Pro and the external HP screen, it works again.  It does not matter which screen the "Finder many" is active on.
    Picture below show how it is supposed to work.  And it still works if no external screen is connected or if the external screen connected but the lid on the Mac is still open (not clamshell mode).
    This is how it looks on the external screen when I do the "4 finger swipe up" and the Macbook Pro is in clamshell mode (lid down).  Please also note how the background image is not minimized in the same way as before.
    Have any other experienced the same problem ?  Where do I report this to Apple ?  Any e-mail or WEB pages where I can report bugs ?

    As an update, I tried switching the main display to the MBP. Nothing changed.
    However, I changed the rotation to 90 degrees and everything is back to Normal! Aside from the fact that I'm looking a 24" screen in the vertical position.

  • Can we display only email address on the sender when receive external incoming mails

    Hello ALL Experts,
    Organization want to see only email addresses in the FROM field when receive External incoming emails from Any domains.
    I know for Sending emails out to the External domain we can control it in exchange with the help of Use Simple Display Name attribute.
    So want the same to the managed for external incoming emails as well, if possible with the help of Transport rule or some custom scripts
    Thanks in advance

    Hi,
    Based on my knowledge, we can use simple display name as an external display name for outgoing messages, but I'm afraid there is no way to do this for incoming mails.
    Best regards,
    Belinda Ma
    TechNet Community Support

  • Counting rising edge during 50ms for a TTL signal

    Hello, I'm using Labwindows 6 and a traditionnal DAQ. I've injected a TTL signal on my card and I would like to count the number of rising edge each 50 ms without using an internal timer in labwindows so that the counting pace cannot be disturbed by Windows.
    Do someone know how to process or which functions should I use?
    Thanks

    Hi it's still me with still some troubles
    I've generated with my counter0 a square wave of 50 ms pulse width from an internal source but then, I don't know how to specify that this signal will also be the  pin gate (ND_PFI_4) of my counter1 which will count the rising edge.
    Moreover I also don't know how to specify my counter1 just to count rising edge while  my gate is at high state; here 's mys code :
        //Generation of an internal 100 KHZ square wave
        GPCTR_Control(1, ND_COUNTER_0, ND_RESET);
        GPCTR_Set_Application(1, ND_COUNTER_0,ND_PULSE_TRAIN_GNR);
        GPCTR_Change_Parameter(1, ND_COUNTER_0, ND_SOURCE,ND_INTERNAL_100_KHZ);
        //Generation of a 100 ms gate
        //50 ms => low state
        //50 ms => high state
        GPCTR_Change_Parameter(1, ND_COUNTER_0, ND_COUNT_1,5000);
        GPCTR_Change_Parameter(1, ND_COUNTER_0, ND_COUNT_2,5000);
         //output the counter pulse, you must call Select_Signal.
        Select_Signal(1, ND_GPCTR0_OUTPUT, ND_GPCTR0_OUTPUT,ND_LOW_TO_HIGH);
        GPCTR_Control(1, ND_COUNTER_0, ND_PROGRAM);  
        //configuration CPTR1 that will count each rising edge while the gate is at high state
        GPCTR_Control (1, ND_COUNTER_1, ND_RESET);
        GPCTR_Set_Application(1, ND_COUNTER_1,ND_SIMPLE_EVENT_CNT);
        GPCTR_Change_Parameter(1, ND_COUNTER_1, ND_SOURCE, ND_PFI_3);
        GPCTR_Change_Parameter (1, ND_COUNTER_1, ND_SOURCE_POLARITY,ND_LOW_TO_HIGH);
        GPCTR_Change_Parameter (1, ND_COUNTER_1, ND_INITIAL_COUNT, 0);
        GPCTR_Control(1,ND_COUNTER_1, ND_PROGRAM);
        GPCTR_Watch (1, ND_COUNTER_1, ND_ARMED, &compteur);
        printf("%d\n",compteur);
    And the value of compteur is not the value expected at all.
    thanks.
    (ps : can you speak french?)

  • Lenovo spkrs work only when external spkrs plugged in

    Arch runs great on noobies Lenovo 3000 n100.
    Streaming audio and system sounds work fine only when external spkrs are plugged into headphone socket.
    Onboard  spkrs can be heard along with external spkrs together. I have tried every combination of Gnome-volume-control sliders and mutes to hear onboard spkrs by themselves but no luck. It's not a big deal as the laptop is always on my desk but I'm just curious if it can be fixed as I am not experienced enough yet.
    Thanks
    Regards

    See this recent thread. It may be instructive.
    http://discussions.apple.com/thread.jspa?messageID=10899641&#10899641

Maybe you are looking for

  • Exception handling for a standard SAP Function Module - the OO way

    Hello, I was wondering what is the correct way to call a standard SAP function module inside a method of global class. I want to display the error via the: get_text( ) and get_longtext( ) methods. I don't want to use the sy-subrc check. Is this possi

  • My cd drive wont load a game

    I just bought football manager 2012 but for some reason when I put the disk in nothing happens for about 2 minuets then it say's "I have inserted a black CD". I thought it might be the CD drive but I put an audio CD in and that worked fine, I checked

  • How do I change the date format in Forms Central from mm/dd/yyy to dd/mm/yyy?

    I'm using Forms Central on a Mac and need to convert the US date format to the one used in Australia ie from mm/dd/yyyy to dd/mm/yyyy. I've tried Field properties and can't see any other options. Is there a quick fix somewhere?

  • Finding the lock wait timeout in Oracle 11g

    Want to know how to find the lock wait timeout set on Oracle 11g

  • Primitive type Changing???

    One of my friends sent me this e-mail. Can anyone help?? ok wood, here's one for you: the software i'm writing get's data from one of two processors on a satelite. these processors use different #'s of bytes for their primitive types. bool - 1 byte s