Jump to content

Grampa_of_Oliva_n_Eden

Members
  • Posts

    2,767
  • Joined

  • Last visited

  • Days Won

    17

Posts posted by Grampa_of_Oliva_n_Eden

  1. My users are in a medical development environment. Sometimes, they're a little paranoid about updating.

    Joe Z.

    My medical customers are in the same situation (da$# lawyers). I keep a seperate boot partition for each version of LV so I can "re-boot back in time" to the version their code was developed in. This is the only method that I havce found that allows me to freeze one version hile still allowing access to others.

    Just my 2 cents,

    Ben

  2. ...

    I've used a lot of state machines but never had the need to use one that was queue-driven. Or maybe just didn't know that's what I should have been using. tongue.gif

    Thanks for your input.

    I started a thread in the old version of LAVA asking if the day of the queue-driven SM was behind us. i was suprised to find how many people thought it was "the way to go". I have a project in-house that was developed (by the customer) and we maintain it. The case selector fills the screen from top to bottom. And between pushing to the front vs back of the queue makes it a real nightmare to maintain. For me, I'll stick with the flat versions were at least I can draw a diagram illustrating state transitions. I pefer to spead things out at let as much code as possible run in parallel and the QD-SM forces everything to wait in line.

    But I as I ack'd earlier, I am in the minority.

    Ben

  3. I tried to bundle by name several references to clusters of controls, but find that when I drop the reference into the cluster constant box on the block diagram, the reference is not recognized by visually changing the border of the cluster box. The reference cannot be dropped into the cluster, which to me is rather strange as I look at what I am trying to do as making a struct containing pointers and seems reasonable to me. I am trying to do this since my front panel contains several clusters each containing a number of controls, and I am not trying to mix controls and indicators. If I can do this then I can pass in just one parameter to a subVI that has to work with all these clusters of controls instead of the many more parameters that I would have to pass in if I do each cluster as a separate parameter.

    Any suggestions?

    In this Nugget I showed a method that allows you to quckly develop the cluster you need to bundle.

    http://forums.ni.com/ni/board/message?board.id=170&message.id=296427&query.id=813501#M296427

    Once you have created it, save it as a type-def as I described here.

    http://forums.ni.com/ni/board/message?board.id=170&message.id=233257#M233257

    Ben

  4. If I understand the question correctly, I think the best solution in this case is just to start the queued state machine that's handling the events in a separate thread. I presume you're calling the queued state machine inside the event case and it's blocking until it completes. If that's true, why not just handle the event case by putting the request on the state machine queue and returning immediately? Then the UI will be ready to handle any button clicks and pass the message on to the state machine thread - of course, I may have completely misunderstood the problem.

    At any rate, I find having more than one event structure on a UI to be a complete PITA. I think there's only one event queue (the real experts can weigh in here) so I find you have to carefully enable/disable controls because any control not handled by the currently active event loop that gets in the queue can cause the application to block forever - the event structure you hope will handle the event can't execute because the other event structure is waiting. This can be avoided and I know some people make this work, but every time I've tried it I've eventually found a better way.

    Mark

    This thread on the dark-side

    http://forums.ni.com/ni/board/message?board.id=170&message.id=245990#M245990

    is a very in-depth discusion of the event structure and who gets waht when and under what conditions. It is not lite reading but it digs into every hole we could think of.

    Ben

    • Like 1
  5. I don't play football or politics but I am a spectator for both.

    We sometimes hear of a medical doctor moving into politics but I have never heard of any engineers doing such (since Jimmy Carter of course).

    I (being an arogant science type) think it is because engineers and scientist are too smart to do that. What other reasons can you think of to exaplin why the brightest amoung us shy away from politics?

    Ben

  6. Hello, I want to programm a chat-client like ICQ or Skype. Is it possible to show both Text and Graphic (Smilye) in one control? Please don't suggest RTB, is there anything else?

    Thank you, Eugen

    have you concidered using an web browser in an ActiveX container?

    Ben

  7. Is there official NI terminology for the concept I called fully connected? What do you think should be the best term for the concept? Somehow it resembles mathematical concept of connected manifolds. Maybe reverse or inverse connected could be more clear. They somehow tell that input need not always terminate to output terminal but instead output terminal must always originate from input terminal.

    I can't say it has an official name but that wire pattern over-laps with the rules for working in-place. This thread on the Dark-side

    http://forums.ni.com/ni/board/message?board.id=170&view=by_date_ascending&message.id=191864#M191864

    includes posts by Greg McKaskle exaplaining how we can construct our diagrams such that sub-VI can work in the buffers of their callers. I have reviewed LVOOP code using that tidbit and LVOOP seems to be 100% consistant with that idea.

    Ben

  8. Do you think among G - 20 leaders are wise people capable to find a link between science and spirituality how I did it?

    http://news.yahoo.com/s/ap/20090924/ap_on_re_us/g20_summit_protests

    If they are not wise do you agree with me that they represent the 98 %( people at animal level) in theirs countries how I said long time ago?

    Each country has the leaders what they deserve.

    Hi alfa,

    I am probably alone in this thought but I'll say it anyway. I admire your persistance and bravery in speaking your mind. I hope that when the time comes I will be able to muster a fraction of your stength to do what has to be done.

    Ben

  9. I am generating final results as a popup VI front panel which allows the user to select the output result to view as an example they can switch between phase vs frequency and Gain vs frequency. Every thing happens dynamically based on the data set selected so that once the selection has been made a button can be pressed to print the VI front panel.

    To make the graph look best when printed out I prefer to have every thing white except the graph grid lines, outlines, scales, titles and the plot lines unfortunately because of the 3D effect of the graph there is no bottom and right hand graph outline which make the plot appear to not have printed correctly.

    post-11721-125621459503_thumb.jpg

    I have tried using a report VI and attaching the plot too but as far I can tell it takes an image of the front panel to achieve this so it has the same problem. I have not used the customise function much other than to define type def's so I dont know if it is possible to do this there.

    Any advice or help would be great.

    Many Thanks in advance,

    Neil.

    That is what you have to do. Just replace the frame with your own image that has a full frame.

    Ben

  10. Does not work!

    Mr.D. schedule

    Mon, WED 9:30- 10:30 , then work outside for 5 hrs, then go home

    TUE, THU 10:00 - 14:00, then go home

    FRI 9:30 - 11:30, then go home

    How can we go to drink after work???

    Set the clock on the PCs ahead 3 hours on Tues or Thurs.

    I was dead serious in my previous reply. Start by being honest with yourself about if you can continue doing his job plus yours and then honest with him that you are killing yourself etc trying do his work plus yours.

    Ben

  11. I think he said:

    "a monkey hitting keys at random on a typewriter keyboard for an infinite amount of time will almost surely type a given text, such as the complete works of William Shakespeare."

    Shaun expressed the idea much better than I. This idea goes beyond the monkey idea becasue an outside entity has to decide if the work is really Shakespeare while the nature of the newly cloned child will decide if it is a "rose" (viable code) or an ill formed bud (broken VI) and, Shakespeares' work need help to reproduce.

    Ben

  12. If you have read my previous stories (), here is the update

    Stupid's wife talked to me in front of stupid and another guy,

    Stupid's wife: GSR, you are working so hard and make "stupid" seem do nothing

    Me: I am working so hard, because I always make mistake, so I need to fix them ( frusty.gif I am too nice to her)

    Stupid's wife: Do you mean "stupid" does not work?

    Me: NoNoNo! I just mean he never makes mistake ( frusty.gif Right, he never, because he never work. OR I need to stand behind him when he works)

    TODAY

    My boss come to me and ask me just set up everytyhing for the "stupid" both building electronic hardware and programming. I say OK! But I have no clue why I need to help this guy. Should I just tell my boss that I really don't want help him because "stupid" has already said I am working so hard

    Please teach me what should I do

    "oh what a tngled web we weive when first we pratcie to decieve." (W. Shakespear?)

    1) Stop lying, you are making ot worse on yourself.

    2) Talk to Stupid and share your thought and feelings.

    3) Try talking to Stupid with a common person that you both respect.

    4) Talk to your boss.

    When you are doing your talking don't accuse or name call. Confess your short-coming and your concerns for Stupid.

    So speak the truth, and be honest with your feelings both in your internal dialog and your outward expresions.

    Ben

  13. I was not fully awake on Saturday AM when it hit me that scripting combined with LVOOP and a bat file (if you are on Windows) maybe enough to get some new life-forms developing on our machines.

    1) Bat files runs a Prime-mover.VI that is a member of a class Life-Form and exist.

    2) Prime-Mover Copies its project to a new loaction and using scripting generates a child class with random code and does this say 100 times for 100 possible children.

    3) A new bat file is generated for each of the children and are run before Prime-mover exits.

    All of the children that result in bad code will not run.

    Eventually a randomly generated VI will actullay run and then clone itself, and generate another generation of children etc.

    But the above just covers survives or does not survive.

    So if I modify the Prime-mover such that also evaluates the quality of itself (and by inheritance, itself) based on the number of Quality points it can earn by posting to LAVA,

    AND

    We give it an copy of the LV help to chew on...

    Would it still tell us the answer is 42?

    Ben

  14. "hard-core" and "hand bell" next to each other in a sentance?!?

    I used to be a stand-in member of a pealing group in my hometown of Orange, NSW. Guess what the group's name was...

    I would so pay to see that biggrin.gif

    That term sounded odd when I first heard from my wife but that is what they call themselves.

    Re: Groups name...

    I don't think even my wife would have figured that one out with have been spoon fed the "pealing" part.

    Ben

  15. The Sixth Dimension!

    Because sometimes, five just aren't enough.

    Has anyone been to a hard-core hand bell concert?

    The extreme ringers are very impresive. I heard an arangement of "The Navy Hymn" that sounded like the ocean. Soloists are amazing! Holding multiple bells in each hand and changing off as the melody shifts. It almost looks like musical juggling.

    Ben

  16. You're right. I haven't considered that the data needs to be shared between all instances.

    What you want aren't constants. You want variables which are written to the first time you use them. This is something I also want, but the problem is that I never figured out a good mechanism for this. Presumably, you want to get these values from a file, but you might also wish to get them from other places (DB, OS, etc.).

    If you can guarantee a single write, you can actually sort of do this today fairly easily - all you need to do is open a reference to the global VI at the init phase, get a reference to all the controls and then load values into them (e.g. using the config file VIs). You can flatten and unflatten all the values into strings, or use something like the OpenG VIs or the code you wrote to produce a human-readable file. The only problem with this is that there's no way to guarantee a single write and no way to guarantee that the write will occur before all reads.

    Alas, a lowly WORM Global is not enough. The read of a non-written WORM would have to hang, Timeout, or return an error (a WORM with a options?). Htat is too much scope creep for me.

    Ben

  17. First Call primitive can take care of that... just put all the code in a case structure that only executes if First Call is true. Thus even if multiple calls are made, the later calls are ignored. Does that solve the problem?

    From where I sit, yes, provided the developer knows that fact and uses the First Call. But a global by itself can have a problem. So returning to your orignial Q, a global by itself could be dangerous.

    Now on the other hand...

    If LVOOP only allowed us to use a NEW flavor of global maybe called a WORM (Write Once Read Many) Global, taht had the first call built in, I would stop pick at this idea. The other plus of the WORM Global is that I would be able stand behind Yair's age old idea of using Globals for defining constants.

    Ben

  18. Should I read into that statement that forking a queue reference makes a copy of the queue?

    I was refering to the wire that presents the data to the Enqueue node. AS I understand it (please correct anything I get wrong!).

    A queue can trasfer data "in-place". The bufer hold ing the data when it is queued is the same buffer that holds the data when it is dequeud. This is only possible if the buffer is not subject to change as in the case where a single wire feeds a queue but is used for something else that LV thinks could change it. In that case the forked wire creates a new buffer so the queue can transfer in-place and the other code can do whatever. So the fork in the queueing code move the work of copying the bufer to that thread.

    If you do not fork the wire, queue the data, then deque and fork to two additional queues (now I am getting carried away) the work of copying the buffer is now done in the recieving thread.

    Just sharing how I understand it.

    Feel free to correct me.

    Ben

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.