Controlling two relays

Hello,
I have a problem in controlling the relays i developed to two loops for relays one to control solenoid and other to control fans. solenoid loop should be working when fans stops. I am unable to control the loops or may be my developed logic is incorrect. Please any body help me with this. I am using pxi2586 hardware.
thanks
shaik
Solved!
Go to Solution.
Attachments:
solenoid and fans.vi ‏56 KB

Two loops are independent of each other and hence you cannot control.
I haven't worked with Ni-Switch but you are initializing at 2 different places and you are using same credentials even though you use different control K0&K1 is it not giving you error ?
One simple thing you can do is Use FAN CONTROL local variable in SOLENOID LOOP. When FAN CONTROL becomes true start the solenoid functionality.
Controlling can be done in many ways, try the above method as initial try.
See the attached Modified VI.
Kudos are appreciated.
Attachments:
solenoid and fans2.vi ‏41 KB

Similar Messages

  • I want to control two relay, but Labview says I have something wrong with my VI

    From the picture, I have 2 relays to control, they are both toggle on/off type, I want to control them at the same time, but fail to do it.
    I already set digital>multiple channels>single sample> 1D boolean(1 line per channel) and before I run, i pick channel 0 and 1 in the front pannel
    When I run, the program doesnt give error, however, I use voltmeter to test the voltage at port 0 and port 1, they are 5V and steady....which doesnt correspond to the VI i write
    After I hit stop, Labivew says,
    pecified read or write operation failed, because the number of lines in the data for a channel does not match the number of lines in the channel.
    If you are using the Digital Waveform datatype, make sure the number of lines in the digital waveform matches the number of lines in the channel. If you are using boolean data, make sure the array dimension for lines in the data matches the number of lines in the channel.
    Number of Lines in Channel: 8
    Number of Lines in Data: 1
    Task Name: _unnamedTask<4>
    What's wrong with my VI? thank you
    Solved!
    Go to Solution.
    Attachments:
    Capture.JPG ‏56 KB
    BEI Delay.vi ‏30 KB
    relay board testing 2_17_2013.vi ‏22 KB

    thank you here are the VI
    I already picked channel 0 and 1, when i hit run, no error, but volmeter show steady 5V at channel 0...
    WHen I hit stop, labview give me similar errors:
    Possible reason(s):
    Write cannot be performed, because the number of channels in the data does not match the number of channels in the task.
    When writing, supply data for all channels in the task. Alternatively, modify the task to contain the same number of channels as the data written.
    Number of Channels in Task: 1
    Number of Channels in Data&colon; 2
    Task Name: _unnamedTask<E>
    I am using USB 6008
    Attachments:
    relay board testing 2_17_2013.vi ‏22 KB
    BEI Delay.vi ‏30 KB

  • Use one fpga vi to control two targets

    Hi,
    I have two fpga because I need more than 8 analogue output and analogue input.  I wonder if I can use one fpga vi to control two targets (the two FPGA boards I use are PCI-7833R) so that the outputs can be synchronized.  I think if it's possible it'll be easier to implement the synchronization between while loops,etc.  If it's not possible, how can I interface between between fpga.vi and make the synchronization possible and make two vi's talk to each other?  Thank you very much for your help!
    Thanks,
    Charles

    I have successfully ran the same code on two (2) different FPGA boards. The difference being that the host will use different Aliases to control the FPGA boards,
    Both FPGA Boards MUST be the same type ( I used PXI-7811s). 
    My program consisted of 6 individual communication portals and there was NO synchronization between boards
    Visualize the Solution
    CLA
    LabVIEW, LabVIEW FPGA

  • I need help with controlling two .swf's from third.

    Hi, thanks for reading!
    I need help with controlling two .swf's from third.
    I have a problem where I need to use a corporate designed
    .swf in a digital signage solution, but have been told by the legal
    department that it can not be modified in any way, I also can't
    have the source file yada yada. I pulled the .swfs from their
    website and I decompiled them to see what I was up against.
    The main swf that I need to control is HCIC.swf and the
    problem is it starts w/ a preloader, which after loading stops on a
    frame that requires user input (button press) on a play button,
    before the movie will proceed and play through.
    What I have done so far is to create a container swf,
    HCIC_container.swf that will act as Target for the HCIC.swf, and
    allow me to send actionscript to the file I'm not allowed to
    modify.
    I managed to get that done with the help of someone on
    another forum. It was my hope that the following script would just
    start HCIC.swf at a frame past the preloader and play button, and
    just play through.
    var container:MovieClip = createEmptyMovieClip("container",
    getNextHighestDepth());
    var mcLoader:MovieClipLoader = new MovieClipLoader();
    mcLoader.addListener(this);
    mcLoader.loadClip("MCIC.swf", container);
    function onLoadInit(mc:MovieClip) {
    mc.gotoAndPlay(14);
    But unfortunately it didn't solve my problem. Because there
    is a media-controller.swf, that is being loaded by HCIC.swf that
    has the controls including the play button to start HCIC.swf.
    Here's a link to a .zip file with all 3 .swf files, and all 3
    .fla files.
    http://www.axiscc.com/temp/HCIC.zip
    What I need to do is automatically start the HCIC.swf file
    bypassing the pre-loader and play button without editing it or the
    media-controller.swf in anyway. So all the scripting needs to be
    done in HCIC_container.swf.
    I know this is confusing, and its difficult to explain, but
    if you look at the files it should make sense.
    ActionScripting is far from my strong point, so I'm
    definitely over my head here.
    Thanks for your help.

    Got my solution on another forum.
    http://www.actionscript.org/forums/showthread.php3?t=146827

  • Control two functions on one button click

    Hello,
    first off, I am relatively new to actionscript 3.0. I was
    wondering if anyone knows how I can control two events on one (the
    same) button click. On click, the first function must jump the user
    to a particular frame label and at the same time trigger a second
    function which is a movie clip on that particular frame. I must
    note that the event listener is attached to an actual Button and
    not a movie clip.
    Any help would be greatly appreciated.

    Thanks for the quick response. I tried out your solution but
    I get the following error...
    TypeError: Error #1009: Cannot access a property or method of
    a null object reference.
    at index_fla::MainTimeline/rev()
    at index_fla::MainTimeline/resources()
    I also tried to create another event listener on Mouse_UP
    ex:
    topNav1_btn.addEventListener(MouseEvent.CLICK, resources);
    topNav1_btn.addEventListener(MouseEvent.MOUSE_UP, rev);
    but I get another strange error...
    ## [Tweener] Error: [object MovieClip] raised an error while
    executing the 'onComplete'handler.
    TypeError: Error #1009: Cannot access a property or method of
    a null object reference.
    at MethodInfo-218()
    at Function/
    http://adobe.com/AS3/2006/builtin::apply()
    at caurina.transitions::Tweener$/updateTweenByIndex()
    at caurina.transitions::Tweener$/updateTweens()
    at caurina.transitions::Tweener$/onEnterFrame()
    ## [Tweener] Error: [object MovieClip] raised an error while
    executing the 'onComplete'handler.
    TypeError: Error #1009: Cannot access a property or method of
    a null object reference.
    at MethodInfo-241()
    at Function/
    http://adobe.com/AS3/2006/builtin::apply()
    at caurina.transitions::Tweener$/updateTweenByIndex()
    at caurina.transitions::Tweener$/updateTweens()
    at caurina.transitions::Tweener$/onEnterFrame()
    any other thoughts? Thanks in advance.

  • Controlling multiple relays on PXI 2569 simultaneously using LabVIEW

    Hi,
    Can anyone please tell me how do I control multiple relays in the PXI 2569 general-purpose raley module? I can't find the example for it. At the moment, the example I have is for controlling individual relay which is only for open/close one relay name at a time.
    However, I need to use all the 100 relays and they got to be controlled at the same time.
    Kind Regards,
    Kieren

    The attached snippet doesn't seem to do the trick.
    Attachments:
    Test 2569 relay control with DAQmx using Digital Out.png ‏36 KB
    Test 2569 relay control with DAQmx using Digital Out.vi ‏19 KB

  • Can the Sound Object control two sounds at once?

    I have a sound object that I want to control two seperate
    sounds in different movie clips..one is intro music which lives on
    the main shell of the website along with the sound object. This
    fades out into a loop that lives on another movie clip that loads
    into the shell on a loadMovie action naturally.
    My goal:
    To control both sound clips with ONE sound object living in
    the main flash site's shell. Can this be done or would I have to
    have two seperate sound objects for each sound clip?
    Thank you,
    Dayton

    You could write a fairly simple class that would act as a
    wrapper for the sound class. In this class you would let it define
    the 2 sound objects but then you would only need to use call to the
    class object to control both. This could also be expanded to
    control more than 2 sounds. It is not exactly what you were hoping
    for but in the long term it would simplify sound control and be
    reusable in pretty much any setting that required sound.
    Tim

  • Use Labview to control two Picomotor actuators successively through Model 8753 iPico driver

    Hello All,
    I want to use Labview to control two Picomotor actuators(belong to channel A ,C) successively through Model 8753 iPico driver.Since the example VI's
    (Application.vi) from Newport's website just control one actuator at one time, so I copied the example code, thus there are two repetitive sections (see the attachment) in
    the while loop structure. The test result was that two Picomotor actuators moved to respective target position circularly. And I found the test was correct when two Picomotor actuators belonged to different address. Can anyone tell why ,what should I do? Any assistance with this matter is greatly appreciated.
    Best Regards,
    Attachments:
    control two picomotor actuators.vi ‏90 KB

    BRox,
    I had a look at the examples and obviously all it does is to communicate to the drive through RS232 with a proprietary protocol. With the documentation in the block diagram and the documentation of the protocol it shouldn't be too hard to understand what's going on, but on the other side NewFocus has obviously missed a chance to provide a high level and easy to use API for their product...
    I can't dive too deeply into the features of this drive, but before you spend too much time on understanding their command language, you should check with NewFocus, if it is possible at all to meet your requirements with their hardware. The main reason why I doubt that is the slow communication speed provided by RS232. The only way to reach a sinusoidal motion profile of 30 to 70 Hz with this type of communication is running the complete trajectory generation and interpolation onboard. If you have planned to generate the motion profile in LabVIEW and send setpoint commands to the drive this will probably not work.
    If the drive provides another command input (e. g. an analog +/- 10 V input for torque or velocity command signals), we can talk about alternative approaches.
    Regards,
    Jochen Klier
    National Instruments

  • Control two functions using a button

    Hi,
    is it possible to control two functions like clearing voltage graph and current graph, by just clicking one button on the front panel?
    how can this be done?

    Put the code for both functions inside the same case of a case structure.

  • PXI-6250 and BNC-2110 to control 5V relay ?!

    I try to use PXI-6250 through BNC-2110 to control 5V relay. Please give advice if it is possible and how.
    Thanks
    Liming
    Solved!
    Go to Solution.

    Hello Liming,
    This is definitely possible, but there are some limitations.  Are there any current requirements for the 5V relay.  If it is low current you should have no problem controlling the relay with one of your PFI lines (they are found in the screw terminal of the BNC-2110).
    Message Edited by Dan_K on 11-21-2008 10:32 AM
    Regards,
    Dan King
    Attachments:
    2008-11-21_103042.jpg ‏68 KB

  • One hardware fader to control two faders in Mainstage via select button

    Hi,
    I try to use one hardware fader von a VMK161 plus controller keyboard to control two faders in Mainstage independently. I want to use a "Select button" where I can route the hardware MIDI fader signal to either 1st or 2nd fader in Mainstage.
    Any idea how to do this?
    Thanks,
    Keys Richards

    Hi
    Unless there is a quick way of re-configuring your hardware fader to send 2 different MIDI messages, I think you are out of luck. I am pretty sure that there is no way to "switch" which Screen Control is active within MS.
    CCT

  • WAD Help:  Need for one dropdown to control two characteristic InfoObjects

    All,
    I have a dashboard built in WAD that contains several charts.  There are several data providers and I have created a few simple dropdowns to apply filters.  Here lies my problem: 
    For one specific characteristic, "business unit", in one data provider the InfoObject is "0material_zgbu"(nav attribute of 0material).  In another data provider, the InfoObject is "0prft_ctr_zgbu" (nav attribute of 0prft_ctr).
    What is the best way to make the dropdown selection apply a filter to both characteristics?  Can I force a dropdown to control two characteristics?
    Should I create a hidden dropdown to control the 2nd and somehow pass the selected value to it using code?
    Any help or advice will be greatly appreciated.
    Thanks
    Rodney
    (fyi.... I am using version 2004s)

    If you feel both Drop Down Boxes will have Same values... then you can display only one Drop Down Box. Once you select any Value, you can trigger a command which will display values for both Data Providers.
    Let me know if you need any further explanation.
    Note: this will work only if both Drop Down Boxes has same Charecterstics Values.
    Nagesh Ganisetti.
    Assign points if it helps.

  • Airport Express systems with two relay stations

    I need to use four Airport Expresses to cover my house from bottom to top. The system design is such that the main base station connected to the broadband router is in the basement, then there are two relay stations to connect to the final remote base station located at the top floor.
    The Apple manual describe the use of one one relay station between the main base station and a remote base station, the case of two relay stations is not covered. The question therefore is what settings the relay stations should have in such a configuration.
      Windows XP  
      Windows XP  
      Windows XP  

    Welcome to the discussions.
    Here is what Apple says.
    The base station that connects to your Internet service provider is the main base station. A remote base station connects wirelessly to the main station and extends (or "rebroadcasts") the wireless network to clients that are not in range of the main. A relay base station is like a remote, but it has the additional function of extending the wireless network to a remote which isn't within range of the main. There can be only one relay between a remote and a main.
    Don

  • Using NI VISA to control serial relay card

    Hi
    I am using a relay card to control the operation of a pneumatic machine. The relay card has an FDTI chip and uses an integrated USB to serial convertor. It came from eBay (see link). The card works fine but I am struggling with the VISA code in my vi (see attached library).
    The card switches a relay when a command from 1 to 8 is sent to it. I.e. if you write 1 to the serial port, the card will switch on relay 1. If you then write 1 again, the relay will switch off.
    so my vi generates a character pulse from 1 to 8 to control the relays. The first element of the resulting array is checked. If it is non zero, the character is written to the serial port.
    Ideally, the case structure then switches to "read mode" where is checks which relays are on using the VISA read vi. The relay states are written to the shift register and then the case structure switches to the default case of 0 where it clears the buffers.
    The e-stop button reads which relays are on and switches all of them off when enabled.
    The problem is that the read function does not work.Everytime a relay is enabled, an error is thrown up when the read mode is enabled. (I do not know the error code but can find out this next week when I am back at work). I know that the read function does work as I can read the card in another vi.
    Can anyone suggest a better way of coding the VISA read and write functions to avoid getting an error everytime the program tries to read from the card? I am new to VISA (I normally just use daqmx devices),
    I suspect that the vi is not allowing enough time for the read function to grab all the bytes from the card and is therefore giving an error. I had to slow the loop down with the time delay to avoid getting errors from the VISA write vi.
    Is there a way to run the VISA rear vi until it reads all bytes from the card?
    Any help would be greaty appreciated.
    Thanks. John
    Attachments:
    relay_question.llb ‏71 KB
    screenshot.jpg ‏117 KB

    the warning is typical.  I often supress (clear) this warning when reading "number of bytes" instead of until "termination character" and I'll supress the expected warning "Termination char recieved - more data may be available" if  I've enabled termination characters.   All it means is that you asked for 8 bytes and got 8 bytes but you don't know how many bytes were there (it was at least 8.)
    The Timeout error means that less than 8 bytes were available in the 1second you waited.  There could be several reasons for this and each affects your code differently.
    The equipment hasn't sent data lately:  in this case you just need to read less often or peek into the buffer (property> bytes at port) to avoid buffer underflow/overflow.  Or set the device to produce data more often.  With your current code your outer while loop timing is dependant whether or not the VISA call timedout or read 8 bytes.  You may need to change to a different arcetechure if it is important to have tight control of the DAQmx task timings.
    The latency of the FTDI driver is delaying sending the bytes.  Unlikely that the 16 mSec is causing a 1 sec TMO error but if it is DECREASE the latencey timer to solve this.  Increasing it would only make it worse.  2mSec would be better than 16.
    Without knowing how the equipment is supposed to work its pretty hard to say one way or the other that the TMO error is "bad" ar the normal consequence of an expected (or predictable) scarcity of data availablity
    Jeff

  • How can I use two midi keyboards to control two different patches?

    I would like to use two midi keyboards in my setup, each controlling a different patch or track.

    Hi,
    Follow the steps in this guide:
    http://www.logicprohelp.com/forum/viewtopic.php?f=5&t=32201
    J.

Maybe you are looking for

  • Any way to use a quick and dirty icon like cLabel in the quick tools toolbar?

    I am a javascript cut-and-paster with ability to cobble things together. In previous versions of Acrobat, I had tools that were added to the toolbar using the technique shown in this script: app.addToolButton({cName: "MyFlattenButton",    cLabel: "Fl

  • Switched from Premiere Pro 2.0 to FCP studio 2

    and I couldn't be happier! No crashes fantastic rendering times simple work flow no glitches with Boris continuum the list goes on.... PLUS the advantage of working on a mac- which I'd never done before I have to say it was the best thing I could hav

  • Emctl start dbconsole issue

    Hello I have two 10g install on my xp. i made two databases on it. untill i made second database my oem using web browser was working fine but know its not i think its port issue. this when i try to start dbconsole service. can any body tell me on wh

  • I can't sign in to my account on itunes

    every time I try to sign in to my account, I get the error "we couldn't complete your itunes store request.The itunes store is temperoraily unavailable. please try again later.".  I tried to sign in from different PC but I couldn't sign in. I can sig

  • MySQL conversion: can't connect to mysql server

    Hi all, I've downloaded the latest migration workbench with the mysql plugin. After I've choosen the source database, I don't get a connection to the source database. The hourglass stays visible for about an hour, no message is shown. The error.log f