Trigger two FPGA instances at same time

I have some basic FPGA code that transmits data bits over a serial bus (RS485),  The code is written so that it waits in the first state of a state machine in a single cycle timed loop.  Upon a certain trigger, it starts reading a FIFO containing data and sends the data out on a Tx line.  It does this until all bits are send then it goes back to the first state to wait for the next trigger.  The trigger is needed because windows has to fill the FIFO first before the FPGA can start sending.
I need two instances of this code running because I have two com busses (one is redundant).  So I am using the FPGA code as a subvi and I wrote a main FPGA vi to call two separate instances of the subvi in parallel.  A regular windows vi writes to the FIFOs for Tx and reads FIFOs for Rx.  No problem so far.
The trick is that I have to start both transmissions within 200nS of each other (yes, nanoseconds).  Windows will write to both FIFOs in parallel, but the timing is 4uS apart, too long.  I tried setting up a boolean flag in the FPGA subvi, but windows can't write to the subvi control directly.  FPGA won't allow it (the Write function is greyed out).  I tried using a FIFO for a flag, but the problem is a race condition.  One of the instances will read the FIFO first and wipe it out.  The other does not get to read it.  I need one common trigger point to be used by both subvi instances.
My final solution was to use a memory in the FPGA subvi and a numeric control in the main FPGA vi.  Windows write to the numeric control,  It can because the control is in the main FPGA vi.  Inside the main FPGA, I run a timed loop that looks for the numeric to be other than zero.  If so, it writes the value to the memory location used by the FPGA subvi.  After some time, the main writes a zero back to the memory to prevent the subvi from starting up again, and it writes a zero to the numeric to reset it.  The whole thing repeats, waiting for windows to write to the numeric again for the next transmission.
I had to do it this way because sometimes I want to transmit on both busses, and sometimes just one or the other.  Numeric values are used to determine which to transmit on.  Now the transmissions start at almost exactly the same time, 1 or 2 nanoseconds apart.  But the trigger process seems very far fetched to me.  I was wondering if there is a better solution.  I'm pretty new to FPGA.
- tbob
Inventor of the WORM Global
Solved!
Go to Solution.

tbob wrote:
Basically I did the same thing using FPGA Memory.  From windows I write to a numeric control which resides inside the FPGA Main vi.  In the FGPA main, I write to the Memory.  Inside the FPGA subvi, I read the memory and decode the value to either use one or the other or both busses.  After fooling with this for some time, because the Read Memeory needs to use a shift register (probably due to it taking an entier clock cycle), I got it to work.  Both busses trigger at the same time.  I guess it really doesn't matter if I use a FIFO or if I use Memory.  The main issue is that I have to write from Windows to the FPGA Main, and then from the FPGA Main to the FPGA subvi.  Then the timing is exact as far as the subvi is concerned.
There are a couple of advantages to using two FIFOs over your approach.  First, you don't need the shift register for the memory location.  Second, you don't have to worry about which VI is responsible for clearing the memory location, nor do you run the risk that one of your subVIs will execute twice, or not at all, if the memory isn't cleared at the right time.  Perhaps most importantly, you'll save yourself space on the FPGA because you won't need arbitration - the extra code that gets added when two parts of the FPGA try to access the same resource at the same time.  In your case, both instances of the subVI access the memory block concurrently, so the FPGA compiler adds extra logic to prevent conflicts.  If you only read the memory block in one place and only write it in one place (the read and write can be in different loops or subVIs) there's no need for arbitration.  By using two FIFOs you can keep them independent and avoid the conflict resolution code.  See the help for "arbitration" for more details.

Similar Messages

  • How to make this two things at the same time ?

    Hello
    When my mouse is on a area, I need :
        -  to show a object (a rectangle inserted with the toolbar)
        -  to show a caption
    I think it's not possible to do this two things at the same time when I use the rollover functions (Rollover caption or Rollover Image).
    I would like to use a button, but the button works only if I click it, and not when I just pass my mouse on it.
    Someone have an Idea?
    I can't use Javascript.
    Thanks

    Rick is correct.  You can use the Rollover Slidelet's rollover area to trigger an Advanced Action.  You'll need to create this Advanced Action with two clauses.  One to SHOW the caption, and the other to SHOW the rectangle.
    Your alternative to the rollover slidelet is to use an Event Handler widget attached to the object that the mouse should roll over.
    The Event Handler will detect when the mouse is over the object and trigger its own Success criteria.  You can then use the widget's ON Success event to trigger the Advanced Action as mentioned above.
    More information about using the Event Handler here: http://www.infosemantics.com.au/adobe-captivate-widgets/download-free-trial-widgets
    An example of using it to do two different things on the same object can be found at this web page: http://www.infosemantics.com.au/adobe-captivate-advanced-elearning-tutorials/beat-adobe-ca ptivate-interactive-catch22
    Trial versions of the widget can be downloaded from here:  http://www.infosemantics.com.au/adobe-captivate-widgets/download-free-trial-widgets

  • Talking to two devices, at the same time.

    Hi,
    I wonder you could help me with my solution.
    I'm using GPIB to talk to two devices. I need to reset and align one device A and control the device B. The process A can take up to 2 minutes. The process B is to cool off the DUT to demanded temperature and it can take up to 3 minutes to achieve the demanded temperature. To monitor these processes I use pull method and:
    for process A I use the STATPER:COND? query (is it 1?)
    for process V I use TEMP? query (get temperature, is the answer within the limits to exit?)
    Now, I do these processes one by one. But, because both the processes have to be done each time before DUT is tested (as a part of a setting up the test routine), I'd like to save some test time. Technically, both two processes are independent, I can trigger them almost at the same time and wait when the longer one finishes itself, and them move to the tests part.
    However, the first attempt of doing go was unsuccessful. When I issued the STATPER:COND? query within the connection to the device A it looks like all GPIB bus is blocked and I cannot issue the TEMP? query to the device B, as the bus seems to be waiting for the STATPER:COND? command sent to the device A to finish.
    Strange thing is that then I issue the STATPER:COND? command for first time, the device is not able to accept any other commands.
    Why?
    What is proper approach to to this test time saving?
    Solved!
    Go to Solution.

    X-Series Signal Analyzer Spectrum Analyzer Mode User's and Programmer's Reference is to be downloaded from the web.
    below are some exerpts from this manual
    you can query and interpret the details with visa write and reads and a bit of bit analysing. I have no time to search for a working example.
    How to Use the Status Registers
    A program often needs to be able to detect and manage error conditions or changes in instrument status. There are two methods you can use to programmatically access the information in status registers:
    • The polling method
    • The service request (SRQ) method
    In the polling method, the instrument has a passive role. It only tells the controller that conditions have changed when the controller asks the right question. The polling method works well if you do not need to know about changes the moment they occur. To detect a change using the polling method, the program must repeatedly read the registers.
    To monitor a condition:
    a.Determine which register contains the bit that reports the condition.
    b.Send the unique SCPI query that reads that register.
    c.Examine the bit to see if the condition has changed.
    To query the status byte register, send the command *STB? The response will be the decimal sum of the bits which are set to 1. For example, if bit number 7 and bit number 3 are set to 1, the decimal sum of the 2 bits is 128 plus 8. So the decimal value 136 is returned. The *STB command does not clear the status register. In addition to the status byte register, the status byte group also contains the service request enable register. This register lets you choose which bits in the status byte register will trigger a service request.
    Send the *SRE <integer> command where <integer> is the sum of the decimal values of the bits you want to enable plus the decimal value of bit 6. For example, assume that you want to enable bit 7 so that whenever the standard operation status register summary bit is set to 1 it will trigger a service request. Send the command
    greetings from the Netherlands

  • Two profile two thunderbird at the same time with same user account

    Dear,
    I would use two Thunderbird at the same time for two different profiles with the same user accounts.
    I using linux OS.
    I was thinking of using:
    # thunderbird -P profile1 &
    # thunderbird -P profile2 &
    But when launching the second command nothing happens.
    Only brings in the foreground thundirbird already started.
    If possible use this configuration now or in the nex future?

    As a rule thunderbird only runs one instance of a profile.
    However, there are a couple of options you could try.
    You could use an addon to esily switch profiles:
    * https://addons.mozilla.org/en-US/thunderbird/addon/profileswitcher/
    there is more help here:
    * http://kb.mozillazine.org/Run_multiple_copies_of_Thunderbird_at_the_same_time
    It does say: 'Multiple instances is intended for debugging, so use it at your own risk'.
    One method would be to use: Start > Run
    "C:\Program Files\Mozilla Thunderbird\thunderbird.exe" -no-remote -P profilename
    there is a space before '-no'
    and also before '-P'
    followed by a space and the profile name
    You could create a shortcut/icon to run each separate profile.

  • Write a progarm to test two parts at the same time

    Hi:
    I need to write a program in LabView that is capable of testing two parts at the same time.
    Explanation:
    I star the test on a unit, once all the electrical test is done move that unit to the pressure test without loosing the current test information and continue the test of the unit thewn generate a serial number only if it passes all the test. Then while the previous unit is going thru the pressure test star testing another unit for the elecrical test and so on.
    I am using LabView 2012

    From what you have described, I agree with what has been answered above. TestStand is specifically designed for. If you would like to provide more information about your application we could give you a more detailed response. For more information about TestStand follow this link
    www.ni.com/teststand
    Ryan
    Ryan
    Applications Engineer
    National Instruments

  • Is there a way to show two angles at the same time in the final edit rather than switch between them with Multicam?

    Can I show two angles at the same time in the final edit rather than alternate with Multicam?

    Stack two clips on top of each other and reduce the sizes. I think that's what you want.

  • One again, "can I use CC on two computers at the same time?" - in practice.

    I know this has been asked before and all those threads are locked. Many asked the question, but I haven't found a satisfying answer yet.
    Can I multi task with CC?
    I want to have my laptop next to my desktop. And while I render, export or whatever my newly shot documentary on the laptop I want to work with a music video project on my desktop. Then when the render is finished I render the music video and go back to the laptop and continue on the documentary. Or maybe I just work 5 minutes on the desktop music video, then come up with something brilliant for the project on the laptop and switch. Back and forth. Will that kind of activity result in any kind of limitation, usage-wise?
    So, working on Premiere on my two computers at the same time.. is it possible? Technically? I know the EULA says "only one person". But will it let one person mutli task?
    I need to know this before I buy. sorry for asking this again, please bless me with a clear answer

    Hi Jimmy Crim,
    Yes in case of Creative cloud subscription you are allowed to install and use the cc apps in any two machines.
    Even if you want you care allowed to use these apps together in both the machines.
    Thanks
    Kapil

  • Can I access two websites at the same time?

    Does Dreamweaver have the ability to open two websites at the same time?
    I basically have a CMS hosted on one server, that connects to my clients sites on other servers. I want to be able to open files on one server and edit them and also edit files on another server at the same time.
    If this isn't available in Dreamweaver, then I think it should be. I often need to copy code from one page in a site to another page in different site. To have the ability to have two windows open, each connected to a different website server would be invaluable to me. By having separate windows, each can have its own server connection. I don't know how easy that would be, but I'd love it!
    Cheers
    Glynn

    You can only connect to one site at a time.  And you need to edit files locally, save & then upload to the remote server.   AFAIK, no single FTP app is capable of connecting to more than one server at a time.  You might be able to do what you want with DW open and an additional 3rd party FTP client like Filezilla, each connecting to different servers.
    Nancy O.

  • How can I open two libraries at the same time on itunes?

    Hey i need help on opening two libraries at the same time on itunes. I don't know if that is possible but need some advice if its possible. I already have several libaries but I need to compare labaries at times due to various users on my computer. Please help .

    Not that I'm aware of. What exactly is that you want to achieve? There are tools for scanning media folders and adding any files not listed in the library, or deleting those that no longer exist. There are also ways to use one library for multiple users so that any tag update gets applied for everyone.
    tt2

  • How can I start two Vi at the same time?

     I have two Vi's, each of these Vi has a stop button. I want to start these two Vis at the same time. I also want to be able to stop the two Vis at the same time. What should I do? Thanks.

    One way to start them is with an Invoke Node and the Run method. You can then stop them with the Set Control Value [Variant] method. When you use the Set Control Value [Variant], you just have to specify the name of the front panel control that stops the while loop. Older versions of LabVIEW only had the Set Control Value method in which you had to use the flatten to string function to pass the Type Descriptor and Flattened Data.
    Message Edited by Dennis Knutson on 03-20-200609:35 AM
    Attachments:
    Run Method.JPG ‏44 KB

  • How can I compare more than two VIs at a same time in labview 2009

    How can I compare more than two VIs at the same time. I am an Lab Engineer I have to check assignments submitted by students and I want to know how many of them are copied from each other. Labview compare VI can only compare two VI at a time while I want to check about 30 VIs at same time.
    Regards,

    I'm not aware of a tool to compare multiple VIs.  If you don't find anything, consider posting this to the LabVIEW Idea Exchange to expose this idea directly to NI R&D.
    Thanks!
    - Greg J

  • Any way to play two clips at the same time one over the other? (transprent)

    Any way to play two clips at the same time one over the other? (transprent)

    Yes.
    See the information here for a variety of ways to do this:
    http://discussions.apple.com/thread.jspa?threadID=933500&tstart=50
    http://discussions.apple.com/thread.jspa?threadID=903151&tstart=0
    http://karsten.schluter.googlepages.com/jackiechancredit
    http://www.geethree.com/slick/V_04.html

  • If I have two appointments at the same time, they overlap in the iOS 7 calendar rather then appearing side-by-side so that I can't read one of them due to the identical colors of the two appointments.  Is there any way to fix this with a setting?

    If I have two appointments at the same time, they overlap in the iOS 7 calendar rather than appearing side-by-side in the daily view, so that I can' read both of them due to the same background color.  Is there a way to change this via a settings change?

    I fyou have "all day" event that are taking up the entire day, check the event. All day event only appear at the top of the time line (and just below the week view). I suspect they are not actually set up as all day, but have specific time frames assigned.
    In teh screen shot below, "Sample" is an all day event; NFL: CAR@SF is not.

  • Re: if weblogic can serve two ports at the same time?

    That's not true. WebLogic supports a non-secure and secure listener port at the
    same time. That was one of the selling points for my organization.
    Michael Girdley wrote:
    If, you mean the same port on two different IP addresses, then the answer is
    yes.
    If, you mean two different ports on the same IP address, then the answer is
    no.
    Thanks,
    Michael
    Michael Girdley
    Product Manager, WebLogic Server & Express
    BEA Systems Inc
    fxy <[email protected]> wrote in message
    news:8fdk99$t9$[email protected]..
    <URGENT QUESTION>
    I'd like to know if weblogic can support two ports at the same time.
    thank you in advance.
    <URGENT QUESTION>

    Well, the question was really meant to see if any change was made to WL to support
    this, not because I didn't believe Michael Girdley.
    P.S., this is something Websphere 4.0 let's you do...In case this encourages someone
    to add this support.
    "Mike Reiche" <[email protected]> wrote:
    >
    If you don't believe Michael Girdley, then I don't know why you would
    believe anyone
    else. I believe the answer is still 'no'.
    Why do they 'have to be on different ports'? We block requests by URI
    - so just
    block all requests to /youradminapp/* at the firewall. Or you can block
    them at
    your Web Server. Or restrict them by user in WL.
    Mike
    you"Anil Arora" <[email protected]> wrote:
    Is it still true that WL 6.0 cannot host multiple (non-secure) HTTPports
    on one
    server? We need this capability within one JVM to allow one web application
    to
    be accessed from one port while another through a second port. Forexample,
    we
    have a application to be exposed through the firewall at port 7001.
    Then we have
    another admin application to only be accessed within the firewall. But
    they need
    to be deployed within the same JVM since they may have shared statebetween
    them.
    Thanks,
    Anil
    "Michael Girdley" <[email protected]> wrote:
    I'm sorry, to clarify my statement: I was speaking about nonsecure
    communications. Weblogic can only support one listener port at a time.
    Thanks,
    Michael
    Michael Girdley
    Product Manager, WebLogic Server & Express
    BEA Systems Inc
    Allen Akers <[email protected]> wrote in message
    news:[email protected]...
    That's not true. WebLogic supports a non-secure and secure listenerport
    at the
    same time. That was one of the selling points for my organization.
    Michael Girdley wrote:
    If, you mean the same port on two different IP addresses, then
    the
    answer is
    yes.
    If, you mean two different ports on the same IP address, then theanswer
    is
    no.
    Thanks,
    Michael
    Michael Girdley
    Product Manager, WebLogic Server & Express
    BEA Systems Inc
    fxy <[email protected]> wrote in message
    news:[email protected]...
    <URGENT QUESTION>
    I'd like to know if weblogic can support two ports at the same
    time.
    thank you in advance.
    <URGENT QUESTION>

  • I am very disappointed with iTunes.  I have 1200 songs and I can't play them.  I try to play them and before one song finish a song starts playing. This then results in hearing two songs at the same time. I will like to know if you can fix this. I feel li

    I am very disappointed with iTunes.  I have 1200 songs and I can’t play them.  I try to play them and before one song finisha song starts playing. This then results in hearing two songs at the same time.I will like to know if you can fix this. I feel like listening with the iTunesplayer is useless.

    I don't know man I too hope apple will do something this new I-tunes blow my top lost my whole tune!!!

Maybe you are looking for