Master and slave problem

Hi Everyone,
When I try to use the MAster and slave template which is provided by the NI itself, try to understand it how it works, but when  I use this concept to implement in my code, just found there is the problem at there:
Problem:
1. The master loop always looping even though there do have a notification from the master to slave but the slave do not respond anything, can't figure the reason.
2. When the master loop is exit then the slave loop just start to execute but it is too late cos master loop already exit.
Those senario are different from the master and slave template. need your help.
Thanks
William Lee

Hi Williamlee,
Thanks for contacting National Instruments, 
It would be much easier if we could see your code, this will help us work out where the issue is, and to help us understand where you maybe having issues... 
Also I would like to include some more information with regards to the Master/Slave template.Developer Zone article : Application Design Patterns : Master/Slave and also a webcast on Software Design Architectures in NI LabVIEW
Kind regards,
Ashish Naik
Field Sales Engineer
National Instruments UK

Similar Messages

  • Master and Slave concept

    hi guys,
    i am confused about the master and slave realtionship in ospf. any one can explain it to me in detail.

    Hello Pankaj,
    The Master and Slave in OSPF are a slightly confusing concept but the idea behind it is quite simple.
    When two routers decide to become fully adjacent, they must synchronize their LSDBs. OSPF tries to optimize this: the routers first exchange only the list of entries in their LSDBs. Each router compares the received list to the list of items in its own database, and if it finds that an LSA is missing or is older than one the neighbor knows about, it requests it from the neighbor afterwards. This way, both routers transmit only the missing or updated LSAs, not the entire LSDBs.
    The list of LSDB entries is carried in Database Description (DBD) packets. Naturally, when routers exchange DBD packets, they must be sure all of them have been properly received by the neighbor, so some sort of acknowledgements must be used. There is a problem here, however: the only packets in OSPF used to carry acknowledgements are LSAck packets, but they can only be used to acknowledge LSU packets (more precisely, individual LSAs carried in LSU packets), not DBD packets. How shall the acknowledgements of DBD packets be accomplished, then?
    OSPF uses a polling style of communication with the DBD packets. DBD packets themselves have sequence numbers used for sequencing and acknowledgement purposes. One of the two routers that are in the synchronization phase will be the one responsible for polling the other (i.e. calling it out it to send another piece of information if it has any), each time with an incremented sequence number. This is the Master role. The other router will only be allowed to respond to a DBD poll, never send any DBD packet without being polled immediately before, and the response DBD packet must carry the sequence number of the Master's DBD poll packet. This is the Slave role. The Slave must respond to each Master's DBD packet even if it has no more LSDB entries to advertise; in that case, the DBD response body will be empty.
    So during the DBD exchange, the Master sends DBD packets to Slave, incrementing the sequence number by one in each round. The Slave waits for DBD packets from the Master and only responds to them, and each response carries the sequence number from the last received Master's DBD packet that was used to poll the Slave. Remember: a Slave must not send DBD packets on its own, only as responses to DBD packets received from the Master, and the sequence number of the Slave's response DBD packet must be set to the Master's poll DBD packet.
    While I call the DBD packets as "polls" and "responses" here for the sake of clarity, the DBD packets do not have this distinction indicated explicitly. Any DBD packet sent from the Master, either with a body carrying a list of LSAs or an empty body, is a poll. Any DBD packet sent from the Slave, again either with a non-empty or empty body, is a response. A DBD packet can have an empty body if the router needs to send a DBD packet to the neighbor (either from Master to repeatedly poll the Slave, or from the Slave to confirm the arrival of the DBD packet from the Master) but has no more LSDB entries to advertise itself.
    There are two issues with this simple procedure. First, there is the issue of who out of two synchronizing routers will be the Master and who will be the Slave. This is resolved during the ExStart phase: both routers initially treat themselves as Master routers, and send DBD packets with random initial sequence numbers to each other, indicating the MS flag (Master) in their header. As they do this, the router with the lower RouterID moves to the Slave role, while the router with the higher RouterID remains in the Master role. The ExStart phase is basically finished after establishing the router's role in the synchronizing pair; at most two DBD packets are needed for that, one from each router. The Exchange phase then lasts until routers have exchanged the entire list of their LSDB entries using DBD packets.
    The second issue is more subtle: how should the Master know whether the Slave needs to be polled further? Clearly, a situation may arise when the Master's LSDB is empty or smaller than the Slave's, and the Master will need to send fewer DBDs than the Slave to list all its LSDB contents. As the Slave can not send a DBD packet on its own, it somehow needs to tell the Master to poll it again. This is accomplished by another flag in DBD packet header, the M (More) flag. If a Slave replies to the Master's DBD packet with its own DBD packet and the M flag set, the Master knows the Slave needs to be polled again. The Master will stop polling the Slave after the last DBD packet fom the Slave has the M flag cleared.
    The RFC 2328 has a nice ASCIIart graph of the adjacency coming up:
                +---+                                         +---+
                |RT1|                                         |RT2|
                +---+                                         +---+
                Down                                          Down
                                Hello(DR=0,seen=0)
                           ------------------------------>
                             Hello (DR=RT2,seen=RT1,...)      Init
                           <------------------------------
                ExStart        D-D (Seq=x,I,M,Master)
                           ------------------------------>
                               D-D (Seq=y,I,M,Master)         ExStart
                           <------------------------------
                Exchange       D-D (Seq=y,M,Slave)
                           ------------------------------>
                               D-D (Seq=y+1,M,Master)         Exchange
                           <------------------------------
                               D-D (Seq=y+1,M,Slave)
                           ------------------------------>
                               D-D (Seq=y+n, Master)
                           <------------------------------
                               D-D (Seq=y+n, Slave)
                 Loading   ------------------------------>
                                     LS Request                Full
                           ------------------------------>
                                     LS Update
                           <------------------------------
                                     LS Request
                           ------------------------------>
                                     LS Update
                           <------------------------------
                 Full
    The I flag here is another flag in DBD headers called the Init flag, and is set only on initial DBD packets in the ExStart phase. If the router has established its Master or Slave role, it clears the I flag. This one is not really that important right now.
    The Master/Slave relationship is built and relevant only during the initial LSDB synchronization when a new adjacency is being established. After the two routers go past the Exchange state, DBD packets are not used anymore, and the whole Master/Slave relationship is forgotten. Remember: Master/Slave is relevant only to DBD packets, and DBD packets are used only in ExStart/Exchange phases. Outside of these states, there are no DBD packets used, hence no Master/Slave relationships exist.
    If there are, say, four routers, R1 till R4, connected to the same switch and run OSPF, during the OSPF bootup, there will be 5 temporary Master/Slave relationship built and torn down afterwards:
    between the DR and BDR as they synchronize (assume those routers are R1 and R2)
    between R3 and DR
    between R3 and BDR
    between R4 and DR
    between R4 and BDR
    Notice the Master/Slave relationship existed between those routers that went through ExStart and Exchange into the Full state. Also keep in mind that in the Full state, there are no more Master/Slave relationship present - they were only needed because of the specific needs of the DBD packet exchange.
    Does this make the issue a little more clear? Please feel welcome to ask further!
    Best regards,
    Peter

  • Master and Slave Loops

    I'm having problems with my Master and slave loop combination.  I would like to be able to start and stop acquiring data from individual thermocouples. Please help.
    Message Edited by nicholas03 on 04-13-2008 03:22 PM
    Attachments:
    eight thermo.JPG ‏106 KB

    Dear Nicholas,
    My first advise would be to check the examples on master-slave patterns, and run them step by step, looking at what the data does...
    In a master-slave system, you use the queue to pass data from the master to the slave.   You're not passing data in the queue... in stead, you're passing data using local variables, which you should NOT do...  
    In the top loops, you should attach the temp array to the enqueue element.   In the bottom loop, you should remove the temp local, and instead get your data from the dequeue vi.
    Also, you have to create a queue with the proper variable.   You can create a queue from any variable type, but it has to know beforehand, and the init vi.  
    Assuming you want to queue the temp array, you're basic structure should look like this:
    It does help if you add your own code, so we can easier edit it for you...  Otherwise we need to use photoshop on your design...
    Message Edited by Anthony de Vries on 04-14-2008 11:30 AM
    Attachments:
    master-slave1.JPG ‏24 KB

  • Master and Slave configurations

    Hi
    I am currently wondering why my master and slave configurations dan't work. I have the Rev. B mother board and I set the jumpers to the right spots. I am trying to get my CD Burner to work with my regular CD Rom on the same wire.

    Jarrett,
    my experience with my 3 Beige G#'s (1 desktop and two towers), tells me that a master/slave configuration with two optical drives is not really possible/compatible.
    As a matter of fact, I had to opt for the following solution:
    - Sony 52X burner installed in the CD bay;
    - Iomega 52X USB burner on the USB PCI card.
    I also had a huge number of problems with the master/slave configuration of drives, and it only worked with certain brands of drives.
    For instance, two WD drives would not get along in the same case (data corruption like there's no tomorrow.....)
    I ended up having a WD and a Seagate, which still get a long nowadays in my B&W G3.
    To give you some more curious feedback on the bad habits of the Beige machines........my old G3 now sits in my son's room.
    Believe it or not, I had to remove the Sony burner, as the computer would not boot from it, at all.
    It would read and play CD's but it would not boot, in the most standard of the configurations:
    - CD Burner Master and 1 IDE drive as a slave;
    - SCSI card with SCSI drive;
    I replaced the burner with the APPLE CD-drive form my B&W, and the system started working and booting like magic (I swear....I did not change anything else).
    It boils down to trying and experimenting. I spent countless hours with those machines trying to figure out why the same configuration working on my Beige minitower would not work on my daughter's Beige minitower, exactly identical machines, both with rev. B boards.
    Hope this can help.
    cheers

  • Multiple errors with DSC modules modbus master and slave

    Hi,
    I've searched quite a lot of posts but haven't found solution for my problem. I'm playing with LabVIEW DSC module and it's modbus master and slave functionalities. Even the LabVIEWs own modbus examples (Modbus Simulator and Fundamentals) seem to work randomly or not at all: When checking the Variable Manager utility Modbus Simulator (i.e. modbus slave/server) seems to deploy variables correctly with good quality but Modbus Fundamentals (i.e. modbus master/client) most often shows unknown value or bad quality for all the variables. When running the VIs I get 'Error -1950679035 Unable to locate variable in the Shared Variable Engine' and sometimes some other errors too. If the Modbus Simulator (slave/server) is expected to work fine I guess I should get two slaves communicating, but this isn't happening either. So maybe Modbus Simulator example isn't working either.
    I've tried undeploying and deploying the libraries, stopping and starting the SVE, booting PC, reinstalling DSC module, and setting firewall and antivirus software off. This problem is going on with two different computers, both of which have recently installed LabVIEW 2011, first PC with Win XP and second PC with Win 7. No other OPC servers should be installed to these computers. And what is really interesting, the problem seems to have nothing to do with my network since Simulator and Fundamentals examples are not working even if the network cable is unplugged!
    Any suggestions? Replies are highly appreciated!

    V8 has the same feature, but the words are different.
    The Generator typically uses the Driver time base, and the Gl. Var Write is writing once per block.
    So, to see all values, you must have a block size of one.
    I set up the Driver timebase to 10 Hz, block size of 1. The Generator and the Read Variable default to the Driver timebase.
    The Generator is making a 2 Hz Rectangle waveform. YOu can see that it's shifted, but otherwise intact.
    - cj
    Measurement Computing (MCC) has free technical support. Visit www.mccdaq.com and click on the "Support" tab for all support options, including DASYLab.

  • DNS addresses (master and slave) + personalizing the url address

    Hello.
    My name is Fernando and I published my site using MobileMe (www.fernandoingles.com).
    It’s working already really well.
    But since I’m from Brazil, I built one in Portuguese as well.
    And since the common site endings here are .br I’m trying to purchase the www.fernandoingles.com.br as well but in order to be able to actually buy the site I have to give them two DNS addresses of the place I’m publishing the website with.
    (one ‘Master’ and one ‘Slave’).
    How can I get those addresses?
    And another thing is that I also have my bands site’s published under my main domain name (fernandoingles.com) with my main MobileMe account (but I have the family pack now).
    [www.pipeusa.net and www.pipebrasil.com]
    I purchased those Urls using GoDaddy and they are all properly forwarded already, which means that when the person types those addresses above it already goes to the correct site.
    But what shows on the actual url above is (http://www.fernandoingles.com/fernandoingles.com/Pipe.html).
    And what I would like to appear is only the addresses (www.pipeusa.net and www.pipebrasil.com) instead of my name before them.
    I bought the family pack so that I would have more space and etc... and already put those addresses ((www.pipeusa.net and www.pipebrasil.com and fernandoingles.com.br) as their main domain.
    But since I’m publishing them all using my own iWeb how could I make those extra sites work as their own main sites?
    Would it work if I log in with the desired MobileMe sub-account (let’s say www.pipeusa.net) and then go to iWeb, move that site to the top and them publish it?

    Thank you so much for the response!
    Great option on the added accounts!!
    Since I manage all those sites myself could I manage them all within the same 'log in' or each and every time I need to make a change on one of those sites I must 'log out' of whatever account I'm in and then 'log in' into the account that the change needs to be made?
    And whenever I 'log in' into those accounts (the ones that have the respective domains) should I replace on iWeb before I publish the top site with the one I want to as the main domain or can I just not do anything at all?
    And about the DNS address issue,
    Since I’m from Brazil, I always build two sites, one in Portuguese and one in English.
    And since the common site endings here in Brazil are '.br' I’m trying to purchase the '.br' option of all the addresses I have as well but in order to be able to actually buy the site I have to give them two DNS addresses of the place I’m publishing the website with.
    (one ‘Master’ and one ‘Slave’).
    How can I get those addresses?"
    Thank you so much for the help!!!!

  • Assign my 2 servers as master and slave driver

    I am trying to set up my 2 servers which already have had data and information: one as Master and the other as Slave how to use the unix commands to do this.
    Thank you very much,
    Paul

    Hi Williamlee,
    Thanks for contacting National Instruments, 
    It would be much easier if we could see your code, this will help us work out where the issue is, and to help us understand where you maybe having issues... 
    Also I would like to include some more information with regards to the Master/Slave template.Developer Zone article : Application Design Patterns : Master/Slave and also a webcast on Software Design Architectures in NI LabVIEW
    Kind regards,
    Ashish Naik
    Field Sales Engineer
    National Instruments UK

  • Synchronization - Master and Slave tasks.

    For syncrhonisation (via hardware) of two modlues; one 4330 and 6361, shall I create one master task for the 4330 and then syncrhinise it with the 6361 module? Or create multiple channels say 5 from 4330 and 5 from 6361 and then specify one channel from 4330 to be the master and all the rest modules from 4330 and 6361 to be slave tasks?
    Thanks, 

    Hi Pepis21,
    My name is George and I am an Applications Engineer at National Instruments. I see Luke has already done a good job of helping you but I found a couple of examples that you might find helpful.
    Here is a tutorial that shows a few more examples of how to synchronise channels and devices using a couple of different methods;
    http://www.ni.com/tutorial/11549/en/
    You may be able to see some other synchronisation examples in the NI example finder within LabVIEW under “DAQmx” under “Hardware Input and Output”. I will also link an image of another example below that shows how to use error wires to force dataflow without using flat sequence structures as Luke suggested.
    I hope these are useful for you.
    Regards,
    George

  • Master and Subprojects problems with Apps

    Hi all,
    What is going on with Master and Subprojects in an Online tenant with apps??
    I will show some pictures about, cause Apps (no-one) is getting information about Master and Subprojects:
    - This picture shows the Project Center, and the project "Master Project Test 1" is a Master Project and the "Project Test 5" is its Subproject:
    After I´ve installed an App with the scope of Project, to get the information of a single project, but I cannot select these two projects already named early:
    Is there the expected behavior? Or Is it a bug?
    Thanks!

    Finally got a chance to test this out Miguel but haven't found any workaround.  I can see behind the scenes we are looking just for PROJ_TYPE=0 when populating the list, and not type 5 (subprojects) or 6 (masters).  I'm trying to find more info
    internally on if this is a design choice or oversight.  I can understand that master projects could give issues as this is specifically a single project permission check - but I can't think of any logic to exclude sub projects.  The only workaround
    I could think of would be to use the Multiple Project option and then select the project within the app.  This would still be secure to just projects the user of the app has access to.
    I'll let you know when I hear more.
    Best regards,
    Brian
    Blog |
    Facebook | Twitter | Posting is provided "AS IS" with no warranties, and confers no rights.
    Project Server TechCenter |
    Project Developer Center |
    Project Server Help | Project Product Page

  • Syncronization of 2 USRP in Reception (master and slave)

    Hi,
    When I run "niUSRP EX Rx Finite Sync.vi " for the USRP slave device connected to the master via the MIMO cable. I set:
    Reference Frequency Source -> MIMO
    Timebase Clock Source -> MIMO
    I have the following error "niUSRP Initiate.vi <err> The PLL reference clock About did not lock Within the alloted time"
    Can you help to resolve this problem?
    Can you help me to synchronize two USRP in reception: one slave and the other is the master connected with MIMO cable?
    Thank you
    Solved!
    Go to Solution.
    Attachments:
    niUSRP EX Rx Finite Sync.vi ‏32 KB

    I set this parameters to the master device that is connected directly to my laptop and10 MHz generator and PPS generator::
    IPAdressMaster=192.168.10.2
    Reference Frequency Source -> RefIn
    Timebase Clock Source -> PpsIn
    -----> that's work
    However, when i tried with the slave device that is connected to the master via the MIMO cable :
    IPAdress=192.168.10.3
    Reference Frequency Source -> MIMO
    Timebase Clock Source -> MIMO
    -----> I have the error mentionned in my first message
    Where is the problemem?
    this exemple ("niUSRP EX Rx Finite Sync.vi " ) allow us to verify the good working of slave device?
    thank you

  • Master-Slave Problem: Please Help

    I am having a problem getting master/slave repositories set up for synchronization.
    My MDM server environment is Solaris with Oracle 10.2 database.
    MDM version is 5.5.41.58 (5.5 SP05).
    I create a repository. I unarchive my data into it. I create a slave repository from it. I go into Data Manager and change the description of one product in the master repository. In the Console, the server log has the following message:
    Master Server failed to log change because of error: The new transaction id is less than the last transaction id. (code 4289454080).
    Has anybody had the same issue? Any clues as to what the problem and/or fix is?
    Thanks in advance.

    Hello Simon,
    Thank you for taking the time to respond.
    The unarchive process involved the following: we have a production catalog running MDM 4.0.58. We had an SAP consultant assist in migrating our catalog to MDM 5.5 SP05. This was done using a local server running Windows and SQL Server. From the Windows MDM 5.5, I made an archive. I transferred it to the Solaris/Oracle environment. Using the Console I did the unarchive.
    One interesting thing to note: when MDM 5.5 SP05 was installed on Solaris, the "Modifications" directory was not created. Initial attempts to synchronize gave a different error. I determined that the directory was missing and had our data center admin create it. He then stopped the MDM server and restarted it. Then I deleted my master and slave repositories and started over. And then got the error referenced above.
    Running the CLIX command gives the following:
    52 for the master and 50 for the slave.
    In the server log, the only errors I see (other than the one about the transaction id's) are when starting the master and slave repositories I see:
    SERVICE 'xxx', SCHEMA 'yyy', ERROR CODE=1002 ||| ORA-01002: fetch out of sequence   Last CMD: SELECT PermanentId, Id, F153, F154, F163, F164, F353, F387, F414 FROM A2i_40
    In the assertion log, there is nothing at the time of creating the slave. When starting the slave, there are many messages relating to accelerators. At the time when I was changing the data in the master, there are messages from A2iIndexedTransactions.cpp (lines 647, 119, 96, and 231).
    If you need any more info, let me know.
    Thanks again for your help.

  • Dual spi device with one master and one slave on the PC end

    The powers that be want to emulate a hight speed RS-232 connection to an instrument we are building. We don't want to poll the instrument to see if it has data. They want the instrument to have both master and slave SPI busses so that it can push data to us.
    I need to find the PC hardware to do this that is compatable with LabView so I can test it. It doesn't have to be a single device. It could be two as long as one can be master and the other slave. We have the NI USB-8452 but it can't be slave.
    TIA  Norm
    Attachments:
    Dual SPI.png ‏26 KB

    Hi Viper
    You are right, the 8451 can only be configured as an SPI Master. For creating a slave you would have to choose an FPGA based solution. Depending on the hardware from NI that you currently have, you can choose from different FPGA cards or devices. I found some links that might help you with your search:
    Community: SPI Slave Device in FPGA
    White Paper: Implementing SPI Communication Protocol in LabVIEW FPGA
    Forums: Slave SPI product recomendation
    Forum: SPI in FPGA Multifunctional card discussion
    White Paper: SPI and LV basics (check section 7)
    Hope the information provided is helpful.
    WenR

  • How to make one Mac the "master", and the other Macs "secondary"?

    When using ISync to my DotMac account, and using three or four Macs all synching to one DotMac account, is it possible to designate one particular Mac to be the "most important" or "parent" Mac, and then all others, (laptops), be less important?
    I just want the Address Book on the main machine, the G5 Desktop, to always take precedence, and never get overwritten in any way, by a less refined Address Book on a laptop traveling machine.
    Thank you.

    iSync (or rather .Mac Sync is what you are referring to) does not work like that.
    There is no master and slave relationship in synchronising. All devices are equal and all devices sync their data to all other devices equally. That is what true synchronising is.
    What you are proposing is not synchronising - it is a simple copy and replace operation from one source, and the SyncServices framework is not designed for that.
    The whole point of synchronising is to get away from having a Master data source. You can change data on ANY device (Mac, phone or PDA) and the changes will be synced to all other devices.

  • 945P NEO and RAID problems

    This is my first time setting up a SATA raid system. Here is how i have the drives set up.
    IDE1- LiteOn Combo drive with jumper set to slave
    SATA1 - Seagate 80gig HD 300mb/s
    SATA2 - Seagate 80gig HD 300mb/s
    when i load up the CMOS it shows the LiteOn as the IDE Primary Slave and it shows the HD's as the IDE Third Master and Slave.
    Then i go to Integrated Peripherials > SATA Devices Configuration
    it wont let me access the Sata Mode; it appears like this
    x SATA MODE         [IDE]
    and i cant access to change it.
    I can change the On-Chip Serial ATA but cannot change the SATA MODE.
    My goal is to make a RAID 0 set up with the drives.

    No, this board does not support RAID. Only the Platinum boards support RAID. Sorry about that...
    Regarding the things claimed by the box, I'm not sure what can you do with it. I think this is MSI mistake, you can approach MSI Support and ask them to give you a reason or this, then you can decide what you need to do next, (going for legal?)
    Anyway, this board does not support RAID.

  • Master down and slave up

    Hi
    what if the master instance goes down and comes back? As the slave will be still up and running when the master becomes available will there be any synchronization problems?
    Help in finding the solution to this.
    Thanks in advance.
    Mahesh

    No. As soon as your master goes down your slave become master and when old master comes back it join as slave in cluster. See http://crxcluster.wemblog.com/ to understand cluster better.
    Yogesh

Maybe you are looking for

  • Older macbook won't boot up.  There is a flashing folder icon.

    How cani restart my older MacBook?  It is flashing a folder icon on startup.

  • Wna problem - pops up for username and password

    We have setup wna according to Oracle's document. But when try to access the portal home page, instead of auto login with the windows username and password, it pops up the login pop-up and ask to enter username and password. Anyone encounter this bef

  • How do I keep albums separate?

    I have an auto with a 12 GB hard drive as part of the music package. I am trying to download from a USB stick into the drive. I pull the songs from iTunes to the USB drive, then plug the drive into the car and download. It downloads, but the album se

  • How can I get back the Exact Duplicates menu item?

    All of a sudden, when I hold down the Option key and open the File Menu, I no longer get the item to show Exact Duplicates -- just plain Duplicates. I have no idea what's gone wrong! Does anyone have an idea how I can get Exact Duplicates back?

  • Fatal, unrecoverable error in FM and RH after spell-checking

    I have TCS 2.5. Last month, a few hours before our product release, I was spell-checking my RoboHelp HTML 8 project and had FrameMaker 9 open at the same time. Suddenly, Frame crashed with the dreaded internal error message, and I could not get it to